Week whatever – Designed a Circuit board using Eagle Cad

So I’ve been off doing all sort of things but not blogging and am now getting back to documemnting my fun on my Blog. I’ll give an update soon on the on going progress on various things but at this point I am crazy excited about making a board.  This came about when I discovered (thru Joe LeGasse) that there is a board service through Seed Studio to have boards made really (really) cheaply. Ten 2-layer boards of a 50mm x 50 mm with plate through holes, solder mask and silkscreen are $9.90 plus shipping ($3.87). There are other options as well. The service is called Fusion PCB so check it out.

I have been working on a controller for an industrial strobe light that I purchased on ebay a number of years ago. It’s a motion analysis strobe made by Kodak that will accurately strobe up to 2kHz but just has a BNC jack for a trigger signal (no timing electronics). I’ve borrowed a function generator from work in the past to use it occasionally but have wanted to build a good trigger circuit.

I put something together on an arduino that works well. It uses the 16-bit counter/timer to count 16MHz clocks to generate the singal on arduino Pin 9, which is directly connected to timer/counter OC1A. I also connected an LCD shield from adafruit that has 5 buttons on it so that I could set the frequency. This is working great. I was about to package this up as a final gadget when I found out about the Fusion service. So I put together a board that has an ATMega328, 6 pin interface to an LCD, 4 buttons a 12V output for the strobe and an LED that blinks with the strobe.

I bought Eagle light for $69. I know there is a free version available but I wanted to get the latest version and upgrade and I know I will be using this a lot and maybe for something commercial (who knows). I also think that software professionals should be paid for their effort and this is professional grade product.

I copied the ATMega328 stuff from boarduino. This has the power supply, connection to the arduino USB programmer using an FDTI interface, a connector for ISP/Debug and the AVR part. I stripped out the connectors and the connection of the reset line through a capacitor to the FDTI interface (this connection disables the ISP debugging capabilty). I added the circuitry I wanted and place and routed the board. Even as a rookie with eagle cad this took me only about 6 hours to make the schematic, place the parts, route the board and generate the gerber files. I paid the $13.77 and emailed the files to Seed Studio and I should have the boards in a few weeks.

The schematic and board files are at https://github.com/gdhamp/Strobe-Controller. I’ll move the code into this repository soon.

Week 4+ – Beagleboard RAID sever is working.

As it turned out, one of the error types I was seeing was of no consequence.  The mtdblock2 errors are only seen at system initialization when Linux is probing devices. During bootup, it queries the block devices to determine if they contain valid file systems. The NAND block device (mtdblock2) gives errors on the read. This is because the TI omap processor boots from the NAND and uses HW ECC during its boot sequence so the memory is written using HW ECC. When Linux accesses it, it is using SW ECC and the reads generate errors. So the probe of the NAND device gives errors, which can be safely ignored because there is no file system on it anyway.

I was able to get a 3.2.3 kernel running and the root file system is on the SD card (mmc block device). I installed the mdadm package and moved the RAID 1 USB disks. The RAID volume was recognized and I was able to mount it without issue. I configured my new server on my home network as an NFS mount so I can reach it from my other system. I also set up port mapping on my DSL modem to provide ssh access from the internet.

Now I have a RAID server running at under 10 watts. Awesome.

Here it is. It’s a bit cumbersome because the beagleboard doesn’t have on-board ethernet and it only has one USB port. It gets its 5v from the powered usb hub and the ethernet is on usb as well (black thing sticking up from the USB hub). The 2 disk drives (green) are 120GB WD passport drives that I’ve had for a while. The other connector is a serial port in case I have problems that preclude me from getting to it from the network.

 

To Mayor Brown

I am disgusted. I had been feeling proud about living in Buffalo and having a leadership that acted differently than other cities and would allow the voices of the people to be heard. I heard Mayor Brown on the radio yesterday indicating that he thought an agreement would be reached to allow the protester to stay. Now I am feeling complete disgust for the city leadership that changed the terms of the permit for the peaceful encampment and then forcibly evicted the occupiers. Certainly these eviction contingencies were in place when Brown spoke yesterday and he must have known that the new terms would not be agreed to. I hate that my mayor lied to me and I am no longer proud to be a Buffalonian.

George Hampton

Week 3 – Struggling with Beagleboard

My goal this week was to set up my Beagleboard as a RAID server. I have had a Dell system with 2 external USB disk drives set up as RAID 1 as my server for the past few years and it has served me well but I don’t like the idea of leaving it powered on all the time as I am pretty anal about watching my power usage. I decided to set up the Beagleboard as my server for two reason: 1. less power – the entire system with disks is less than 10 watts. 2. I will soon be getting a Raspberry Pi and the Beagleboard will no longer be of interest as a development platform.

