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. Help to Beginner..

Help to Beginner..

Scheduled Pinned Locked Moved Hardware
boardrc 8mhzsensor
10 Posts 4 Posters 6.7k Views 1 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.
  • D Offline
    D Offline
    dzairo
    wrote on last edited by
    #1

    Hi all .
    I'm beginner for Arduino and MySensor too..
    I searching any open-source star or mesh network with nRF24L01+ and find MySensor .
    It's look good .. then I try it ..

    Here is my sensor dev board ..
    IMAG1232.jpg
    and here is my schematic..
    SensorBoard1.png
    I try in my Serial Gateway this sketch: SerialGateway with internal 8Mhz RC oscilator .. in my serial port terminal set COM15 (my COM port) and set speed 115200 .. after power Up my gateway then I receive this :
    0;0;3;0;14;Gateway startup complete.

    Then to my sensor upload sketch : BinarySLeepSwitchSensor and powr up .. and in my terminal receive this :
    0;0;3;0;9;read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:255;255;3;0;3;
    But if push button for INT0 or INT1 still receive same data ..
    What is wrong ..
    Then I have this question:

    1. Where I can find more information about serial protocol ... what does mean data from gateway?
    2. I want run my sensor board with 32kHz crystal in TIMER2 ... where is any example .. Sleep and wake up every predefined time ..
    3. Is possible make network with more Repeater Node in serial .. for example gateway<->repeater1<->repeater2<->repeater3<->My Sensor
    4. Where I can find more informatioin about protocol .. if want make own code for sensor .. but not in arduino platform .. but for AVR Studio (GCC .. WinAVR) ..

    In my sensor use NTC temperature sensor and 32kHz crystal .. and my power consumption is 10uA ... TIMER2 is every 1sec wakeup.. Then I want make own code if is possible ..

    regards.

    1 Reply Last reply
    0
    • daulagariD Offline
      daulagariD Offline
      daulagari
      Hero Member
      wrote on last edited by
      #2

      On:

      Where I can find more information about serial protocol ... what does mean data from gateway?

      Have a look at http://www.mysensors.org/build/serial_api

      Where I can find more information about protocol .. if want make own code for sensor .. but not in arduino platform .. but for AVR Studio (GCC .. WinAVR) ..

      You can download and probably did download the source code from github so why don't you try to get that working on the AVR Studio?

      1 Reply Last reply
      0
      • K Offline
        K Offline
        kalle
        wrote on last edited by
        #3

        You will find the API/Sensor/Gateway info here:

        http://mysensors.org/build/sensor_api

        1 Reply Last reply
        0
        • D Offline
          D Offline
          dzairo
          wrote on last edited by
          #4

          Ehm.. I read this help but still can not decode string format..
          0;0;3;0;14;Gateway startup complete. in original serial communication example is 6 value in string : 12;6;0;0;3;1.4\n
          But I received only 5 ...
          and if received data : read: 255-255-0 s=255,c=3,t=3,pt=0,l=0:255;255;3;0;3;
          what is : 255-255-0 and : s=255,c=3,t=3,pt=0,l=0
          I don't find any place where can read what is it ..

          Pls answer here ... decode my serial data ..

          Ehm... if I push another button .. INT0 or INT1 still received same data .. where is problem..
          and I have connected LED to PD0 and PD1 (UART) .. and after power ON code inicialize UART and set output to PD1 (TX pin) how to disable this pin???

          regards.

          1 Reply Last reply
          0
          • daulagariD Offline
            daulagariD Offline
            daulagari
            Hero Member
            wrote on last edited by
            #5

            in original serial communication example is 6 value in string : 12;6;0;0;3;1.4\n
            But I received only 5 ...

            The 6th "value" is the payload, see Message Structure Elements at http://www.mysensors.org/build/serial_api, just like "Gateway startup complete." is the payload for the "0;0;3;0;14;Gateway startup complete. " message.

            node-id;child-sensor-id = 255;255 means something like broadcast. It is for example used for nodes that do not have an address yet.

            Lines starting with "read: " are strictly no protocol messages, they are debug output of the gateway.

            1 Reply Last reply
            0
            • D Offline
              D Offline
              dzairo
              wrote on last edited by
              #6

              Hi daulagari.
              Thanks for your help.
              Now little understand...
              But what is this :255-255-0 s=255,c=3,t=3,pt=0,l=0: this are just debug information?
              and this is my packet ? 255;255;3;0;3; still is only 5 argument .. where is 6-argument ? payload?
              what is s=255 , or c=3 , pt=0 , l=0 ... where I can finid more information about this ?

              thanks ... regards...

              PS: where I can find more inforation about structure of communication between sensor and gateway , repeater?

              1 Reply Last reply
              0
              • D Offline
                D Offline
                dzairo
                wrote on last edited by
                #7

                and ... still not answer why sensor don't send informatioin what button I pushed INT0 or INT1

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

                  @dzairo

                  and this is my packet ? 255;255;3;0;3; still is only 5 argument .. where is 6-argument ? payload?

                  that is the sensor node requesting an address. Either reply with 255;255;3;0;4;1, this instructs the node that it should use address 1. Or initialize the sensor framework in the sensor node with a hardcoded address (look at gw.begin in the documentation area)

                  If the node is not assigned an address, it will not send any other sensor data.

                  1 Reply Last reply
                  0
                  • daulagariD Offline
                    daulagariD Offline
                    daulagari
                    Hero Member
                    wrote on last edited by
                    #9

                    what is s=255 , or c=3 , pt=0 , l=0 ... where I can finid more information about this ?

                    AFAIK this is not documented somewhere .. apart from the source files.

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      dzairo
                      wrote on last edited by
                      #10

                      Hi.... hehe... I must decode it from source code?? hmmmm... interesting...
                      where I need to write my question?

                      1. power down mode .. every 1 sec wake up .. using timer2 32kHy crystal
                        2.make sensor with more sensor type in one device .. for example .. temperature , energy meter, bin input state.. etc..
                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      16

                      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