SlideShare a Scribd company logo
Spooky Projects
Introduction to Microcontrollers with Arduino
Class 1
7 Oct 2006 - machineproject - Tod E. Kurt
Everyone’s had a little programming experience, right?
Who’s had any electrical experience?
What’s for Today
• Introduction to Arduino
• Building an LED flashlight
• Making some blinky LED eyes
Class Kit
What’s in your goodie bag
Class Kit Manifest
• Arduino NG USB board
• Arduino ProtoShield
• Solderless breadboard
• USB cable
• RC servo
• piezo buzzer
• 6m hookup wire in ghastly
colors
• potentiometer with knob
• R,G,B and mystery LEDs
• two push switches
• 9V battery and connector
• 220, 330, 10k, and 1M
resistors
• light sensitive resistor
• 5.1v zener diode
• square of velcro
• scary eyeballs
And other bits as we progress
Ignore most of the kit for now, just use Arduino board and USB cable
Complete kit manifest with part numbers will be online
A Word on Safety
• Electronics are toxic to you
• Lead in some of the parts
• Wash up afterwards
• You are toxic to electronics
• Static-sensitive: don’t shuffle your feet
• Wires only bend so much
What is Arduino?
• Open Source Physical Computing Platform
• open source: free to inspect & modify
• physical computing. er, what?ubiquitous computing, pervasive
computing, ambient intelligence, calm computing, everyware, spimes, blogjects, smart objects...
• A physical board, a programming
environment, a development philosophy
• Tiny computer you can program
• Completely stand-alone, talks to other devices
Physical computing as invisible computing
Can run off a battery
Can talk to other computers, cell phones, etc.
What is Arduino?
• Based on AVR-GCC, avr-libc, AVRlib and
Processing (all open source projects)
• Very similar to Basic Stamp (if you know it)
• but cheaper, faster, & open
• Uses AVR ATmega8 microcontroller chip
Basic Stamp uses PIC microcontroller chip.
PICs and AVRs are very comparable, one’s not necessarily better than the other
AVRs are a little better if you’re using a language like C (stack-based)
Don’t need to worry about the chip particulars for now
What is Arduino?
• Why not just use a bare AVR ATmega8 chip?
• Arduino is also a standardized “bootloader”
• A tiny program that loads other programs
• It’s alive during first 5 seconds
A bootloader is akin to an BIOS on a real computer. It handles the startup of the chip
After 5 seconds, your program runs
Don’t need special programmer board with a bootloader
Arduino can work with other AVR chips, some are smaller than your fingernail, cost ~ 40 cents
What is Arduino?
• Capabilities
• 8 kBytes of Flash program memory
• 1 kByte of RAM
• 12 MHz (Apple II: 1 MHz)
• Inputs and Outputs
• 13 digital input/output pins
• 5 analog input pins
Digital I/O can read switches and buttons, control LEDs and motors
Analog input can read knobs or other varying sensors
Analog output can be done with PWM
What is Arduino?
• Write programs on your PC
• Download them into the Arduino board
• Arduino board can then be used by itself
But how do you program it?
No keyboard, mouse or display
Your PC becomes the “head”
Arduino Board
2”
1.7”
reset
button
power
LED
test
LED
TX/RX
LEDs
digital input/output
analog input
Also: USB input, power input, ICSP programming header
Arduino Board
analog inputs
reset
button
power
LED
test
LED
digital I/O
Diagrammatic version, to simplify
But of a slightly older version of the board
Digital? Analog?
• Digital – only has two values: on/off
• Analog – has many (infinite) values
• Computers don’t really do analog
• So they fake it, with quantization
Quantization = breaking up the analog range into bins. The number of bins is the resolution.
More bins = higher accuracy, but is more complex
Digital can be thought of as only two bins.
Arduino Software
compile
(verify)
upload to board
status
area
That’s the full code for blinking an LED, btw.
Arduino defines several useful functions like digitalWrite() and delay(). more on that later
Processing and Wiring not needed
Arduino & Processing
http://processing.org/
build generative art or other applets easily
not needed for Arduino, but can work with it
Arduino has essentially the same GUI as Processing
Easier than Arduino, since all software
Though similar UI and philosophy, Arduino is a different language
We’ll use Processing later in the class to let the computer control Arduino & vice-versa
• Download software: http://arduino.cc/
• Mac OS X PPC or Intel (must pick)
• Windows 2000/XP
• Install drivers
• In “drivers” folder, pick appropriate one
• Windows: unzip driver, plug in board, setup
• “macosx-setup-command” for Mac folk
• Reboot
Installing Arduino
Different Arduino downloads for each operating system
Different drivers for each OS too
“macosx-setup-command” must be run before reboot,
but, it will go away in next version
Using Arduino
• Programs are called “sketches”
• Load up example sketch “led_blink”
Errors
Must select
serial port
“Programmer is
not responding”
What’s my serial port?
Windows: Use Device Manager to find COM port
Mac: It’s called “/dev/tty.usbserial-something”
Using Arduino
• Write program
• Compile (check for errors)
• Reset board
• Upload to board
Try it out with “led_blink”!
On reset, board will flash on-board pin 13 LED really fast for a split-second to indicate bootloader
exists
When uploading, TX/RX lights will flash as data is transferred
Then the board resets, pin 13 will flash fast again
Finally, your program will run
Arduino Board Lifecycle
Take a Break
Making Circuits
heart pumps, blood flows voltage pushes, current flows
LEDs
physical characteristics schematic symbol
• LED = Light-Emitting Diode
• electricity only flows one way in a diode
• Needs a “current limiting” resistor, or burns
out
bar = minus
Many types of integrated lenses.
Some project a narrow beam (like the ones in this class), some project a very wide beam
LED flashlight
wiring diagram schematic
All LED circuits are essentially this: power source, current limiter, LED
Flat part of LED goes to negative, like bar in schematic
The higher the resistance, the dimmer the LED; the lower, the brighter
LED flashlight
Take out solderless breadboard, resistor, LED, and battery and make a circuit
LEDs have been marked a little as to what color they are, but color doesn’t matter here
Solderless Breadboards
groups of 5
connected
but not connected
across the jump not
connected
Insert wires into holes to make a connection.
*Much* easier, quicker than soldering
But, they wear out, are expensive ($8 for this little one)
Using Solderless
Breadboards
Using needle nose pliers can help
Grab wire or lead toward end and push into hole
Blinky LED circuit
wiring diagram schematic
“hello world” of microcontrollers
In schematics signals often flow from top-left to bottom-right
Common nodes like “gnd” are given their own symbol
Pick any digital pin to hook up to, doesn’t matter which
Blinky LED circuit
• Plug shield on top of Arduino board
• Stick breadboard to shield
Blinky LED Software
You’ve already seen it.
Arduino Sketch
Structure
• Declare variables at top
• Initialize
• setup() – run once at beginning, set pins
• Running
• loop() – run repeatedly, after setup()
Pins can be changed in loop() too, but conceptually easier in setup()
Arduino “Language”
• Language is standard C (but made easy)
• Lots of useful functions
• pinMode() – set a pin as input or output
• digitalWrite() – set a digital pin high/low
• digitalRead() – read a digital pin’s state
• analogRead() – read an analog pin
• analogWrite() – write an “analog” PWM value
• delay() – wait an amount of time
• millis() – get the current time
• And many others. And libraries. And examples!
Also: serial library, LCD library, servo examples
Development Cycle
• Make as many changes as you want
• Not like most web programming: edit ➝ run
• Edit ➝ compile ➝ upload ➝ run
edit
compile
upload
run
More Blinky Madness
Add LEDs
Next Week
• Reading buttons
• Reading analog values (knobs)
• Detecting the dark
• More complex LED circuits
• Stand-alone Arduino
Tod E. Kurt
tod@todbot.com
END Class 1
ATmega8 & Arduino

