I wrote this a few weeks ago and forgot to post it.
I received a Raspberry PI recently. It looks great, nice and small.
I have been playing with PlugComputers, such as the SheevaPlug and the Seagate Goflex series for a few years. They form the basis of my low power computer systems that are on 24x7. The Raspberry PI is just like one of them but with a few extra facilities.
Getting up and running was a breeze. I simply downloaded the image, by bittorrent, if I remember correctly. It only took a few minutes.
I blew it onto an SD card and powered it up. Hey Presto! it worked. I was able to determine it's IP address and ssh in to have a look around. Perfect.
I didn't have a HDMI cable to hand, so I used a composite cable to connect it to the TV. It worked but the quality was not the best. Moved on.
I was wondering what to use the PI for. I still don't know.
I came across an article talking about using the PI with OWFS. http://raspberrypi.homelabs.org.uk/
OWFS stands for One Wire File System. 1-Wire is a technology developed by Dallas Semiconductor (Maxim-IC), that actually uses 2 wires to communicate with devices such as temperature sensors, switches, voltage detectors, a/d converters and so on. I use it extensively throughout the house to measure temperature and control things. One of the great things about the 1-Wire devices is that they are pretty cheap.
On the Raspberry PI, there are a number of input/output pins. The ones of interest in relation to 1-Wire stuff are the I2C pins. I2C is basically a serial protocol. It is the building blocks that USB and SATA are built on.
The good thing is that Maxim-IC make a number of I2C to 1-Wire controllers. These are the DS2482 and DS2483. There are probably others also.
So, the possibility to connect the chips directly to the PI was real.
I was able to acquire a couple of DS2482s from a friend of mine. I had to mount them on a 16 way SOIC to DIP converter.
The OWFS system was easily compiled from source on the Raspberry PI and installed.
I then began the search for the I2C drivers.
This was a hard one. I found many forums that resulted in a dead end. Many kernels were compiled and failed. I couldn't get/build a kernel
that would work with the drivers installed.
I found a fella that had a pre-built kernel built for Debian. I
use Arch, which is pretty different in it's config, even though it is Linux.Here is the link I used http://www.bootc.net/projects/raspberry-pi-kernel/ I also installed the latest firmware.
Anyhoo, I was able to install the new kernel and modules and boot a
workable system. Cool.
All the quick checks were good.
I then wired up the chips, DS2482, and started the main program
owserver. Hey presto, it worked.
I wired a couple of DS18B20's and could see them and read temperatures.
Success.
I love this embedded Linux crap.
Thursday, July 5, 2012
Raspberry PI Stuff and Building a Case
My Raspberry PI arrived a few weeks ago.
I tried both the Debian and Arch Linux boot images.
I don't have a convenient HDMI TV to play with, so I settled on the Arch version.
It suites me better, as I really wanted to use it as another Plug Computer, to do something with.
What to do with it? I am not sure yet. There will probably be something Home Automation related.
I am a big fan of the 1-Wire technology, for temperature sensors and control, so I compiled the latest version of OWFS on it. It worked fine with the USB 1-Wire controller.
The RPi has an I2C interface, so I decided to get my hands on a couple of DS2482-100s and DS2482-800s. These are I2C to 1-Wire controllers. After a bit of messing about, I was able to address the conrolllers using OWFS.
That will be a furure post, hopefully.
I was looking for a suitable plastic case fir the new toy. There are quite a few about and rather pricy for what they are. I liked the one on SKPANG. Including postage and VAT, it would come in at about €20. As my friend Ber would say 'Balzac' to that.
I came accross a post by Pecker Dunne on raspberrypi.org http://www.raspberrypi.org/phpBB3/viewtopic.php?f=40&t=9165&e=0
I was able to get a small sheet of perspex. Using youtube, I was able to determine that the 'score and snap' method was the best and cleanest way to get the pieces I wanted.
I made a few attempts. Two sheets of perspex and some No4 screws and nuts. I got some plastic washers to hold the board. It was just the job.
Attempt 2. In the presious version, I had put the screws too close to the IO header.
I also decided to make a breadboard version of it, to add breadboards and a USB hub.
I found that 3 screws would hold the RPi quite tightly and was easier to position the top piece.
Add a 10 port powered USB Hub
Some Breadboards
A Nanode and Xino Basic Arduinos for completeness.
I plan to use the slim breadboard for connections from the RPi headers and the larger one for the various components.
I sized the main plate, based on a plastic box with cover I have. Everything fits in and can be safely stored between project activity.
The next investigation will involve the Ciseco Slice of PI and the XRF radio module.
I tried both the Debian and Arch Linux boot images.
I don't have a convenient HDMI TV to play with, so I settled on the Arch version.
It suites me better, as I really wanted to use it as another Plug Computer, to do something with.
What to do with it? I am not sure yet. There will probably be something Home Automation related.
I am a big fan of the 1-Wire technology, for temperature sensors and control, so I compiled the latest version of OWFS on it. It worked fine with the USB 1-Wire controller.
The RPi has an I2C interface, so I decided to get my hands on a couple of DS2482-100s and DS2482-800s. These are I2C to 1-Wire controllers. After a bit of messing about, I was able to address the conrolllers using OWFS.
That will be a furure post, hopefully.
I was looking for a suitable plastic case fir the new toy. There are quite a few about and rather pricy for what they are. I liked the one on SKPANG. Including postage and VAT, it would come in at about €20. As my friend Ber would say 'Balzac' to that.
I came accross a post by Pecker Dunne on raspberrypi.org http://www.raspberrypi.org/phpBB3/viewtopic.php?f=40&t=9165&e=0
I was able to get a small sheet of perspex. Using youtube, I was able to determine that the 'score and snap' method was the best and cleanest way to get the pieces I wanted.
I made a few attempts. Two sheets of perspex and some No4 screws and nuts. I got some plastic washers to hold the board. It was just the job.
Attempt 2. In the presious version, I had put the screws too close to the IO header.
I also decided to make a breadboard version of it, to add breadboards and a USB hub.
I found that 3 screws would hold the RPi quite tightly and was easier to position the top piece.
Add a 10 port powered USB Hub
Some Breadboards
A Nanode and Xino Basic Arduinos for completeness.
I plan to use the slim breadboard for connections from the RPi headers and the larger one for the various components.
I sized the main plate, based on a plastic box with cover I have. Everything fits in and can be safely stored between project activity.
The next investigation will involve the Ciseco Slice of PI and the XRF radio module.
Saturday, June 16, 2012
Wireless Doorbell Amplifier
The Mater's doorbell started to become unreliable. The wires were pastered in concrete, so troubleshooting was pretty much out of scope.
I got 3 Homeeasy wireless doorbells and programmed them to one button transmitter. I put the plug-in unit in three different rooms.
Everything worked fine. The major issue is that the sound produced when the button is pressed was not very loud.
A new project was born.
Being a cheapskate Northsider, I decided to go for the best value option.
This would include buying the least abount of stuff and repurpose some parts I already had. I had a fairly small speaker box from a now defunct Hi-Fi unit. A 5V power supply which was an old Nokia phone charger. Some wire.
I got an amplifier kit from BitzBox.co.uk for £4.99.
http://www.bitsbox.co.uk/kits/projectkits.html
So cheap, what could possibly go wrong. Everything is included, as can be seen from the photo.
The instructions are quite good. I put it together and it worked first time. Woo hoo!! I have to say, it is a great kit and excellent value.
I dismantled the plug-in unit and connected two wires to the speaker leads. These wires were connected to the input on the amplifier board.
Connected up the power supply to the board and the speaker cables to the output connectors.
Tested it, all OK. Woo Hoo again!
Lastly, I hot glued the board onto the back of the speaker. I tried to open the speaker box, but it was too dense, so no joy there. Anyway everything will be hidden away, so hot glue was a good choice.
Anyway, I installed it in the Mater's house. Everyone was happy.
Job done.
I got 3 Homeeasy wireless doorbells and programmed them to one button transmitter. I put the plug-in unit in three different rooms.
Everything worked fine. The major issue is that the sound produced when the button is pressed was not very loud.
A new project was born.
Being a cheapskate Northsider, I decided to go for the best value option.
This would include buying the least abount of stuff and repurpose some parts I already had. I had a fairly small speaker box from a now defunct Hi-Fi unit. A 5V power supply which was an old Nokia phone charger. Some wire.
I got an amplifier kit from BitzBox.co.uk for £4.99.
http://www.bitsbox.co.uk/kits/projectkits.html
So cheap, what could possibly go wrong. Everything is included, as can be seen from the photo.
The instructions are quite good. I put it together and it worked first time. Woo hoo!! I have to say, it is a great kit and excellent value.
I dismantled the plug-in unit and connected two wires to the speaker leads. These wires were connected to the input on the amplifier board.
Connected up the power supply to the board and the speaker cables to the output connectors.
Tested it, all OK. Woo Hoo again!
Lastly, I hot glued the board onto the back of the speaker. I tried to open the speaker box, but it was too dense, so no joy there. Anyway everything will be hidden away, so hot glue was a good choice.
Anyway, I installed it in the Mater's house. Everyone was happy.
Job done.
Wednesday, May 23, 2012
Best Cajun Spice Mix
Cajun Spice Mix A handy mix using fairly ordinary ingredients. I like grinding my own pepper, as results in a more aromatic product. I have a grinder, I use for spices and one for coffee. You really need two grinders, as hot hot coffee is not great.
This mix gives a reasonably hot result, the pepper also gives a fairly smokey flavour. Mmmmmm....
If you are using fine ground black pepper, you will need to reduce the amount by 1/3. Otherwise it is very hot.
70 Grams Course Ground Black Pepper
26 Grams Garlic Powder
50 Grams Paprika
25 Grams Salt
7 Grams Dried Origano
10 Grams Dried Parsley
Mix together
Great with Chicken, Pork, Potato Wedges or basically anything.
To use just place the food in a bowl and sprinkle sufficient powder.
I suppose you need enough to cover the food.
Then grill or barbacue. It can be fried but it burns easily and creates loads of smoke.
Monday, April 2, 2012
DIY Cold Smoker
A while ago, I got a present of a Cold Smoke Generator http://www.macsbbq.co.uk/CSG.html. I used a cardboard box as a smoker and started smoking.
Very easy process. There are instructions at the above link.
I had a few smoking sessions which were very successful. I used bacon, cheese and salmon. Fantastic result. I also tried some if the Bratwurst from Lidls.
The Cold Smoke Generator is basically a metal tray, with a spiral, where you put wood dust in it. You light one end of the dust and it smoulders for about 8 hours. Very cool idea.
I decided to build a wooden smoker. I wanted one that I could dismantle and out together easily, i.e. store when not in use.
I wanted 4 racks, which is more then I had with the cardboard box fella.
I headed out to B&Q, because they have a greater range of stuff.
I got a couple of sheets of plywood, 3m x 60cm x 3mm or so.
I also got some of the following:
Some battons. I had some already, so I got what I needed.
4 x food racks (I think I got them in HomeStore&More in Blanch. Fairly pricey.)
Draft proofing tape. I got some about 5 years ago, for a different project. It was brown, but who cares.
I already had loads of screws. I like the brass Philips type. They are called chipboard screws. I use them for everything.
Some long set screws with normal nuts and extra wing nuts.
The dimensions I used were:
61cm High
Two sides were 55cm wide. These will have the rack battons on them. Lets call them sides.
Two sides were 35cm wide. Nothing here. Let's call them front and back.
1. Make the frames. I drilled holes first and screwed. Easy and had no wook splits. Use lots of screws. I wanted 10cm between between the racks on the side frames. Work it out.
2. Drill holes in the front and back frames for the long set screws
3. Drill some larger holes on the outside of the front and back frames to sort of countersink the normal nuts on the set screws.
4. Mark the top of the frames with a number to reflect how they will be put together.
5. Drill holes from the front and back frames through the side panels. See above.
6. Fit the set screws and get the countersunk nuts recessed.
7. Cut the plywood to the required size for the various frames.
8. Again use loads of screws to fix the panels to the frame. It needs to be fairly air tight, obviously.
9. You can now assemble it. Use the wing nuts also.
10. Make the lid.
11. Make a frame that fits the assembled structure. Loads of screws.
12. Cut a plywood panel that fits the frame. I had of a hangover to prevent any rain problem.
13. Disassemble. Add the Draft proofing tape on all the seals, including the lid.
14. Done.
Ready to SMOKE.
Here are some other photos:
Simply whack in the Cold Smoke Generator and off you go.
The most recent smoking involved some back bacon, mild cheddar and salmon.
The bacon and cheese turned out fantastic.
The salmon was an epic fail. I cured it for two days before smoking it. It turned out quite nice but way way too salty. I couldn't any more then a few thin slices. Better luck next time.
Top tip with the Cold Smoke Generator:
1 or 2 days before you are going to use it, take out the wood dust and let it dry properly. I have found that the wood dust really likes dampness, and unless it is perfectly dry, can be a pain to get smoking.
Very easy process. There are instructions at the above link.
I had a few smoking sessions which were very successful. I used bacon, cheese and salmon. Fantastic result. I also tried some if the Bratwurst from Lidls.
The Cold Smoke Generator is basically a metal tray, with a spiral, where you put wood dust in it. You light one end of the dust and it smoulders for about 8 hours. Very cool idea.
I decided to build a wooden smoker. I wanted one that I could dismantle and out together easily, i.e. store when not in use.
I wanted 4 racks, which is more then I had with the cardboard box fella.
I headed out to B&Q, because they have a greater range of stuff.
I got a couple of sheets of plywood, 3m x 60cm x 3mm or so.
I also got some of the following:
Some battons. I had some already, so I got what I needed.
4 x food racks (I think I got them in HomeStore&More in Blanch. Fairly pricey.)
Draft proofing tape. I got some about 5 years ago, for a different project. It was brown, but who cares.
I already had loads of screws. I like the brass Philips type. They are called chipboard screws. I use them for everything.
Some long set screws with normal nuts and extra wing nuts.
The dimensions I used were:
61cm High
Two sides were 55cm wide. These will have the rack battons on them. Lets call them sides.
Two sides were 35cm wide. Nothing here. Let's call them front and back.
1. Make the frames. I drilled holes first and screwed. Easy and had no wook splits. Use lots of screws. I wanted 10cm between between the racks on the side frames. Work it out.
2. Drill holes in the front and back frames for the long set screws
3. Drill some larger holes on the outside of the front and back frames to sort of countersink the normal nuts on the set screws.
4. Mark the top of the frames with a number to reflect how they will be put together.
5. Drill holes from the front and back frames through the side panels. See above.
6. Fit the set screws and get the countersunk nuts recessed.
7. Cut the plywood to the required size for the various frames.
8. Again use loads of screws to fix the panels to the frame. It needs to be fairly air tight, obviously.
9. You can now assemble it. Use the wing nuts also.
10. Make the lid.
11. Make a frame that fits the assembled structure. Loads of screws.
12. Cut a plywood panel that fits the frame. I had of a hangover to prevent any rain problem.
13. Disassemble. Add the Draft proofing tape on all the seals, including the lid.
14. Done.
Ready to SMOKE.
Here are some other photos:
Simply whack in the Cold Smoke Generator and off you go.
The most recent smoking involved some back bacon, mild cheddar and salmon.
The bacon and cheese turned out fantastic.
The salmon was an epic fail. I cured it for two days before smoking it. It turned out quite nice but way way too salty. I couldn't any more then a few thin slices. Better luck next time.
Top tip with the Cold Smoke Generator:
1 or 2 days before you are going to use it, take out the wood dust and let it dry properly. I have found that the wood dust really likes dampness, and unless it is perfectly dry, can be a pain to get smoking.
Arch Linux Stora Error - Fixed
I kept getting the following error repeated every gew seconds, filling up the log files like crazy. unable to receive ctrl connection: Function not implementedI found this after a bit of research ##in /etc/rc.local add
kill $(pidof udevd)
sleep3
udevd &
A reboot later and no problem.
It seems there was some problem between between different versions of udevd
Tuesday, March 6, 2012
Arch Linux on a Netgear Stora
I got one of these recently.
It is basically a Plug Computer, with the following specs:
My goal is to put Arch Linux on it. It seems that no one has done this yet.
What I am going to do, is set-up the system with Debian, which boots from the hard disk. There a number of recipes around to do this, particularly on the openstora.com site. I am following this one http://www.openstora.com/phpBB3/viewtopic.php?t=217
It did not contain all the information, so I thought about writing this walk through and fill in some blanks.
What you need to start is a USB serial cable. I got a Nokia phone data cable from eBay for a few Euros. Cut the end off the cable and solder some header thing on it. I used and old PC motherboard cable that I chopped up.
You also need some method to access the disk as a USB device. I used an old dismantled external drive controller board, which was handy.
To remove the back panel, you need to remove the two screws behind the Disk Release Latches. There are two of those nasty plastic clips about 5cm in from each side. There are two more of these nasty fellas about 9cm down from the top on the left and right side. Gently prise the panel with a small screw driver and it should pop off. Pop it off from the top as there are two clips on the bottom of the panel. These can be seen when looking at the bottom of the case.
You can see the serial port pins at the top of the board.
The pin-outs are from right to left:
Pin Function Notes
1 3.3Vdc Pin is the farthest from the battery.
2 RXD Recieve Data line from Stora.
3 TXD Transmit Data line from Stora.
4 GND Ground.
I will be using 2, 3 and 4, as I have cable made from an old Nokia USB data cable.
I installed tftp-hpa on the laptop, as the tftp server.
Connect stora to real network
Set-up environment for flashing.
The install the files from your tftp server
This will install Debian to the hard disk.
The disk partitioning takes a long time, 40 minutes or so, so go and have a cup of tea or a beer. I wouldn't recommend reboot at this time, cuz I don't know what state the Stora would be in. Perhaps and expensive brick.
Then, it begins installing the system..............
I then followed the remaining instructions on http://www.openstora.com/phpBB3/viewtopic.php?t=217
I got quite a few errors but kept going.
Presto chango! Debian!
aka FAIL
It wouldn't boot. Feck again.
I scrolled down further on that page and began to experiment a bit with the settings.
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
Again FAIL. Again Feck.
I took out the drive and connected it via USB to my laptop.
I ended up with a single partition that had some GPT data in the partition table
# fdisk -l /dev/sdb
WARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk
doesn't support GPT. Use GNU Parted.
Feck again.
I used this link to remove it http://www.rodsbooks.com/gdisk/wipegpt.html
All cool.
Install Arch Linux
My next plan, was to prepare the disk and put an arm version of Arch Linux on it.
What you need is, the board ot whatever to connect your SATA drive to a USB cable. Connect it up.
Mine was /dev/sdb
Partition New Disk
I wanted to have the following disk layout:
/dev/sdb1 = 2Gb plenty of space. I don't want to have to worry that it will fill up and require maintenance at a later date.
/dev/sdb2 = swap of 1Gb
/dev/sdb3 = The rest of the disk
I have taken out some of the disk detail because it just clutters up the page.
> fdisk /dev/sdb
Delete whatever partitions are on the disk.
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
Command (m for help): n
Partition type:
p primary (0 primary, 0 extended, 4 free)
e extended
Select (default p): p
Partition number (1-4, default 1): 1
First sector (2048-3907029167, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-3907029167, default 3907029167): +20G
Command (m for help): n
Partition type:
p primary (1 primary, 0 extended, 3 free)
e extended
Select (default p): p
Partition number (1-4, default 2):
Using default value 2
First sector (41945088-3907029167, default 41945088):
Using default value 41945088
Last sector, +sectors or +size{K,M,G} (41945088-3907029167, default 3907029167): +1G
Command (m for help): n
Partition type:
p primary (2 primary, 0 extended, 2 free)
e extended
Select (default p): p
Partition number (1-4, default 3):
Using default value 3
First sector (44042240-3907029167, default 44042240):
Using default value 44042240
Last sector, +sectors or +size{K,M,G} (44042240-3907029167, default 3907029167):
Using default value 3907029167
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 2048 41945087 20971520 83 Linux
/dev/sdb2 41945088 44042239 1048576 83 Linux
/dev/sdb3 44042240 3907029167 1931493464 83 Linux
Command (m for help): t
Partition number (1-4): 2
Hex code (type L to list codes): 82
Changed system type of partition 2 to 82 (Linux swap / Solaris)
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 2048 41945087 20971520 83 Linux
/dev/sdb2 41945088 44042239 1048576 82 Linux swap / Solaris
/dev/sdb3 44042240 3907029167 1931493464 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
Done
Set-up the file systems and install Arch and Kernel files
I wanted to have journeling so I setup /dev/sdb1 to ext3. It should be reognised as ext2 on boot.
mkfs.ext3 /dev/sdb1
mkfs.ext4 /dev/sdb3
Mount /dev/sdb1 and cd to the mount point
wget http://archlinuxarm.org/os/ArchLinuxARM-armv5te-latest.tar.gz
extract the Arch linux tarball to the root of /dev/sdb1
e.g.
tar zxvf /location/ArchLinuxARM-armv5te-latest.tar.gz
kernel image: http://dl.dropbox.com/u/1397036/stora_di/uImage
initrd image: http://dl.dropbox.com/u/1397036/stora_di/uInitrd
wget the images and copy them into the boot directory of /dev/sdb1
Almost complete.
Finally put the disk back in the stora in the left slot.
Boot into the uBoot prompt.
Here are the settings I found that worked.
setenv mainlineLinux yes
setenv arcNumber 2743
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
Let it run and it should boot into Arch Linux.
Woo Hoo !!!
Restore Original Firmware
It seems that the original firmware is stilled in Nand. To restore this use the following:
setenv mainlineLinux=no
setenv arcNumber
setenv bootcmd_ide
setenv bootcmd 'nand read.e 0x800000 0x100000 0x300000; setenv bootargs $(console) $(bootargs_root); bootm 0x800000'
saveenv
reset
Back to Arch Linux
setenv mainlineLinux yes
setenv arcNumber 2743
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
The End
Now to put it back together, set it up with the services I want and put it into production as a house file server and some other sneaky things.
It is basically a Plug Computer, with the following specs:
My goal is to put Arch Linux on it. It seems that no one has done this yet.
What I am going to do, is set-up the system with Debian, which boots from the hard disk. There a number of recipes around to do this, particularly on the openstora.com site. I am following this one http://www.openstora.com/phpBB3/viewtopic.php?t=217
It did not contain all the information, so I thought about writing this walk through and fill in some blanks.
What you need to start is a USB serial cable. I got a Nokia phone data cable from eBay for a few Euros. Cut the end off the cable and solder some header thing on it. I used and old PC motherboard cable that I chopped up.
You also need some method to access the disk as a USB device. I used an old dismantled external drive controller board, which was handy.
To remove the back panel, you need to remove the two screws behind the Disk Release Latches. There are two of those nasty plastic clips about 5cm in from each side. There are two more of these nasty fellas about 9cm down from the top on the left and right side. Gently prise the panel with a small screw driver and it should pop off. Pop it off from the top as there are two clips on the bottom of the panel. These can be seen when looking at the bottom of the case.
You can see the serial port pins at the top of the board.
The pin-outs are from right to left:
Pin Function Notes
1 3.3Vdc Pin is the farthest from the battery.
2 RXD Recieve Data line from Stora.
3 TXD Transmit Data line from Stora.
4 GND Ground.
I will be using 2, 3 and 4, as I have cable made from an old Nokia USB data cable.
I installed tftp-hpa on the laptop, as the tftp server.
Connect stora to real network
Set-up environment for flashing.
setenv mainlineLinux yes setenv arcNumber 2743 setenv ipaddr XXX.XXX.XXX.XXX #This is the IP of your Stora setenv serverip XXX.XXX.XXX.XXX #This is the IP of your TFTP server saveenv reset
The install the files from your tftp server
tftpboot 0x200000 uImage.di
tftpboot 0x800000 uInitrd.di
setenv bootargs console=ttyS0,115200n8 base-installer/initramfs-tools/driver-policy=most
bootm 0x200000 0x800000This will install Debian to the hard disk.
The disk partitioning takes a long time, 40 minutes or so, so go and have a cup of tea or a beer. I wouldn't recommend reboot at this time, cuz I don't know what state the Stora would be in. Perhaps and expensive brick.
Then, it begins installing the system..............
I then followed the remaining instructions on http://www.openstora.com/phpBB3/viewtopic.php?t=217
I got quite a few errors but kept going.
Presto chango! Debian!
aka FAIL
It wouldn't boot. Feck again.
I scrolled down further on that page and began to experiment a bit with the settings.
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
Again FAIL. Again Feck.
I took out the drive and connected it via USB to my laptop.
I ended up with a single partition that had some GPT data in the partition table
# fdisk -l /dev/sdb
WARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk
doesn't support GPT. Use GNU Parted.
Feck again.
I used this link to remove it http://www.rodsbooks.com/gdisk/wipegpt.html
All cool.
Install Arch Linux
My next plan, was to prepare the disk and put an arm version of Arch Linux on it.
What you need is, the board ot whatever to connect your SATA drive to a USB cable. Connect it up.
Mine was /dev/sdb
Partition New Disk
I wanted to have the following disk layout:
/dev/sdb1 = 2Gb plenty of space. I don't want to have to worry that it will fill up and require maintenance at a later date.
/dev/sdb2 = swap of 1Gb
/dev/sdb3 = The rest of the disk
I have taken out some of the disk detail because it just clutters up the page.
> fdisk /dev/sdb
Delete whatever partitions are on the disk.
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
Command (m for help): n
Partition type:
p primary (0 primary, 0 extended, 4 free)
e extended
Select (default p): p
Partition number (1-4, default 1): 1
First sector (2048-3907029167, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-3907029167, default 3907029167): +20G
Command (m for help): n
Partition type:
p primary (1 primary, 0 extended, 3 free)
e extended
Select (default p): p
Partition number (1-4, default 2):
Using default value 2
First sector (41945088-3907029167, default 41945088):
Using default value 41945088
Last sector, +sectors or +size{K,M,G} (41945088-3907029167, default 3907029167): +1G
Command (m for help): n
Partition type:
p primary (2 primary, 0 extended, 2 free)
e extended
Select (default p): p
Partition number (1-4, default 3):
Using default value 3
First sector (44042240-3907029167, default 44042240):
Using default value 44042240
Last sector, +sectors or +size{K,M,G} (44042240-3907029167, default 3907029167):
Using default value 3907029167
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 2048 41945087 20971520 83 Linux
/dev/sdb2 41945088 44042239 1048576 83 Linux
/dev/sdb3 44042240 3907029167 1931493464 83 Linux
Command (m for help): t
Partition number (1-4): 2
Hex code (type L to list codes): 82
Changed system type of partition 2 to 82 (Linux swap / Solaris)
Command (m for help): p
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 2048 41945087 20971520 83 Linux
/dev/sdb2 41945088 44042239 1048576 82 Linux swap / Solaris
/dev/sdb3 44042240 3907029167 1931493464 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
Done
Set-up the file systems and install Arch and Kernel files
I wanted to have journeling so I setup /dev/sdb1 to ext3. It should be reognised as ext2 on boot.
mkfs.ext3 /dev/sdb1
mkfs.ext4 /dev/sdb3
Mount /dev/sdb1 and cd to the mount point
wget http://archlinuxarm.org/os/ArchLinuxARM-armv5te-latest.tar.gz
extract the Arch linux tarball to the root of /dev/sdb1
e.g.
tar zxvf /location/ArchLinuxARM-armv5te-latest.tar.gz
kernel image: http://dl.dropbox.com/u/1397036/stora_di/uImage
initrd image: http://dl.dropbox.com/u/1397036/stora_di/uInitrd
wget the images and copy them into the boot directory of /dev/sdb1
Almost complete.
Finally put the disk back in the stora in the left slot.
Boot into the uBoot prompt.
Here are the settings I found that worked.
setenv mainlineLinux yes
setenv arcNumber 2743
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
Let it run and it should boot into Arch Linux.
Woo Hoo !!!
Restore Original Firmware
It seems that the original firmware is stilled in Nand. To restore this use the following:
setenv mainlineLinux=no
setenv arcNumber
setenv bootcmd_ide
setenv bootcmd 'nand read.e 0x800000 0x100000 0x300000; setenv bootargs $(console) $(bootargs_root); bootm 0x800000'
saveenv
reset
Back to Arch Linux
setenv mainlineLinux yes
setenv arcNumber 2743
setenv bootcmd_ide 'ide reset; ext2load ide 0 0x200000 /boot/uImage; ext2load ide 0 0x800000 /boot/uInitrd'
setenv bootcmd 'setenv bootargs $(console) root=/dev/sda1; run bootcmd_ide; bootm 0x200000 0x800000'
saveenv
reset
The End
Now to put it back together, set it up with the services I want and put it into production as a house file server and some other sneaky things.
Labels:
arch linux,
archlinuxarm,
arm,
house server,
netgear,
stora
Wednesday, February 15, 2012
Bloody Dovecot Error Solved
I added an email account to my email server recently. No problem.
My mail set-up is Arch Linux, Postfix and Dovecot. Thunderbird as a client using Imap.
The problem was, I was getting the following error:
Error: user newuser: Initialization failed: mail_location not set and autodetection failed: Mail storage autodetection failed with home=/home/newUser
Feck!!!
The google machine didn't help.
It took a while, but the solution was to edit the file /etc/dovecot/conf.d/10-mail.conf
Add the line:
mail_location = mbox:~/mail:INBOX=/var/mail/%u
and restart dovecot. Problem solved.
My mail set-up is Arch Linux, Postfix and Dovecot. Thunderbird as a client using Imap.
The problem was, I was getting the following error:
Error: user newuser: Initialization failed: mail_location not set and autodetection failed: Mail storage autodetection failed with home=/home/newUser
Feck!!!
The google machine didn't help.
It took a while, but the solution was to edit the file /etc/dovecot/conf.d/10-mail.conf
Add the line:
mail_location = mbox:~/mail:INBOX=/var/mail/%u
and restart dovecot. Problem solved.
Wednesday, December 21, 2011
Frozen Turkeys @ Lidl and Dunnes
Here is a quick analysis of frozen turkeys purchased @ Lidl and Dunnes
4,5K Turkey @ Lidl = 10 euro
3.5K Turkey @ Dunnes = 6.5 Euro
I roasted both on a Monday. We had sambs etc. on the Tuesday and I made a casserole fella on Tuesday night.
There was a whole breast of turkey left, after making the casserole using the Lidl turkey. Not with the Dunnes one.
This would suggest that the carcass was the same size and the difference in weight was meat. So, and extra Kg in breast meat, perhaps.
Lidl turkey is better value then the Dunnes one. Bloody Gemermans.
This is in now way scientific and is just a perception of a single comparison which was not measured fully.
4,5K Turkey @ Lidl = 10 euro
3.5K Turkey @ Dunnes = 6.5 Euro
I roasted both on a Monday. We had sambs etc. on the Tuesday and I made a casserole fella on Tuesday night.
There was a whole breast of turkey left, after making the casserole using the Lidl turkey. Not with the Dunnes one.
This would suggest that the carcass was the same size and the difference in weight was meat. So, and extra Kg in breast meat, perhaps.
Lidl turkey is better value then the Dunnes one. Bloody Gemermans.
This is in now way scientific and is just a perception of a single comparison which was not measured fully.
Saturday, December 17, 2011
Easy Roast Venison Recipe
I recently got a leg of venison from the beautiful Paul. It was just over 1.5kg in weight, and was from a Sika calf. Milk fed is best, I always say.
I am a big fan of the slow roast method, so I decided to do the same with the venison. Slow roasting is like half roasting half steaming and usually results in a very tender outcome. I have some cast iron pots with heavy lids, which is great for this task. If I am roasting a large piece of meat, I use a standard roasting pan covered with a tin foil tent. It is just as good but more work.
I usually put a head of celery under the meat when I am roasting it. This helps protect it from the heat of the roasting pot. I failed to see the celery that was hidden in plain sight in the fridge, so I used some carrots instead.
Preheat the oven to the highest.
As venison is very lean and the muscles contain virtually no fat, lay some streaky rashers over the top of the meat to help keep it moist.
Simply put the meat on the veg, pour in some hot water, maybe 500ml. I usually then bring it to the boil on the hob before bunging it in the oven. Put it in the oven at max for 20 - 30 mins, then turn it down to 150 degrees centegrade.
Cook it for a further 2 hours. Remove from the heat and let it rest for about 30 mins.
I made the gravy with the remaining juices and some chicken stock I had in the freezer, with a dash of light soy sauce.
The result was truely fantastic. Totally fall off the bone texture. No need to cut it, it just flakes away. So tender. It didn't have a strong gamey flavor either. It was like the best roast beef, only it tasted better.
It was so nice, I even forgot to use the almost obligatory Red Current Jelly.
I will certainly use this method again.

