Good LED Circuit 5V0 GND. What Voltage Does Meter See? Answer: 5 V.

Slides:



Advertisements
Similar presentations
Khaled A. Al-Utaibi Interfacing an LED The Light Emitting Diode (LED) Applications DC Characteristics & Operation Interfacing to.
Advertisements

EMS1EP Lecture 6 Digital Inputs
ARDUINO CLUB What we’re really doing. BASICS The setup() and loop() functions.
Lab7: Introduction to Arduino
Programming Microcontrollers B. Furman 19MAR2011.
Re-programming the Simon Says with Arduino Linz Craig, Brian Huang.
Digital & Analog Inputs. Review Fundamental parts of an Arduino program are … Setting output types using pinMode. Declaring variables Can write a digital.
ELCT 201 week 13 Analog ON/OFF control system conversion to Digital ON/OFF control system.
Intro to Programming and Microcontrollers. Activity Group into pairs and sit back-to-back. Pick one person who is going to draw. The other person will.
Finish your programs from last week STOPLIGHT CIRCUIT! You may need … – int – void setup() – void loop() – pinMode – digitalWrite – delay.
Basic Circuits – Lab 2 Arduino and Sensors Xmedia Spring 2011.
ARDUINO 1 Under Development. Arduino  Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software.
Lecture 9: Microcontrollers – part 1 BJ Furman 29OCT2012.
chipKit Sense Switch & Control LED
ARDUINO 1 Under Development. Arduino  Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software.
ARDUINO 1 Under Development. Arduino  Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software.
Khaled A. Al-Utaibi  The Push Button  Interfacing Push Buttons to Arduino  Programming Digital Inputs  Working with “Bouncy”
Cascade switching of an LED EAS 199B Winter 2013.
Tweaking Your Simon Adding a photoresistor and changing code Instruction by Pete Lewis and Linz Craig.
Pulse Width Modulation (PWM). 100% Pulse Width Modulation (PWM) 0% On the chipKIT there are 490 periods per second. Use analogWrite(pin, value) to control.
LECTURE 2 – INPUTS THIS LECTURE WILL INTRODUCE HOW TO INPUT SIGNALS INTO AN ARDUINO.
Warmup – 16FEB2012 This one is for practice. I have paper if you need it. Suppose there are eight, single-pole, single-throw (SPST) switches connected.
ARDUINO 1. Basics  Comments  /* * Blink * * The basic Arduino example. Turns on an LED on for one second, * then off for one second, and so on... We.
Arduino Circuits and Code. int ledPin = 9; void setup() { pinMode(ledPin, OUTPUT); } void loop() { digitalWrite(ledPin, LOW); delay(1000); digitalWrite(ledPin,
Lecture 10: Peripherals Bryan Burlingame 04 November 2015.
ARDUINO 1 By Wilmer Arellano. Arduino.  Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use.
Arduino libraries Datatekniker Udvidet hardware/software.
Autumn, 2012C.-S. Shieh, EC, KUAS, Taiwan1 智慧電子應用設計導論 (1/3) Sensors I Chin-Shiuh Shieh ( 謝欽旭 ) Department of Electronic.
INTERNET OF EVERYTHING SDU 2016 Week 4. Simple Digital and Analog Inputs  The Arduino’s ability to sense digital and analog inputs allows it to respond.
Photoresistor resistance changes dramatically with light level living with the lab Using Photoresistors with an Arduino © 2011 LWTL faculty team.
Motor TYWu.
Microcontroller basics Embedded systems for mortals.
Microcontroller basics Embedded systems for mortals.
Robotics Grant Agreement No LLP UK-LEONARDO-LMP Project acronym: CLEM Project title: Cloud services for E-Learning in Mechatronics Technology.
Programming in Arduino Materials:Arduino Board Casperelectronics Pre Pres. Notes Photos from workshop?
Bdps 2 Lecture 2. Circuits and Ohm's Law For resistive circuits.
LAB1 TYWU. Devices Dip Switch (4 Switches) Triple Output LED (RGB) –Common Cathode.
Arduino + Bluetooth TYWu. Connection Arduino + Bluetooth Module.
:Blink Blink: Er. Sahil Khanna
ARDUINO 실습 과제 보 고서. PWM 은 아날로그 출력이라는 함수를 사용하게 되는데 이 출력에는 3, 5, 6, 9, 10, 11 번의 핀만 사용 가능. ( 숫자 옆 에 ~ 표시 )
Istituto Tecnico Industriale A.Monaco EURLAB Control a Servo Motor If you want to swing an robot arm or … steer a robot you need a special motor (Servo).
Arduino “Getting Started” Instructor : Dr Matthew Miss Khin Yi Kyaw
[LAB 2] Cloud9 IDE  Cloud9 IDE introduction  Example and Exercise.
1 Introduction to Coding. 2 Example Codes A lot of example codes are given with Arduino IDE A code can often be based on a previous example rather than.
Introduction to Physical Computing
Assist. Prof. Rassim Suliyev - SDU 2017
Microcontroller basics
Microcontroller basics
Wireless Cue Light Project
Cascade switching of an LED
Welcome to Arduino A Microcontroller.
Get Your Project Started with Arduino
(6. Sunu) (AVR Assembly Örnekleri)
3.0 ARDUINO WORKSHOP PRESENTATION FOR STUDENTS IN 4º DEGREE OF COMPULSORY SECONDARY EDUCATION 3.0.
Arduino.
IoT Programming the Particle Photon.
Chapter 2 Push button and Potentiometer
Arduino 101 Credit(s):
using the Arduino to make LEDs flash
Servos and Stepper Motors
CS-4540 Robotics - Lab 05 Switch inputs to the Arduino Uno
Last of the LED’s and Arduino
Programming 2: The Arduino IDE & First Sketches
Arduino Practice: Photoresistors, PWM, Potentiometers, Motors
(Dr. Öğr. Üyesi Deniz Dal)
CTY SAR FCPS Shawn Lupoli, Elliot Tan
Arduino Uno circuit basics
Setting up a basic program with Arduino
SAURABH GINGADE.
Arduino程式範例.
Presentation transcript:

Good LED Circuit 5V0 GND

What Voltage Does Meter See? Answer: 5 V

What Voltage Does Meter See? Answer: 0 V R is a pull-down resistor

What Voltage Does Meter See? Answer: 0 V

What Voltage Does Meter See? Answer: 5 V R is a pull-up resistor

chipKit Sense Switch & Control LED

/* Set Pin 25 (ledPin) to HIGH. */ int ledPin = 25; // Label Pin 25 ledPin. void setup() { // setup() runs once. pinMode(ledPin, OUTPUT); // Set ledPin for output. } void loop() { // loop() runs "forever". digitalWrite(ledPin, HIGH); // Set ledPin HIGH. } Program to Turn on LED