Well, this week turned into a massively frustrating exerience with the Beagleboard trying to get Linux running. I continue to see errors with the MMC card no matter what I do. I am trying to use a Ubuntu arm build and if I use either the curent 11.10  or 11.04  releases I see a boat load of these errors:

[  181.645996] mmcblk0: error -84 transferring data, sector 4603160, nr 32, cmd response 0x900, card status 0xb00
[  181.735992] mmcblk0: error -84 transferring data, sector 4604216, nr 136, cmd response 0x900, card status 0xb00

If I go back to 10.10, I see a similar boat, but it is full of these errors:

[   20.931884] end_request: I/O error, dev mtdblock2, sector 8
[   20.944763] uncorrectable error :
[   20.948272] end_request: I/O error, dev mtdblock2, sector 128
[   20.961456] uncorrectable error :

I have tried several different SD cards and it acts the same so I am guessing there is some issue with the MMC drivers in the linux kernel for ARM.  The lack of people complaining about this when I google it gives me a bit of suspicion about this but the fact that it acts differently under different Linux kernels make me think that there is something fishy going on.

So here is my plan. I am going to spend another week on this project. First I will try the Ångström distribution for the Beagleboard and see if the MMC errors persist. If not, great, I can get the RAID services running and perhaps take on my next project. If the errors persist, I’ll dig into the kernel sources and see if I can do anything about it. I don’t have access to an ARM emulator, so I will just be able to look at the code and MMC specs to see if I can determine what is going on and fix it. I plan to either have this working by next Sunday, or I simply give up and buy an extra Raspberry Pi board for the server.  Even if this turns into a two week failure, I’ll have learned some stuff about the Linux kernel and MMC protocols.

I also started my oximeter project. I took apart a commercial oximeter that I bought to see what makes it tick. I’ll post pictures as I dig into the project more.

Also, I got a pad lock open that I don’t know the combination to using a coke can (look here).

B-O-X

So this week I finished just under the wire. I made a sign out of EL wire to take to Buffalo Bandits games so that when the opposing team get a penalty, I can celebrate with some geeky flair. Here is the result:

B-O-X finished (click on this to watch the video)

Most of the work on this was attaching the EL wire to the piece of carpet that I bought at Home Depot. I did the layout in chalk and then attached the EL wire by stitching it with embroidery floss. This took several hours as I am not so skilled at hand stitching.  I then wired the EL wire to a cat-5 network cable which was used to power the lights.  This attaches to a box that has a 3 AA batteries, three AC inverters to power the EL wire and 3 switches (OK so it has four switches but one isn’t used because I had the crazy idea that I could light all three just by wiring another switch an powering all three. luckily I drew out the wiring diagram right before I started soldering and realized my blunder)(UPDATE 23Jan2012-16:14: So I realized in the shower this morning that I just need some diodes to allow the 4th switch to turn on all three letters in a way that doesn’t affect the other switches, I’ll update the circuit and post the schematic at some point).

I still need to wash off the chalk and cover the curly turns but I am calling it done and I will take care of these cosmetic things when I go to the Bandits game (I can’t make the game this week but I’ll be there on Feb 4).

Here are some pictures.

 

 

Speak out against SOPA and PIPA

Do your part.

I sent this to my Congressional Representatives:

Hello,

I am writing to speak out against the bills before Congress regarding internet piracy – H.R.3261 “Stop Online Piracy Act” and S.968 “PROTECT IP”. I believe that these bills are flawed and overly broad in their means of enforcement and do not provide the proper processes of review and appeal which could lead so serious abuses. It is my understanding that these bills would allow action to be taken against alleged copyright infringers based solely on accusation of a content provider. This is contrary to the core values of America’s ideas of due process and innocence until proven guilty.

I am an internet user that does respect the intellectual property rights of content providers. I consider it important to properly compensate providers of creative content in order to allow them to survive and prosper and create more content. I agree that content providers need a means to protect their intellectual property but passing a bill that provides such broad powers scares me. I have for many years considered the internet the best embodiment of the first amendment – everyone now has a public forum to voice their opinion. This is a great thing and we, as a nation, should embrace and cherish this and not allow this technological advancement that gives everyone a voice to be limited by commercial interest.  I am not suggesting that enforcement of intellectual property rights should not be enforced it is simply that we need to enact laws that strike a balance between the individual rights of free expression and the rights of content providers to protect their commercial interests. I believe that the bills being considered do not find this balance and have to potential to damage the ability of the internet to provide an “individual soapbox” to all of us.
In essence, I believe that Congress can and should do a better job and draft bills that do more to protect the openness of the internet while still allowing content creator to protect their commercial interest.

Respectfully,

George Hampton