I am a big fan of the slow roast method, so I decided to do the same with the venison. Slow roasting is like half roasting half steaming and usually results in a very tender outcome. I have some cast iron pots with heavy lids, which is great for this task. If I am roasting a large piece of meat, I use a standard roasting pan covered with a tin foil tent. It is just as good but more work.
I usually put a head of celery under the meat when I am roasting it. This helps protect it from the heat of the roasting pot. I failed to see the celery that was hidden in plain sight in the fridge, so I used some carrots instead.
Preheat the oven to the highest.
As venison is very lean and the muscles contain virtually no fat, lay some streaky rashers over the top of the meat to help keep it moist.
Simply put the meat on the veg, pour in some hot water, maybe 500ml. I usually then bring it to the boil on the hob before bunging it in the oven. Put it in the oven at max for 20 - 30 mins, then turn it down to 150 degrees centegrade.
Cook it for a further 2 hours. Remove from the heat and let it rest for about 30 mins.
I made the gravy with the remaining juices and some chicken stock I had in the freezer, with a dash of light soy sauce.
The result was truely fantastic. Totally fall off the bone texture. No need to cut it, it just flakes away. So tender. It didn't have a strong gamey flavor either. It was like the best roast beef, only it tasted better.
It was so nice, I even forgot to use the almost obligatory Red Current Jelly.
I will certainly use this method again.
Sunday, April 10, 2011
Dovecot Failed after upgrade
I upgraded my SheevaPlug server which runs PlugBox.
It operates my email and internet server, plus other services.
Anyway, I ran 'pacman -Syu', as you do to upgrade the OS.
Among other things, Dovecot was upgraded.
Having restarted Dovecot, I got the following error:
doveconf: Fatal: Error in configuration file /etc/dovecot/conf.d/10-ssl.conf line 14: ssl_key: Can't open file /etc/ssl/private/dovecot.key: No such file or directory
My response was something like, Feck, Feck, Feck.
Consulting Dr. Google gave me no solace.
I decided that I needed to generate a new certificate and key. I ran the following:
openssl req -new -x509 -nodes -config /etc/ssl/dovecot-openssl.cnf -out dovecot.cert -keyout dovecot.key -days 365
and gor the following output:
Generating a 1024 bit RSA private key
.................++++++
............................................++++++
writing new private key to 'dovecot.key'
-----
I moved the files to where /etc/dovecot/conf.d/10-ssl.conf expected them to be.
After restarting dovecot, I had to change the connection settings in Thunderbird to:
Connecting Security: SSL/TLS
Authentication Method: Normal Password
Happy Days........
It operates my email and internet server, plus other services.
Anyway, I ran 'pacman -Syu', as you do to upgrade the OS.
Among other things, Dovecot was upgraded.
Having restarted Dovecot, I got the following error:
doveconf: Fatal: Error in configuration file /etc/dovecot/conf.d/10-ssl.conf line 14: ssl_key: Can't open file /etc/ssl/private/dovecot.key: No such file or directory
My response was something like, Feck, Feck, Feck.
Consulting Dr. Google gave me no solace.
I decided that I needed to generate a new certificate and key. I ran the following:
openssl req -new -x509 -nodes -config /etc/ssl/dovecot-openssl.cnf -out dovecot.cert -keyout dovecot.key -days 365
and gor the following output:
Generating a 1024 bit RSA private key
.................++++++
............................................++++++
writing new private key to 'dovecot.key'
-----
I moved the files to where /etc/dovecot/conf.d/10-ssl.conf expected them to be.
After restarting dovecot, I had to change the connection settings in Thunderbird to:
Connecting Security: SSL/TLS
Authentication Method: Normal Password
Happy Days........
Tuesday, November 9, 2010
The Most Measured Fridge in the World
What would you measure about your fridge?
I wanted to measure Temperature and Energy Usage.
A few months ago, I used two 1-Wire DS18S20 Temperature sensors and OWFS to measure the temperature in the main fridge and the freezer compartment. It is a fairly standard and straightforward set-up which I am not going to cover here. I stick the readings in a MySQL database and produce graphs using gnuplot. Interesting in a very geeky way.
You can see the way behaviour such as leaving the door open for a minute or more can drastically effect the temperature. It can take over an hour go get to a stable temperature.

