preload
Oct 30

The Arduino workshop I mentioned before, is actually going to happen! :-) This will be a busy day, for both the organizing party as well as the attendees! A short list of the things we will be doing during that day:

  • Building an Arduino on a breadboard
  • Soldering a JeeNode
  • The Arduino IDE and testing the JeeNode
  • Experimenting with sensors and actors
  • Building a Room board
  • HomeSeer integration.

Enough to fill a complete day I’d say!

For the HomeSeer integration we’ll be using a slightly modified version of JeeNode for HomeSeer. This script based solution will help the attendees to integrate the hardware they created into HomeSeer in a very simple way. And since all the source code is provided, everyone can extend and/or modify it so that it will fit their personal needs the way they want.

Although I’m not a HomeSeer user, I do have a HomeSeer license that was paid for by a fundraiser that took place earlier this year. So I can play with HomeSeer whenever I like without any dirty tricks while I’m working on the Plugins I created or when I’m doing stuff like this.

I soldered a new JeeNode v4, a Room Board, uploaded the JeeNode sketch and connected it to the AA Power Board:

JeeNode with Room Board

JeeNode with Room Board

The JeeLink sketch was uploaded to the, eh, JeeLink, and I added an extra line to the HomeSeer startup script to get the JeeNode script running. After some initial configuration like setting the JeeLink COM port and some RF related settings, I was good to go:

HomeSeer Status

HomeSeer Status

OK, it’s all working; I can see the Room Board sensors in HomeSeer. Now it’s time to upgrade the JeeNode sketch to make it more power usage aware, cause I assume that will be important for those who attend this workshop. Back at home, they’ll probably start creating their own battery powered sensors, so a good starting point is essential. And that’s what I’m working on right now.

Tagged with:
Sep 24

The motion sensor i finished yesterday needed some last tests; namely, what resistor should i use? Internal? External? And in the case of external, what value? Now the internal pull-up resistors of the Arduino are 20 k. But why not try to use a higher value, cause even with this resistor the rule V = I * R applies, right? When the JeeNode is in power down mode, i measure 1.36V over the external (100 k) resistor I used till now. That means there’s a current of 13.6 μA going through the resistor. With the internal 20k resistor this would be 5 times more: 68 μA! Yuck! And all that in power down mode, no way!

OK; i bought a huge case with an assortment of resistors a few years ago, ranging from 12Ω to 1 MΩ. Hey, let’s try that last one, 1 MΩ. This will add an additional factor of 10 to the external resistor value, resulting in the current dropping to 1.36 μA. And guess what; with this resistor the behavior of the PIR didn’t change; this is very nice! I hope I’m not overlooking or breaking any electrical laws or rules by doing this, but this seems the right thing to do..

Programming the XBee and placing it in the breakout board is all there’s left to do; I guess you could say this 3rd sensor is finished! :-)

Tagged with:
Sep 23

This evening I started building the first ELV PIR13 based motion sensor. Looking at the time right now, I think it took me 2.5 hours; during that time I soldered a JeeNode, attached a cable to the PIR13, soldered a XBee breakout board, soldered the wires to the JeeNode, drilled some holes in the enclosures,  … well here’s the result:

Almost finished

With each sensor that I build, it’s becoming less time consuming to build the hardware. With the sketch compiled and uploaded in debug mode, i wanted to see if everything was working OK, and it did. One last thing has to be resolved before i can move this sensor to it’s final location, and that’s if I can enable the internal pull-up on the interrupt pin. I probably can,  but maybe that’s not such a good idea. I mean, a pull-up resistor consumes power, so it matters if it’s 100 Ω or 100 kΩ, right? What if the resistor can have a higher resistance (and the PIR still working well) than the internal pull-up? Would that save me energy? And how much? An issue to spend the next evening with, cause this is all to new for me to decide based on experience or knowledge…

So that’s why i added a header on JeeNode port 2 (click the image and you’ll get a more detailed view) and put a resistor in there, between P and I; so I don’t have to rely on the internal pull-up if I don’t want to but can also discard that external resistor – based on what I think is best based on my findings.

Tagged with:
Sep 21

Although i came home rather late this evening, i had about an hour left to proceed with the ELV PIR13-based motion sensor.  Let’s see if I can get the PIR13 working on an interrupt pin…

I took the sketch from motion sensor v2 as a start, changed some minor things and uploaded the sketch to the JeeNode. Bummer, I forgot that now the PIR13 output pin is attached to an interrupt pin, there’s no more internal pull-up enabled. That’s why the thing isn’t working! Adding an external resistor between + and the PIR output solved this as you can see by looking at the output:

[Motion_PIR13]
0
1
0
1
1
0
0
0
etc....

