UPDATE: October 28, 2013
I’ve released all of the wixel and html5 code for this project, you can find details here: HERE
FINALLY, the power returns and I have a chance to test my breakouts! First test is great. I have the Raspberry Pi driving the master Wixel via USB. This slave Wixel, soldered into my breakout board, sits on the other side of my shop. A 5v wall wart provides the power. This is a nice mix of micro servos, minis and three standards. Works great!
In case you have not followed all my posts, what I have here is a master wixel plugged into the Raspberry Pi. Using the built in packet addressing mode of the TI processor (check out the Data Sheet), it sends servo commands to each slave in a round robin sort of protocol. Each slave can control up to 6 servos and return 3 analog inputs to the master.
I’m getting a really good update rate of about 4ms per slave. Once started, it just keeps running, the Raspberry Pi, via the USB to the master, just has to write a servo value into a table and on the next turn for that slave, it’s updated. This frees the Pi from any work at all in maintaining the network, it’s all auto-magic.
Here are some more pics of the widget.
I’ve decided that standing it up at 90 degrees like in other pics is not worth it. Much easier just to solder it in like this:
Here is a LINK to a previous post about the breakout boards. And ANOTHER that has some s/w details. Note, I have NOT released the internal code apps for the Wixels yet, I’m not sure if I will or not, depends on the results of my next project.
Work progresses on the control interface. After fooling a bit with an Android native app, I decided that was way too overkill. So here is the same idea implemented in HTML5. It will run on pretty much anything, or I hope it will as it’s browser based.
Here is a link to a basic version. There is no save or load, it’s just the framework-
The workflow is that you click a symbol, then click where you want it on the grid. This allows you to build a route that resembles the control for any railroad layout. The right mouse button clears a symbol from the map. It still needs a load and save option and finally, I will need a run module page that will load this file and allow you to control vs editing.
The path is a web page load from the RPi, with tornado passing down data to the master Wixel. From there the master will communicate with all the respective slaves over wireless, allowing me to touch a switch icon on the tablet and have the servo at the far end of the chain move the turnout. The HTML5 logic will then redraw the route in color to indicate where the train is going to go. That’s the plan anyhow. There are lots of possibilities with this protocol model, anything that needs R/C servos controlled over 2.4ghz wireless from the Raspberry Pi. Or any master for that matter.
I’ve already tested the basic code on the RPi via lighttp to my Android tablet and it works great. More logic to put in but the idea here is to enable the editing and control on any device, laptop, desktop or tablet. So far I’m very happy with this project and I’m getting close to completion.
Later I’d like to actually track the trains with RFID (or something) and animate that somehow on the tablet. However, that is down the road a bit, I’m going to limit my scope here on this one so I can finish it up.