More Related Content

What's hot (20)

What are the different types of arduino boards
What are the different types of arduino boardsWhat are the different types of arduino boards
What are the different types of arduino boards
elprocus
 
Arduino Lecture 1 - Introducing the Arduino
Arduino Lecture 1 - Introducing the ArduinoArduino Lecture 1 - Introducing the Arduino
Arduino Lecture 1 - Introducing the Arduino
Eoin Brazil
 
Intro to Arduino
Intro to ArduinoIntro to Arduino
Intro to Arduino
Qtechknow
 
Introduction to Arduino
Introduction to ArduinoIntroduction to Arduino
Introduction to Arduino
Luki B. Subekti
 
Ardui no
Ardui no Ardui no
Ardui no
Amol Sakhalkar
 
IOTC08 The Arduino Platform
IOTC08 The Arduino PlatformIOTC08 The Arduino Platform
IOTC08 The Arduino Platform
Eoin Brazil
 
The arduino uno is a microcontroller board based on the
The arduino uno is a microcontroller board based on theThe arduino uno is a microcontroller board based on the
The arduino uno is a microcontroller board based on the
Pramod Kumar
 
Introduction to the Arduino
Introduction to the ArduinoIntroduction to the Arduino
Introduction to the Arduino
Wingston
 
Arduino Workshop Day 2
Arduino  Workshop Day 2Arduino  Workshop Day 2
Arduino Workshop Day 2
Yogendra Tamang
 
