Electronic Workshop Weekend: Arduino

Electronic Workshop Weekend: Arduino

After an inspiring lecture on circuit bending and electronics held by Edinburgh based digital artist Yann Seznec last week I decided to try something new. In this lecture we looked at some interesting possibility in using electronics separately and in combination with computers. This seemed like an interesting domain to check out, so I ordered some electronic components and an Arduino to play with the ideas from the lecture to learn more about it.

Perhaps the most interesting part is that electronics offer us to work at a lower abstraction level than the computer. Another advantage is the alternative inputs and outputs you can use in combination with projects in everything from low level C to high level Max MSP.  Hearing a relay click or to see some simple LEDs blinking gives a feeling of mastery on the same level as sorting algorithms and searching through huge databases, and by getting it to communicate with the computer you can experiment beyond the limits of the sandbox provided in the computer. Why not let a variable in the program be dependent on the temperature in the room, or on the amount of light? Or you can turn it around and let the result of your last budget result in a green or a red lamp blinking. Or maybe you want the number of visitors of your webpage be represented by the frequency of a tune from a speaker. Maybe you want to combine it together with the power of the Internet to take a picture each time your alarm clock goes off and publish this using Twitter or surveillance the toaster through its own blog where it will put a new post as the toast reach for the sky? Well, you have the opportunity.

The most obvious difference from playing around with computers is that the electronic components are physically alterable and the real deal; no surprise, but it has implications. If you simulate a higher voltage than expected or connect something the wrong way in a computer program the worst thing that would happen is that the program prompt a catched error or maybe an infamous null pointer exception. Dealing with real voltages and circuits, the components can bust, but if you make sure not to use anything really powerful and read the instructions when you use more complicated components such as micro controllers you should be OK.  The set I bought contained several components, and endless opportunities. In the beginning I tried to get a LED to flash and to gather input from the photo sensor, but with time and training I was able to do some more advance stuff, and in the end of a long day I managed to controll the time between each exposure on my DSLR (great for time lapse).

The interface between the computer and the components is the Ardurino. This is a little blue board with some analog ports, some digital ports, an USB connector and a power inlet. It is running on open source software downloadable from the homepage. The program is very similar to Processing, and has the opportunity to compile and upload the code, and to receive messages sent from the board. The board can run alone with software uploaded and using the ports on the board you can make small programs, meaing that you don’t need to have it hooked up to the computer to play around. If you want to use wireless technology or controll the board using Ethernet there are shields supporting Bluetooth and RJ45 Ethernet connections available. You can also get smaller components with Ardurino loader if you want to bring with you the logic programmed away from the little blue board.

There is a wide variety of components, and they all have their distinctive features and functions.Measuring temperature, light, radon level, speed, direction, proximity, RFID tags, taking pictures, well you find all kinds of components to hook up, and if you don’t want to buy new, you can always reuse your old toys, as in this video.

As we know from electric and electronic theory, the whole play is about getting the electricity from plus to minus and in between the polarities we can play around. The electricity will find the shortest path in terms of resistance, and the circuiut has to be complete to work. One of the easiest circuits are made by connecting an outlet from one of the digital ports through a LED, further through a resistor and then to ground. The lamp will be switched on when the port is set to high, and accordingly switched off when the port is set to low. This can be realized using the digital port (0 or 1, off or on), but using the analog ports the Arduino can address the lamp with a signal between 0 and 255 (a byte instead of a bit), which makes it possible to dim or to set it to a value in between the 0 and the 1. The repspective ports can be set at both input and output, and this is done really easy through methods in the Arduino “language”, there are also many libraries to do everyting from utilizing advance components with the board to sending messages to different software.

I have created a folder here, where I will put up some source code as I try out different things. I will also see if I can get up some sketches of the components as well. Until further, here are some pictures taken while playing around.

2 thoughts on “Electronic Workshop Weekend: Arduino

Leave a Reply

Your email address will not be published. Required fields are marked *