A quick overview on the architecture of the Physical Interaction Design Workshop 2009 setup, by Wendy Ju
Very broadly, a PID setup allows computers to react progammatically to events in the physical world.
Actions, events and states are detected by sensor circuits, which convey signals to an embedded microcontroller, which in turn addresses a computer program. The computer program can then respond by producing sound and graphics, or it can pass commands back to an embedded processor, which can effect action, sound, or display through the use of electronics.
A circuit is an interconnection of electrical elements such as resistors, inductors, capacitors, voltage sources, current sources, and switches in a network that has a closed loop, giving a return path for the current. A sensor circuit incorporates a sensor which varies resistance, inductance, capacitance, or otherwise varies voltage or current to produce signals indicating the state of the sensed phenomena.
A microcontroller is essentially a small computer on a chip. Like any computer, it has memory, and can be programmed to do calculations, receive input, and generate output. Unlike a PC, it incorporates memory, a CPU, peripherals and I/O interfaces into a single chip. Microcontrollers are ubiquitous, found in almost every electronic device from ovens to iPods.
For this workshop we will be using an Atmel AVR ATMega168.
PID 2009 setup
For this workshop, we will be using breadboards and Arduino Nanos running Firmata, as platforms for the sensor circuit and embedded microcontroller, respectively. On your computer, you will be using MAX/MSP or PD, graphical programming environments that use a patch-programming model and enable sound synthesis.
The Arduino is an electronics prototyping platform with a hardware and software component.
The Arduino software application is an IDE for programming firmware for the Arduino hardware. Its programming language is based on C; it has some structures, variables and functions specially designed for managing microcontroller electronics. It is open source and can be downloaded for free.
The Arduino hardware is based on the Atmel AVR microcontroller family. There is not one Arduino board, but, rather, a host of boards based on the same basic open-source design. Ours, the Arduino Nano, is based on the Arduino Decimila design, but is smaller, and breadboard-mountable.
The Arduino hardware has the advantage of being mass-produced, relatively low-cost and readily and widely available. More importantly, there is a wide community of folks using Arduino, which makes it easier to get support after this workshop.
Firmata is a generic protocol for microcontrollers to communicate with software on a host computer. Firmata firmware is available for the Arduino and PIC platforms; Firmata host software is available for Pd and Max/MSP, as well as for Processing, C++, Python, Flash, SuperCollider, Perl and Visual Basic.
Firmata is not as widely used as Arduino; people usually write custom Arduino firmware code to suit their application. Because Firmata works generically to collect inputs and issue outputs, it is generally not as efficient in time or bandwidth as custom firmware. However, by using Firmata, we can abstract away many of the details of microcontroller programming to focus our efforts on our MAX/MSP or PD programs.
As a point of reference, the table below shows some alternatives to the platforms we are using in this workshop.
|Electronic circuit platform||Microcontroller platform||Programming Environments|