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. My Project
  3. Starting with MySensors

Starting with MySensors

Scheduled Pinned Locked Moved My Project
startingnoobnewbie
9 Posts 4 Posters 2.6k 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.
  • S Offline
    S Offline
    siddmon
    wrote on last edited by
    #1

    Hi guys,

    Just started and finished my ESP8266MQTTClient, I still don't understand how all this works and I was wondering if there is any documentation or just a simple example like:
    Node - button - present it and send msg when button is pressed
    MQTTGateway - I don't know what goes into presentation or loop and haven't seen any examples for receive yet

    My guess is that I still need a controller which gets the information from the gateway but it's only a guess I haven't found any documentation yet on how to get started.

    Thanks, feel free to refer me to other posts if this was already answered

    mfalkviddM 1 Reply Last reply
    0
    • S siddmon

      Hi guys,

      Just started and finished my ESP8266MQTTClient, I still don't understand how all this works and I was wondering if there is any documentation or just a simple example like:
      Node - button - present it and send msg when button is pressed
      MQTTGateway - I don't know what goes into presentation or loop and haven't seen any examples for receive yet

      My guess is that I still need a controller which gets the information from the gateway but it's only a guess I haven't found any documentation yet on how to get started.

      Thanks, feel free to refer me to other posts if this was already answered

      mfalkviddM Offline
      mfalkviddM Offline
      mfalkvidd
      Mod
      wrote on last edited by
      #2

      @siddmon welcome to the MySensors community!

      The best place to start is the Getting started guide.

      The button example is available here: https://www.mysensors.org/build/binary

      1 Reply Last reply
      1
      • S Offline
        S Offline
        siddmon
        wrote on last edited by
        #3

        Thanks for the links, I got the gateway working (I think)

        ..0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        .pm open,type:2 0
        ...0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ............................................................................................................................0;255;3;0;9;TSF:MSG:READ,255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
        0;255;3;0;9;TSF:MSG:BC
        0;255;3;0;9;TSF:MSG:FPAR REQ,ID=255
        0;255;3;0;9;TSF:PNG:SEND,TO=0
        0;255;3;0;9;TSF:CKU:OK
        0;255;3;0;9;TSF:MSG:GWL OK
        0;255;3;0;9;TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=OK:0
        ...0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ............................................................................................................................0;255;3;0;9;TSF:MSG:READ,255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
        0;255;3;0;9;TSF:MSG:BC
        0;255;3;0;9;TSF:MSG:FPAR REQ,ID=255
        0;255;3;0;9;TSF:PNG:SEND,TO=0
        0;255;3;0;9;TSF:CKU:OK
        0;255;3;0;9;TSF:MSG:GWL OK
        0;255;3;0;9;TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=OK:0
        ..0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ....0;255;3;0;9;TSF:MSG:READ,255-255-0,s=255,c=3,t=3,pt=0,l=0,sg=0:
        ...............................
        

        I think that means it's receiving data from the other node.

        In my other node I have the following output, which I think is sending information correctly

        0 MCO:BGN:INIT NODE,CP=RNNNA--,VER=2.2.0-beta
        4 TSM:INIT
        4 TSF:WUR:MS=0
        11 TSM:INIT:TSP OK
        13 TSM:FPAR
        15 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
        823 TSF:MSG:READ,0-0-255,s=255,c=3,t=8,pt=1,l=1,sg=0:0
        828 TSF:MSG:FPAR OK,ID=0,D=1
        2023 TSM:FPAR:OK
        2024 TSM:ID
        2025 TSM:ID:REQ
        2028 TSF:MSG:SEND,255-255-0-0,s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=OK:
        4035 TSM:ID
        4036 TSM:ID:REQ
        4038 TSF:MSG:SEND,255-255-0-0,s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=OK:
        6046 TSM:ID
        6047 TSM:ID:REQ
        6049 TSF:MSG:SEND,255-255-0-0,s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=OK:
        8057 TSM:ID
        8058 TSM:ID:REQ
        8060 TSF:MSG:SEND,255-255-0-0,s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=OK:
        

        For the ESP8266MQTTClient, what IPs do I need to set?

        // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
        #define MY_IP_ADDRESS 192,168,1,5
        
        // If using static ip you need to define Gateway and Subnet address as well
        #define MY_IP_GATEWAY_ADDRESS 192,168,1,5  //This is the IP of my PC
        #define MY_IP_SUBNET_ADDRESS 255,255,255,0
        
        
        // MQTT broker ip address.
        #define MY_CONTROLLER_IP_ADDRESS 192, 168, 1, 88
        
        // The MQTT broker port to to open
        #define MY_PORT 1883
        

        From this code I think:
        MY_IP_ADDRESS - IP address of the gateway
        MY_IP_GATEWAY_ADDRESS - should this be the same as above?
        For connecting to Domoticz, do I need to what IP do I need to use? should it be port 1883 or something different?

        TIA

        1 Reply Last reply
        0
        • S Offline
          S Offline
          siddmon
          wrote on last edited by
          #4

          found this page which should help me get Domoticz configured

          https://www.domoticz.com/wiki/MySensors

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

            @siddmon
            For beginning domoticz is a good point to start with, also consider using ethernet gateway instead of mqtt as it is simpler than mqtt (al least until you are more familiar with everything)

            1 Reply Last reply
            0
            • S Offline
              S Offline
              siddmon
              wrote on last edited by
              #6

              @gohan, I'm so close now, I just need to make Domoticz to recognize my gw and the devices.

              I have verified that I get a message in the gw when toggling the switch in the node, so that part works :)

              Posted in their forums for help configuring Domoticz, I'm so close to have a working setup

              L gohanG 2 Replies Last reply
              0
              • S siddmon

                @gohan, I'm so close now, I just need to make Domoticz to recognize my gw and the devices.

                I have verified that I get a message in the gw when toggling the switch in the node, so that part works :)

                Posted in their forums for help configuring Domoticz, I'm so close to have a working setup

                L Offline
                L Offline
                LastSamurai
                Hardware Contributor
                wrote on last edited by
                #7

                @siddmon Whats the problem with domoticz and the gw? Should be very easy to setup. Here is a picture of my settings:
                0_1490808772283_upload-e4d4a00e-c7b8-43ed-8611-602ac5c6818a

                Just use the right topic names in your gw sketch. More infos on that here.

                1 Reply Last reply
                0
                • S siddmon

                  @gohan, I'm so close now, I just need to make Domoticz to recognize my gw and the devices.

                  I have verified that I get a message in the gw when toggling the switch in the node, so that part works :)

                  Posted in their forums for help configuring Domoticz, I'm so close to have a working setup

                  gohanG Offline
                  gohanG Offline
                  gohan
                  Mod
                  wrote on last edited by
                  #8

                  @siddmon remember to install beta version of Domoticz otherwise you will not get mysensors support

                  1 Reply Last reply
                  0
                  • S Offline
                    S Offline
                    siddmon
                    wrote on last edited by
                    #9

                    @LastSamurai Thanks for the image, I had the address as localhost instead of the IP of the raspberry PI, changed it and everything works now :)

                    @gohan , yes, I upgraded to beta version since release doesn't have MQTT support yet.

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


                    7

                    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