The changes that had to be made to the sketch to get the PIR13 running were minimal, so I will change the Motion v2 sketch in a way that it can be used with the Panasonic PIR as well as the PIR13; just to keep the number of sketches used to a minimum.

Tagged with:
Sep 19

LED strips

Even in full daylight and the LED strips @ 50%, this already looks VERY OK to me! Can’t wait till it’s dark outside..

After some small tests during the last couple of weeks, it was time to finish replacing a lamp near the TV with LED lighting. It’s still a big cable mess in the corner where the TV is located, but you can’t start cleaning up when you’re not finished, right? A lamp, holding 2 energy saving light bulbs, consuming 11W, has now been replaced by LED strips attached to the back of the TV. I call it my “DIY ambilight” project :-)

The following components were used:

  • 1 x JeeNode v4;
  • 2 x MOSFET Plug;
  • 3 meters of warm white LED strip;
  • XBee series 2 module;
  • XBee breakout board;
  • 3.5 mm mono plugs;
  • 12V power supply.

And 3 x software; 1 for my Home Automation system, 1 for the JeeNode and 1 for the Touchscreen. The Pronto will follow soon.

From my Home Automation system i can control each of the 4 segments individually; i created a new device type and when i send a “L=30” command to this device, the LED strip on the left of the TV goes to 30%. When i send a “B=0“, the bottom LED strip goes to 0%. A “*=10” will result in all 4 LED strips to go to 10%.

The hardware (power supply, JeeNode, LED strips) is controlled by a PLCBUS appliance module, so when it’s time to go to bed, i don’t have to worry about additional standby power usage.

On the Touchscreen i added a popup form so i can change the settings of the LED strips:

TV LED control

Although I’m technically able to, i didn’t put 4 trackbar controls on this form to control each LED segment individually. The reason for that is that I don’t think it will ever be used by anyone else but myself. I think, in daily practice, these 4 LED strips will only be switched on and off, once a brightness level has been set that suits the ligthing in the rest of the living room.

The sketch that is running on the JeeNode is pretty straight forward, once you’ve seen Jean Claude Wipplers sketch to control RGB strips. I think it’s needless to say that without his hardware, software and sharing of knowledge, i would probably still be watching blinking LEDs… well, sort of :-)

Well, anyway, here it is.

Curious about how the back side of the TV looks right now? Here you can see where the LED strips are attached to the back side of the TV and where i placed the 12V adapter and the enclosure that holds the MOSFET plugs, JeeNode and XBee.

Once i had it all (more or less) figured out, it took me 2 afternoons to go from a cardboard test setup to what it is now. Based on the response from wife and children, this is the best thing that has happened since the introduction of the touchscreen. Which I implemented 18 months ago… :-? And what has happened to that $$$ Roomba???

Update:

Power consumption? The LED strips provide enough light @ 16%, resulting in a total of 2W power usage. Not bad!

Tagged with:
Sep 17

Movee

Domotica Comments Off

Making a video takes too much time; I do have a DV cam, but in my opinion it takes to long to rewind, connect the firewire cable, transfer the clip to the PC etc. etc. My Nikon D90 also has video capabilities, but I’ve used it maybe once or twice in the beginning. The D90 can shoot 1280×720@24 fps MJPEG movies. I used it a couple of times again while we were on holiday and the results were quite good; although i still prefer my DV cam: focusing is slow and a bit difficult with the D90.

Here’s a small clip of my test with a JeeNode and 4 LED strip remainders i still had from my kitchen LED adventure.

Tagged with:
Sep 16

Two PIR13′s arrived yesterday. I immediately unpacked them to see if they would fit in the enclosure I want to use for them. It fits, but there’s not much room for error.

The lens is larger than the one on the previous PIR I used; this one requires a 13 mm hole, the previous was 10 mm. And the PIR13 lens sticks out more then the Panasonic version. But still, i prefer this much more than the X10-RF motion sensors i used in my former life :-)

The PIR13 PCB is glued to the top plate with hot glue. As you can see there’s not much tolerance along the long sides of the PCB; if the hole through the top plate is a bit excentric, you’ll have a hard time to make it all fit right. So pay attention there!

One nasty thing happened to me while preparing the 1st PIR13 to fit in the box; i decided it was wise to get rid of the 3 headers that are sticking out of the PCB; they were much to long! So i took my soldering iron and tried to get those things out. Normally, when you remove the plastic piece of the header and hold the soldering iron against a pin, they automatically fall out, sometimes with a bit of help, or they stick to the soldering iron. This time it was different; as if the pins were rammed into the PCB with a hammer! So i used a pair of pliers to gently pull the pin out; and while doing that, i damaged the PCB in a way that can’t be repaired anymore; aarggh!! First a voltage regulator blown up, now this.. what is this??

