Presentation is loading. Please wait.

Presentation is loading. Please wait.

Intro to Arduino with LilyPad Make a MakerSpace, Artisan’s Asylum Linz Craig, Chris Taylor, Mike Hord & Joel Bartlett.

Similar presentations


Presentation on theme: "Intro to Arduino with LilyPad Make a MakerSpace, Artisan’s Asylum Linz Craig, Chris Taylor, Mike Hord & Joel Bartlett."— Presentation transcript:

1 Intro to Arduino with LilyPad Make a MakerSpace, Artisan’s Asylum Linz Craig, Chris Taylor, Mike Hord & Joel Bartlett

2 Overview of Class Getting Started: Installation and Applications Electrical: Components, Input and Output, Analog and Digital Trouble Shooting: Serial Communication Additional Teaching Tools: Giant Components and Breadboard, Free Teaching Materials

3 Arduino Board “Strong Friend” Created in Ivrea, Italy in 2005 by Massimo Banzi & David Cuartielles Open Source Hardware Atmel Processor Coding is accessible (C++, Processing, ModKit and MiniBloq)

4 The LilyPad Dev Board

5

6

7

8 Flip the Board Over Do you see the wires that are running to the sensors, LEDs, and buttons? The microcontroller can already talk to the inputs and outputs!

9 Board Type

10 Other Board Type

11 Serial Port / COM Port

12 Analog and Digital All Arduino signals are either Analog or Digital All computers including Arduino, only understand Digital It is important to understand the difference between Analog and Digital signals since Analog signals require an Analog to Digital conversion

13 Output Output is always Digital To Output a Digital signal (On or Off) use this code: digitalWrite ( pinNumber, value ); Where value is HIGH or LOW To output a signal that pretends to be Analog use this code: analogWrite ( pinNumber, value ); Where value is a number 0 - 255

14

15 Output Output is always Digital Using a Digital signal that pretends to be an Analog signal is called Pulse Width Modulation Use Pulse Width Modulation, or P.W.M., for anything that requires a signal between HIGH and LOW P.W.M. is available on Arduino pins # 3, 5, 6, 9, 10, and 11

16 Output Output is always Digital, even when it’s P.W.M. For P.W.M. the Arduino pin turns on then off very fast P.W.M. Signal @ 25%P.W.M. Signal @ 75% P.W.M. Signal rising

17 Input Input is any signal entering an electrical system Both digital and analog sensors are forms of input Input can also take many other forms: Keyboards, a mouse, infared sensors, biometric sensors, or just plain voltage from a circuit

18

19 Analog Input To connect an analog Input to your Arduino use Analog Pins # 0 - 5 To get an analog reading: analogRead ( pinNumber ); Analog Input varies from 0 to 1023 on an Arduino

20 Digital Input To connect digital input to your Arduino use Digital Pins # 0 – 13 (Although pins # 0 & 1 are also used for serial) Digital Input needs a pinMode command: pinMode ( pinNumber, INPUT ); Make sure to use caps for INPUT To get a digital reading: digitalRead ( pinNumber ); Digital Input values are only HIGH (On) or LOW (Off)

21 Digital Sensors No matter what the sensor there are only two settings: On and Off Signal is always either HIGH (On) or LOW (Off) Voltage signal for HIGH will be a little less than 5V on your Uno Voltage signal for LOW will be 0V on most systems

22 Setup, Internal Pullup Resistors void setup ( ) { digitalWrite (12, HIGH); } You will need to create internal pullup resistors in setup, to do so digitalWrite the pin HIGH

23 Serial Communication Serial Communication is the transferring and receiving of information between two machines, the Arduino dedicates pin # 0 to receiving information and pin 1 to transferring information

24 Serial in Setup

25 Serial Monitor

26 Serial Communication: Serial Setup void setup ( ) { Serial.begin ( 9600 ) ; } In this case the number 9600 is the baud rate at which the computer and Arduino communicate

27 Serial Communication: Sending a Message void loop ( ) { Serial.print ( “Constructivism & “ ) ; Serial.println ( “Mechatronics” ) ; }

28 Serial Communication

29 Serial Communication: Serial Debugging void loop ( ) { int xVar = 10 ; Serial.print ( “Variable xVar is “ ) ; Serial.println ( xVar ) ; }

30 Serial Communication: Serial Troubleshooting void loop ( ) { Serial.print ( “Digital pin 9 reads “ ) ; Serial.println ( digitalRead ( 9 ) ) ; }

31 Making the World’s Worst Musical Instrument Now for some really crappy dubstep…. If we have time. Because, really, who has time for crappy dubstep?

32 MODKit: WWW.modk.it Graphical User Interface for intuitive coding of Arduino Developed by Ed Baafi and Collin Reisdorf

33 Fritzing Virtual Electrical Prototyping Project started in 2007 by the Interaction Design Lab at the University of Applied Science Potsdam, Germany Open Source Prototypes: Document, Share, Teach, Manufacture

34 Murphy’s Law If it can go wrong, it will… eventually. Be ready to improvise.

35 Developing Instructors They will surprise you. Being open will lead you to some interesting places. Have some student leaders. Get some laughs to make people comfortable.

36 Other Teaching Tools Sewing: http://www.sparkfun.com/tutorials/category/16 Processing: http://processing.org/ Ohm’s Law Board: http://learn.sparkfun.com/curriculum/26 Giant Breadboard and Components: http://learn.sparkfun.com/curriculum/22http://learn.sparkfun.com/curriculum/22, http://learn.sparkfun.com/curriculum/23 Additional Resources: http://learn.sparkfun.com/curriculum http://www.arduino.cc/

37 Questions?

38 www.sparkfun.com 6175 Longbow Drive, Suite 200 Boulder, Colorado 80301


Download ppt "Intro to Arduino with LilyPad Make a MakerSpace, Artisan’s Asylum Linz Craig, Chris Taylor, Mike Hord & Joel Bartlett."

Similar presentations


Ads by Google