Arduino Uno circuit basics

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
Anurag Dwivedi & Rudra Pratap Suman.  Open Source electronic prototyping platform based on flexible easy to use hardware and software.
Embedded Sumo 1T4 – 1T5 UTRA.
Using the Arduino to Make an LED Flash Work in teams of two! living with the lab digital I/O pins (I/O = input / output) USB cable plug power pins.
Introduction to Arduino Prepared by R. Lamond.  “Arduino is an open-source electronics prototyping platform based on flexible, easy- to-use hardware.
Basic Circuits – Lab 2 Arduino and Sensors Xmedia Spring 2011.
Embedded Programming and Robotics
ARDUINO PROGRAMMING Working with the Arduino microcontroller.
Working with Arduino: Lesson #1: Getting Acquainted with the Kit EGN1007.
Arduino. What is it? A open-source software suite and single-board microcontroller. Allows easy and affordable prototyping of microcontroller applications.
Introduction to the Arduino
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.
L ILY P AD T RAINING C ENTENNIAL E LEMENTARY 2012 Material by Linz Craig Revision by Sarah Bloms Additional images by Modkit & Adam Meyer.
Good LED Circuit 5V0 GND. What Voltage Does Meter See? Answer: 5 V.
1 - Remove LED from 13 and GND - Bring out your breadboard from HW#4 Arduino Overview:
Microcontroller Hands-on Workshop #2 Ahmad Manshad New Mexico State University Institute of Electrical and Electronics Engineers October 31, 2009.
Arduino libraries Datatekniker Udvidet hardware/software.
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.
:Blink Blink: Er. Sahil Khanna
Arduino “Getting Started” Instructor : Dr Matthew Miss Khin Yi Kyaw
1 Transistor. 2 Transistors are used to turn components on and off They come in all different shapes and sizes.
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.
What is Arduino? It's an open source electronics prototyping platform: Open source: resources that can be used, redistributed or rewritten free of charge,
Harpeth Hall Jan 2016 Introduction to Arduino Prepared for Harpeth Hall Winterim January 2016.
Having fun with code, using Arduino in a middle school CS classroom
Arduino.
Getting Started: Building & Programming
Val Manes Department of Math & Computer Science
Downloading Arduino FOR WINDOWS.
Microcontroller basics
UTA010 : Engineering Design – II
An Arduino Workshop A Microcontroller.
Cascade switching of an LED
Welcome to Arduino A Microcontroller.
Get Your Project Started with Arduino
UCD ElecSoc Robotics Club 2017/2018
Arduino Part 1 Topics: Microcontrollers Programming Basics
INC 161 , CPE 100 Computer Programming
Arduino.
Въведение в Arduino.
Arduino Basics Connect Arduino to USB port
Arduino Uno and sensors
Introduction to Arduino Microcontrollers
Introduction to Arduino Microcontrollers
Arduino and Grove LET’S START.
ARDUINO     What is an Arduino? Features 14 Digital I/O pins 6 Analogue inputs 6 PWM pins USB serial 16MHz Clock speed 32KB Flash memory 2KB SRAM.
What is Arduino? By James Tedder.
Arduino 101 Credit(s):
using the Arduino to make LEDs flash
Working with Arduino: Lesson #1: Getting Acquainted with the Kit
Welcome to Digital Electronics using the Arduino Board
Chapter 1 Introduction of Arduino
Arduino : Introduction & Programming
Arduino Part 4 Let there be more light.
CTY SAR FCPS Shawn Lupoli, Elliot Tan
Arduino Motor Lab Inspired by NYU ITP project
Multiplexing seven-segment displays
Aeroponic Engineering and Vertical Farming
Setting up a basic program with Arduino
Introduction to Arduinos
SAURABH GINGADE.
Arduino程式範例.
Introduction to Arduino IDE and Software
Interrupts.
Presentation transcript:

Arduino Uno circuit basics

Let’s build our first circuit ! What is an Arduino? An Arduino can be used to develop interactive objects, taking inputs from a variety of switches or sensors, and controlling a variety of lights, motors, and other physical outputs. Arduino projects can be stand-alone, or they can communicate with software running on your computer. Our iLumin8 project will be a stand-alone Arduino project, the final light display will be controlled just by your Arduino board. Let’s build our first circuit !

1. File  Examples  01.Basics  Bare Minimum Now copy the code below and paste into the sketch pad, to replace this code // the setup function runs once when you press reset or power the board void setup() { // initialize digital pin 13 as an output. pinMode(13, OUTPUT); } // the loop function runs over and over again forever void loop() { digitalWrite(13, HIGH); // turn the LED on (HIGH is the voltage level) delay(1000); // wait for a second digitalWrite(13, LOW); // turn the LED off by making the voltage LOW

Arduino Code Basics

‘Blink’ example code: The example code above contains a lot of ‘comments’. The symbol // is used to write a ‘comment’ in the program to allow another user to understand how the program works. The comments are not part of the code. Without comments, the code would look like this:

Change the Code! Try changing the delay time from 1000 to 200 (milliseconds) Can you make the code work from pin 9 instead of pin 13? What else can you do to change the code?

2. File  Examples  01.Basics  Fade Upload the ‘Fade’ example sketch Use the same circuit as Blink Which pin will need to be connected to the LED? (check the beginning of the sketch code) Can you change the code to get the LED to fade faster? fade slower? fade to only half the maximum brightness?

Adding a switch to the circuit

Make a Touch Lamp

3. File  Examples  01.Basic  Bare Minimum Type the following code into the Bare Minimum sketch and save it on your desktop as Touch Lamp. Upload it and try it out!

Flashing LEDs – remember the Flip Flop circuit Flashing LEDs – remember the Flip Flop circuit? An Arduino can do the same with only a few parts – two LEDs and two 100Ω resistors: void setup() { // put your setup code here, to run once: pinMode(7, OUTPUT); //Pin 7 is defined as output pinMode(8, OUTPUT); //Pin 8 is defined as output } void loop() { // put your main code here, to run repeatedly: digitalWrite(7, HIGH); //turn on the LED on pin 7 delay(1000); //wait for 1000 milliseconds digitalWrite(7, LOW); //turn off the LED on pin 7 digitalWrite(8, HIGH); //turn on the LED on pin 8 digitalWrite(8, LOW); //turn off the LED on pin 8 //Athe end of the loop the program starts again from the beginning of //the loop part. So..turn on LED on pin 7..wait for 1000 //milliseconds..etc..etc..