
Key technologies: Adobe Air / ActionScript 3, Phidget motor controllers and sensors. Custom built LED lights.
All motor control and game play programming
This was a purely mechanical piece, no screen involved. It included an insane amount of motors and sensors:
This project was unusual in that I had to learn how to control many unfamiliar pieces of hardware at once. The various motor types had different protocols. There were other inputs and outputs as well. Some communicated over socket connections, others over serial. Some input data could be used as-is, other data needed to be converted to a suitable format.
The hardest part to program was controlling the stepper motors that moved the rainbow pieces up and down. Unlike the servos and DC motors, stepper motors have no built-in constrains to movement. They can move infinitely in either direction. But our rainbow pieces required a finite range of movement. So I worked out how to track their position using digital encoders and apply constraints via light sensors. Also each stepper seemed to display a slightly different range of position values, requiring each one to be addressed separately, with its own calibration procedure, to keep the rainbow pieces in alignment.
Another challenge was that the game play went thru several iterations before we landed on the final mechanism. In hindsight, I think we could have chosen simpler game play interaction, perhaps ditching the joystick and simply using a single button. But in the end the visitors figured it out and it was very satisfying watching them team up to and build rainbows.