This is an average day. Not much activity. Quick opens and closes. There is a temperature spike in the freezer about 10 am. This happens about every 30 hours or so and I think this represents the automatic defrost function. This removes the requirement to have to defrost the fridge from time to time. Cool in my book.
The main reason for this article is to outline the process involved in installing a new Currentcost IAM (Individual Appliance Module) and how to extract the readings and process them.
I have using Currentcost sensors and display/receiver for a number of years to measure electricity consumption in my house.
I have a CC128 Display/Receiver Unit connected to a Linux computer which reads the XML output, parses it and stores it in a RRD database and a MySQL database.
I then use a few scripts to gather the data and product graphs which I display on a web page. Excellent stuff.
The set-up is based on the excellent write up on http://www.jibble.org/currentcost/.

So, after waiting for yonkity bonks for the Currentcost IAM to be released, I saw that they were available recently. They measure the energy usage of an particular appliance and send it to your receiver, in my case the CC128.

They are available on Amazon.co.uk for about £30. I am based in Dublin, so the postage was about £20. Feck I thought. My brother, who is also a Currentcost fan, bought 2 and posted it to me. Postage about £10, still to high. They need to do something about that.
Anyway, the time came to install one of the IAMs and set-up the logging and graphing processes. I had a look around but could not find much useful information about how to handle the extra sensors.
I found some information on the Currentcost site here http://www.currentcost.com/cc128/xml.htm. Not really much help though.
What I did at the end of the day, was just configure the new sensor and plugged in the fridge.
I watched the output from the CC128 and noticed, that there were two lines output. One was for the main energy sensor and the other one was from the new sensor.
Here is an example:
<msg><src>CC128-v0.11</src><dsb>00621</dsb><time>13:46:40</time><tmpr>21.9</tmpr><sensor>0</sensor><id>01223</id><type>1</type><ch1><watts>00601</watts></ch1></msg>
<msg><src>CC128-v0.11</src><dsb>00621</dsb><time>13:46:42</time><tmpr>21.9</tmpr><sensor>1</sensor><id>01181</id><type>1</type><ch1><watts>00001</watts></ch1></msg>
As you can see the lines are fairly similar. The first point of note is the sensor number0 and 1 . This was enough to discriminate between the sensors.
I then modified the data collection script as follows:
Original line
m!<ch1><watts>0*(\d+)</watts></ch1>.*<tmpr> *([\-\d.]+)</tmpr>!
had to be changed to
m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>0</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!
as in e.g.
#Sensor 0
if ($line =~ m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>0</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!)
{
my $watts = $2;
my $temp = $1;
system("rrdtool update /var/www/html/currentcost/data/powertemp.rrd N:$watts:$temp");
system("./mysql_bit.sh $watts $temp");
}
#Sensor 1
if ($line =~ m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>1</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!)
{
my $watts1 = $2;
my $temp1 = $1;
system("rrdtool update /var/www/html/currentcost/data/powertemp_mod1.rrd N:$watts1:$temp1");
system("./mysql_module_bit.sh 1 $watts1 $temp1");
}
That was it basically. Everything worked.

