Archives for the month of: February, 2013

My servo homework has turned into yet another way to fade LEDs, this time with colored polarizer sheets.  Two out of three layers of polarizers are crudely taped to servo motors which rotate them a bit, causing color and intensity changes.  Also, I can’t get enough of these slow color changing LEDs from adafruit- they start red then cycle through four colors, going out of synch somewhat randomly.  The arduino code is basically the same as the previous post… Read the rest of this entry »

//this arduino code uses a potentiometer to control a servo motor (and LED).

#include <Servo.h>  //access servo library
const int ledPin = 3; //LED output pin
int brightValue = 0; //LED brightness output

Servo mote;  //define servo called ‘mote’
const int analogpin = A0; //analog in pin
int analogValue = 0;  //analog input from potentiometer
int newValue = 0; // output value to servo in degrees (analogValue scaled from 0-180)

void setup() {

pinMode (ledPin, OUTPUT);
mote.attach(9);    //attach servo to pin 9, (‘detach’ stops servo)

void loop() {

analogValue  = analogRead(analogpin);
brightValue = analogRead(analogpin);

newValue = map(analogValue, 0, 1023, 0, 179);
brightValue = map(analogValue, 0, 1023, 0, 240);


analogWrite(ledPin, brightValue);

In this video the arduino controls some LEDs and a speaker.  The idea was to use the input values from a pressure sensor to provide some basic shape of output information, with +/-  some random number to influence pitch, brightness, duration.   Didn’t quite turn out as hoped, but I like the grainy texture of the sound.   Also, I added a few slow fade color changing LEDs for ambience (for these, I used the sensor only as on/off signal- they really just do their own thing).

Code (click to view) :


Hello arduino.

To get acquainted, we wrote some basic code:

Untitled 4

Which prints:

Untitled 5


Baby steps- dreams of glowing-interactive forms/sculpture, for a while now, yet have I ever touched a soldering iron?  No.  Above- I made light!  Variable resistor controls intensity…