Workshop: Introduction to Microcontrollers with Arduino

From Design and Build Lab
Revision as of 21:10, 27 September 2018 by Joshw (talk | contribs)
Jump to navigation Jump to search

This certification is for the use of the micro-controller set.

This workshop will consist of two main objectives; how to control Digital output and inputs and how to control an analog output and input

(basic outline)

First, download and install the Arduino IDE (as of the writing of this lab, version 1.85) into your operating system of choice.

Download and install Teensyduino (as of the writing of this lab, version 1.41), which adds Teensy support to the Arduino IDE. Just follow the prompts; you don’t need to install all the libraries, but if you ever want to work with Teensies in the future, it’s worth taking the time to install them now.

Then double check that you are using the right board by going to Tools then Board and selecting Teensy 3.2 / 3.1, then go to Tools → Port and depending on your operating system go to Windows: select COMX, where X is the largest number (it should also say Teensy 3.2) or OSX: select /dev/cu.usbmodemXXXXXX, where XXXXXX is some number. This may not show up with Teensy. (You can see that neither of these operating systems handle hardware communication ports very elegantly.)

the default programmer for teensy is AVRISP mkII. To use it go to Programmer and select AVRISP mkII.

Code for teensy.png

1. digital outputs blinking led inputs button 2. analog inputs knob (potentiometer) outputs fading LED