Here is an average 4 Hour Graph and Usage of the fridge at the weekend. Some activity, not much.
Bloody hungry machines. It makes up a significant part of our electricity bill. Not much you could do except increase the general minimum temperature. Some research required, I think.
I think I will produce a daily Fridge Electricity Bill. I have done this for the house, based on Dale Lanes idea
If you need more information, leave a comment.
I wanted to measure Temperature and Energy Usage.
A few months ago, I used two 1-Wire DS18S20 Temperature sensors and OWFS to measure the temperature in the main fridge and the freezer compartment. It is a fairly standard and straightforward set-up which I am not going to cover here. I stick the readings in a MySQL database and produce graphs using gnuplot. Interesting in a very geeky way.
You can see the way behaviour such as leaving the door open for a minute or more can drastically effect the temperature. It can take over an hour go get to a stable temperature.

This is an average day. Not much activity. Quick opens and closes. There is a temperature spike in the freezer about 10 am. This happens about every 30 hours or so and I think this represents the automatic defrost function. This removes the requirement to have to defrost the fridge from time to time. Cool in my book.
The main reason for this article is to outline the process involved in installing a new Currentcost IAM (Individual Appliance Module) and how to extract the readings and process them.
I have using Currentcost sensors and display/receiver for a number of years to measure electricity consumption in my house.
I have a CC128 Display/Receiver Unit connected to a Linux computer which reads the XML output, parses it and stores it in a RRD database and a MySQL database.
I then use a few scripts to gather the data and product graphs which I display on a web page. Excellent stuff.
The set-up is based on the excellent write up on http://www.jibble.org/currentcost/.
So, after waiting for yonkity bonks for the Currentcost IAM to be released, I saw that they were available recently. They measure the energy usage of an particular appliance and send it to your receiver, in my case the CC128.

