Over the last week or so I have been playing around with getting Node.js up and running on my Raspberry Pi. I have found it to be a great learning experience and I’m pretty sure I will be using it for all of my embedded UI projects from now on. With the help of frame works like Express getting a static site up and running is really easy and Socket.io makes communications really easy too. As I posted before I have been playing with these SRF modules to get some wireless comms going for home automation and I used python to get up and running fast. Afterwards I decided to use this as a opportunity to get in Node as I’ve wanted to try it out for a while but always need a project to apply myself to. This is still a long way off but have a look at the first working version https://github.com/rosterloh/EVE-node. More as I carry on discovering!

Advertisements

Sites like Kickstarter and Indiegogo make me very excited. They really do give opportunities to projects that probably never would have seen the light of day. A recent project to build a affordable 3D scanner has caught my eye. Have a look and see what you think.

Photon 3D Scanner

Photon Image

Photon 3D Scanner

Link  —  Posted: April 23, 2013 in Crowdfunding
Tags: , ,

I had a little time to play around this weekend so I got out some toys I’ve been meaning to play with and got a few things up and running. My EVE board has been lying around collecting dust so I assembled the RFM12B and the Ciseco SRF modules along with a TMP100 on board temperature sensor. The EVE board has 2 locations where the SRF module can be fitted but I put it on the 868MHz location as that’s the frequency I am using. The PCB is routed such that the Pi can communicate with it via SPI on SS0 but it also has pads for the serial connection which is a blessing as the firmware that the module is shipped with uses serial and not SPI. Although you can OTA program these devices since I don’t have any radio modules that can easily connect to a PC I just hooked up an FTDI adapter to the serial port and programmed them using their XCM tool. The firmware image can be found here.

RFu328

I also have one of their Arduino compatible boards with a footprint for the same SFR module on the Pi so I programmed that up with the RFu328 code (I used the beta firmware) and put a small sketch on there which periodically reads the temperature and humidity values from a DHT22 sensor and sends them out to anyone listening. The protocol used to send these packets is LLAP which is really basic but gets the job done. CRC and other such things are handled in hardware so that is not required in the protocol. After that it was easy enough write a python script on the Raspberry Pi to read the values and for now just posts them to COSM.

Next phase I’m going to set up some web sockets and have a play around with some HTML5. All in all it was a fun little weekend project and I am most happy with how far it’s come.

I would also like to change this so that the sensors do no just present the data but rather are polled. While I’m at it I’d also like to build in standard inputs and outputs so I don’t have to change the code if I want to add a few basics later.

I’ve gotten myself into quite a few projects at the moment and I think I need to spend some time finishing a few things off rather than just taking new things on. The first and easiest thing to tick off the list would be Ambilight. It’s all up and running and working great! I really love it. All that needs doing is packaging it all up so that it looks nice. In doing so I have ordered a few things which should all arrive soon. The first thing I did after trying out a few wall warts was to order a decent 5.5A switchmode power supply. I think it’s good practice to have a supply that can output a good deal more than you need so it is not living on the edge of it’s capabilities.

I didn’t like having the Arduino hanging off the edge of the TV and needed another 5V supplied micro board so I ordered a Xino Mini from Ciseco. This is a great little respin of the Arduino Mini but doesn’t carry it’s heavy cost. It will be great and unnoticeable behind the TV. Along with that I needed a 5V I/O FTDI adapter which is the last thing I am waiting for as the wrong part was sent out to me. Once I have it all put together I’ll post pictures but this was a fun little project.

Apart from this I have been playing with my EVE board and getting a few home automation projects off the ground. Not too much to speak of yet but keep an eye on my github page because all the code will be there.

The last thing I have been busy with is a software project that will be very useful for home and work which has started as a python application which I have named Phantom. This program will run as a client or server and using the Pyro library dynamically generate a list of compatible devices on a network, query their capabilities and generate a GUI to control them. It was dreamed up in the middle of the night and will be great for hardware test Linux boards. I think I’ll start out with a lot of things hard coded and then try to make as much as dynamic as possible. Below is the beginnings of what I hope to achieve.

Phantom Flowchart

Posted: March 24, 2013 in Uncategorized