Introduction to arduino
Introduction to arduinoIntroduction to arduino
Introduction to arduino
Ahmed Sakr
 
Arduino Workshop
Arduino WorkshopArduino Workshop
Arduino Workshop
atuline
 
Arduino Full Tutorial
Arduino Full TutorialArduino Full Tutorial
Arduino Full Tutorial
Akshay Sharma
 
Ardublock tutorial
Ardublock tutorialArdublock tutorial
Ardublock tutorial
Jakie_Li
 
Introduction to arduino!
Introduction to arduino!Introduction to arduino!
Introduction to arduino!
Makers of India
 
Introduction to Arduino Microcontroller
Introduction to Arduino MicrocontrollerIntroduction to Arduino Microcontroller
Introduction to Arduino Microcontroller
Mujahid Hussain
 
Intro to Arduino Revision #2
Intro to Arduino Revision #2Intro to Arduino Revision #2
Intro to Arduino Revision #2
Qtechknow
 
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Eoin Brazil
 
Arduino as an embedded industrial controller
Arduino as an embedded industrial controllerArduino as an embedded industrial controller
Arduino as an embedded industrial controller
Jose Luis Poza Luján
 
Arduino Workshop Day 1 - Basic Arduino
Arduino Workshop Day 1 - Basic ArduinoArduino Workshop Day 1 - Basic Arduino
Arduino Workshop Day 1 - Basic Arduino
Vishnu
 
Arduino: Tutorial de Arduino
Arduino: Tutorial de ArduinoArduino: Tutorial de Arduino
Arduino: Tutorial de Arduino
SANTIAGO PABLO ALBERTO
 
What are the different types of arduino boards
What are the different types of arduino boardsWhat are the different types of arduino boards
What are the different types of arduino boards
elprocus
 
Arduino Lecture 1 - Introducing the Arduino
Arduino Lecture 1 - Introducing the ArduinoArduino Lecture 1 - Introducing the Arduino
Arduino Lecture 1 - Introducing the Arduino
Eoin Brazil
 
Intro to Arduino
Intro to ArduinoIntro to Arduino
Intro to Arduino
Qtechknow
 
IOTC08 The Arduino Platform
IOTC08 The Arduino PlatformIOTC08 The Arduino Platform
IOTC08 The Arduino Platform
Eoin Brazil
 
The arduino uno is a microcontroller board based on the
The arduino uno is a microcontroller board based on theThe arduino uno is a microcontroller board based on the
The arduino uno is a microcontroller board based on the
Pramod Kumar
 
Introduction to the Arduino
Introduction to the ArduinoIntroduction to the Arduino
Introduction to the Arduino
Wingston
 
Introduction to arduino
Introduction to arduinoIntroduction to arduino
Introduction to arduino
Ahmed Sakr
 
Arduino Workshop
Arduino WorkshopArduino Workshop
Arduino Workshop
atuline
 
Arduino Full Tutorial
Arduino Full TutorialArduino Full Tutorial
Arduino Full Tutorial
Akshay Sharma
 
Ardublock tutorial
Ardublock tutorialArdublock tutorial
Ardublock tutorial
Jakie_Li
 
Introduction to arduino!
Introduction to arduino!Introduction to arduino!
Introduction to arduino!
Makers of India
 
Introduction to Arduino Microcontroller
Introduction to Arduino MicrocontrollerIntroduction to Arduino Microcontroller
Introduction to Arduino Microcontroller
Mujahid Hussain
 
Intro to Arduino Revision #2
Intro to Arduino Revision #2Intro to Arduino Revision #2
Intro to Arduino Revision #2
Qtechknow
 
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Arduino Lecture 4 - Interactive Media CS4062 Semester 2 2009
Eoin Brazil
 
Arduino as an embedded industrial controller
Arduino as an embedded industrial controllerArduino as an embedded industrial controller
Arduino as an embedded industrial controller
Jose Luis Poza Luján
 
Arduino Workshop Day 1 - Basic Arduino
Arduino Workshop Day 1 - Basic ArduinoArduino Workshop Day 1 - Basic Arduino
Arduino Workshop Day 1 - Basic Arduino
Vishnu
 

