Navigation

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

    Posts made by riataman

    • Arduino Nano + NRF24L01 in single side PCB

      Hey I'm completly new to PCB making. I etched my first PCB with an arduino nano plus an NRF24L01 module. I couldn't route all the traces and ended up using one jumper wire.

      Is it possible to route a connection between those two components if you are using a single side PCB with big traces (basically I don't want any traces between pins) ? Has anyone done anything like that? I mostly used the eagle autorouter and then tried to do it by hand but failed miserably, but I'm a noob and this and maybe missing the good tricks!

      0_1474384261700_Capture.PNG

      posted in Hardware
      riataman
      riataman
    • RE: Battery operated actuator

      Since some people people have found this useful I'm posting an update. Six months have passed and I'm very happy with the results. The nodes using the 4 second sleep are barely now into the nominal voltage of two AA batteries (3V) and I think those can last a copule of years like that.

      The 2 second sleep node is dipping a lot faster, but I suspect that the cause is the Si7021 taking readings every 3minutes that is accelerating the decline, even then I think this one could almost make it to a year.

      0_1461689309569_battery.png

      posted in Development
      riataman
      riataman
    • RE: Battery operated actuator

      @ToniA Tony that's way cool and very similar what I'm doing. The split units that I have are GE and Whirlpool. I don't see you having support for those in HeatpumpIR, I hope to find the time to publish my analysis of their protocol (I only decoded it partially, those have long sequences to maintain time/timers but I just hard coded that).

      I was thinking about tapping into the condenser, specially to see if I could find a better way to detect if the unit was on since the indirect method of measuring the current going to the unit has some drawbacks (when the unit is in heat mode and it reaches the target temperature the current that it draws is the same as when its off, so there's no way to tell on/off state at that point).

      At the end I decided against fiddling with the unit itself since my wife wouldn't be very happy if I broke it.

      What kind of UI do you use to control the units? I'm really not using any MySensors code/controllers at all, everything I have is written from scratch (minus sensors libraries) .

      posted in Development
      riataman
      riataman
    • RE: Battery operated actuator

      @ahmedadelhosni: A big part of me doing this project is for controlling the ACs when I'm not home (for example if I'm heading home and I want it to be warm/cool when I arrive). I can access the controlling UI from anywhere as long as I have internet. What I was thinking is that I can increase the sleep time during the night when I usually not sending commands.

      I think you can still improve my power consumption, the RF24 library has some delay() calls that could potentially be changed to sleep calls, or just don't do them at all since you'll be sleeping in another moment, would need careful review. Also my arduino pro mini is consuming a bit more current than what I have seen other archive, I never was able to figure out why, probably with a barebones Atmega328 board you can improve on those too.

      Another area that could use more research is the listening time, I'm listening for 15ms and that was the barely necessary in my test, but I kind of remember if you didn't sleep the radio you could get away with shorter listening times, that maybe end up using less power. Also I'm using the 250kbps transmission speed of the RF24 radio, if you go with the 2mbps the time to transmit a packet over the air maybe shorter, I'll be worth investigating that.

      I have two nodes that are connected to the wall and I have found that I don't really need them to be directly pointed to the AC, if you get very bright IR leds and drive them at full voltage/current the IR light will basically bounce in the whole room and that gives you a lot more flexibility in placement.

      The other bit that I have and that I forgot to post is a node that I wired in the switch box and is using current transformers and the EmonLib to monitor the current going to the AC units, that allows me to know if the AC is turned on or off, something very useful when I want to control them remotely. I'll try to post pictures of that tomorrow.

      posted in Development
      riataman
      riataman
    • RE: Battery operated actuator

      0_1454087697334_voltage.png

      There you go, I think the rate of discharge went down a little bit inline with the 2A alkaline discharge curves I have seen.

      You can't tell exactly by the chart, but all updates are up to today (Jan 29) Master is at 2.88V, JP is at 3.027V and Magy is at 2.979V.

      I think I'll call this a success since looks like I'm en route to last at least the 6months that was my original goal.

      By the way, I added a Si7021 sensor to the "master" node and it now reports temperature and humidity every 3minutes. It also has now a magnetic window sensor that it monitors via a pin interrupt to report open/closed state of a window.

      I'll try to find time to document all this project for the contest, here is an screenshoot of the web UI that I'm using to control the whole thing.

      0_1454088780552_accontrol.png

      The web UI is basically jquery mobile widgets plus a bit of javascript. The backend is written in python+flask running in a raspberry pi, that sends commands to my radio control, written in C also running in the same raspberry pi, the controller manages the radio communication, the nrf radio is directly wired to the raspberry pi IO pins.

      It controls 5 independent AC units, three are running on batteries and two are wall powered. The interface scales very well to desktop/mobile so I can control my ACs from anywhere on the internet.

      One of those nodes can also controls a Lutron IR wall switch. Another one has a natural gas sensor. And most of them have temperature/humidity sensors.

      posted in Development
      riataman
      riataman
    • RE: SI7021 Multisensor - first try

      @n3ro said:

      @riataman said:

      with a 5v arduino

      Hey 😃
      the operating voltage of this component is 1.9 to 3,6 v. not 5v 😃

      That's true for the individual SI7021 IC, but in the breakout the regulator steps down the voltage to 5v and additional circuitry does 3.3<->5v level shifting. I have tested that particular breakout with a 5v arduino and it works just fine.

      posted in Development
      riataman
      riataman
    • RE: SI7021 Multisensor - first try

      @korttoma said:

      Speaking of the Si021, has anyone tried to use 2 Si7021 sensors on the same node?

      Since the i2c address is hardcoded I see two ways of doing this:

      1. Power the two sensors from gpio pins (instead of connecting them to vcc, connect each to a separate gpio pin), when you want to read one sensor you put one high and the other low. I'm not really sure if this will work at all.

      2. Use a soft i2c library like this one: https://github.com/todbot/SoftI2CMaster that way you have two sets of i2c pins. I'm pretty sure this one should work.

      posted in Development
      riataman
      riataman
    • RE: SI7021 Multisensor - first try

      @n3ro said:

      Big THX,

      now i have understand how to use the si7021 🙂

      Reading works great!

      But the sleeping current is very high ~1500uA

      If you got this breakout: http://www.aliexpress.com/item/Industrial-High-Precision-Si7021-Humidity-Sensor-with-I2C-Interface-for-Arduino/32340228487.html?ws_ab_test=searchweb201556_1_79_78_77_80,searchweb201644_5,searchweb201560_1 it includes a 3.3v regulator and level shifting so you can actually use the sensor with a 5v arduino but it consumes quite a bit of current (60uA in the ones I got) even when idling.

      What I did was desolder the regulator and solder a small wire to bypass it (sorry for potato quality pic).

      gy21.png

      Then I ordered this breakout for future nodes: http://www.aliexpress.com/item/New-HTU21D-Temperature-and-Humidity-Sensor-Module/1970355069.html?ws_ab_test=searchweb201556_1_79_78_77_80,searchweb201644_5,searchweb201560_1 that one doesn't seem to include any additional circuits (other than the pull up resistor and safety? resistor).

      posted in Development
      riataman
      riataman
    • RE: Battery operated actuator

      In case anyone is interested in this topic I'm updating with my battery results after 1 month.

      Master is the sensor running the code I posted above, I hope I'm in good track for the battery to last at least 6months. JP and Magy are running the same code but sleep for 4 seconds instead of 2. I think they are following the same pattern as master but almost 2x slower. Ups in voltage seems to be 100% temperature related. Those are running in 2 AA batteries.

      Untitled.png

      posted in Development
      riataman
      riataman
    • RE: Arduino Mega 2560 Can we use more interrupts than 2?

      You can have CHANGE interrupts in any pins in the atmega328. See http://playground.arduino.cc/Main/PinChangeInterrupt

      I haven't actually tested it, but it's in my list of things to try, as I want to have door/window sensors that monitor 4+ doors.

      Edit: I went ahead and tested, it worked just copy and pasting the code from that page. The interrupt will wake up a atmega328p. You just will need to figure out what pin actually changed by remembering state.

      posted in Development
      riataman
      riataman
    • RE: Need idea for turn off speakers when tv is off

      You can use a current transformer to detect when the TV is on, I'm doing something like that to detect when my air conditioner units are on.

      Something like this: http://openenergymonitor.org/emon/buildingblocks/how-to-build-an-arduino-energy-monitor

      But as they say, they already sell things to do what you want easily already.

      posted in General Discussion
      riataman
      riataman
    • RE: Having issues with 2AAA battery project and AVRDUDE

      @LastSamurai said:

      Perhaps this helps. As far as I know and have read 1Mhz doesn't really change that much because you sleep most of the time anyways. Try to disable the BOD, that uses most of the power.

      I don't think the idea behind changing the clock to 1Mhz is to save energy, but to allow the mcu to run at lower voltages (allowing it to keep running when the batteries are already considered dead for other uses). The Atmega328 can run down to 1.8V but only if your clock speed is 4Mhz or lower. We change it to 1Mhz because its easier to do that in software, rather than solder a new crystal.

      posted in Hardware
      riataman
      riataman
    • RE: Battery operated actuator

      So I got around to implement this. My project is an air conditioner controller. I decoded my AC remote IR protocol and write code to send it using an arduino pro mini.

      This is the mainloop I'm using, basically I sleep 2seconds, then listen for commands for 15milli seconds.

      void loop()
      {  
        bool gotCommand = false;
        RadioCommand data;
      
        // Power up the radio, start listening and then sleep 15MS to allow
        // the radio to receive any commands.
        radio.powerUp();
        radio.startListening();
        LowPower.powerDown(SLEEP_15MS, ADC_OFF, BOD_OFF);
        // Clean the full pipeline. Only execute the last command
        while ( radio.available() )
        {   
          radio.read( &data, sizeof (RadioCommand));
          gotCommand = true;
        }
      
        if (nLoops > PING_LOOPS)
        {
          sendBatteryStatus();
          nLoops = 0;
        }
      
        radio.powerDown();
      
        // If we got a command and its actually different than last time
        if (gotCommand && lastSeq != data.seq)
        {
          SendWhirlpoolCommand (data.data);
          lastSeq = data.seq;
        }
      
        nLoops++;
      
        LowPower.powerDown(SLEEP_2S, ADC_OFF, BOD_OFF);
      }
      

      The sending side is a raspberry pi that just tries to send the same message for 5 seconds when it wants to send a command.

      I have very good reception so it always picks the package on the first try, this gives me an average command actuation of 1second, pretty good.

      I ran this in two AA rechargable nimh batteries for 3 days and the voltage didn't changed at all. Today I changed the batteries for two ElCheapo alkalines, the ones that I actually want to use. I'll report back how the batteries are progressing.

      I want to add a temperature/humidity sensor, probably going to be ordering either the Si7021 or the HTU21D as I need it go work with low voltages as I'm not using any step up, I'm running everything directly from the batteries.

      BTW, I'm not using any of the mysensors.org software as I wanted to write the whole stack myself for the learning experience (I have already the the nodes, controller and web interfaces for this) but I have found that this community has a lot of the same goals that I do.

      posted in Development
      riataman
      riataman
    • RE: Low Power Temperature Sensor

      Check the bmp180. Its a presure sensor, but it includes a fairly accurate temperature sensor and is rated down to 1.8v.

      posted in Hardware
      riataman
      riataman
    • RE: Battery operated actuator

      Hey NeverDie, is there any documentation/tutorial on that? I googled it and only ran into an arduino forum thread that dismissed that mode.

      posted in Development
      riataman
      riataman
    • Battery operated actuator

      Has anyone had success with a wireless battery receiver?

      I think at this point battery transmiter are well unsderstood and can last years on batteries.

      But an arduino that can listen for commands is harder to pull of since the radio needs to be awake to receive commands, but that consumes lots of power.

      I searched for a ultra low (< 500uA) wireless receiver that could wake the arduino on receiving and but didnt find anything even close.

      The only other option i was thinking about is introduce an acceptable delay. Say you sleep for 8s (max watch dog timer lenght) and then listen for commands for 100ms or so. The transmitter would have to be either constantly transmiting for 8s when it wanted to issue a command or keep a synced clock with the reciver (it could be keep up to date in every transmission) depending on the acuracy of the clocks the receiver awake time could be minimized.

      Anyway iam going to test that last strategy after i finnish my proyect to operate on constant wall power and then ill try to switch it to batteries (its an AC remote control)

      posted in Development
      riataman
      riataman