/* Set Pin 25 (ledPin) to HIGH if Pin 4 (buttonPin) is HIGH. Otherwise set Pin 25 to LOW. */ int ledPin = 25; // Label Pin 25 ledPin. int buttonPin = 4; // Label Pin 4 buttonPin. void setup() { // setup() runs once. pinMode(buttonPin, INPUT); // Set buttonPin for input. pinMode(ledPin, OUTPUT); // Set ledPin for output. } void loop() { // loop() runs "forever". // Check if buttonPin is HIGH. if (digitalRead(buttonPin) == HIGH) { digitalWrite(ledPin, HIGH); // Set ledPin HIGH. } else { digitalWrite(ledPin, LOW); // Set ledPin LOW. } Button-Controlled LED

/* Alternate Pin 25 (ledPin) between HIGH and LOW every half second if Pin 4 (buttonPin) is HIGH. Otherwise set Pin 25 to LOW. */ int ledPin = 25; // Label Pin 25 ledPin. int buttonPin = 4; // Label Pin 4 buttonPin. void setup() { // setup() runs once. pinMode(buttonPin, INPUT); // Set buttonPin for input. pinMode(ledPin, OUTPUT); // Set ledPin for output. } void loop() { // loop() runs "forever". // Check if buttonPin is HIGH. if (digitalRead(buttonPin) == HIGH) { digitalWrite(ledPin, HIGH); delay(500); // Wait a half second. digitalWrite(ledPin, LOW); delay(500); // Wait another half second. } else { digitalWrite(ledPin, LOW); } Button-Controlled (Blinking) LED