With the 2nd PIR13, i just cut off half of the pin length…

I foresee a “battle” for my spare time, between the LED strips and this new motion sensor… :-)

Tagged with:
Sep 14

Last weekend i was working on one of those things where i started collecting components a long time ago but that still wasn’t finished. Time to finally use these 4 meters of LED strip!

Warm white LED strip

With this warm white LED strip i want to create my own lighting in the corner where our TV is mounted to the wall. The strips will be put on the back side of the TV, shining on the (white) wall. I’m not really into RGB strips; it’s nice to see (for a while), but it’s to colorful for my taste.

I’m going to use a JeeNode with 2 MOSFET plugs to control the 4 segments:

JeeNode and MOSFET plugs

All wirelessly controllable by the use of an XBee module of course; a new page on my Pronto TSU 9600 with a couple of sliders (like on the picture below) to control these 4 segments individually will do the rest:

Pronto sliders

But while i was trying to create some sort of experimental setup with 4 small pieces of LED strip on a piece of cardboard, something went  terribly wrong; somehow the wires of the 12V LED adapter made contact with something that couldn’t handle this amount of power: Poofff !! One voltage regulator blown to pieces. I don’t know how this could go wrong, cause I didn’t do this, it just happened!

VR fried

Well, this JeeNode doesn’t work anymore…

OK. Fortunately I had another unused JeeNode laying around so i could finish the test (it works brilliantly), but what to do with this JeeNode? Replace the VR (the only component with visual damage) or discard the whole JeeNode cause there will probably be more components that suffered from this? I don’t know; I’m the type of guy that didn’t even know what a pull-up resistor was a year ago, so I’ve got no clue :-(

First I’ll finish this TV LED project and when I’m almost running out of JeeNodes in the future, I’ll give this damaged one a try…

Tagged with:
Sep 06

Now that i have no more PIR sensors in stock, I had to find me an alternative. The requirements: low power of course, it should be able to fit in the PIR enclosure i already have in use and not too expensive, cause I’ll need a lot of them. The ELV PIR13 seems to be the right candidate for the job; this would bring down the PIR power usage from 170 µA to 40 µA. I don’t have to tell you what that will do to battery life :-)

ELV PIR13: PCB 25 x 37 mm, 13 mm PIR

I’ve ordered a couple of these ELV PIR13′s and will build a 3rd motion sensor with one of these. In the meantime I also changed some things in the code to reduce the JeeNode power usage in power down mode even more: it went down from 20 µA to 6.5 µA. Calculations show a theoretical battery life of 200 weeks… well, i think the internal discharge will have screwed up the battery before that…

BTW, the 2 motion sensors that are currently being used, are still running fine on their first set of batteries.

Tagged with:
Aug 07

Since i removed a bunch of MS13 sensors recently, i am missing some input on what is going on at several places in our home. So while i was making a list of things i need in the near future, i realized i should extend the motion sensors a bit more, or otherwise i would lose the dark/light sensor the MS13 provided. And why not add temperature as well; cause that would mean i could do without the Oregon sensors also. I mean, why use 2 sensor devices (one only for temperature and another one for motion and light) when you can combine it all into one? Let’s have a look at temperature…

I still have 10 DS1820 1-Wire sensors somewhere from the days when i started with Domotica, but i never used them; maybe now i finally found a purpose for them? Let’s connect a few to an Arduino and see if  i can get a temperature reading:

Arduino with 3 x DS1820

Arduino with 3 x DS1820

And of course, there’s a library to use 1-Wire devices with an Arduino.. so before i knew it, i was polling the temperature of 3 DS1820s :-)

Addr:10 6C 5 CA 0 8 0 C3  Temp=25.50 grC
Addr:10 33 EC 3 1 8 0 E1  Temp=25.50 grC
Addr:10 FB 90 C9 0 8 0 1A  Temp=25.50 grC

Addr:10 6C 5 CA 0 8 0 C3  Temp=25.50 grC
Addr:10 33 EC 3 1 8 0 E1  Temp=25.50 grC
Addr:10 FB 90 C9 0 8 0 1A  Temp=25.50 grC

Addr:10 6C 5 CA 0 8 0 C3  Temp=25.50 grC
Addr:10 33 EC 3 1 8 0 E1  Temp=25.50 grC
Addr:10 FB 90 C9 0 8 0 1A  Temp=25.50 grC

Add an additional LDR and I’m done; ready to replace a large part of all my sensors: all remaining MS13s and most of my Oregon Scientific Temperature & Humidity sensors with my own :-)

Tagged with: