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. Announcements
  3. 💬 The Sensor Network

💬 The Sensor Network

Scheduled Pinned Locked Moved Announcements
46 Posts 11 Posters 2.9k Views 10 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.
  • zboblamontZ zboblamont

    @frydrik For a population of 500,000, say 200,000 customers, you are into commercial scale data gathering such as EON etc might deploy, a principal driver for the power companies fitting smart meters.
    I would have to guess in a city of the size you mention, smart meters are already in place...

    skywatchS Offline
    skywatchS Offline
    skywatch
    wrote on last edited by
    #29

    @zboblamont Absolutely - with hundreds of meters in properties, most of which will have wifi ap's, wifi cameras, bluetooth devices and microwave ovens then it's a really complex situation.

    1 Reply Last reply
    0
    • skywatchS skywatch

      @frydrik I think you need to spend more time with mysensors to appreciate it's strengths and weaknesses and from that experience decided if it is suitable for your needs.

      F Offline
      F Offline
      frydrik
      wrote on last edited by
      #30

      @skywatch Hello, I'm fascinated by the mysensors project, take off your hat in front of those who develop it, I'm not a programmer, that's why I can ask a lot of stupid questions, but otherwise you can't gain experience, I'm currently programming an arduino I use graphical programming I use a Russian application: flprog is very good for me, you can program an arduino with superficial programming knowledge. Now I'm trying to learn C ++ so I can clear up the code in arduino.

      skywatchS 1 Reply Last reply
      0
      • mfalkviddM mfalkvidd

        @frydrik said in 💬 The Sensor Network:

        @mfalkvidd thanks for the answer, but I have another question, why can't the number of nodes be increased to more than 254? Is it a hardware limitation or can these values be changed inside libraries?

        Because the MySensors library is designed that way, and because sending larger addresses will mean that messages must be shorter that what's currently supported.

        But MySensors is open source - anyone with enough skills, time and motivation can change it.

        F Offline
        F Offline
        frydrik
        wrote on last edited by
        #31

        @mfalkvidd Hello, can you help me understand, I use the example to read the data on an electric meter, but I have some problems,
        when I set PULSE_FACTOR with the one indicated on the meter I receive the wrong result, for me the meter has PULSE_FACTOR 5000 and I receive double V_VAR1 with the number of real pulses, that is if the number as ex. 10 pulses the node transmits in Gateway 20. if I set PULSE_FACTOR = with the one indicated on the counter I get a value double with the real one, in the sketch I set PULSE_FACTOR 2500 and now I get real kwh as on the counter, my question is why does V_VAR1 have such values?

        1 Reply Last reply
        0
        • F frydrik

          @skywatch Hello, I'm fascinated by the mysensors project, take off your hat in front of those who develop it, I'm not a programmer, that's why I can ask a lot of stupid questions, but otherwise you can't gain experience, I'm currently programming an arduino I use graphical programming I use a Russian application: flprog is very good for me, you can program an arduino with superficial programming knowledge. Now I'm trying to learn C ++ so I can clear up the code in arduino.

          skywatchS Offline
          skywatchS Offline
          skywatch
          wrote on last edited by skywatch
          #32

          @frydrik You don't really need to be a "C++ programmer" to use mysensors. There are a lot of examples that you can learnn from and modify to your needs.

          That said I am impressed that a Russian speaker is getting on with this in such a fast way. :)

          I hope I don't upset anyone with this, but I still think of mysensors as an amateur/home project.... A learning adventure if you think of it like that. I don't consider it a commercial ready application for large scale implementation.

          That is of course just my experience and opinion based on many years using it. Your opinion may be different to mine, but the only way to know is to learn, try, fail, develop and try again...... ;)

          F 1 Reply Last reply
          1
          • skywatchS skywatch

            @frydrik You don't really need to be a "C++ programmer" to use mysensors. There are a lot of examples that you can learnn from and modify to your needs.

            That said I am impressed that a Russian speaker is getting on with this in such a fast way. :)

            I hope I don't upset anyone with this, but I still think of mysensors as an amateur/home project.... A learning adventure if you think of it like that. I don't consider it a commercial ready application for large scale implementation.

            That is of course just my experience and opinion based on many years using it. Your opinion may be different to mine, but the only way to know is to learn, try, fail, develop and try again...... ;)

            F Offline
            F Offline
            frydrik
            wrote on last edited by
            #33

            @skywatch Hello, I am from the Republic of Moldova, I am a Romanian speaker, I also learned the Russian language, My country is the poorest country in Europe. I am also trying to implement this remote meter reading project as a pilot project, on my own account, I have no funding here, I have to implement it myself without any resources. so I can't say this is a commercial project

            skywatchS 1 Reply Last reply
            0
            • F frydrik

              @skywatch Hello, I am from the Republic of Moldova, I am a Romanian speaker, I also learned the Russian language, My country is the poorest country in Europe. I am also trying to implement this remote meter reading project as a pilot project, on my own account, I have no funding here, I have to implement it myself without any resources. so I can't say this is a commercial project

              skywatchS Offline
              skywatchS Offline
              skywatch
              wrote on last edited by
              #34

              @frydrik OK, so with no funding the only option is to educate yourself little-by-little.

              Build a small test system and keep trying it in new locations to see how it goes. Learning by doing is the best and quickest way I think.

              Have you considered that signals might be hacked, spoofed or jammed? How will you mitigate such things?

              What you want to do may seem simple at first, but there is a lot to think about with such big ambitions.

              There is no easy short cut - try things for yourself and if you have problems then post them here and I am sure many people will try and help you.

              F 1 Reply Last reply
              0
              • skywatchS skywatch

                @frydrik OK, so with no funding the only option is to educate yourself little-by-little.

                Build a small test system and keep trying it in new locations to see how it goes. Learning by doing is the best and quickest way I think.

                Have you considered that signals might be hacked, spoofed or jammed? How will you mitigate such things?

                What you want to do may seem simple at first, but there is a lot to think about with such big ambitions.

                There is no easy short cut - try things for yourself and if you have problems then post them here and I am sure many people will try and help you.

                F Offline
                F Offline
                frydrik
                wrote on last edited by
                #35

                @skywatch Hi, thank you very much for the encouragement, I will try to document the steps I did with pictures with schemes, but I will also think about security.

                1 Reply Last reply
                0
                • skywatchS Offline
                  skywatchS Offline
                  skywatch
                  wrote on last edited by skywatch
                  #36

                  @frydrik My approach would be to make one gateway and one node only. It will simplify testing and speed it up a lot!

                  Decide which bootloader you will use and why (the below list will impact that decision).

                  Learn how to burn a bootloader and when successful move on to....

                  Get the code working.

                  Then add soft or hard signing to messages if you think you need to.
                  Then add encryption to messages if you think you need to.
                  Then add wireless firmware updates (FOTA) if you think you need to.

                  Then, when you have it all as you want it is easy to duplicate it very quickly to lots of nodes. And test again.

                  Also I suggest manually assigning node ID's as when power goes off they will all come back with the same ID, not randomly assigned ones.

                  Always save a modified sketch with a new name or verison so if things don't go well you can go back to the last working version.

                  It is very likely that you will hit many obsticals along the way. You need to remain focused and determined to do what you want. Be warned that it's going to take some time.

                  F 1 Reply Last reply
                  0
                  • skywatchS skywatch

                    @frydrik My approach would be to make one gateway and one node only. It will simplify testing and speed it up a lot!

                    Decide which bootloader you will use and why (the below list will impact that decision).

                    Learn how to burn a bootloader and when successful move on to....

                    Get the code working.

                    Then add soft or hard signing to messages if you think you need to.
                    Then add encryption to messages if you think you need to.
                    Then add wireless firmware updates (FOTA) if you think you need to.

                    Then, when you have it all as you want it is easy to duplicate it very quickly to lots of nodes. And test again.

                    Also I suggest manually assigning node ID's as when power goes off they will all come back with the same ID, not randomly assigned ones.

                    Always save a modified sketch with a new name or verison so if things don't go well you can go back to the last working version.

                    It is very likely that you will hit many obsticals along the way. You need to remain focused and determined to do what you want. Be warned that it's going to take some time.

                    F Offline
                    F Offline
                    frydrik
                    wrote on last edited by frydrik
                    #37

                    @skywatch
                    Hi, now I do, I have 1 gate and 3 nodes, I have already connected 1 node to a test meter, now I choose the same data that is displayed on the meter screen and MYCONTROLLER, node ID I install it manually, now I want to test at what maximum distance can the connection between the gate and the node be made, the gate is made on TTGO LoRa32 SX1276 OLED and the test node also TTGO LoRa32 SX1276 OLED, the other 2 nodes are nodemcu esp8266 + RFM95, they have standard antennas that do not inspire me much confidence , I want to try to build other antennas to see the difference between the standard antenna and the one I made, then I want to solve the problem with bootloader for FOTA, I think to create the nodes from nodemcu esp8266 + RFM95 because I want to connect to a node several counters from 2-6-8, because arduino Pro Mini / Nano no more than 2 interrupts esp8266 all gpio can be as interrupt, here I think how to do bootloader for FOTA.!!
                    my test stand:
                    P01019-092719.jpg

                    1 Reply Last reply
                    0
                    • RagoTubeR Offline
                      RagoTubeR Offline
                      RagoTube
                      wrote on last edited by
                      #38

                      Hi friends, in the above "The Radio Communication" topic I see these lines "You can also send messages directly between two nodes in the network without transiting through the gateway. For example, your outside temperature sensor can send its data directly to another sensor in your kitchen with an attached display."
                      This is what I am struggling to achieve , please help me with an Example Sketch for both sender and receiver for the above setup and it will be a great start for me to explore the excellent features of MySensors IoT.

                      J 1 Reply Last reply
                      0
                      • RagoTubeR RagoTube

                        Hi friends, in the above "The Radio Communication" topic I see these lines "You can also send messages directly between two nodes in the network without transiting through the gateway. For example, your outside temperature sensor can send its data directly to another sensor in your kitchen with an attached display."
                        This is what I am struggling to achieve , please help me with an Example Sketch for both sender and receiver for the above setup and it will be a great start for me to explore the excellent features of MySensors IoT.

                        J Offline
                        J Offline
                        jkandasa
                        Plugin Developer
                        wrote on last edited by
                        #39

                        @RagoTube examples are there in,

                        • https://github.com/mysensors/MySensors/tree/development/examples
                        • https://github.com/mysensors/MySensorsArduinoExamples

                        The following sketch can help you to get your setup,
                        https://github.com/mysensors/MySensors/blob/development/examples/Node2Node/Node2Node.ino

                        RagoTubeR 1 Reply Last reply
                        1
                        • J jkandasa

                          @RagoTube examples are there in,

                          • https://github.com/mysensors/MySensors/tree/development/examples
                          • https://github.com/mysensors/MySensorsArduinoExamples

                          The following sketch can help you to get your setup,
                          https://github.com/mysensors/MySensors/blob/development/examples/Node2Node/Node2Node.ino

                          RagoTubeR Offline
                          RagoTubeR Offline
                          RagoTube
                          wrote on last edited by
                          #40

                          @jkandasa Hi, thank you, I am a newbie, please advice what are the changes to be done to use Node2Node, to receive data from a sender and display on a LCD or OLED please. I am finding difficult only on the Receiver side, please help.
                          With Great Regards,

                          J 1 Reply Last reply
                          0
                          • RagoTubeR RagoTube

                            @jkandasa Hi, thank you, I am a newbie, please advice what are the changes to be done to use Node2Node, to receive data from a sender and display on a LCD or OLED please. I am finding difficult only on the Receiver side, please help.
                            With Great Regards,

                            J Offline
                            J Offline
                            jkandasa
                            Plugin Developer
                            wrote on last edited by jkandasa
                            #41

                            @RagoTube
                            Note: I didn't test this code. I believe it should work.

                            Sender node

                            #define MY_DEBUG
                            #define MY_RADIO_RF24
                            #define MY_NODE_ID 21
                            
                            #define DISPLAY_NODE_ID 0
                            
                            #define TEMPERATURE_SENSOR_ID 0
                            
                            #include "MySensors.h"
                            
                            // triggering interval
                            static const uint32_t trigger_ms = 10000; // 10 seconds
                            
                            uint32_t lastTrigger = 0;
                            MyMessage msgGeneral(TEMPERATURE_SENSOR_ID, V_TEMP);
                            
                            void setup() {
                            }
                            
                            void presentation() {
                              sendSketchInfo("Temperature node 1", "1.0");
                              present(TEMPERATURE_SENSOR_ID, S_TEMP, "Temperature");
                            }
                            
                            void loop() {
                              if (millis() - lastTrigger > trigger_ms) {
                                lastTrigger = millis();
                                // set destination address
                                msgGeneral.setDestination(DISPLAY_NODE_ID);
                                
                                // get temperature from your temperature sensor
                                float lastTemperature = 0.0; // update from your sensor
                            
                                // send message to display node
                                send(msgGeneral.set(lastTemperature));
                              }
                            }
                            

                            Display node (Gateway node)

                            #define MY_DEBUG
                            #define MY_RADIO_RF24
                            #define MY_GATEWAY_SERIAL
                            
                            #define TEMPERATURE_SENSOR_ID 0
                            #define TEMPERATURE_NODE_ID 21
                            
                            #include "MySensors.h"
                            
                            float lastTemperature = 0.0;
                            
                            void presentation() {
                              sendSketchInfo("Display node / Gateway", "1.0");
                            }
                            
                            void setup() {
                            }
                            
                            void loop() {
                            }
                            
                            void updateDisplay() {
                              // update your display with "lastTemperature"
                            }
                            
                            void receive(const MyMessage &message) {
                              if (message.sender == TEMPERATURE_NODE_ID) { // message from temperature node
                                if (message.sensor == TEMPERATURE_SENSOR_ID && message.type == V_TEMP) { // message from temperature sensor
                                  lastTemperature = message.getFloat();
                                  updateDisplay(); // update display
                                }
                              }
                            }
                            
                            1 Reply Last reply
                            0
                            • RagoTubeR Offline
                              RagoTubeR Offline
                              RagoTube
                              wrote on last edited by
                              #42

                              Thank you so much and very kind of you. I will try this.

                              1 Reply Last reply
                              0
                              • RagoTubeR Offline
                                RagoTubeR Offline
                                RagoTube
                                wrote on last edited by
                                #43

                                Hai jkandasa, It works fine, thank you so much for your examples and it cleared lot my doubts. Thanks again, you have given me good start.

                                1 Reply Last reply
                                1
                                • RagoTubeR Offline
                                  RagoTubeR Offline
                                  RagoTube
                                  wrote on last edited by
                                  #44

                                  Hi, I missed to notice that, it works as long as the Gateway is ON, when I turn off the Gateway it stops receiving the data. I assumed that your example "Node2Node" code will work with out a Gateway in between. Please advice.

                                  J 1 Reply Last reply
                                  0
                                  • RagoTubeR RagoTube

                                    Hi, I missed to notice that, it works as long as the Gateway is ON, when I turn off the Gateway it stops receiving the data. I assumed that your example "Node2Node" code will work with out a Gateway in between. Please advice.

                                    J Offline
                                    J Offline
                                    jkandasa
                                    Plugin Developer
                                    wrote on last edited by jkandasa
                                    #45

                                    @RagoTube looks like we need a gateway in a sensor network and with the help of gateway node-node communication can happen. The beauty of MySensors gateway is, you can use your gateway as a node.
                                    I just updated my example shown here. Now the display node is a gateway node.

                                    1 Reply Last reply
                                    0
                                    • RagoTubeR Offline
                                      RagoTubeR Offline
                                      RagoTube
                                      wrote on last edited by
                                      #46

                                      Thanks again for your immediate advice. It should be OK now.

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


                                      12

                                      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