Navigation

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

    chuckconnors

    @chuckconnors

    7
    Reputation
    56
    Posts
    904
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    chuckconnors Follow

    Best posts made by chuckconnors

    • How can I control a servo with Mysensors? Automatic cat feeder

      Hey guys. Our cat is our alarm clock and I'm trying to solve that. Every morning she demands to be fed around 6am weekends included. My goal is to fix that problem with an automatic cat feeder.

      I'm trying to figure out a way to control a little microservo that I want to use to trigger a springloaded hinged door. The servo gets power and moves 90 degrees. When this happens the door springs open and the cat can get the food.

      I've written the bit that moves the servo to open and also back to closed position. I need to trigger these actions using MySensors. I'm guessing the best way is to use the relay sketch, but I'm at a loss as to how to modify it. I'm not a programmer so the coding for this sketch is a little foreign to me.

      Can someone explain how the relay sketch can be modified? I would like it to run the 'open door with servo' portion when the relay would be energized, and the 'close door with servo' portion when the relay would be idle.

      Any help is greatly appreciated. In fact, our whole household thanks you for helping us sleep in!!

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: How can I control a servo with Mysensors? Automatic cat feeder

      Here's the cardboard prototype proof-of-concept video:

      Youtube video

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: Binary sensor expanded help

      Much cleaner! I'll give it a go soon. Thanks for all the help!

      posted in Development
      chuckconnors
      chuckconnors
    • RE: Troubleshoot ethernet gateway

      Found the problem. Bad connection to router. I am now able to interact with it. Ping did work as did netcat. Thanks again.

      posted in General Discussion
      chuckconnors
      chuckconnors

    Latest posts made by chuckconnors

    • RE: 💬 Infrared Sender and Receiver

      @Reza said:

      this module ( ir transmitter ) is weak in transmit . for more than 2 or 3 meter distance dont work . also for less than 1 meter we must direct connection exactly.
      i think this is related to power or noise or problem of module ?!
      can you guidance me ?

      I'm thinking of building this but am concerned about limited range. I'd like it to work 10ft/3m. Can someone confirm that this does not work at these distances? If so, is there a way to increase the range?

      posted in Announcements
      chuckconnors
      chuckconnors
    • RE: ATtiny supported?

      @tlustoch said:

      Any progress? I like to build simple low-power temperature sensor based on attiny85 but cannot compile mysensors sketch if attiny85 set as a processor 😞

      I've switched over to the ESP8266 runing ESPEasy firmware. Very cheap and very easy to use.

      posted in Hardware
      chuckconnors
      chuckconnors
    • RE: Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      @sundberg84 said:

      @chuckconnors - BMP180 or Bmp280 for example.

      Those appear to be atmospheric pressure sensors. Looking for humidity sensors other than the DHT11/DHT22.

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      @sundberg84 said:

      @AWI probably because its mentioned in the build page? But i agree - I now know as well there is better out there.

      Can you tell me what better sensors are out there? These DHT11's I have vary wildly with regards to relative humidity.

      posted in General Discussion
      chuckconnors
      chuckconnors
    • OpenHAB not assigning node id

      I just built two new Humidity/Temp/Motion sensors. I'm using OpenHAB 1.3.8 with Mysensors 1.5.1

      I can see that things are working okay in Arduino IDE:

      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      sensor started, id=255, parent=0, distance=1
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      0
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      T: 80.60
      req id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,st=ok:
      H: 40.00
      
      

      Netcat to my ethernet gateway shows this:

      root@debian#  nc 192.168.0.99 5003
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      255;255;3;0;3;
      

      OpenHAB is receiving information from my other Mysensors nodes and those values update. I am not seeing anything in the logs about the new sensors not being assigned. It's like it's not seeing them.

      Can anyone help?

      posted in OpenHAB
      chuckconnors
      chuckconnors
    • RE: Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      @tbowmo said:

      @chuckconnors

      if you look at the "examples" repository, it both examples folder, and libraries that should work with the enclosed examples. Copy the library, that you want to use, to Arduino/libraries/... and the example to Arduino/... and try to compile them.

      HOLY SMOKES! I totally missed the libraries directory. Thank you and sorry for the troubles.

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      @AWI said:

      @chuckconnors this is what I found as a working example on my system. I still don't understand why the DHT keeps being so popular. There are much better temp/hum sensors around..... But anyway, this one should work.

      Installation
      ------------
      
      Place the [DHT][download] library folder in your `<arduinosketchfolder>/libraries/` folder. You may need to create the `libraries` subfolder if its your first library. Restart the Arduino IDE. 
      
      [download]: https://github.com/markruys/arduino-DHT/archive/master.zip "Download DHT library"
      [example]: https://github.com/markruys/arduino-DHT/blob/master/examples/DHT_Test/DHT_Test.pde "Show DHT example"
      [header]: https://github.com/markruys/arduino-DHT/blob/master/DHT.h "Show header file"```
      

      Thanks for the reply. I'm pretty sure that's one of the ones I tried. I ended up finding an old install I had and copied the library from there and it's working now.

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      Can someone please look at their libraries and tell me which one I need to use? Apparently installing Arduino IDE does not install this library by default and all the ones I've tried have failed. I don't see any documentation on which one to use.

      I've got a handful of sensors built but I can't program them until I get this resolved. I really appreciate your time and help. Thanks!

      posted in General Discussion
      chuckconnors
      chuckconnors
    • Can't compile Humidity sketch 2.0 .. What DHT library do I need?

      I'm trying to compile the Humidity sketch 2.0 and am getting an error. Here's the sketch I'm using:

      https://raw.githubusercontent.com/mysensors/MySensorsArduinoExamples/master/examples/HumiditySensor/HumiditySensor.ino

      /**
       * 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
       * This sketch provides an example how to implement a humidity/temperature
       * sensor using DHT11/DHT-22 
       * http://www.mysensors.org/build/humidity
       */
       
      // Enable debug prints
      //#define MY_DEBUG
      
      // Enable and select radio type attached
      #define MY_RADIO_NRF24
      //#define MY_RADIO_RFM69
      
      #include <SPI.h>
      #include <MySensors.h>  
      #include <DHT.h>  
      
      #define CHILD_ID_HUM 0
      #define CHILD_ID_TEMP 1
      #define HUMIDITY_SENSOR_DIGITAL_PIN 3
      unsigned long SLEEP_TIME = 30000; // Sleep time between reads (in milliseconds)
      
      DHT dht;
      float lastTemp;
      float lastHum;
      boolean metric = true; 
      MyMessage msgHum(CHILD_ID_HUM, V_HUM);
      MyMessage msgTemp(CHILD_ID_TEMP, V_TEMP);
      
      void setup()  
      { 
        dht.setup(HUMIDITY_SENSOR_DIGITAL_PIN); 
      
        metric = getConfig().isMetric;
      }
      
      void presentation()  
      { 
        // Send the Sketch Version Information to the Gateway
        sendSketchInfo("Humidity", "1.0");
      
        // Register all sensors to gw (they will be created as child devices)
        present(CHILD_ID_HUM, S_HUM);
        present(CHILD_ID_TEMP, S_TEMP);
      }
      
      void loop()      
      {  
        delay(dht.getMinimumSamplingPeriod());
       
        // Fetch temperatures from DHT sensor
        float temperature = dht.getTemperature();
        if (isnan(temperature)) {
            Serial.println("Failed reading temperature from DHT");
        } else if (temperature != lastTemp) {
          lastTemp = temperature;
          if (!metric) {
            temperature = dht.toFahrenheit(temperature);
          }
          send(msgTemp.set(temperature, 1));
          #ifdef MY_DEBUG
          Serial.print("T: ");
          Serial.println(temperature);
          #endif
        }
        
        // Fetch humidity from DHT sensor
        float humidity = dht.getHumidity();
        if (isnan(humidity)) {
            Serial.println("Failed reading humidity from DHT");
        } else if (humidity != lastHum) {
            lastHum = humidity;
            send(msgHum.set(humidity, 1));
            #ifdef MY_DEBUG
            Serial.print("H: ");
            Serial.println(humidity);
            #endif
        }
        
        sleep(SLEEP_TIME); //sleep a bit
      }
      

      The error I'm getting is this:

      
      Arduino: 1.6.6 (Windows 7), Board: "Arduino Pro or Pro Mini, ATmega328 (3.3V, 8 MHz)"
      
      C:\Users\User\Documents\Arduino-new\sketch_jul17e\sketch_jul17e.ino:39:19: fatal error: DHT.h: No such file or directory
      
       #include <DHT.h>  
      
                         ^
      
      compilation terminated.
      
      exit status 1
      Error compiling.
      
      

      I noticed a case sensitive issue so I changed DHT.h to dht.h and I get a bit further but then hit an error on line:

      DHT dht;
      
      

      I changed that to dht dht; and get a bit further still:

      Arduino: 1.6.6 (Windows 7), Board: "Arduino Pro or Pro Mini, ATmega328 (3.3V, 8 MHz)"
      
      C:\Users\User\Documents\Arduino-new\sketch_jul17e\sketch_jul17e.ino: In function 'void setup()':
      
      sketch_jul17e:55: error: 'class dht' has no member named 'setup'
      
         dht.setup(HUMIDITY_SENSOR_DIGITAL_PIN); 
      
             ^
      
      C:\Users\User\Documents\Arduino-new\sketch_jul17e\sketch_jul17e.ino: In function 'void loop()':
      
      sketch_jul17e:72: error: 'class dht' has no member named 'getMinimumSamplingPeriod'
      
         delay(dht.getMinimumSamplingPeriod());
      
                   ^
      
      sketch_jul17e:75: error: 'class dht' has no member named 'getTemperature'
      
         float temperature = dht.getTemperature();
      
                                 ^
      
      sketch_jul17e:81: error: 'class dht' has no member named 'toFahrenheit'
      
             temperature = dht.toFahrenheit(temperature);
      
                               ^
      
      sketch_jul17e:91: error: 'class dht' has no member named 'getHumidity'
      
         float humidity = dht.getHumidity();
      
                              ^
      
      exit status 1
      'class dht' has no member named 'setup'
      
      

      As you've probably guessed, I'm just trying things to see if I can get it to work. I'm guessing it's a library thing and could use some guidance as to what library I should be using. Thanks!

      posted in General Discussion
      chuckconnors
      chuckconnors
    • RE: Codebender motion sketch compile error

      @tbowmo Sorry. I was unclear. I don't mind using the Arduino IDE on my windows machine, but I don't know how to install the correct libraries to use the legacy code. Either that or is there a temp/humidity example sketch for 2.0? I can't find one in the code examples and I don't know what needs to be modified from the older version to make it work with 2.0. Just changing the include name is not enough.

      posted in General Discussion
      chuckconnors
      chuckconnors