They are available on Amazon.co.uk for about £30. I am based in Dublin, so the postage was about £20. Feck I thought. My brother, who is also a Currentcost fan, bought 2 and posted it to me. Postage about £10, still to high. They need to do something about that.
Anyway, the time came to install one of the IAMs and set-up the logging and graphing processes. I had a look around but could not find much useful information about how to handle the extra sensors.
I found some information on the Currentcost site here http://www.currentcost.com/cc128/xml.htm. Not really much help though.
What I did at the end of the day, was just configure the new sensor and plugged in the fridge.
I watched the output from the CC128 and noticed, that there were two lines output. One was for the main energy sensor and the other one was from the new sensor.
Here is an example:
<msg><src>CC128-v0.11</src><dsb>00621</dsb><time>13:46:40</time><tmpr>21.9</tmpr><sensor>0</sensor><id>01223</id><type>1</type><ch1><watts>00601</watts></ch1></msg>
<msg><src>CC128-v0.11</src><dsb>00621</dsb><time>13:46:42</time><tmpr>21.9</tmpr><sensor>1</sensor><id>01181</id><type>1</type><ch1><watts>00001</watts></ch1></msg>
As you can see the lines are fairly similar. The first point of note is the sensor number
I then modified the data collection script as follows:
Original line
m!<ch1><watts>0*(\d+)</watts></ch1>.*<tmpr> *([\-\d.]+)</tmpr>!
had to be changed to
m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>0</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!
as in e.g.
#Sensor 0
if ($line =~ m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>0</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!)
{
my $watts = $2;
my $temp = $1;
system("rrdtool update /var/www/html/currentcost/data/powertemp.rrd N:$watts:$temp");
system("./mysql_bit.sh $watts $temp");
}
#Sensor 1
if ($line =~ m!<tmpr>\s*(-*[\d.]+)</tmpr><sensor>1</sensor>.*<ch1><watts>0*(\d+)</watts></ch1>!)
{
my $watts1 = $2;
my $temp1 = $1;
system("rrdtool update /var/www/html/currentcost/data/powertemp_mod1.rrd N:$watts1:$temp1");
system("./mysql_module_bit.sh 1 $watts1 $temp1");
}
That was it basically. Everything worked.

