Apr 01

RFduino, single chip arduino and Bluetooth

The RFduino is an arduino compatible made using the Nordic 32-bit ARM Cortex-M0 processor. The cool thing about this is that it can run arduino code and has bluetooth built in. If I can find something like this that can do RF mesh networking (or maybe bluetooth can be used, though it's usually for short range applications) so I can make wireless sensor nodes/laser tag modules that can communicate to a central hub. Just an idea.

Mar 26

ATmega32U4 vs ATmega328P

I am thinking about using an ATmega32U4 instead of the ATmega328P for my laser tag project. The main advantage of the 32U would be built in USB (at the cost of built in serial hardware. Oh darn, I can use software serial. Not a big deal). The 32U is also twice as expensive. The table below summarizes the differences that matter for the laser tag project (there are many differences. I only care about the ones that my project needs. Mainly, programmability and cost; both chips have the functionality that I need).

Microprocessor ATmega32U4 ATmega328P
USB Yes No
Serial (hardware) No Yes
Price (Quantity = 1) $6.04 $3.05
Price (Quantity = 100) $3.42 $1.73
Barebones Arduino $22.95 (adafruit) $29.95 (adafruit)

But, of course, there are similarities. Both chips have 32 kB of flash memory for storing programs, and both have hardware timers, PWM and enough output for the basic laser tag game that I want to implement. Therefore, since both of these chips have these properties, this information has no effect on my decision because it does not help me distinguish which alternative is better.

Both processors are supported (can be programmed with) the arduino IDE, which makes my life a lot easier. Since the 32U doesn't need an FTDI chip for USB to serial conversion, it saves about $15 for the cost of the board. As of now, I should use the 32U instead of the 328P, since it will make the device cheaper by implementing USB communication on chip.

Dangerous Prototypes posted an article about Paperduino, an arduino Leonardo (Leonardo uses the 32U) clone. It has a cool tutorial on putting a paper label onto the board as well, which is a nice touch. For more information on the 32U4 and the Leonardo, the guys at arduino posted a great article.

Mar 22

Laser Tag Parts and Resources

Open Source laser tag already exists. Miles Tag is an open source laser tag project that has already developed open source laser tag modules. So why would I reinvent the wheel? I'm not. The purpose of my laser tag project is to teach other people how to build the units themselves and understand the science behind it.

So, here's a link to their tagging protocol. This protocol is the same as Version 2 of my laser tag project. If version 3 (serial) doesn't work, then I'll go back to this method of communication. They also have information about lenses, which is something I haven't looked into yet.

Also, their store has parts and part numbers. I may as well use standard components. Like their IR LED. I probably won't buy these parts from them, since I will most likely be able to get them from mouser, digikey or Jameco for less, but I do appreciate the effort that went into these devices. This is a great resource.

Mar 21

Solar Panel Battery Charger Circuit

One of my problems with batteries is that they die (and that they're so dramatic. Other electronics break, but not batteries. They die. They were living, electricity feeding things that are now dead. It's sad.). There are solar charging circuits that you can buy from adafruit (note, this product is being redesigned, so the link may not work in 15-20 days from this posting, according to adafruit), which has great tutorials on how to use their products along with how it's built, but I also found another circuit at electronics-lab.com that has a solar charging circuit. I'd like to make solar powered robots, but for now I'm just buying lots of 9V and AA batteries. Going green will have to wait until time allows.

Microchip also has a solar power charging paper, which goes over the use of their chip designed for use charging batteries using solar power. Here is the article.

Mar 21

The terror of the Snooze Button

Lifehacker posted a video today by ASAP Science (they have a Youtube channel) about how the snooze button doesn't help you get any more sleep and can actually make you more tired. This adds to my convictions that the alarm clock that I make will not have a snooze button. It will wake me up, whether I want it to or not. And as the saying goes, "The me in the morning will have no respect for the me that set the alarm."

Mar 16

PCB advice and fabrication

This post is about PCB (printed circuit board) services and full-fledged PCB manufacturing. You can etch your own one sided board (double sided boards are possible. There's a tutorial by BlondiHacks showing you how), or you can purchase them from a PCB service. Here's a list of PCB services and some advice on making your own PCB's. I will use a 2"x3", 2-layer pcb for my pricing comparisons.

Fusion PCB Service from seeedstudio: They have a minimum quantity of 10 boards, and use cm instead of inches. A 5cm x 10cm (50 cm^2 opposed to 38.71 cm^2 for a 2"x3" board) PCB costs $2.39 per board.

OSH Park: Formerly DorkBot, this Open Source Hardware company offers 2-layer PCB's for $5 per square inch for a quantity of 3. That means it's $10 per board for a 2"x3" board (you have to order in batches of 3, so you get three 2"x3" boards for $30). If you order over 150 square inches, it's $1 per square inch, or $6 per board. They use Eagle as their CAD software. Their boards look good (I think silk screening is included, but I'm not sure).

Futurlec PCB Service: Futurlec has a PCB service. There is a $25 setup cost per run, but for a 2"x3" board, it's $3.1 in quantities of 100 and $3.8 for 1. They can also do solder masks and silk screening. With silk screening and a solder mask, it's $3.71 for 100 boards.

Fritzing Fab: They charge by cm^2, which means that I have about 38 cm^2 for a 2"x3" board. Even in quantities of over 200 cm^2 (about 5 boards), it's $20 per board. They are a lot more expensive than the other suppliers. They use Fritzing though. (for over 10, it's around $17).

