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. Parameters and settings

Parameters and settings

Scheduled Pinned Locked Moved Development
10 Posts 5 Posters 2.6k Views 5 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.
  • stefaanvS Offline
    stefaanvS Offline
    stefaanv
    wrote on last edited by
    #1

    Hi,

    I'd like to write settings/parameters to my chicken shed sensor/actuator node. For instance lux level settings, sunset and sundown time, light activation time, etc.
    Has anyone done something similar ? If so, what MySensors mechanism did you use ?
    Do you think there is a need for a specific mechanism to send settings to nodes ?

    Stefaan

    mfalkviddM 1 Reply Last reply
    1
    • P Offline
      P Offline
      pjr
      wrote on last edited by
      #2

      I think normally the controller has all the logic and node behaves more like a sensor/actuator device... but :)

      You could publish fake sensors what you can use at controller level to send information to sensor and handle those on message received.
      Some controllers might already support V_HVAC_SETPOINT_HEAT and V_TEXT setting from UI.

      Time setpoint sensors would be what you need but it does not exist.

      stefaanvS 1 Reply Last reply
      0
      • stefaanvS stefaanv

        Hi,

        I'd like to write settings/parameters to my chicken shed sensor/actuator node. For instance lux level settings, sunset and sundown time, light activation time, etc.
        Has anyone done something similar ? If so, what MySensors mechanism did you use ?
        Do you think there is a need for a specific mechanism to send settings to nodes ?

        Stefaan

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

        @stefaanv https://www.mysensors.org/build/scene_controller has an example for a node that sets variables, maybe you can use that as a base?

        stefaanvS 1 Reply Last reply
        0
        • vorowskiV Offline
          vorowskiV Offline
          vorowski
          wrote on last edited by
          #4

          I usually get parameters from gateway during startup - then you can influence certain values through gateway and no need to change sketch.....

          1 Reply Last reply
          0
          • sundberg84S Offline
            sundberg84S Offline
            sundberg84
            Hardware Contributor
            wrote on last edited by
            #5

            As someone said, im using the login in the controller for this.
            A lux sensor is reporting to the controller (Domoticz), which also keeps track on sunset/sundown.
            I can use LUA code and script events dependent on lux/sun.

            For example turning my windowlights on when lux < 30:

            commandArray = {}
            v = tonumber(otherdevices_svalues['Outsidelight'])
            
            f  (v <= 30) then
             commandArray['Group:Windowlights']='On'
            end
            
            return commandArray
            

            Controller: Proxmox VM - Home Assistant
            MySensors GW: Arduino Uno - W5100 Ethernet, Gw Shield Nrf24l01+ 2,4Ghz
            MySensors GW: Arduino Uno - Gw Shield RFM69, 433mhz
            RFLink GW - Arduino Mega + RFLink Shield, 433mhz

            stefaanvS 1 Reply Last reply
            0
            • sundberg84S sundberg84

              As someone said, im using the login in the controller for this.
              A lux sensor is reporting to the controller (Domoticz), which also keeps track on sunset/sundown.
              I can use LUA code and script events dependent on lux/sun.

              For example turning my windowlights on when lux < 30:

              commandArray = {}
              v = tonumber(otherdevices_svalues['Outsidelight'])
              
              f  (v <= 30) then
               commandArray['Group:Windowlights']='On'
              end
              
              return commandArray
              
              stefaanvS Offline
              stefaanvS Offline
              stefaanv
              wrote on last edited by
              #6

              @sundberg84, @pjr
              I prefer to have basic automation in the sensor/actuator combination itself. then if the controller is off-line, the chickens still survive.
              Since my controller is a mix of test/production environment it is nog uncommon for it fail. One common thing is that USB ports change names after reboot in which can both the MySensors and the RfxCom devices stop communicating.

              1 Reply Last reply
              1
              • mfalkviddM mfalkvidd

                @stefaanv https://www.mysensors.org/build/scene_controller has an example for a node that sets variables, maybe you can use that as a base?

                stefaanvS Offline
                stefaanvS Offline
                stefaanv
                wrote on last edited by
                #7

                @mfalkvidd
                Nope, what I need is variables being set from the controller so that they can be updated/changed without changing the sketch. The scene controller does not do that.

                mfalkviddM 1 Reply Last reply
                0
                • P Offline
                  P Offline
                  pjr
                  wrote on last edited by
                  #8

                  Hmm. Could this be (ab)used somehow?
                  https://www.mysensors.org/download/sensor_api_20#requesting-data

                  1 Reply Last reply
                  0
                  • stefaanvS stefaanv

                    @mfalkvidd
                    Nope, what I need is variables being set from the controller so that they can be updated/changed without changing the sketch. The scene controller does not do that.

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

                    @stefaanv then it seems what you need seems to be standard functionality for any controller, and standard functionality for MySensors.

                    The first dimmer example ( https://www.mysensors.org/build/dimmer ) requests the value from the controller in setup().
                    Another example is https://www.mysensors.org/build/pulse_power

                    The dimmer uses a value that can be 0-100. There are other data types. V_TEXT can be used for custom variable types that aren't supported natively by MySensors and the controller.

                    1 Reply Last reply
                    0
                    • P pjr

                      I think normally the controller has all the logic and node behaves more like a sensor/actuator device... but :)

                      You could publish fake sensors what you can use at controller level to send information to sensor and handle those on message received.
                      Some controllers might already support V_HVAC_SETPOINT_HEAT and V_TEXT setting from UI.

                      Time setpoint sensors would be what you need but it does not exist.

                      stefaanvS Offline
                      stefaanvS Offline
                      stefaanv
                      wrote on last edited by
                      #10

                      @pjr
                      V_HVAC_SETPOINT_HEAT comes closest to what I need but is still related to the sensor/actuator variable that is being controlled. I also need to send parameters that are totally unrelated to any of the sensor/actuator variables. This could f.i. be the cycle time of the measurements, whether or not sleep mode is used, ...
                      I launched a feature request in meantime.

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


                      19

                      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