Similar to Arduino spooky projects_class1 (20)

Designers, please mind the gap! Let's get started with Arduino
Designers, please mind the gap! Let's get started with ArduinoDesigners, please mind the gap! Let's get started with Arduino
Designers, please mind the gap! Let's get started with Arduino
Fahed Al Riachi
 
13223971.ppt
13223971.ppt13223971.ppt
13223971.ppt
SuYee13
 
Intro to Arduino
Intro to ArduinoIntro to Arduino
Intro to Arduino
avikdhupar
 
Arduino Comic-Jody Culkin-2011
Arduino Comic-Jody Culkin-2011Arduino Comic-Jody Culkin-2011
Arduino Comic-Jody Culkin-2011
ΚΔΑΠ Δήμου Θέρμης
 
Arduino comic v0004
Arduino comic v0004Arduino comic v0004
Arduino comic v0004
DO!MAKERS
 
Introduction to Arduino
Introduction to ArduinoIntroduction to Arduino
Introduction to Arduino
baabtra.com - No. 1 supplier of quality freshers
 
Introduction To Arduino-converted for s.pptx
Introduction To Arduino-converted for s.pptxIntroduction To Arduino-converted for s.pptx
Introduction To Arduino-converted for s.pptx
rtnmsn
 
02 Sensors and Actuators Understand .pdf
02 Sensors and Actuators Understand .pdf02 Sensors and Actuators Understand .pdf
02 Sensors and Actuators Understand .pdf
engsharaf2025
 
Arduino Workshop (3).pptx
Arduino Workshop (3).pptxArduino Workshop (3).pptx
Arduino Workshop (3).pptx
HebaEng
 
Arduino Development For Beginners
Arduino Development For BeginnersArduino Development For Beginners
Arduino Development For Beginners
FTS seminar
 
Arduino.pptx
Arduino.pptxArduino.pptx
Arduino.pptx
AadilKk
 
Getting startedwitharduino ch04
Getting startedwitharduino ch04Getting startedwitharduino ch04
Getting startedwitharduino ch04
Anil Yadav
 
Arduino Slides With Neopixels
Arduino Slides With NeopixelsArduino Slides With Neopixels
Arduino Slides With Neopixels
sdcharle
 
introductiontoarduino-111120102058-phpapp02.pdf
introductiontoarduino-111120102058-phpapp02.pdfintroductiontoarduino-111120102058-phpapp02.pdf
introductiontoarduino-111120102058-phpapp02.pdf
HebaEng
 
Introduction to Arduino with ArduBlock & SparkFun LilyPad
Introduction to Arduino with ArduBlock & SparkFun LilyPadIntroduction to Arduino with ArduBlock & SparkFun LilyPad
Introduction to Arduino with ArduBlock & SparkFun LilyPad
Brian Huang
 
Basic arduino components and more things about arduino
Basic arduino components and more things about arduinoBasic arduino components and more things about arduino
Basic arduino components and more things about arduino
GeorgeTsak
 
Intro_to_Arduino_-_v30.pptx
Intro_to_Arduino_-_v30.pptxIntro_to_Arduino_-_v30.pptx
Intro_to_Arduino_-_v30.pptx
CephasMpandikaKalemb
 
Arduino slides
Arduino slidesArduino slides
Arduino slides
sdcharle
 
Arduino Workshop Slides
Arduino Workshop SlidesArduino Workshop Slides
Arduino Workshop Slides
mkarlin14
 
Arduino_IOT Arduino_IOT Arduino_IOTArdui
Arduino_IOT Arduino_IOT Arduino_IOTArduiArduino_IOT Arduino_IOT Arduino_IOTArdui
Arduino_IOT Arduino_IOT Arduino_IOTArdui
deepikayadav216323
 
Designers, please mind the gap! Let's get started with Arduino
Designers, please mind the gap! Let's get started with ArduinoDesigners, please mind the gap! Let's get started with Arduino
Designers, please mind the gap! Let's get started with Arduino
Fahed Al Riachi
 
13223971.ppt
13223971.ppt13223971.ppt
13223971.ppt
SuYee13
 
Intro to Arduino
Intro to ArduinoIntro to Arduino
Intro to Arduino
avikdhupar
 
Arduino comic v0004
Arduino comic v0004Arduino comic v0004
Arduino comic v0004
DO!MAKERS
 
