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. General Discussion
  3. Why I quit using MySensors for actuators

Why I quit using MySensors for actuators

Scheduled Pinned Locked Moved General Discussion
55 Posts 19 Posters 13.1k Views 25 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.
  • Sergio RiusS Sergio Rius

    @NeverDie it doesn't have any physical button. It's always actuated through the controller.
    Also the door motor is on a completely separated circuit. Has its own PSU (ac) and it's independently activated with relays through opto-isolators.
    It cuts motor power when it's not used.

    Don't miss understand, is working very well. I only presented it as an example for an actuator that was giving trouble but that was made to work.

    NeverDieN Offline
    NeverDieN Offline
    NeverDie
    Hero Member
    wrote on last edited by NeverDie
    #46

    @Sergio-Rius said in Why I quit using MySensors for actuators:

    independently activated with relays through opto-isolators

    If I'm not mistaken, relay contacts can bounce too, just like a button. Well, anyway, just water under the bridge at this point it sounds like.

    Sergio RiusS 1 Reply Last reply
    0
    • Sergio RiusS Sergio Rius

      @korvad The sketch is a mess and I'm sure what I'm doing with 4 relays could be made with only two, but the changes I incorporated where basically:

      void loop() {
        refreshStatus();
      
        // Don't do anything else during movement
        if (CurrentStatus == GOINGUP || CurrentStatus == GOINGDOWN) return;
      ...
      

      And in receive:

      void receive(const MyMessage &message) {
        static uint32_t next_cmd = 0;
        switch (message.type) {
        case V_STATUS:
          if (message.sensor == CHILD_ID_TOGGLE) {
      #ifdef _DEBUG
            DEBUGPLN("*** RECEIVED TOGGLE *************************");
      #endif
            // Avoid controller command echoes.
            const uint32_t now = millis();
            if (PENDING(now, next_cmd)) {
      #ifdef _DEBUG
              DEBUGPLN("Too much commands in a short while! Ignoring.");
      #endif
              return;
            }
            next_cmd = now + MIN_RX_INTERVAL;
      ...
      
      K Offline
      K Offline
      korvad
      wrote on last edited by
      #47

      @Sergio-Rius thx, will try to adapt your sketch to my needs.

      1 Reply Last reply
      0
      • NeverDieN NeverDie

        @Sergio-Rius said in Why I quit using MySensors for actuators:

        independently activated with relays through opto-isolators

        If I'm not mistaken, relay contacts can bounce too, just like a button. Well, anyway, just water under the bridge at this point it sounds like.

        Sergio RiusS Offline
        Sergio RiusS Offline
        Sergio Rius
        wrote on last edited by
        #48

        @NeverDie As the relays only activate the main motor power supply and controls start&stop and direction, bouncing is not a problem.
        Perhaps you where thinking on an arduino actuating the door mechanism button?

        1 Reply Last reply
        0
        • alowhumA Offline
          alowhumA Offline
          alowhum
          Plugin Developer
          wrote on last edited by
          #49

          @dakipro said in Why I quit using MySensors for actuators:

          I understand the principle, number of sent packets should match number of received ones per node :)
          I thought it was perhaps already implemented on node/gateway level. I guess one could always send Text or some custom label and handle it in controller, but having it integrated in gateway itself would be awesome :)

          wait, what?

          I thought MySensors already implemented this! It doesn't?

          I want to use mysensors to turn a heater on and off. That's serious stuff. I thought MySensors went beyond 433 stuff because if made sure that messages arrived?

          Nca78N 1 Reply Last reply
          1
          • alowhumA alowhum

            @dakipro said in Why I quit using MySensors for actuators:

            I understand the principle, number of sent packets should match number of received ones per node :)
            I thought it was perhaps already implemented on node/gateway level. I guess one could always send Text or some custom label and handle it in controller, but having it integrated in gateway itself would be awesome :)

            wait, what?

            I thought MySensors already implemented this! It doesn't?

            I want to use mysensors to turn a heater on and off. That's serious stuff. I thought MySensors went beyond 433 stuff because if made sure that messages arrived?

            Nca78N Offline
            Nca78N Offline
            Nca78
            Hardware Contributor
            wrote on last edited by
            #50

            @alowhum if you use ACK you know if message arrived or not. MySensors will resend message a few times if it fails (there's a #define for this I think) but not forever. If it's critical you can handle the false when it's returned in your code and resend the message after a little delay, and send yourself a warning/alert in the end if the node is unreachable).

            alowhumA 1 Reply Last reply
            2
            • Nca78N Nca78

              @alowhum if you use ACK you know if message arrived or not. MySensors will resend message a few times if it fails (there's a #define for this I think) but not forever. If it's critical you can handle the false when it's returned in your code and resend the message after a little delay, and send yourself a warning/alert in the end if the node is unreachable).

              alowhumA Offline
              alowhumA Offline
              alowhum
              Plugin Developer
              wrote on last edited by
              #51

              @nca78 Thanks for the explananation! Do you perhaps know of an example sketch that has good example code for this? I haven't come accross it.

              Nca78N 1 Reply Last reply
              2
              • alowhumA alowhum

                @nca78 Thanks for the explananation! Do you perhaps know of an example sketch that has good example code for this? I haven't come accross it.

                Nca78N Offline
                Nca78N Offline
                Nca78
                Hardware Contributor
                wrote on last edited by
                #52

                @alowhum I made a test with the scipt of a remote control switch. I will look for it but it's really not some advanced programming :)

                alowhumA 1 Reply Last reply
                1
                • Nca78N Nca78

                  @alowhum I made a test with the scipt of a remote control switch. I will look for it but it's really not some advanced programming :)

                  alowhumA Offline
                  alowhumA Offline
                  alowhum
                  Plugin Developer
                  wrote on last edited by
                  #53

                  @nca78 Well, anything is helpful! Thanks!

                  1 Reply Last reply
                  0
                  • JohnRobJ Offline
                    JohnRobJ Offline
                    JohnRob
                    wrote on last edited by
                    #54

                    Hi, I know I'm a little late to this thread. I'm just starting with MySensors and am learning by reading the posts.

                    Currently I am waiting for hardware for my 1st gateway so I am not encumbered by details.

                    I notice in all the reported cases the "problem" node is AC powered, while many of the "good" sensor nodes are battery powered. Could this be significant? It would be interesting if someone with a "problem" actuator node could put a battery operated sensor node in the same area.

                    Just a thought.

                    Nca78N 1 Reply Last reply
                    0
                    • JohnRobJ JohnRob

                      Hi, I know I'm a little late to this thread. I'm just starting with MySensors and am learning by reading the posts.

                      Currently I am waiting for hardware for my 1st gateway so I am not encumbered by details.

                      I notice in all the reported cases the "problem" node is AC powered, while many of the "good" sensor nodes are battery powered. Could this be significant? It would be interesting if someone with a "problem" actuator node could put a battery operated sensor node in the same area.

                      Just a thought.

                      Nca78N Offline
                      Nca78N Offline
                      Nca78
                      Hardware Contributor
                      wrote on last edited by
                      #55

                      @johnrob said in Why I quit using MySensors for actuators:

                      Hi, I know I'm a little late to this thread. I'm just starting with MySensors and am learning by reading the posts.

                      Currently I am waiting for hardware for my 1st gateway so I am not encumbered by details.

                      I notice in all the reported cases the "problem" node is AC powered, while many of the "good" sensor nodes are battery powered. Could this be significant? It would be interesting if someone with a "problem" actuator node could put a battery operated sensor node in the same area.

                      Hello,

                      the problem is an actuator node has to listen to the radio constantly and can't sleep, so it can't last long on batteries...

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


                      15

                      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