Navigation

    • Register
    • Login
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. andmaster
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    andmaster

    @andmaster

    0
    Reputation
    9
    Posts
    413
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    andmaster Follow

    Best posts made by andmaster

    This user hasn't posted anything yet.

    Latest posts made by andmaster

    • MyControler V1.4.0 issues

      Hi all,

      First of all, great controller. i've been using for a week, and it is great!!

      I define my self as a complete noobs, and so, i'm here asking for your assistance, if you please.
      I've got the MySensors gateway in a raspberry pi. It has Mycontroller in the same pi as well. its configured as ethernet, and listening in 0.0.0.0:5003. All the nodes appearing, wich means, working great.
      Sadly, i've got a power down in my house, for an instant, but the raspberry pi rebooted.
      First issue, i'cant put MYcontroller to start at boot. Following all the steps, i got:
      0_1551700467275_8538e6dc-dffe-4e5b-af81-e1efed14f4f3-image.png

      I dont know else what to do. I've used root login to put the file in the etc/init.d folder, done everything in the tutorial, but i am still getting that error. What can i do?

      Also, and this is issue number 2 i've found that the gateway, after a few hours, had a status DOWN. and even after checking everything, that did not changed.. So i've formated the SD card, and installed everything again. Now, it is active and working, but i am not sure why that happened.

      Can i ask please for your assistance on those matters?

      Thanks in advance!!
      Andre

      posted in MyController.org
      andmaster
      andmaster
    • RE: Upgrading to 2.0 sketch dificulty

      hi @niccodemi that did the trick.

      I've made a quick comparison and i guess the issue was that i've defined my button without a proper array.

      this also has a change i think is important. i had a push button, and i wanted a toggle 🙂

      Just made a change. i want relay on to be 1 (high) and off to be 0 (low).
      This way, it starts every time at 0

      many thanks!!

      posted in Troubleshooting
      andmaster
      andmaster
    • RE: Upgrading to 2.0 sketch dificulty

      @mfalkvidd the example is provided here: https://github.com/mysensors/MySensorsArduinoExamples/blob/master/examples/RelayWithButtonActuator/RelayWithButtonActuator.ino

      what you are mentioning is the example where you can put multiple relays, but without any button actuator.

      Thanks

      posted in Troubleshooting
      andmaster
      andmaster
    • RE: Upgrading to 2.0 sketch dificulty

      @mfalkvidd this is the example 😃

      posted in Troubleshooting
      andmaster
      andmaster
    • Upgrading to 2.0 sketch dificulty

      Hi all,

      i've been trying for the last few hours to convert a multirelaywithbutton actuator to 2.0 with no sucess...

      the most i get is a "random" id of the relays in domoticz, and the buttons dont work properly..

      As so, i've founded an example in 2.0 but to a single relay.
      the sketch i've found in examples is:

      /**
       * The MySensors Arduino library handles the wireless radio link and protocol
       * between your home built sensors/actuators and HA controller of choice.
       * The sensors forms a self healing radio network with optional repeaters. Each
       * repeater and gateway builds a routing tables in EEPROM which keeps track of the
       * network topology allowing messages to be routed to nodes.
       *
       * Created by Henrik Ekblad <henrik.ekblad@mysensors.org>
       * Copyright (C) 2013-2015 Sensnology AB
       * Full contributor list: https://github.com/mysensors/Arduino/graphs/contributors
       *
       * Documentation: http://www.mysensors.org
       * Support Forum: http://forum.mysensors.org
       *
       * This program is free software; you can redistribute it and/or
       * modify it under the terms of the GNU General Public License
       * version 2 as published by the Free Software Foundation.
       *
       *******************************
       *
       * REVISION HISTORY
       * Version 1.0 - Henrik Ekblad
       * 
       * DESCRIPTION
       * Example sketch for a "light switch" where you can control light or something 
       * else from both HA controller and a local physical button 
       * (connected between digital pin 3 and GND).
       * This node also works as a repeader for other nodes
       * http://www.mysensors.org/build/relay
       */ 
      
      // Enable debug prints to serial monitor
      #define MY_DEBUG 
      
      // Enable and select radio type attached
      #define MY_RADIO_NRF24
      //#define MY_RADIO_RFM69
      
      // Enabled repeater feature for this node
      #define MY_REPEATER_FEATURE
      
      #include <SPI.h>
      #include <MySensors.h>
      #include <Bounce2.h>
      
      #define RELAY_PIN  4  // Arduino Digital I/O pin number for relay 
      #define BUTTON_PIN  3  // Arduino Digital I/O pin number for button 
      #define CHILD_ID 1   // Id of the sensor child
      #define RELAY_ON 1
      #define RELAY_OFF 0
      
      Bounce debouncer = Bounce(); 
      int oldValue=0;
      bool state;
      
      MyMessage msg(CHILD_ID,V_LIGHT);
      
      void setup()  
      {  
        // Setup the button
        pinMode(BUTTON_PIN,INPUT);
        // Activate internal pull-up
        digitalWrite(BUTTON_PIN,HIGH);
        
        // After setting up the button, setup debouncer
        debouncer.attach(BUTTON_PIN);
        debouncer.interval(5);
      
        // Make sure relays are off when starting up
        digitalWrite(RELAY_PIN, RELAY_OFF);
        // Then set relay pins in output mode
        pinMode(RELAY_PIN, OUTPUT);   
            
        // Set relay to last known state (using eeprom storage) 
        state = loadState(CHILD_ID);
        digitalWrite(RELAY_PIN, state?RELAY_ON:RELAY_OFF);
      }
      
      void presentation()  {
        // Send the sketch version information to the gateway and Controller
        sendSketchInfo("Relay & Button", "1.0");
      
        // Register all sensors to gw (they will be created as child devices)
        present(CHILD_ID, S_LIGHT);
      }
      
      /*
      *  Example on how to asynchronously check for new messages from gw
      */
      void loop() 
      {
        debouncer.update();
        // Get the update value
        int value = debouncer.read();
        if (value != oldValue && value==0) {
            send(msg.set(state?false:true), true); // Send new state and request ack back
        }
        oldValue = value;
      } 
       
      void receive(const MyMessage &message) {
        // We only expect one type of message from controller. But we better check anyway.
        if (message.isAck()) {
           Serial.println("This is an ack from gateway");
        }
      
        if (message.type == V_LIGHT) {
           // Change relay state
           state = message.getBool();
           digitalWrite(RELAY_PIN, state?RELAY_ON:RELAY_OFF);
           // Store state in eeprom
           saveState(CHILD_ID, state);
          
           // Write some debug info
           Serial.print("Incoming change for sensor:");
           Serial.print(message.sensor);
           Serial.print(", New status: ");
           Serial.println(message.getBool());
         } 
      }
      

      Can anyone help geting this so i can have:
      4 relays
      4 buttons
      domoticz also controling each one?

      Many thanks in advance.

      posted in Troubleshooting
      andmaster
      andmaster
    • RE: Ethernetgateway with ENC28J60?

      Hi @thm ,

      can you share your working code? i'cant help you with the update but you could help me, because i cant get my gateway working.

      many thanks in advance 😉

      posted in Development
      andmaster
      andmaster
    • RE: Arduino Nano Ethernet Gateway not working

      Well, the behaviour is odd. it blinks but nothing shows in the serial monitor. Also, domoticz dont find it..
      i will try other things 😉

      thanks anyway

      posted in Troubleshooting
      andmaster
      andmaster
    • RE: Arduino Nano Ethernet Gateway not working

      Hi scalz,

      Thanks for your reply.

      I've tested that, and the sketch did compile. However, did not worked.

      I've tested all the connections. everything is ok. simple does not work.

      Someone have a code that works, so that i can use?
      Thanks in advance

      posted in Troubleshooting
      andmaster
      andmaster
    • Arduino Nano Ethernet Gateway not working

      Hi all,

      First of all, great community here! learned a lot!!

      Althougt i'm a really rookie in all of this.

      I've built som temperature nodes, with ds18b20 + nrf24l01 + arduino pro mini.
      built a serial gateway and everything worked fine in domoticz.

      now, i want to do some other trial, and its a fail over a fail.
      i've a arduino nano+enc28j60+nrf24l01.
      ive used the connection diagram avail here: https://www.mysensors.org/build/ethernet_gateway
      I've used also the code avail in the link above. changed the ip, mac addr, loaded to the arduino, and got the error 0;0;3;0;9;radio init fail.
      Uncomment the softspi in myconfig.h, like i've saw in the forum. i was so thriled this would work, and i've got the error my sketch was too big. (just uncommented softspi).

      in this point, i'm asking, if someone can help me.

      Many thanks in advance

      posted in Troubleshooting
      andmaster
      andmaster