Introduction To Arduino-converted for s.pptx
Introduction To Arduino-converted for s.pptxIntroduction To Arduino-converted for s.pptx
Introduction To Arduino-converted for s.pptx
rtnmsn
 
02 Sensors and Actuators Understand .pdf
02 Sensors and Actuators Understand .pdf02 Sensors and Actuators Understand .pdf
02 Sensors and Actuators Understand .pdf
engsharaf2025
 
Arduino Workshop (3).pptx
Arduino Workshop (3).pptxArduino Workshop (3).pptx
Arduino Workshop (3).pptx
HebaEng
 
Arduino Development For Beginners
Arduino Development For BeginnersArduino Development For Beginners
Arduino Development For Beginners
FTS seminar
 
Arduino.pptx
Arduino.pptxArduino.pptx
Arduino.pptx
AadilKk
 
Getting startedwitharduino ch04
Getting startedwitharduino ch04Getting startedwitharduino ch04
Getting startedwitharduino ch04
Anil Yadav
 
Arduino Slides With Neopixels
Arduino Slides With NeopixelsArduino Slides With Neopixels
Arduino Slides With Neopixels
sdcharle
 
introductiontoarduino-111120102058-phpapp02.pdf
introductiontoarduino-111120102058-phpapp02.pdfintroductiontoarduino-111120102058-phpapp02.pdf
introductiontoarduino-111120102058-phpapp02.pdf
HebaEng
 
Introduction to Arduino with ArduBlock & SparkFun LilyPad
Introduction to Arduino with ArduBlock & SparkFun LilyPadIntroduction to Arduino with ArduBlock & SparkFun LilyPad
Introduction to Arduino with ArduBlock & SparkFun LilyPad
Brian Huang
 
Basic arduino components and more things about arduino
Basic arduino components and more things about arduinoBasic arduino components and more things about arduino
Basic arduino components and more things about arduino
GeorgeTsak
 
Arduino slides
Arduino slidesArduino slides
Arduino slides
sdcharle
 
Arduino Workshop Slides
Arduino Workshop SlidesArduino Workshop Slides
Arduino Workshop Slides
mkarlin14
 
Arduino_IOT Arduino_IOT Arduino_IOTArdui
Arduino_IOT Arduino_IOT Arduino_IOTArduiArduino_IOT Arduino_IOT Arduino_IOTArdui
Arduino_IOT Arduino_IOT Arduino_IOTArdui
deepikayadav216323
 
Ad

Recently uploaded (20)

ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
Jasper Oosterveld
 
Jira Administration Training – Day 1 : Introduction
Jira Administration Training – Day 1 : IntroductionJira Administration Training – Day 1 : Introduction
Jira Administration Training – Day 1 : Introduction
Ravi Teja
 
Evaluation Challenges in Using Generative AI for Science & Technical Content
Evaluation Challenges in Using Generative AI for Science & Technical ContentEvaluation Challenges in Using Generative AI for Science & Technical Content
Evaluation Challenges in Using Generative AI for Science & Technical Content
Paul Groth
 
Gihbli AI and Geo sitution |use/misuse of Ai Technology
Gihbli AI and Geo sitution |use/misuse of Ai TechnologyGihbli AI and Geo sitution |use/misuse of Ai Technology
Gihbli AI and Geo sitution |use/misuse of Ai Technology
zainkhurram1111
 
Data Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any ApplicationData Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any Application
Safe Software
 
Contributing to WordPress With & Without Code.pptx
Contributing to WordPress With & Without Code.pptxContributing to WordPress With & Without Code.pptx
Contributing to WordPress With & Without Code.pptx
Patrick Lumumba
 
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Lorenzo Miniero
 
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Nikki Chapple
 
Measuring Microsoft 365 Copilot and Gen AI Success
Measuring Microsoft 365 Copilot and Gen AI SuccessMeasuring Microsoft 365 Copilot and Gen AI Success
Measuring Microsoft 365 Copilot and Gen AI Success
Nikki Chapple
 
Maxx nft market place new generation nft marketing place
Maxx nft market place new generation nft marketing placeMaxx nft market place new generation nft marketing place
Maxx nft market place new generation nft marketing place
usersalmanrazdelhi
 
Co-Constructing Explanations for AI Systems using Provenance
Co-Constructing Explanations for AI Systems using ProvenanceCo-Constructing Explanations for AI Systems using Provenance
Co-Constructing Explanations for AI Systems using Provenance
Paul Groth
 
