Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Hardware
  3. Second setup, choosing a radio

Second setup, choosing a radio

Scheduled Pinned Locked Moved Hardware
44 Posts 8 Posters 359 Views 8 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P projectMarvin

    Reading more it seems like OTA for these devices is not supported yet.
    @NeverDie @scalz Did you ever get OTA working on these boards?

    NeverDieN Offline
    NeverDieN Offline
    NeverDie
    Hero Member
    wrote on last edited by NeverDie
    #5

    @projectMarvin said in Second setup, choosing a radio:

    Reading more it seems like OTA for these devices is not supported yet.
    @NeverDie @scalz Did you ever get OTA working on these boards?

    Nope, not in C, but I did achieve OTA using micropython, uLisp, and Forth, because those 3 are interpreted. However, there may be more information available now on how to do OTA for it in C than there was when I last checked. With C it would require a wireless bootloader. Perhaps one or more of the nRF52 RTOS's would have it by now. It might (?) possibly even be a part of platform.io by now, though I'm doubtful.

    1 Reply Last reply
    1
    • P projectMarvin

      @Sasquatch Cool thanks!

      I'm really conflicted about what to choose.
      The nRF52s run cortex M4s, which I have worked a lot with.
      But I want OTA because I don't want to run around and manually upgrade each node. Then I will try to avoid it and end up running a lot of versions of each node.
      The rfm95 is a viable option, slightly more expensive but very good range. But as I understood it they are not very suitable for battery powered actuators, not sure why though.

      S Offline
      S Offline
      Sasquatch
      wrote on last edited by
      #6

      @projectMarvin
      nrf52 rx current is ~5mA - 480h on 2400mAh battery
      rfm69 rx current is 16mA - 150h same battery

      Both times rather pathetic, you never run battery powered node in constant rx mode.
      If you power down radio as often and for as long as possible you can get 5+ years out of both radios on single AA lithium thionyle battery and keep data flowing every minute or so. I suspect that on Nrf it might need less programming acrobacy.

      As for OTA, you should need to update your firmware only when security patches come out for library, once a year maybe?
      pulled from nrf52840 datasheet:

      The non-volatile memory controller (NVMC) is used for writing and erasing of the internal flash memory
      and the UICR (user information configuration registers).
      (...)
      The CPU must be halted before initiating a NVMC operation from the debug system.
      

      It looks to me that self programming is not possible. BUT i have never worked with tem (or any other M4) so what do i know ;)

      1 Reply Last reply
      0
      • P projectMarvin

        Reading more it seems like OTA for these devices is not supported yet.
        @NeverDie @scalz Did you ever get OTA working on these boards?

        berkseoB Offline
        berkseoB Offline
        berkseo
        wrote on last edited by
        #7

        @projectMarvin Most recently, I tried updating mysensors nodes on nrf52840 via nRF Conect (BLE). Incredibly fast.

        NeverDieN 1 Reply Last reply
        1
        • berkseoB berkseo

          @projectMarvin Most recently, I tried updating mysensors nodes on nrf52840 via nRF Conect (BLE). Incredibly fast.

          NeverDieN Offline
          NeverDieN Offline
          NeverDie
          Hero Member
          wrote on last edited by
          #8

          @berkseo said in Second setup, choosing a radio:

          @projectMarvin Most recently, I tried updating mysensors nodes on nrf52840 via nRF Conect (BLE). Incredibly fast.

          If you have step-by-step instructions on exactly how to do that, it would help just about everybody.

          berkseoB 1 Reply Last reply
          0
          • NeverDieN Offline
            NeverDieN Offline
            NeverDie
            Hero Member
            wrote on last edited by NeverDie
            #9

            It's a timely topic, as Nordic just 1 month ago appears to have published info on how to do OTA using their development kit: https://devzone.nordicsemi.com/nordic/short-range-guides/b/mesh-networks/posts/thread-tutorial-practical-guide-for-device-upgrade-ota

            Unfortunately, it seems like a different world entirely from the Sanjeev code, which doesn't utilize the Nordic Bluetooth devkit.

            I'm moderately hopeful that Adafruit may one day release a wireless bootloader that's more compatible with the Sanjeev code. However, there's a risk Adafruit would make it for CircuitPython instead.

            P 1 Reply Last reply
            0
            • NeverDieN Offline
              NeverDieN Offline
              NeverDie
              Hero Member
              wrote on last edited by
              #10

              It looks as though ARM MBED has FOTA working for the nRF51822:
              https://os.mbed.com/teams/Bluetooth-Low-Energy/wiki/Firmware-Over-the-Air-FOTA-Updates

              ARM MBED is the rtos that Arduino chose for its nRF52840 "nano" product offerings.

              1 Reply Last reply
              0
              • NeverDieN NeverDie

                @berkseo said in Second setup, choosing a radio:

                @projectMarvin Most recently, I tried updating mysensors nodes on nrf52840 via nRF Conect (BLE). Incredibly fast.

                If you have step-by-step instructions on exactly how to do that, it would help just about everybody.

                berkseoB Offline
                berkseoB Offline
                berkseo
                wrote on last edited by berkseo
                #11

                @NeverDie This is not a very convenient update process, although it is incredibly fast. You need to download the archive with the firmware to your phone. In the nRF Conect app, you will connect to a mysensors device that has previously been switched to bootloader mode (secure bootloader). Next, you need to choose the archive with the firmware and accept the download. This is a research interest rather than a working option :)

                1 Reply Last reply
                1
                • NeverDieN NeverDie

                  It's a timely topic, as Nordic just 1 month ago appears to have published info on how to do OTA using their development kit: https://devzone.nordicsemi.com/nordic/short-range-guides/b/mesh-networks/posts/thread-tutorial-practical-guide-for-device-upgrade-ota

                  Unfortunately, it seems like a different world entirely from the Sanjeev code, which doesn't utilize the Nordic Bluetooth devkit.

                  I'm moderately hopeful that Adafruit may one day release a wireless bootloader that's more compatible with the Sanjeev code. However, there's a risk Adafruit would make it for CircuitPython instead.

                  P Offline
                  P Offline
                  projectMarvin
                  wrote on last edited by
                  #12

                  @NeverDie How about this?
                  https://github.com/adafruit/Adafruit_nRF52_Bootloader
                  based on nrf5 sdk v11 though, current version is 17.

                  I had almost given up on mysensors and was considering the nrf52840 with openthread and mqtt-sn since nordic has working examples for that all the way from a mostly sleeping nrf52840 to an mqtt-sn - mqtt bridge.
                  I really like the nrf52840 and I want OTA since I know I will never leave my nodes alone and stop updating their codes :upside_down_face:
                  LoRa is problematic since I want something that is legal in both Sweden and China.

                  But mbed os shows promise and if the nano ble runs mbed on an nrf52840 then that should open a lot of doors.
                  Maybe this project will finally push me to adopt an RTOS :grin:

                  This sounds promising.
                  https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v17.0.0%2Fexamples_bootloader.html&cp=7_1_4_4

                  NeverDieN 1 Reply Last reply
                  1
                  • P projectMarvin

                    @NeverDie How about this?
                    https://github.com/adafruit/Adafruit_nRF52_Bootloader
                    based on nrf5 sdk v11 though, current version is 17.

                    I had almost given up on mysensors and was considering the nrf52840 with openthread and mqtt-sn since nordic has working examples for that all the way from a mostly sleeping nrf52840 to an mqtt-sn - mqtt bridge.
                    I really like the nrf52840 and I want OTA since I know I will never leave my nodes alone and stop updating their codes :upside_down_face:
                    LoRa is problematic since I want something that is legal in both Sweden and China.

                    But mbed os shows promise and if the nano ble runs mbed on an nrf52840 then that should open a lot of doors.
                    Maybe this project will finally push me to adopt an RTOS :grin:

                    This sounds promising.
                    https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_nrf5_v17.0.0%2Fexamples_bootloader.html&cp=7_1_4_4

                    NeverDieN Offline
                    NeverDieN Offline
                    NeverDie
                    Hero Member
                    wrote on last edited by NeverDie
                    #13

                    @projectMarvin said in Second setup, choosing a radio:

                    Looking at:

                    https://github.com/adafruit/Adafruit_nRF52_Bootloader

                    it does look as though there is a possible OTA mechanism:

                    DFU = LOW and FRST = LOW: Enter bootloader with OTA, to upgrade with a mobile application such as Nordic nrfConnect/Toolbox

                    but if it requies a mobile phone application... it sounds a bit inconvenient, similar to what berkseo was alluding to. Nordic's software efforts always seem to assume Bluetooth, which is frustrating, because the hardware itself obviously doesn't have to rely on Bluetooth per se.

                    However, at the bottom it does seem to give you the option of crafting your own bootloader, and so that might be a way to do it right:

                    How to compile and build

                    You should only continue if you are looking to develop bootloader for your own. You must have have a J-Link available to "unbrick" your device.

                    I get the impression amazon's FreeRTOS may (?) also offer a way to FOTA update an nRF52840.

                    I haven't looked into Thread, but the nRF52840 supposedly supports Thread, and maybe (?) by now Thread is mature enough to have FOTA.

                    P 1 Reply Last reply
                    0
                    • NeverDieN Offline
                      NeverDieN Offline
                      NeverDie
                      Hero Member
                      wrote on last edited by NeverDie
                      #14

                      From what I gather Particle had a FOTA for their nrf52840 modules, but they ruined it by making it a monthly paid subscription service. Too bad.

                      P 1 Reply Last reply
                      0
                      • NeverDieN NeverDie

                        @projectMarvin said in Second setup, choosing a radio:

                        Looking at:

                        https://github.com/adafruit/Adafruit_nRF52_Bootloader

                        it does look as though there is a possible OTA mechanism:

                        DFU = LOW and FRST = LOW: Enter bootloader with OTA, to upgrade with a mobile application such as Nordic nrfConnect/Toolbox

                        but if it requies a mobile phone application... it sounds a bit inconvenient, similar to what berkseo was alluding to. Nordic's software efforts always seem to assume Bluetooth, which is frustrating, because the hardware itself obviously doesn't have to rely on Bluetooth per se.

                        However, at the bottom it does seem to give you the option of crafting your own bootloader, and so that might be a way to do it right:

                        How to compile and build

                        You should only continue if you are looking to develop bootloader for your own. You must have have a J-Link available to "unbrick" your device.

                        I get the impression amazon's FreeRTOS may (?) also offer a way to FOTA update an nRF52840.

                        I haven't looked into Thread, but the nRF52840 supposedly supports Thread, and maybe (?) by now Thread is mature enough to have FOTA.

                        P Offline
                        P Offline
                        projectMarvin
                        wrote on last edited by
                        #15

                        @NeverDie Here is a nordic fota over thread example.
                        https://infocenter.nordicsemi.com/index.jsp?topic=%2Fsdk_tz_v4.1.0%2Fthread_example_dfu.html&cp=7_3_2_10_4_0
                        They also support using a dongle or DK with a raspberry as a border router.

                        Nordics documentation is fairly extensive and quite easy to search, I like it :)
                        The nrf52840 DK is kind of the standard example hardware for openthread so they have plenty of examples.

                        1 Reply Last reply
                        1
                        • NeverDieN NeverDie

                          From what I gather Particle had a FOTA for their nrf52840 modules, but they ruined it by making it a monthly paid subscription service. Too bad.

                          P Offline
                          P Offline
                          projectMarvin
                          wrote on last edited by
                          #16

                          @NeverDie I read something about that Particle discontinued their BLE mesh boards :/

                          NeverDieN 1 Reply Last reply
                          0
                          • P projectMarvin

                            @NeverDie I read something about that Particle discontinued their BLE mesh boards :/

                            NeverDieN Offline
                            NeverDieN Offline
                            NeverDie
                            Hero Member
                            wrote on last edited by
                            #17

                            @projectMarvin said in Second setup, choosing a radio:

                            @NeverDie I read something about that Particle discontinued their BLE mesh boards :/

                            At least in part. Hackaday says Particle discontinued their Xenons.

                            P 1 Reply Last reply
                            0
                            • NeverDieN NeverDie

                              @projectMarvin said in Second setup, choosing a radio:

                              @NeverDie I read something about that Particle discontinued their BLE mesh boards :/

                              At least in part. Hackaday says Particle discontinued their Xenons.

                              P Offline
                              P Offline
                              projectMarvin
                              wrote on last edited by
                              #18

                              @NeverDie said in Second setup, choosing a radio:

                              @projectMarvin said in Second setup, choosing a radio:

                              @NeverDie I read something about that Particle discontinued their BLE mesh boards :/

                              At least in part. Hackaday says Particle discontinued their Xenons.

                              https://blog.particle.io/mesh-deprecation/
                              :/

                              1 Reply Last reply
                              0
                              • scalzS Offline
                                scalzS Offline
                                scalz
                                Hardware Contributor
                                wrote on last edited by scalz
                                #19

                                @projectMarvin
                                indeed nrf52 + mysensors fota is not officially supported.
                                When I tried fota, I used nordic/Adafruit (secure) bootloader and derived it (because we used adafruit core + mysensors).
                                That was a while ago.. but actually I prefer and need subghz.
                                Unfortunately I'm working on others fun projects so I don't have time to work on nrf5 for the moment.

                                Sure using mobile app for fota is not convenient. better code a server-side app, micro service, for this task.

                                1 Reply Last reply
                                0
                                • P Offline
                                  P Offline
                                  projectMarvin
                                  wrote on last edited by
                                  #20

                                  So after spending some time reading on the forum I have kind of shifted toward rfm69 with a sensebender ethernet mqtt gateway.
                                  However this comes with new concerns.
                                  The only rfm69 frequency I can use is 433 MHz, which means huge antennas. Even coiled they are pretty big.
                                  Searching Taobao (chinese aliexpress) the rfm69 modules are quite uncommon and so I'm worried that they are already a bit aged.
                                  Also the majority of the ones listed are the C version with a different pinout than the version used by sensebender.
                                  The sensebender gateway is aging, it 5 years old with the last update 3 years ago.
                                  This is not negative, I'm just wondering if it's still a good gw for a new system or will it soon be considered old and lacking?

                                  I'm not sure what the development plan is for mysensors, will we keep using nrf24 and rfm forever or is there any plan to shift towards something newer?

                                  1 Reply Last reply
                                  0
                                  • scalzS Offline
                                    scalzS Offline
                                    scalz
                                    Hardware Contributor
                                    wrote on last edited by scalz
                                    #21

                                    @projectMarvin
                                    why can't you use other freq than 433?

                                    • Even if rfm69 is not very new, there are lot of choices on aliexpress for cheap with different variants( freq and footprints). RFM69 works great for longer range vs nrf24/52.

                                    • RFM69HCW variant is footprint compatible with RFM95W.

                                    • MySensors new driver is RFM69<->RFM95 communication compatible

                                    • RFM95 is more expensive, a bit more power efficient (especially in RX mode, but so far there is no listenmode in MySensors, so that's not a big detail)

                                    About the sensebender gw, I have one but actually I use my own gw designs (because I can). But I don't think SAMD mcu is "obsolete" for a good gw :)

                                    Personally I prefer an external gw (Serial or ethernet), than radio module directly connected to rpi.

                                    For the moment, afaik, MySensors plan is still the same, and might remain the same for quite a while I think: arduino, nrf24, rfm69/95.
                                    We (me especially) wanted to add others newer soc for subghz (like TI's) but it's not worth the effort, I'm too busy for supporting this.
                                    So it's easier for the team to support what we use.

                                    C 1 Reply Last reply
                                    1
                                    • NeverDieN Offline
                                      NeverDieN Offline
                                      NeverDie
                                      Hero Member
                                      wrote on last edited by NeverDie
                                      #22

                                      @scalz said in Second setup, choosing a radio:

                                      MySensors new driver is RFM69<->RFM95 communication compatible

                                      Good to hear! That potentially gives us the best of both worlds.

                                      On the cost front, the STM32WLE5 is the first single chip solution that has both an MCU and LoRa integrated onto a single die. What's interesting is that it appears to be priced lower than Semtech's standalone LoRa chips.

                                      So much depends on price. The Fanstel top-end nRF52840 modules have range that's comparable to an RFM69, but at better data rates. They're pricier than what most people want to pay though, so that has all but ruined the uptake rate.

                                      If Expressif were to offer a Wi-Fi 6 chip with WiFi-NOW capabilities, and which could sleep at ultra low power, then the promise of its gigabit speeds would be a game changer. Unfortunately, I'm not aware of any announced plans for them to do that.

                                      scalzS 1 Reply Last reply
                                      1
                                      • NeverDieN NeverDie

                                        @scalz said in Second setup, choosing a radio:

                                        MySensors new driver is RFM69<->RFM95 communication compatible

                                        Good to hear! That potentially gives us the best of both worlds.

                                        On the cost front, the STM32WLE5 is the first single chip solution that has both an MCU and LoRa integrated onto a single die. What's interesting is that it appears to be priced lower than Semtech's standalone LoRa chips.

                                        So much depends on price. The Fanstel top-end nRF52840 modules have range that's comparable to an RFM69, but at better data rates. They're pricier than what most people want to pay though, so that has all but ruined the uptake rate.

                                        If Expressif were to offer a Wi-Fi 6 chip with WiFi-NOW capabilities, and which could sleep at ultra low power, then the promise of its gigabit speeds would be a game changer. Unfortunately, I'm not aware of any announced plans for them to do that.

                                        scalzS Offline
                                        scalzS Offline
                                        scalz
                                        Hardware Contributor
                                        wrote on last edited by scalz
                                        #23

                                        @NeverDie
                                        There are others soc with LORA integrated, often with tiny footprints.

                                        I agree about nrf and bitrate. I have bt840xe on one of my gw, not sure if I would use one on a coincell node :)
                                        I mean nrf52840+external frontend is almost same rf power output as rfm69 at 13dB which would be a lot for a coincell, but rfm69 has better penetration and no potential coexistence problem with other protocol if using mysensors. Well, we are talking about differents beasts, depends on the usecase, there are pros&cons in both I think.

                                        Here, I'm quite happy with my cheap rfm69 modules, I get a very nice range, I don't need any repeater (a bit more than 2acres area, with nodes in different buildings and thick rock walls, metals obstacles etc).

                                        NeverDieN 1 Reply Last reply
                                        1
                                        • scalzS scalz

                                          @NeverDie
                                          There are others soc with LORA integrated, often with tiny footprints.

                                          I agree about nrf and bitrate. I have bt840xe on one of my gw, not sure if I would use one on a coincell node :)
                                          I mean nrf52840+external frontend is almost same rf power output as rfm69 at 13dB which would be a lot for a coincell, but rfm69 has better penetration and no potential coexistence problem with other protocol if using mysensors. Well, we are talking about differents beasts, depends on the usecase, there are pros&cons in both I think.

                                          Here, I'm quite happy with my cheap rfm69 modules, I get a very nice range, I don't need any repeater (a bit more than 2acres area, with nodes in different buildings and thick rock walls, metals obstacles etc).

                                          NeverDieN Offline
                                          NeverDieN Offline
                                          NeverDie
                                          Hero Member
                                          wrote on last edited by
                                          #24

                                          @scalz said in Second setup, choosing a radio:

                                          There are others soc with LORA integrated, often with tiny footprints.

                                          Who? I've tried googling this, and all I find is STMicroelectronics. The rest are all SiP rather than SOC as far as I can tell.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          9

                                          Online

                                          11.7k

                                          Users

                                          11.2k

                                          Topics

                                          113.0k

                                          Posts


                                          Copyright 2019 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • MySensors
                                          • OpenHardware.io
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular