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. Development
  3. Is my project possible with MySensors?

Is my project possible with MySensors?

Scheduled Pinned Locked Moved Development
14 Posts 7 Posters 3.9k Views 4 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.
  • pansenP pansen

    Hi,

    I think it is possible. However, in your special case I would rather implement something from the scratch since you do not really need MySensors here (except maybe for signing messages and the WebGUI but you said no controller so..).

    There are nrf24 libraries floating around in the web, probably also some signing functionality I would suppose.

    For sending messages to your network, I'd just put another arduino to the RPi and use the serial port.

    So answering your questions:

    • Implement yourself, for MySensors I don't know
    • See above. MySensors has some signing capabilties afaik
    • Datasheet p24 describes the "received power detector (RPD)" which in the end is a register that can be read out.

    Hope that helps

    F Offline
    F Offline
    frazzle
    wrote on last edited by
    #5

    Thanks for the answers!

    @pansen said in Is my project possible with MySensors?:

    Hi,

    I think it is possible. However, in your special case I would rather implement something from the scratch since you do not really need MySensors here (except maybe for signing messages and the WebGUI but you said no controller so..).

    There are nrf24 libraries floating around in the web, probably also some signing functionality I would suppose.

    For sending messages to your network, I'd just put another arduino to the RPi and use the serial port.

    So answering your questions:

    • Implement yourself, for MySensors I don't know
    • See above. MySensors has some signing capabilties afaik
    • Datasheet p24 describes the "received power detector (RPD)" which in the end is a register that can be read out.

    Hope that helps

    At the moment I don't really want to start something from scratch.

    @pjr said in Is my project possible with MySensors?:

    1. Yes you can. Take a look at serial api documentation. You need to implement "controller" software by yourself.
    2. Use signing. You can find more information from here
    3. Not really. nRF24 library support only check if signal => -64dBm or not.. see this
    4. It might be easier to use arduino as gw. See ACK functionality from documentation for resending the lost packages.
    1. Thanks, I'll have a look at that. Any other information about "writing your own controller"?
    2. Well that feature isn't that important, so guess I'm fine dropping it.
    3. Why would arduino be better as a gateway?

    @sundberg84 said in Is my project possible with MySensors?:

    @pjr what comes to my mind might be hard is using batteries to run nodes with relays. The nodes needs to be awake all the time not to miss any message on/off for the relay and that consumes power.

    Power consumption shouldn't be an issue as I'll use a big 12v battery and the wireless nodes are only used for short periods (propably not longer than 5 hours)

    pansenP 1 Reply Last reply
    0
    • F frazzle

      Thanks for the answers!

      @pansen said in Is my project possible with MySensors?:

      Hi,

      I think it is possible. However, in your special case I would rather implement something from the scratch since you do not really need MySensors here (except maybe for signing messages and the WebGUI but you said no controller so..).

      There are nrf24 libraries floating around in the web, probably also some signing functionality I would suppose.

      For sending messages to your network, I'd just put another arduino to the RPi and use the serial port.

      So answering your questions:

      • Implement yourself, for MySensors I don't know
      • See above. MySensors has some signing capabilties afaik
      • Datasheet p24 describes the "received power detector (RPD)" which in the end is a register that can be read out.

      Hope that helps

      At the moment I don't really want to start something from scratch.

      @pjr said in Is my project possible with MySensors?:

      1. Yes you can. Take a look at serial api documentation. You need to implement "controller" software by yourself.
      2. Use signing. You can find more information from here
      3. Not really. nRF24 library support only check if signal => -64dBm or not.. see this
      4. It might be easier to use arduino as gw. See ACK functionality from documentation for resending the lost packages.
      1. Thanks, I'll have a look at that. Any other information about "writing your own controller"?
      2. Well that feature isn't that important, so guess I'm fine dropping it.
      3. Why would arduino be better as a gateway?

      @sundberg84 said in Is my project possible with MySensors?:

      @pjr what comes to my mind might be hard is using batteries to run nodes with relays. The nodes needs to be awake all the time not to miss any message on/off for the relay and that consumes power.

      Power consumption shouldn't be an issue as I'll use a big 12v battery and the wireless nodes are only used for short periods (propably not longer than 5 hours)

      pansenP Offline
      pansenP Offline
      pansen
      wrote on last edited by
      #6

      @frazzle said in Is my project possible with MySensors?:

      Why would arduino be better as a gateway?

      If you connect the nrf24 via SPI it will be emulated as an ethernet gateway, and I assume it is more complicated than using a serial gateway (i.e. Arduino) which you directly send commands to, via ttyUSBx. No experience in that though, maybe it is worth to dig a bit more.

      Orange Pi Plus 2e connected to nrf24 PA via SPI running git-development MySensors gateway, OpenHAB2, mosquitto and MySQL persistence.

      1 Reply Last reply
      1
      • gohanG Offline
        gohanG Offline
        gohan
        Mod
        wrote on last edited by
        #7

        Using an Arduino as gateway is much easier than compiling the gateway in the rpi especially for troubleshooting if you are not expert

        1 Reply Last reply
        0
        • tbowmoT Offline
          tbowmoT Offline
          tbowmo
          Admin
          wrote on last edited by
          #8

          @frazzle

          If it's essential for your project to read out RSSI, then I suggest to use rfm69(h)w for radio, as they have an RSSI register that you can read.

          For the security, if you implement signing it will add a bit of latency in the loop, as the nodes has to exchange nonces before sending the actual data.

          RFM69 has a hardware encryption engine, so it can encrypt things on the fly (this is not the same as signing though, and can be subjectable to record / playback of transmissions)

          If you want to go with a "no hazzle" hardware solution with an external gateway, there is also the sensebender gateway.

          F 1 Reply Last reply
          2
          • tbowmoT tbowmo

            @frazzle

            If it's essential for your project to read out RSSI, then I suggest to use rfm69(h)w for radio, as they have an RSSI register that you can read.

            For the security, if you implement signing it will add a bit of latency in the loop, as the nodes has to exchange nonces before sending the actual data.

            RFM69 has a hardware encryption engine, so it can encrypt things on the fly (this is not the same as signing though, and can be subjectable to record / playback of transmissions)

            If you want to go with a "no hazzle" hardware solution with an external gateway, there is also the sensebender gateway.

            F Offline
            F Offline
            frazzle
            wrote on last edited by
            #9

            @tbowmo said in Is my project possible with MySensors?:

            @frazzle

            If it's essential for your project to read out RSSI, then I suggest to use rfm69(h)w for radio, as they have an RSSI register that you can read.

            For the security, if you implement signing it will add a bit of latency in the loop, as the nodes has to exchange nonces before sending the actual data.

            RFM69 has a hardware encryption engine, so it can encrypt things on the fly (this is not the same as signing though, and can be subjectable to record / playback of transmissions)

            If you want to go with a "no hazzle" hardware solution with an external gateway, there is also the sensebender gateway.

            It would be more of a gimmick than really needed (signal strength within 50m and line of sight should be no issue I think). But it's nice to know that the RFM69 offers that.

            Any information/statistics on how much signing affects RDT?

            Encryption is definitely not needed, but preventing replay attacks is. Doesn't need to be the most sophisticated thing in the world, but it should offer a reasonable amount of protection.

            1 Reply Last reply
            0
            • tbowmoT Offline
              tbowmoT Offline
              tbowmo
              Admin
              wrote on last edited by
              #10

              @frazzle

              Not using signing actively myself (yet), so can't help with any numbers there.. Someone else has to kick in with their experience..

              1 Reply Last reply
              0
              • AnticimexA Offline
                AnticimexA Offline
                Anticimex
                Contest Winner
                wrote on last edited by
                #11

                Message exchange with and without signing would look something like this:

                Scenario: No one require signing:
                Sending from node to GW:
                node->gw (message)

                Sending from GW to node:
                gw->node (message)

                Scenario: GW does not require signed messages, node does:
                Sending from node to GW:
                node->gw (message)

                Sending from GW to node:
                gw->node (nonce request)
                node->gw (nonce)
                gw->node (signed message)

                Scenario: GW require signed messages, node does as well:
                Sending from node to GW:
                node->gw (nonce request)
                gw->node (nonce)
                node->gw (signed message)

                Sending from GW to node:
                gw->node (nonce request)
                node->gw (nonce)
                gw->node (signed message)

                So, not counting calculation latencies, from a pure transmission point of view, a signed messages takes three times longer than a non signed message does due to handshaking.

                Do you feel secure today? No? Start requiring some signatures and feel better tomorrow ;)

                1 Reply Last reply
                4
                • P Offline
                  P Offline
                  pjr
                  wrote on last edited by
                  #12

                  @Anticimex
                  Have you measured or know someone who has or can you estimate how much the communication takes time with one "relay on" command for example?
                  1ms, 10ms or 100ms?

                  AnticimexA 1 Reply Last reply
                  0
                  • P pjr

                    @Anticimex
                    Have you measured or know someone who has or can you estimate how much the communication takes time with one "relay on" command for example?
                    1ms, 10ms or 100ms?

                    AnticimexA Offline
                    AnticimexA Offline
                    Anticimex
                    Contest Winner
                    wrote on last edited by
                    #13

                    @pjr
                    No. It depend on your HW and what frequency you execute with. So it will be quite specific to the setup, and that vary a lot between users.

                    Do you feel secure today? No? Start requiring some signatures and feel better tomorrow ;)

                    1 Reply Last reply
                    0
                    • F Offline
                      F Offline
                      frazzle
                      wrote on last edited by
                      #14

                      I'm rethinking my network layout right now and I was thinking if I could use an ESP8266 in AP mdoe (running a websocket server like: https://github.com/Links2004/arduinoWebSockets) as a serial gateway?
                      The description of the example code on the "Building a serial gateway" page says:

                      * DESCRIPTION
                      * The ArduinoGateway prints data received from sensors on the serial link.
                      * The gateway accepts input on seral which will be sent out on radio network.
                      

                      So could I just use Serial.write() to push my commands the esp8266 received from my smartphone on the websocket connection to serial, which will then be sent out to the nodes via radio?
                      In the other direction I would need to read data from the serial and push it to the smartphone via the websocket connection.

                      I was also thinking to just connect my phone to the gateway via usb and then make an app that sends commands to the gateway over serial, but a wireless connection would be so much nicer.

                      I'm probably gonna order some nrf24 module and some more arduinos on the weekend so I can tinker a bit with them as I'm new to radio stuff.

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


                      21

                      Online

                      11.7k

                      Users

                      11.2k

                      Topics

                      113.1k

                      Posts


                      Copyright 2025 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