PCB advice: Here's a blog about making PCB's for pick and place machines to pick and place onto. It also has other PCB information that you could use.

Outsourcing PCB manufacturing:

Ch00ftech has an article about outsourcing the manufacturing process for PCBs entirely. It covers using Myro, a Chinese manufacturing company, to make the PCBs and assemble them. It covers a lot of good information if you don't want to hand solder a whole bunch of boards.

Seedstudio also has a service where they manufacture the PCB's and put all of the components on them. They have you purchase the materials for them (and have them sent there), but it's another option instead of just looking at Myro.

Mar 16

Pick and Place Machines

If I want to manufacture boards on a small scale (say I build a laser tag or gps puzzle box board and want to make a few. Like 100), and I don't want to solder them all by hand, then I'll need a business partner or a pick and place machine. Since doing it myself will be cheaper and potentially more fun to learn, I've looked a bit into pick and place machines. Since I'm trying to keep costs down to as low as possible, I'm looking into DIY or other low cost alternatives. I found a few pick and place machines on the internet, and here they are (this is not exhaustive. It's just some cool things I found).

Open Source Pick and Place:  This is an open source pick and place project. They use a raspberry pi as the processor and they are trying to get the machine to cost around $2000. They're trying to do a kickstarter come summer 2013.

Dangerous Prototypes blog: TM220A: This is a chinese pick and place machine that does not do any vision processing (aka, doesn't auto correct by looking at the parts and the board to see if it is placing things correctly). It is around $3600.

Hoektronics meet a Shenzhen Maker: This is a cool article about a person who wanted to learn about pick and place machines and went to see someone who has his own fabrication lab in his house. It's a neat article. The guy who runs the blog, Hoektronics, also has some other cool projects, like the blinkyboard, an Atmega 32u4, which is the same processor that is in the arduino Leonardo (the blinkyboard is made to control LED strips).

Build a Pick and Place Machine: The guys from build your own CNC machine have made a pick and place machine for DIY enthusiasts to build. It's around $3700 and requires a good amount of knowledge to assemble it. Which means more time I'm spending putting a machine together instead of making parts.

Pick and Place Assistent: This one isn't an automated pick and place machine, but it does look like a handy tool to help with picking and placing components by hand. It's about $100.

However, in order for a purchase such as this to be a good idea, I need to make a case that the time saved using the machine outweighs the time I would have spent making the darn things by hand. Therefore, before I dive in, I need to clearly estimate the number of boards I will be making (aka actually building the product and testing it out) and do a cost benefit analysis before I get the machine. In the meantime, this is notes for me for the future, because knowledge is power. And power is Voltage times Amperage.


Mar 15

RFM12B Wireless Modules

Over the months, I've ran across a number of wireless modules, each telling me different things about their capabilities. There's the XBee, a great module that has books written to teach people how to use it. They come in many flavors and have a lot of breakout boards. They are also $17 for the low power version or $28 for the Xbee Pro, according to digi.com. Then there's the Nordic nRF24L01, which is a low cost module with an arduino library. They cost $4.75 (on sale now at yourduino.com for $2.75. Nice) Lower cost, but more difficult to set up for the beginner (there are code samples, people have used these before).

I recently came across the RFM12B. It's $6.95 at Sparkfun, but I doubt that's as cheap as one can find them, since Sparkfun usually is a bit more expensive than other suppliers (I have nothing against them. They were one of the first suppliers to carry arduinos, and I appreciate that. I also look for bargains). It also has a library (created by Low Power Lab based on the JeeLabs RFM12B library), which is completely open source (MIT license, so the code that uses it must also be open source, but since my project is open source too, that doesn't matter). Not sure whether or not it will be easier to use than the nRF24L01, but it's worth looking into if I make all the laser tag modules use RF to communicate hits to a central hub. That'll happen later in the process, after the core functionality is ironed out. Potentially, IR communication could be all I use for my open source laser tag project (note, OpenTag is a  DASH7 protocol stack, which is an open source wireless network standard. Damn. Can't use that name), so I won't need to have a wireless module on the units.

Note: the guy over at Low Power Lab is manufacturing an arduino clone with a RFM12B wireless module called the Moteino. He has some videos about soldering the Moteinos  (along with the stencil he uses to apply the solder paste) along with the iTeadStudio PCB's that he's using. Check out his blog at lowpowerlab.com.

You can also build a DIY laser cutter that can cut stencils. The tutorial is here.

Mar 13

Color of light Changes Alertness

NASA has planned an experiment to attempt to help astronauts get sleep on the international space station. According to research, blue light helps wake people up while red light helps people fall asleep. This apparently means that staring at my computer screen before going to bed apparently doesn't help me fall asleep. But it does mean that my alarm clock should be heavy on the blue light to wake me up in the morning, and it could also have RGB LED's that go heavy on the red light as I'm getting ready for bed. That could help mimic the sunrise and sunset and give me a sleep pattern that is either more stable (because it's easier for me to fall asleep and wake up) or that is more easily tuned because I can give my body the necessary light cues to tell it to fall asleep when my work lets me. Either way, I'll need to experiment. And for that, I need the clock.

Article on color changing lightbulbs assisting sleep

NASA ISS color test