Agentic AI - The New Era of Intelligence
Agentic AI - The New Era of IntelligenceAgentic AI - The New Era of Intelligence
Agentic AI - The New Era of Intelligence
Muzammil Shah
 
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 ADr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr. Jimmy Schwarzkopf
 
Introducing FME Realize: A New Era of Spatial Computing and AR
Introducing FME Realize: A New Era of Spatial Computing and ARIntroducing FME Realize: A New Era of Spatial Computing and AR
Introducing FME Realize: A New Era of Spatial Computing and AR
Safe Software
 
Kubernetes Cloud Native Indonesia Meetup - May 2025
Kubernetes Cloud Native Indonesia Meetup - May 2025Kubernetes Cloud Native Indonesia Meetup - May 2025
Kubernetes Cloud Native Indonesia Meetup - May 2025
Prasta Maha
 
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
James Anderson
 
Let’s Get Slack Certified! 🚀- Slack Community
Let’s Get Slack Certified! 🚀- Slack CommunityLet’s Get Slack Certified! 🚀- Slack Community
Let’s Get Slack Certified! 🚀- Slack Community
SanjeetMishra29
 
SDG 9000 Series: Unleashing multigigabit everywhere
SDG 9000 Series: Unleashing multigigabit everywhereSDG 9000 Series: Unleashing multigigabit everywhere
SDG 9000 Series: Unleashing multigigabit everywhere
Adtran
 
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Aaryan Kansari
 
End-to-end Assurance for SD-WAN & SASE with ThousandEyes
End-to-end Assurance for SD-WAN & SASE with ThousandEyesEnd-to-end Assurance for SD-WAN & SASE with ThousandEyes
End-to-end Assurance for SD-WAN & SASE with ThousandEyes
ThousandEyes
 
ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
ELNL2025 - Unlocking the Power of Sensitivity Labels - A Comprehensive Guide....
Jasper Oosterveld
 
Jira Administration Training – Day 1 : Introduction
Jira Administration Training – Day 1 : IntroductionJira Administration Training – Day 1 : Introduction
Jira Administration Training – Day 1 : Introduction
Ravi Teja
 
Evaluation Challenges in Using Generative AI for Science & Technical Content
Evaluation Challenges in Using Generative AI for Science & Technical ContentEvaluation Challenges in Using Generative AI for Science & Technical Content
Evaluation Challenges in Using Generative AI for Science & Technical Content
Paul Groth
 
Gihbli AI and Geo sitution |use/misuse of Ai Technology
Gihbli AI and Geo sitution |use/misuse of Ai TechnologyGihbli AI and Geo sitution |use/misuse of Ai Technology
Gihbli AI and Geo sitution |use/misuse of Ai Technology
zainkhurram1111
 
Data Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any ApplicationData Virtualization: Bringing the Power of FME to Any Application
Data Virtualization: Bringing the Power of FME to Any Application
Safe Software
 
Contributing to WordPress With & Without Code.pptx
Contributing to WordPress With & Without Code.pptxContributing to WordPress With & Without Code.pptx
Contributing to WordPress With & Without Code.pptx
Patrick Lumumba
 
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Multistream in SIP and NoSIP @ OpenSIPS Summit 2025
Lorenzo Miniero
 
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Protecting Your Sensitive Data with Microsoft Purview - IRMS 2025
Nikki Chapple
 
Measuring Microsoft 365 Copilot and Gen AI Success
Measuring Microsoft 365 Copilot and Gen AI SuccessMeasuring Microsoft 365 Copilot and Gen AI Success
Measuring Microsoft 365 Copilot and Gen AI Success
Nikki Chapple
 
Maxx nft market place new generation nft marketing place
Maxx nft market place new generation nft marketing placeMaxx nft market place new generation nft marketing place
Maxx nft market place new generation nft marketing place
usersalmanrazdelhi
 
Co-Constructing Explanations for AI Systems using Provenance
Co-Constructing Explanations for AI Systems using ProvenanceCo-Constructing Explanations for AI Systems using Provenance
Co-Constructing Explanations for AI Systems using Provenance
Paul Groth
 
Agentic AI - The New Era of Intelligence
Agentic AI - The New Era of IntelligenceAgentic AI - The New Era of Intelligence
Agentic AI - The New Era of Intelligence
Muzammil Shah
 
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 ADr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr Jimmy Schwarzkopf presentation on the SUMMIT 2025 A
Dr. Jimmy Schwarzkopf
 
