networking

Working again towards my final project, I wanted to build on the bus network that Neil demonstrated in class. Each node acts as a block in a tangible query. A button on the block allows the user to select options for that part of the query (for example, the type of visualization or the field in the database table).

board design

Wanting to keep the boards simple, I adapted Neil's bridge/node CAD files to add a button, while still using the ATtiny45. I reused one of the programming pins (SCK/PB2) as the RX (serial out) pin, and used PB4 to handle the button's input instead. This was a good opportunity to play around with circuit layout in cad_ui. It was a bit tedious at first, but after I tried to understand the layout parameters instead of doing it by trial-and-error, I found the tool much more useful than Eagle. I guess the only problem is there's no verification of shorts or DRC rule checking.

milling and stuffing

I made two nodes and one bridge. Since I missed the input/output devices weeks, these were the first boards I had made in over a month. Consequently, I made most of the mistakes one can make using the Modella and wasted a couple of copper boards. Notably, I exported the PNGs from cad_ui at 500 pixels/mm, instead of 500 DPI, which made fab_modules crash. Also, I exported the exterior from cad_ui instead of the interior, which ended up being too tight a cut. I lowered the Modella's head too far down so it couldn't cut deep enough when I was cutting the boards out. Thanks to Matt for his advice on this last one, wouldn't have caught it myself.

Stuffing took awhile, mainly because I'm out of practice and had to do three boards instead of one. One note is that we didn't have any 2x2 and FTDI headers. I scavenged my only other non-ISP board for an FTDI header and used 2x3 headers that hang off the boards.

testing the network

I first tested the network using Neil's original code, with the small change of switching the serial out (RX) pin to PB2 instead of PB4. Everything worked great! The pattern below (kinda hard to see) was 0-0-1-2-2-1-0, where 0-2 goes from left to right.

I wanted to program the boards so a button press would change a database query, and be reflected in a browser on the laptop, but ran out of steam. But this was definitely a useful step forwards in my final project!

files