User Tools

Site Tools


courses:intro.prototyping.fall.2017.oct18

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
courses:intro.prototyping.fall.2017.oct18 [2017/10/17 23:38]
rickard
courses:intro.prototyping.fall.2017.oct18 [2019/03/14 04:45] (current)
rickard
Line 1: Line 1:
 +===== Introduction to Arduino =====
  
 +Today we dove into the world of Arduino and sampled some key functions using it. 
 +
 +Digital reading and output, analog reading and output, sending values back to the computer and controlling the movement of a servo. The session was an introduction to show you how to work with the Arduino and how to work with it's tutorials to learn more.
 +
 +<​html>​
 +<!--
 +As I said there will be no more right out homework, but it's time for you to plan time for your own practice. This may sound daunting, but as with the assignments for processing I suggest starting with a small session trying out tutorials and commands, and then adding complexity to it.
 +-->
 +</​html>​
 +
 +Naturally this means you can make use of all the resources of the interaction Lab. Arduino, USB-cable breadboard and any components/​shields/​sensors etc is at your disposal. If you want to, you can even buy your own Arduino kit from me (worth 600 SEK, you pay 300 SEK) which contains most things you need for basic tutorials.
 +
 +=== During the intro session we went through the following tutorials on www.arduino.cc:​ ===
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​Blink|Blink (blinking LED)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​Button|Button (a button controls a LED)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​AnalogInOutSerial|Analog In, Out Serial (reading a potentiometer,​ controlling fade and sending values back to computer)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​Knob|Knob (controlling a servo with a potentiometer)]]
 +
 +=== Suggestions to expand on these tutorials: === 
 +Blink: Make a more complex blinking pattern, connect more LEDs and blink together
 +
 +Button: Connect another button and have the code turn on the LED if you press one, and off if you press the other.
 +
 +Analog in, out serial: have the LED light up in steps rather than gradually (hint: replace map() with if-statements)
 +
 +Knob: Connect a LED to the Arduino and have it light up when the servo is at any end value (0 or 180).
 +
 +
 +=== Other suitable starter level tutorials ===
 +
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​Fade|Fade (introduction to analogWrite())]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​InputPullupSerial|Input pullup (How to use a simpler button circuit)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​StateChangeDetection|State machine (counting button presses and changing state/​mode)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​tonePitchFollower|tonePitchFollower (play music with a light sensor)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​Sweep|Sweep (control a servo only by code)]]
 +
 +[[https://​www.arduino.cc/​en/​Tutorial/​HelloWorld|HelloWorld (write text to an LCD)]]
 +
 +There'​s more fun and advice to find on Arduino'​s [[http://​playground.arduino.cc/​|playground]] and [[http://​forum.arduino.cc/​|forum]].
 +
 +=== Tutorials on Intructables.com ===
 +
 +instructables.com is an excellent web resource for ANY hobby project and if you search on the site for "​Arduino"​ you will get a LOT of hits on projects of different difficulties. An example is a user called MertArduino who has a wide variety of projects, many of which is at a good learning level and using parts that we have in the Lab.
 +
 +An especially useful early tutorial on Instructables is [[http://​www.instructables.com/​id/​3-Beginner-Arduino-Mistakes/​|3 beginner mistakes with Arduino]]
 +
 +<​html>​
 +<!--
 +=== In conclusion: ===
 +
 +I'm still here, we still have more sessions before Intro to prototyping is done, but to progress you need to plan the time to practice. I can advice and suggest, and I will definitely help and tutor, but at this stage what is needed to understand better is not so much me talking rather than you trying, failing, trying and learning. "​Thinking with our hands",​ as Camille calls it. 
 +-->
 +</​html>​