Introducing FME Realize: A New Era of Spatial Computing and AR
Introducing FME Realize: A New Era of Spatial Computing and ARIntroducing FME Realize: A New Era of Spatial Computing and AR
Introducing FME Realize: A New Era of Spatial Computing and AR
Safe Software
 
Kubernetes Cloud Native Indonesia Meetup - May 2025
Kubernetes Cloud Native Indonesia Meetup - May 2025Kubernetes Cloud Native Indonesia Meetup - May 2025
Kubernetes Cloud Native Indonesia Meetup - May 2025
Prasta Maha
 
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
GDG Cloud Southlake #43: Tommy Todd: The Quantum Apocalypse: A Looming Threat...
James Anderson
 
Let’s Get Slack Certified! 🚀- Slack Community
Let’s Get Slack Certified! 🚀- Slack CommunityLet’s Get Slack Certified! 🚀- Slack Community
Let’s Get Slack Certified! 🚀- Slack Community
SanjeetMishra29
 
SDG 9000 Series: Unleashing multigigabit everywhere
SDG 9000 Series: Unleashing multigigabit everywhereSDG 9000 Series: Unleashing multigigabit everywhere
SDG 9000 Series: Unleashing multigigabit everywhere
Adtran
 
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Agentic AI Explained: The Next Frontier of Autonomous Intelligence & Generati...
Aaryan Kansari
 
End-to-end Assurance for SD-WAN & SASE with ThousandEyes
End-to-end Assurance for SD-WAN & SASE with ThousandEyesEnd-to-end Assurance for SD-WAN & SASE with ThousandEyes
End-to-end Assurance for SD-WAN & SASE with ThousandEyes
ThousandEyes
 
Ad