Here is an average 4 Hour Graph and Usage of the fridge at the weekend. Some activity, not much.
Bloody hungry machines. It makes up a significant part of our electricity bill. Not much you could do except increase the general minimum temperature. Some research required, I think.
I think I will produce a daily Fridge Electricity Bill. I have done this for the house, based on Dale Lanes idea
If you need more information, leave a comment.
Tuesday, October 12, 2010
SheevaPlug Plug Computer Rises From the Ashes
I got a SheevaPlug Plug Computer over a year ago. I installed Fedora 12 on an SD card. Worked great.
I used it as part of my home automation set-up. I had 1-wire temperature and humidity sensors and a barometer running off it. I also had my Homeeasy 1-Wire remote control system running on it.

Anyway, one day I decided to tidy up the cabling in the area the plug computer lived. This also involved moving the plug computer to a new socket.
I powered it down in the correct manner and moved it. Plugged it back in and it did not come back on. Stuck an USB console on it and it was dead.
There was some furious work to port the 1-Wire scripts and functionality to another device. In this event, it was a Linksys NSLU2 which I had configured with OpenWRT a week earlier. Surprisingly, it was well capable of the job. It became my new 1-Wire controller.
I searched the forums and they were talking about the boot loader being corrupt. I followed that line of enquiry for a while and got nowhere. Still dead. All that would happen was there was flashing leds. No help.
I eventually found some talk about a dud power supply. I cracked the lid on it and tried my trusty multimeter. The result was that there was only 2.1 volts coming out of the power supply instead on 5 volts. Progress at last.
After a few snips, I was able to get a power supply from an old mobile phone soldered to the connector from the original power supply to power the motherboard of the plug computer. This was the business. The plug computer was back on the air.
The SD card was inadvertently pulled out of the plugcomputer while it was on and resulted in a crashed SD card. Feck again.
It was actually relatively easy to reinstall the Fedora 12 file system using the original Instructables article. Note to self, do a backup of the SD card this time.
I found some articles on repairing the original power supply but I decided not to go down that route.

There was also mention of www.globalscaletechnologies.com selling a replacement power supply. It turns out to be €7.54 but the delivery was €39.19. Way too much. The warranty from globalscaletechnologies was only for 1 month. I was fecked, so I said "feck that".
I found that there was a UK supplier http://www.newit.co.uk/ that had the power supply at a much more acceptable price around €20. Cool. I went about ordering it.
It arrived a few days later. The install was a breeze. Finished the set-up of SD install and off we went.
Success.
Everyone's a winner!.
I used it as part of my home automation set-up. I had 1-wire temperature and humidity sensors and a barometer running off it. I also had my Homeeasy 1-Wire remote control system running on it.

Anyway, one day I decided to tidy up the cabling in the area the plug computer lived. This also involved moving the plug computer to a new socket.
I powered it down in the correct manner and moved it. Plugged it back in and it did not come back on. Stuck an USB console on it and it was dead.
There was some furious work to port the 1-Wire scripts and functionality to another device. In this event, it was a Linksys NSLU2 which I had configured with OpenWRT a week earlier. Surprisingly, it was well capable of the job. It became my new 1-Wire controller.
I searched the forums and they were talking about the boot loader being corrupt. I followed that line of enquiry for a while and got nowhere. Still dead. All that would happen was there was flashing leds. No help.
I eventually found some talk about a dud power supply. I cracked the lid on it and tried my trusty multimeter. The result was that there was only 2.1 volts coming out of the power supply instead on 5 volts. Progress at last.
After a few snips, I was able to get a power supply from an old mobile phone soldered to the connector from the original power supply to power the motherboard of the plug computer. This was the business. The plug computer was back on the air.
The SD card was inadvertently pulled out of the plugcomputer while it was on and resulted in a crashed SD card. Feck again.
It was actually relatively easy to reinstall the Fedora 12 file system using the original Instructables article. Note to self, do a backup of the SD card this time.
I found some articles on repairing the original power supply but I decided not to go down that route.

