Navigation

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

    Konrad Walsh

    @Konrad Walsh

    5
    Reputation
    29
    Posts
    986
    Profile views
    1
    Followers
    0
    Following
    Joined Last Online

    Konrad Walsh Follow

    Best posts made by Konrad Walsh

    • 3-in-1 Humidity Temp and Motion

      I am wanted to share my 3-in-1 sensor in case its of use to anyone
      Its really just a combination of what's already available

      I used the following hardware:

      Arduino Nano LINK - Gave me both 3.3v and 5v output without having to mess with extra hardware(steppers)
      1 x Motion Sensor LINK
      1 x DHT22 LINK

      Connections is as all other guides except:
      Motion Sensor digital to Pin D3
      and the DHT to Pin D4

      Here is my code

      #include <SPI.h>
      #include <MySensor.h>  
      #include <DHT.h>  
      
      #define CHILD_ID_HUM 0
      #define CHILD_ID_TEMP 1
      #define CHILD_ID_MOT 2   // Id of the sensor child
      #define HUMIDITY_SENSOR_DIGITAL_PIN 4
      
      #define DIGITAL_INPUT_SENSOR 3   // The digital input you attached your motion sensor.  (Only 2 and 3 generates interrupt!)
      #define INTERRUPT DIGITAL_INPUT_SENSOR-2 // Usually the interrupt = pin -2 (on uno/nano anyway)
      
      
      unsigned long SLEEP_TIME = 30000; // Sleep time between reads (in milliseconds)
      
      MySensor gw;
      DHT dht;
      float lastTemp;
      float lastHum;
      boolean metric = true; 
      MyMessage msgHum(CHILD_ID_HUM, V_HUM);
      MyMessage msgTemp(CHILD_ID_TEMP, V_TEMP);
      MyMessage msgMot(CHILD_ID_MOT, V_TRIPPED);
      
      void setup()  
      { 
        gw.begin();
        dht.setup(HUMIDITY_SENSOR_DIGITAL_PIN); 
      
        // Send the Sketch Version Information to the Gateway
        gw.sendSketchInfo("Humidity/Motion", "1.0");
      
      
       pinMode(DIGITAL_INPUT_SENSOR, INPUT);      // sets the motion sensor digital pin as input
       
        // Register all sensors to gw (they will be created as child devices)
        gw.present(CHILD_ID_HUM, S_HUM);
        gw.present(CHILD_ID_TEMP, S_TEMP);
        gw.present(CHILD_ID_MOT, S_MOTION);
         
        metric = gw.getConfig().isMetric;
      }
      
      void loop()      
      
      {  
        // Read digital motion value
        boolean tripped = digitalRead(DIGITAL_INPUT_SENSOR) == HIGH; 
              
        Serial.println(tripped);
        gw.send(msgMot.set(tripped?"1":"0"));  // Send tripped value to gw 
        
        delay(dht.getMinimumSamplingPeriod());
      
        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);
          }
          gw.send(msgTemp.set(temperature, 1));
          Serial.print("T: ");
          Serial.println(temperature);
        }
        
        float humidity = dht.getHumidity();
        if (isnan(humidity)) {
            Serial.println("Failed reading humidity from DHT");
        } else if (humidity != lastHum) {
            lastHum = humidity;
            gw.send(msgHum.set(humidity, 1));
            Serial.print("H: ");
            Serial.println(humidity);
        }
      
        
       
        // Sleep until interrupt comes in on motion sensor. Send update every two minute. 
        gw.sleep(INTERRUPT,CHANGE, SLEEP_TIME);
      }
      
      
      

      If anyone wants more info please ask.. I will put up pictures or diagrams if needed

      posted in My Project
      Konrad Walsh
      Konrad Walsh
    • Assistance Needed Completing GAS Air Quality Sensor

      2014-12-01_15h04_52.png
      At the challenge from @HEK and realising we have no S_AIR_QUALITY files.. I have set out to create them..

      I am stuck with finalising the .ino sketch. I want to achieve this in one device with three pieces of data. .Its early days on development but I could do with help through the last parts..

      I have attached my files as they are. In the .ino sketch the problem is with my gw.send(msgxxxx) parts.

      AirQualitySensor.ino
      https://codebender.cc/sketch:65086

      S_AirQuality1.xml
      D_AirQuality1.xml
      D_AirQuality1.json

      posted in Development
      Konrad Walsh
      Konrad Walsh

    Latest posts made by Konrad Walsh

    • RE: 💬 MyMultisensors

      @alexsh1 Thank you

      posted in OpenHardware.io
      Konrad Walsh
      Konrad Walsh
    • RE: 💬 MyMultisensors

      I am sorry.. I should have been more clear...
      When you say PCB.. Is that a fully assembled product with all the mentioned sensors? Or is it a board and you add sensors to it..

      Please excuse my ignorance

      posted in OpenHardware.io
      Konrad Walsh
      Konrad Walsh
    • RE: 💬 MyMultisensors

      Phenomenal!

      I have a stupid question.. clicking buy on the page.. what exactly does that buy you>?

      posted in OpenHardware.io
      Konrad Walsh
      Konrad Walsh
    • RE: Bluetooth Proximity Sensor

      i am "semi" abandoned it.. I couldn't get it work at all... but I cant say I fully grasp the syntax yet. Hopefully @HEK gets the notion...

      posted in Development
      Konrad Walsh
      Konrad Walsh
    • RE: Bluetooth Proximity Sensor

      i am "semi" abandoned it.. I couldn't get it work at all...

      posted in Development
      Konrad Walsh
      Konrad Walsh
    • RE: Assistance Needed Completing GAS Air Quality Sensor

      @korttoma Hey

      Just back on track from today.. so will getting looking to this again

      posted in Development
      Konrad Walsh
      Konrad Walsh
    • RE: Assistance Needed Completing GAS Air Quality Sensor

      @korttoma Hey

      Bear with me.. I hope to complete this over the weekend.. work got in the way.. But the goal is to achieve what you requested... I just need to stabilize things first

      posted in Development
      Konrad Walsh
      Konrad Walsh
    • RE: 3-in-1 Humidity Temp and Motion

      @Nuubi LOL.. its a secret!!!

      and I will share my carefully guarded secret... Air quality sensor!! or in other words.. smoke and gas detector...

      posted in My Project
      Konrad Walsh
      Konrad Walsh
    • RE: Assistance Needed Completing GAS Air Quality Sensor

      @epierre OK.. I wil lget this set up functioning first as a stanadalone device. I have the sketch completed now.. Just finishing off the vera files.. Then I will look at improving things

      posted in Development
      Konrad Walsh
      Konrad Walsh
    • RE: Assistance Needed Completing GAS Air Quality Sensor

      @BulldogLowell LOL .. maybe dont depend on my skills..!! 🙂

      posted in Development
      Konrad Walsh
      Konrad Walsh