Wow, what an incredible project! So well put together. I’m truly impressed.

fabiobaltieri

One frustrating aspect of firmware or kernel development on commodity hardware, such as cheap evaluation board or production devices, is the necessity of power-cycling the target device to reboot it every time the developer needs to load and run a new software build.

It sometimes happens that a development board is designed with proper management electronics to ease software development or automated testing, but in most cases the developer has reset the board manually, and sadly quite often reset buttons are unaccessible or just non-existent, requiring the developer to unplug and replug the power cable. If this ends up in your workflow and at the end of the day your fingers hurt, something is wrong.

This project is a small AVR/V-USB based board to control the power supply of development boards and other low voltage and USB powered devices. It allows to program a sequence of events for the output…

View original post 916 more words

Update on Ambilight

Posted: February 26, 2013 in Ambilight
Tags: ,

As with all things in electronics the easiest most trivial projects are the ones that give you the most hassle. I have completed the build for my Ambilight system and am using a 3.5A 5V supply which is doing fine for now. Each LED can draw as much as 0.25W on full brightness so I’ll either just use half the LEDs for now or get a bigger power supply. The problem I’ve been having is that I’m getting strange results outputting the communications signal to the LED strip. During initial testing everything was going fine but I was only ever outputting green, red or blue at any given time. Now that I’ve put the whole thing together there seem to be some comms problems. On closer inspection of the WS2811 datasheet I’ve seen that VIH (the input voltage detected as a high) is 0.7VDD which with my 5V supply is 3.5V. The microcontroller I am using uses a 3V3 IO voltage so I can see how when communications get fast things would go wrong. I will try the system tonight with an arduino at 5V IO voltage and see if it fixes the problem.

On a side note Adafruit have updated their Flora Pixel to version 2 which I think uses the same WS2811 IC. As always the have a library on their github page which implements a really nice colour wheel demo. The FastSpi library that I’ve been using has also had an update recently which makes the code a lot cleaner. Have a look but be aware that it is just a preview release at the moment. I’ve uploaded my current working into a project on my github page but this will be cleaned up when I have a final working version. The boblight.conf I was talking about in my last post is there too.

Ambilight build

Posted: January 28, 2013 in Ambilight
Tags: , , ,

I have started a new little project this weekend which I have had in the back of my mind for a while and never managed to start. I am building an Ambilight system for my HTPC as I think it’s pretty cool and is a nice excuse for another small microcontroller project. There are many projects like this out there on the web but as always I never do things exactly the same as everyone else. I guess the Adalight project is the closest thing to what I’m building but the RGB LED strip I got uses the WS2811 IC instead of the WS2801. This chip is pretty amazing as it puts the 3 LEDs and the controller all on the same piece of silicone and it is driven by only 1 line from the controller.

So I obviously couldn’t use the library available on github from Adafruit. The library recommended by the seller was FastSPI. This was pretty easy to get going with the demo code except that you have to declare  your device as TM1804 and not WS2801. Other than that the rest of the system just uses Boblight in XBMC and a controller connected to USB reading and setting the RGB values to the LEDS.

I’ve decided to do all my testing on an Arduino Uno I have lying around and then port the code to a smaller board once it is all working (probably the JeeNode).  The code was pretty easy and I’ll post links once I’ve uploaded it somewhere but the difficult part was really understanding and configuring boblightd. Boblightd has a complicated configuration file but I got started with another file which I got from here with a handy real word description of things here.

Basically the way things worked out with my particular strip on my particular monitor I have 32 LEDs running along the top 1 in each of the top corners and 13 running along each side but not all the way to the bottom. So therefore I have to configure 60 LEDs but not across the full height of the screen. So that gives a situation as bellow:

LED layout
So with the horizontal and vertical scans starting at zero in the top left of the diagram above and my LED strip starting with LED0 just above the bottom right I configured my boblight.conf file for my particular system. I tested this out using the boblight-constant application and things seemed fine but I unfortunately don’t have a 5V power supply which I can use for this project long term. I think 5V 2A will be sufficient. So for now that’s as all I have but I will post again with a video when it’s done. For now some pics…

 IMG_20130126_144931IMG_20130126_144942