Week 12. output devices


group assignment

see FabLab Kamakura's group assignment page.


For my final project, I want my surFABoard to blink colorfully depending on the values of a sensor.

My main board will have sensors, GPS, and SD cards for logging and need more pins ATtiny 44 or 45 has. I decided to design satshakit board with LEDs as output in this week assignment. I used RGB LED modules, WS2821Bs.


source: WS2821B (Sparkfun)

board design

I designed my satshakit based on the satshakit CNC and connected it with LEDs with reference to a typical application circuit of LEDs' datasheet.

source: WS2821B datasheet

Here is a schematics.

and routing.

It is a png file for milling.

I found milling was not successful. Conducting lines were not straight enough, and some parts were missing. I checked mods toolpath, but I couldn't figure out why.

When I took out a PCB, I felt SRM-20's stage move. As right side bolts were not tightened hard enough, the stage seemed to move during milling.

After tightening bolts, I milled my board again. I got a successful result.

after tightening bolts (left), first milling (right)

soldering components

Its name was ATmega328P, but its size was tiny. I checked connections every pin after soldering. I'd say I can't be too careful.

I followed a tradition and named my satshakit board "Junino" (Jun + Arduino).

In an Eagle schematic, I carelessly used VCC and 5V together. I noticed it because RGB LEDs didn't light up at all. I connected two parts inside the yellow dashed line square and used the board later experiment.

making Junino Arduino IDE compatible

I wired Junino with FabISP based on the image below.

I soldered zero Ohm resistor at SJ2 again to supply 5V voltage through FabISP.

An indicator LED was on, which meant the voltage was applied to my board.

I exactly followed instructions below to make Junino Arduino IDE compatible.

  1. open Arduino IDE
  2. select proper programmer by clicking on Tools->Programmer (for example USBtinyISP)
  3. select Arduino UNO as Tools->Board
  4. click on Tools->Burn Bootloader

output test

First, I uploaded a basic Blink sketch. In case of using FabISP as a programmer (not FTDI), select File->Upload using a programmer to upload the code to satshakit.

And I found a LED of pin 13 blinking successfully.

Green LED(assigned to PIN13) is blinking

For an assignment, I used one of Adafruit example, strandtest sketch.
Before uploading the sketch, I included NeoPixel library. I modified the code for my Junino board, a pin assigned to LEDs was 19(A5), and the number of LEDs was 3.

Here is the result!!


revised satshakit board with LEDs (Eagle schematic/PCB layout; toolpaths for traces/interior): archived format (.zip)

arduino IDE sketches: blink.ino and strandtest.ino (.ino)

WS2821B datasheet