There was also mention of www.globalscaletechnologies.com selling a replacement power supply. It turns out to be €7.54 but the delivery was €39.19. Way too much. The warranty from globalscaletechnologies was only for 1 month. I was fecked, so I said "feck that".
I found that there was a UK supplier http://www.newit.co.uk/ that had the power supply at a much more acceptable price around €20. Cool. I went about ordering it.
It arrived a few days later. The install was a breeze. Finished the set-up of SD install and off we went.
Success.
Everyone's a winner!.
Wednesday, July 21, 2010
Homeasy Remote PC Control - Linux & 1-Wire
As discussed previously, I am a big fan of the Homeeasy range of products.
I have quite a few in use around the house. 16 in total.
My first adventure in home automation involved some X10 devices. These were OK but were slow to respond and overall unreliable.
I had appliance and lighting modules, some bayonet modules, pir and remote controls. Also some wireless transceivers and a controller. Now all unused.
I then came across the Homeeasy range of products. I think my brother Peter introduced me to them. Fairly cheap, so I got a few of them.
Came across James @ Notes from a small field, who was talking about setting up an arduino to operate like a Homeeasy remote control.
After a bit of work and revision, I was able to get a working arduino/homeeasy rig working. Here is a link to that particular project: Simple/Manual Protocol Arduino/Homeeasy
The final version also contained an Ethernet shield and operated as a web server. Various commands were sent to the web server using the URL to pass parameters, which were picked up by the arduino. Very good actually. It has been running for almost a year now. No crashes.
So, it worked fairly well. It is about 80% effective. It was mainly used in the kitchen and there were some dead spots that were only about 10% effective. Don't know why. Swapped modules, etc., still dead spots. This would have been OK for me but not acceptable for SWMBO and the other house inhabitants.
As hinted above, this set-up only accounted for the transmission of the Homeeasy Simple Protocol. This is not compatible with all the Homeeasy range of products. They also use an Advanced Protocol for some of their devices, such as sockets and wall switches.
I wanted to use some of these switches and sockets, so I had to get a method to remotely control them.
Around that time, there was a lot of activity in the adruino homeeasy controller area.
There were a number of options available for Homeeasy Advanced Protocol programming on the arduino.
I tried many of them but found less then 100% reliability. Again some dead zones or sometimes it would work and sometimes it wouldn't. Definitely not acceptable.
During this journey, I noticed that the hand held remote was very reliable. I presume it was something to do with my implementation. Personally, I think there is an aerial issue. I don't know anything about that, so I parked this project and moved to another approach.
I read about using the actual Homeeasy hand held remote wired up to an arduino on Instructables and something similar in the Practical Arduino book.
Easy enough. I put it together and it worked perfectly. 100%
So, then I thought, the arduino is all very good, but all I am doing is using the arduino as a smart relay controller.
I have been using the Dallas 1-Wire devices for a number of years to read temperature and other weather readings. I also use a 1-Wire relay to control my boiler.
Using a schedule stored in a database, the boiler goes on and off as required. This is the subject of another post, I think.
I decided to use 1-Wire switches to control the hand held remote.
I got myself a breadboard some wires and a couple of DS2408 chips and my trusty USB 1-Wire controller.

Again following the wiring layout on Instructables - Arduino Home automation, got it all up and running in no time.
There are 4 on and 4 off buttons and the DS2408 has 8 switches.
To utilise the 4 zones, I needed another 4 switches. I used the other DS2408 for this.

The 1-Wire system is controlled from a Linux box on the network. I wrote a PHP script that presented me with various devices and On/Off buttons to control them.
I used OWFS (One Wire File System) suite of programs to talk directly with the 1-Wire switches.
Happy days.
I have quite a few in use around the house. 16 in total.
My first adventure in home automation involved some X10 devices. These were OK but were slow to respond and overall unreliable.
I had appliance and lighting modules, some bayonet modules, pir and remote controls. Also some wireless transceivers and a controller. Now all unused.
I then came across the Homeeasy range of products. I think my brother Peter introduced me to them. Fairly cheap, so I got a few of them.
Came across James @ Notes from a small field, who was talking about setting up an arduino to operate like a Homeeasy remote control.
After a bit of work and revision, I was able to get a working arduino/homeeasy rig working. Here is a link to that particular project: Simple/Manual Protocol Arduino/Homeeasy
The final version also contained an Ethernet shield and operated as a web server. Various commands were sent to the web server using the URL to pass parameters, which were picked up by the arduino. Very good actually. It has been running for almost a year now. No crashes.
So, it worked fairly well. It is about 80% effective. It was mainly used in the kitchen and there were some dead spots that were only about 10% effective. Don't know why. Swapped modules, etc., still dead spots. This would have been OK for me but not acceptable for SWMBO and the other house inhabitants.
As hinted above, this set-up only accounted for the transmission of the Homeeasy Simple Protocol. This is not compatible with all the Homeeasy range of products. They also use an Advanced Protocol for some of their devices, such as sockets and wall switches.
I wanted to use some of these switches and sockets, so I had to get a method to remotely control them.
Around that time, there was a lot of activity in the adruino homeeasy controller area.
There were a number of options available for Homeeasy Advanced Protocol programming on the arduino.
I tried many of them but found less then 100% reliability. Again some dead zones or sometimes it would work and sometimes it wouldn't. Definitely not acceptable.
During this journey, I noticed that the hand held remote was very reliable. I presume it was something to do with my implementation. Personally, I think there is an aerial issue. I don't know anything about that, so I parked this project and moved to another approach.
I read about using the actual Homeeasy hand held remote wired up to an arduino on Instructables and something similar in the Practical Arduino book.
Easy enough. I put it together and it worked perfectly. 100%
So, then I thought, the arduino is all very good, but all I am doing is using the arduino as a smart relay controller.
I have been using the Dallas 1-Wire devices for a number of years to read temperature and other weather readings. I also use a 1-Wire relay to control my boiler.
Using a schedule stored in a database, the boiler goes on and off as required. This is the subject of another post, I think.
I decided to use 1-Wire switches to control the hand held remote.
I got myself a breadboard some wires and a couple of DS2408 chips and my trusty USB 1-Wire controller.
Again following the wiring layout on Instructables - Arduino Home automation, got it all up and running in no time.
There are 4 on and 4 off buttons and the DS2408 has 8 switches.
To utilise the 4 zones, I needed another 4 switches. I used the other DS2408 for this.
The 1-Wire system is controlled from a Linux box on the network. I wrote a PHP script that presented me with various devices and On/Off buttons to control them.
I used OWFS (One Wire File System) suite of programs to talk directly with the 1-Wire switches.
Happy days.
Sunday, July 18, 2010
One of my mothers roses
My mother has always been a keen gardener. She had a very large garden, when she lived on the north side of Dublin. She moved to the Dark Side (south) about four years ago.

I remember, when I lived there during those eternal summers, having to work in the garden when all my friends were out playing. Possibly another blog.
The new garden was much much smaller then the previous one. Probably about one twentieth. She is pushing on a bit, so it is not too much of a problem having a smaller garden.

She was always a big fan of roses.
She has being building up a stock of roses over the past few years and was having great success with the blooms.

I often get a few rose blooms when I visit her. Some are really spectacular.

