Programming a Microcontroller
Programming a microcontroller is a process with two components. One happens in a PC or host computer, and the other in the microcontroller itself. On the PC there is what is called a programming development environment, which generally includes an editor for the user to type its programs, and include the functionality to compile and generate the necessary files that are understandable by the microcontroller and written to what is known as object binary file. This binary file can be downloaded to the microcontroller and then executed by it. To download the file to the microcontroller, a special setup is needed, usually done through a serial port. Once the program is downloaded to the microcontroller it can be disconnected from the host computer. The program will stay in the microcontroller’s memory and will be executed every time the microcontroller is turned on. The programming languages available to program microcontrollers range from native versions of assemblers, C and BASIC, but there are others that can be programmed in most popular programming languages like Java and Logo.
Nowadays there is a wide range of popular, powerful, and relatively inexpensive microcontrollers available on the market for commercial, educational, hobbyist and entertainment applications. The microcontroller’s functionality varies from basic logic control up to fully functioning computers with wireless internet or network access, Bluetooth, GPS capabilities and more complex systems. Many companies like Motorola, Microchip, Parallax, Texas Instruments, Rabbit Semiconductors, and ATMEL etc. have a vast selection of programmable devices. [Barragán, 2004]
Using Everyday Objects as Communication tools
Fig. 40 Microcontroller’s programming process [source: Barragan,2004]