Arduino spooky projects_class1

  • 1. Spooky Projects Introduction to Microcontrollers with Arduino Class 1 7 Oct 2006 - machineproject - Tod E. Kurt Everyone’s had a little programming experience, right? Who’s had any electrical experience?
  • 2. What’s for Today • Introduction to Arduino • Building an LED flashlight • Making some blinky LED eyes
  • 3. Class Kit What’s in your goodie bag
  • 4. Class Kit Manifest • Arduino NG USB board • Arduino ProtoShield • Solderless breadboard • USB cable • RC servo • piezo buzzer • 6m hookup wire in ghastly colors • potentiometer with knob • R,G,B and mystery LEDs • two push switches • 9V battery and connector • 220, 330, 10k, and 1M resistors • light sensitive resistor • 5.1v zener diode • square of velcro • scary eyeballs And other bits as we progress Ignore most of the kit for now, just use Arduino board and USB cable Complete kit manifest with part numbers will be online
  • 5. A Word on Safety • Electronics are toxic to you • Lead in some of the parts • Wash up afterwards • You are toxic to electronics • Static-sensitive: don’t shuffle your feet • Wires only bend so much
  • 6. What is Arduino? • Open Source Physical Computing Platform • open source: free to inspect & modify • physical computing. er, what?ubiquitous computing, pervasive computing, ambient intelligence, calm computing, everyware, spimes, blogjects, smart objects... • A physical board, a programming environment, a development philosophy • Tiny computer you can program • Completely stand-alone, talks to other devices Physical computing as invisible computing Can run off a battery Can talk to other computers, cell phones, etc.
  • 7. What is Arduino? • Based on AVR-GCC, avr-libc, AVRlib and Processing (all open source projects) • Very similar to Basic Stamp (if you know it) • but cheaper, faster, & open • Uses AVR ATmega8 microcontroller chip Basic Stamp uses PIC microcontroller chip. PICs and AVRs are very comparable, one’s not necessarily better than the other AVRs are a little better if you’re using a language like C (stack-based) Don’t need to worry about the chip particulars for now
  • 8. What is Arduino? • Why not just use a bare AVR ATmega8 chip? • Arduino is also a standardized “bootloader” • A tiny program that loads other programs • It’s alive during first 5 seconds A bootloader is akin to an BIOS on a real computer. It handles the startup of the chip After 5 seconds, your program runs Don’t need special programmer board with a bootloader Arduino can work with other AVR chips, some are smaller than your fingernail, cost ~ 40 cents
  • 9. What is Arduino? • Capabilities • 8 kBytes of Flash program memory • 1 kByte of RAM • 12 MHz (Apple II: 1 MHz) • Inputs and Outputs • 13 digital input/output pins • 5 analog input pins Digital I/O can read switches and buttons, control LEDs and motors Analog input can read knobs or other varying sensors Analog output can be done with PWM
  • 10. What is Arduino? • Write programs on your PC • Download them into the Arduino board • Arduino board can then be used by itself But how do you program it? No keyboard, mouse or display Your PC becomes the “head”
  • 12. Arduino Board analog inputs reset button power LED test LED digital I/O Diagrammatic version, to simplify But of a slightly older version of the board
  • 13. Digital? Analog? • Digital – only has two values: on/off • Analog – has many (infinite) values • Computers don’t really do analog • So they fake it, with quantization Quantization = breaking up the analog range into bins. The number of bins is the resolution. More bins = higher accuracy, but is more complex Digital can be thought of as only two bins.
  • 14. Arduino Software compile (verify) upload to board status area That’s the full code for blinking an LED, btw. Arduino defines several useful functions like digitalWrite() and delay(). more on that later Processing and Wiring not needed
  • 15. Arduino & Processing http://processing.org/ build generative art or other applets easily not needed for Arduino, but can work with it Arduino has essentially the same GUI as Processing Easier than Arduino, since all software Though similar UI and philosophy, Arduino is a different language We’ll use Processing later in the class to let the computer control Arduino & vice-versa
  • 16. • Download software: http://arduino.cc/ • Mac OS X PPC or Intel (must pick) • Windows 2000/XP • Install drivers • In “drivers” folder, pick appropriate one • Windows: unzip driver, plug in board, setup • “macosx-setup-command” for Mac folk • Reboot Installing Arduino Different Arduino downloads for each operating system Different drivers for each OS too “macosx-setup-command” must be run before reboot, but, it will go away in next version
  • 17. Using Arduino • Programs are called “sketches” • Load up example sketch “led_blink”
  • 19. What’s my serial port? Windows: Use Device Manager to find COM port Mac: It’s called “/dev/tty.usbserial-something”
  • 20. Using Arduino • Write program • Compile (check for errors) • Reset board • Upload to board Try it out with “led_blink”! On reset, board will flash on-board pin 13 LED really fast for a split-second to indicate bootloader exists When uploading, TX/RX lights will flash as data is transferred Then the board resets, pin 13 will flash fast again Finally, your program will run
  • 23. Making Circuits heart pumps, blood flows voltage pushes, current flows
  • 24. LEDs physical characteristics schematic symbol • LED = Light-Emitting Diode • electricity only flows one way in a diode • Needs a “current limiting” resistor, or burns out bar = minus Many types of integrated lenses. Some project a narrow beam (like the ones in this class), some project a very wide beam
  • 25. LED flashlight wiring diagram schematic All LED circuits are essentially this: power source, current limiter, LED Flat part of LED goes to negative, like bar in schematic The higher the resistance, the dimmer the LED; the lower, the brighter
  • 26. LED flashlight Take out solderless breadboard, resistor, LED, and battery and make a circuit LEDs have been marked a little as to what color they are, but color doesn’t matter here
  • 27. Solderless Breadboards groups of 5 connected but not connected across the jump not connected Insert wires into holes to make a connection. *Much* easier, quicker than soldering But, they wear out, are expensive ($8 for this little one)
  • 28. Using Solderless Breadboards Using needle nose pliers can help Grab wire or lead toward end and push into hole
  • 29. Blinky LED circuit wiring diagram schematic “hello world” of microcontrollers In schematics signals often flow from top-left to bottom-right Common nodes like “gnd” are given their own symbol Pick any digital pin to hook up to, doesn’t matter which
  • 30. Blinky LED circuit • Plug shield on top of Arduino board • Stick breadboard to shield
  • 31. Blinky LED Software You’ve already seen it.
  • 32. Arduino Sketch Structure • Declare variables at top • Initialize • setup() – run once at beginning, set pins • Running • loop() – run repeatedly, after setup() Pins can be changed in loop() too, but conceptually easier in setup()
  • 33. Arduino “Language” • Language is standard C (but made easy) • Lots of useful functions • pinMode() – set a pin as input or output • digitalWrite() – set a digital pin high/low • digitalRead() – read a digital pin’s state • analogRead() – read an analog pin • analogWrite() – write an “analog” PWM value • delay() – wait an amount of time • millis() – get the current time • And many others. And libraries. And examples! Also: serial library, LCD library, servo examples
  • 34. Development Cycle • Make as many changes as you want • Not like most web programming: edit ➝ run • Edit ➝ compile ➝ upload ➝ run edit compile upload run
  • 36. Next Week • Reading buttons • Reading analog values (knobs) • Detecting the dark • More complex LED circuits • Stand-alone Arduino