This is an example of the best yet.
I remember, when I lived there during those eternal summers, having to work in the garden when all my friends were out playing. Possibly another blog.
The new garden was much much smaller then the previous one. Probably about one twentieth. She is pushing on a bit, so it is not too much of a problem having a smaller garden.
She was always a big fan of roses.
She has being building up a stock of roses over the past few years and was having great success with the blooms.
I often get a few rose blooms when I visit her. Some are really spectacular.
This is an example of the best yet.
Monday, June 14, 2010
I've found it. Ultimate Chilli Sauce / Salsa
After many years spent in the quest for the best Chili Sauce, I determined that the only way to find one is to make it myself.
There are basically at least two types, cooked and uncooked. I prefer the uncooked varieties, as they are usually sharper and more pungent in flavour.
I have tried many, from the US, Mexico, Africa and Asia.
Some I found were quite good but lacked the roundness in flavour I was searching for. Others were too mild or burned my face off. Not quite what I was looking for.
Anyway, I tried a number of recipes from books and the net. Not quite there.
I more or less stumbled on this one.
I bought two packets of fresh chillies in a local supermarket chain store (Dunnes Stores). This is often a bit suspect, as I am sure that they are just ordered from the suppliers, without respect to the heat they produce. In fact I bought some there a few months ago that were very very mild. The past few times I bought them they were nice and hot.
I don't have easy access to any Asian shops, so it is usually supermarket chillies or nothing.
OK. I bought my packets of chillies and did nothing with them.
They were getting a bit limp in the fridge, so I thought I better use them.
I searched in the cupboard for something suitable to make a chilli sauce with. I often use lime juice to add a bit of liquid and flavour. No limes. Feck, I said.
Found a large tin of Pineapple. Cool, I thought.
I am a big fan of Garlic, so I selected a whole bulb of it.
So, I had:
1 x Tin of Pineapple
1 x Bulb of Garlic
2 x Packets of fresh Chillies (Probably 10 or 12 in total)
1 x Blender
Peel the garlic and chop the chillies into large pieces.
Put the flesh of the pineapple into the blender. Reserve the juice/syrup. You may need the juice if the mixture is too dry.
Add a half to a full teaspoon of salt, depending on taste.
Add the chillies and garlic to the blender and zizz.
Blend until you get the consistency you like. I like it a bit chunky.
Add more juice if necessary.
Give it a taste.
Adjust seasoning.
Too Hot = Enjoy it. Or add another tin of pineapple.
Not hot enough = Add a teaspoon of chilli powder or more chillies.
Too much Garlic = Enjoy it.
I put the result into jars and store in the fridge.
Remember, this is an uncooked sauce, so all the crazy yeasts in the air will be trying to do rude things in the sauce. The fridge will take the lead out of their pencils. The worst that will happen, is that the sauce will ferment.
Love the Burn
There are basically at least two types, cooked and uncooked. I prefer the uncooked varieties, as they are usually sharper and more pungent in flavour.
I have tried many, from the US, Mexico, Africa and Asia.
Some I found were quite good but lacked the roundness in flavour I was searching for. Others were too mild or burned my face off. Not quite what I was looking for.
Anyway, I tried a number of recipes from books and the net. Not quite there.
I more or less stumbled on this one.
I bought two packets of fresh chillies in a local supermarket chain store (Dunnes Stores). This is often a bit suspect, as I am sure that they are just ordered from the suppliers, without respect to the heat they produce. In fact I bought some there a few months ago that were very very mild. The past few times I bought them they were nice and hot.
I don't have easy access to any Asian shops, so it is usually supermarket chillies or nothing.
OK. I bought my packets of chillies and did nothing with them.
They were getting a bit limp in the fridge, so I thought I better use them.
I searched in the cupboard for something suitable to make a chilli sauce with. I often use lime juice to add a bit of liquid and flavour. No limes. Feck, I said.
Found a large tin of Pineapple. Cool, I thought.
I am a big fan of Garlic, so I selected a whole bulb of it.
So, I had:
1 x Tin of Pineapple
1 x Bulb of Garlic
2 x Packets of fresh Chillies (Probably 10 or 12 in total)
1 x Blender
Peel the garlic and chop the chillies into large pieces.
Put the flesh of the pineapple into the blender. Reserve the juice/syrup. You may need the juice if the mixture is too dry.
Add a half to a full teaspoon of salt, depending on taste.
Add the chillies and garlic to the blender and zizz.
Blend until you get the consistency you like. I like it a bit chunky.
Add more juice if necessary.
Give it a taste.
Adjust seasoning.
Too Hot = Enjoy it. Or add another tin of pineapple.
Not hot enough = Add a teaspoon of chilli powder or more chillies.
Too much Garlic = Enjoy it.
I put the result into jars and store in the fridge.
Remember, this is an uncooked sauce, so all the crazy yeasts in the air will be trying to do rude things in the sauce. The fridge will take the lead out of their pencils. The worst that will happen, is that the sauce will ferment.
Love the Burn
Saturday, April 10, 2010
433mhz RF Radio Controller Wireless Remote Control
I picked up one of these gadgets recently on eBay. Pretty good, really.
It consists of a remote control and receiver module.

There are 4 buttons (A to D) on the remote that switches the lines on or off.
It works on a latch system. One press on, one press off.
While this action has its uses, I feel that it is a bit limited in a home automation scenario.
433mhz devices are not always 100% reliable. This frequency is heavily used by many devices and can cause interference.
So, you press a button and wonder, is the device still Off or On? Who the feck knows. Press it again and you are still in the same position. Did it turn On or Off???
I prefer systems that have specific On and Off buttons.
Anyway, this latch type of devices still have many uses.
An On/Off system can be easily designed. Button A = On, B = Off. The same with buttons C and D.
Or just 4 On buttons.

The receiver is fairly straightforward, as the image shows.
I had a bit of a problem with the pin outs. By receiver board had no pin legend. I was able to work out the pins of interest. Then I noticed that the advert had the pins labelled. Doh! I was correct anyway, so no problem.
Specifications:
* Channels: 4
* RF radio: 433MHz
* Operating range: up to 300m (984ft)
* Power: 4.5 – 7V
* Dimensions: 4.5 x 2cm (1.8 x 0.8”)
* Weight: 5g
Pin Assignment :
* D0: Output 0
* D1: Output 1
* D2: Output 2
* D3: Output 3
* GND: Ground
* VT: Switching voltage (will be transmitted to the corresponding output when pressing a button)
* VCC: Supply Voltage
I wired it up and it works.
I connected it to a 1-Wire Switch, a DS2408.
The DS2408 is a very versatile device. While it can be used as a switch, it can also be used to sense a 5 volt signal.
It is an 8 port switch but I am only using 4 for sensing voltage.
Using OWFS (1-Wire File System), I was able to detect when a button has been pressed.
Uber cool.
I can detect when a button is pressed and use the computer to take some action, such as switching on or off a device or a number of devices. Not quite sure yet.
What I think I will do is pop an opto-coupler into the mix and use the DS2408 to control the receiver.
For example:
1. Press a button
2. Sense the voltage using the DS2408 and do something
3. Switch off the power to the receiver and back on again.
4. This will clear the sensed voltage and mean that every button press is easily detected as an event request.
It consists of a remote control and receiver module.

There are 4 buttons (A to D) on the remote that switches the lines on or off.
It works on a latch system. One press on, one press off.
While this action has its uses, I feel that it is a bit limited in a home automation scenario.
433mhz devices are not always 100% reliable. This frequency is heavily used by many devices and can cause interference.
So, you press a button and wonder, is the device still Off or On? Who the feck knows. Press it again and you are still in the same position. Did it turn On or Off???
I prefer systems that have specific On and Off buttons.
Anyway, this latch type of devices still have many uses.
An On/Off system can be easily designed. Button A = On, B = Off. The same with buttons C and D.
Or just 4 On buttons.

The receiver is fairly straightforward, as the image shows.
I had a bit of a problem with the pin outs. By receiver board had no pin legend. I was able to work out the pins of interest. Then I noticed that the advert had the pins labelled. Doh! I was correct anyway, so no problem.
Specifications:
* Channels: 4
* RF radio: 433MHz
* Operating range: up to 300m (984ft)
* Power: 4.5 – 7V
* Dimensions: 4.5 x 2cm (1.8 x 0.8”)
* Weight: 5g
Pin Assignment :
* D0: Output 0
* D1: Output 1
* D2: Output 2
* D3: Output 3
* GND: Ground
* VT: Switching voltage (will be transmitted to the corresponding output when pressing a button)
* VCC: Supply Voltage
I wired it up and it works.
I connected it to a 1-Wire Switch, a DS2408.
The DS2408 is a very versatile device. While it can be used as a switch, it can also be used to sense a 5 volt signal.
It is an 8 port switch but I am only using 4 for sensing voltage.
Using OWFS (1-Wire File System), I was able to detect when a button has been pressed.
Uber cool.
I can detect when a button is pressed and use the computer to take some action, such as switching on or off a device or a number of devices. Not quite sure yet.
What I think I will do is pop an opto-coupler into the mix and use the DS2408 to control the receiver.
For example:
1. Press a button
2. Sense the voltage using the DS2408 and do something
3. Switch off the power to the receiver and back on again.
4. This will clear the sensed voltage and mean that every button press is easily detected as an event request.
Subscribe to:
Posts (Atom)

























