This document provides an overview of Arduino programming concepts including:
- Microcontrollers contain a CPU, memory, input/output pins and other peripherals on a single integrated circuit.
- Arduino is an open-source electronics platform with a microcontroller, pins to connect circuits, and software to program it.
- The core Arduino functions include setup(), loop(), pinMode(), digitalWrite(), digitalRead(), analogWrite(), analogRead(), and delay().
- Examples demonstrate blinking LEDs, reading input, using conditions and loops, arrays, LCD displays, and controlling servo motors.
- Arduino programming provides an accessible way to learn embedded systems and interact with circuits.
Arduino_CSE ece ppt for working and principal of arduino.pptSAURABHKUMAR892774
油
The document provides an introduction and overview of Arduino boards and programming. It discusses:
- The different types of Arduino boards available.
- How to get started with the Arduino IDE and programming Arduino boards.
- Examples of common sensors and actuators that can be connected to Arduino boards like LEDs, buttons, temperature sensors.
- The basic structure of Arduino programs including setup(), loop(), and common functions like digitalRead(), digitalWrite(), and pinMode().
This document provides an overview of an Arduino course covering embedded systems and programming. The summary includes:
- The course covers introduction to embedded systems including components, characteristics, and basic structure. It also covers introduction to computer programming concepts for Arduino like variables, operators, and control statements.
- The Arduino environment and programming is explained including the board, IDE, sensors, actuators and communication. Common electronic components and modules used with Arduino like LEDs, buttons, LCDs, ultrasonic sensors, and Bluetooth are described.
- The document concludes with a section on circuit diagrams for Arduino projects. Key concepts around pins, analog/digital input/output, pulse width modulation, delay, and
This document provides an overview of an Arduino course covering embedded systems and programming. The summary includes:
- The course covers introduction to embedded systems including components, characteristics, and basic structure. It also covers introduction to computer programming concepts for Arduino including variables, operators, control statements, functions, and C language basics.
- The document outlines the Arduino environment including boards, software IDE, sensors, actuators and provides examples of electronic components like LEDs, buttons, and code for digital input/output and serial communication.
- Finally, the course covers creating circuit diagrams and interfacing with common modules like LCD displays, ultrasonic sensors, relays, Bluetooth and DC motors.
The document provides an overview of topics related to interfacing sensors and actuators with Arduino microcontrollers. It discusses basic I/O components, sensor interfacing including ultrasonic, IR, temperature and motion sensors. It also covers actuators, motor control, LCD displays and programming concepts for Arduino like digital and analog I/O, PWM and interrupts. References for further reading on Arduino programming are also provided.
4 IOT 18ISDE712 MODULE 4 IoT Physical Devices and End Point-Aurdino Uno.pdfJayanthi Kannan MK
油
The document discusses the Arduino Uno microcontroller board. It provides details about the Arduino platform and describes the Arduino Uno board, which is based on the ATmega328P microcontroller. It lists the main components of the Arduino Uno board and explains the functions of pins and inputs/outputs. The document also provides an overview of the fundamentals of Arduino programming, including key functions, variables, conditions, and serial communication.
The document provides an overview of the Arduino Uno microcontroller board. It describes the main components of the board including 14 digital input/output pins, 6 analog inputs, a 16MHz crystal oscillator, a USB connection, a power jack, and a reset button. It also explains how to power the board using a USB cable connected to a computer or an external power supply. The document then introduces some basic Arduino programming concepts like functions, data types, control structures, and input/output functions.
This document provides an overview of the Arduino Uno microcontroller board. It defines a microcontroller as a single-chip computer containing a CPU, memory, and input/output interfaces. The Arduino is an open-source electronics platform with easy-to-use hardware and software that allows anyone to develop interactive electronic projects. Key specifications of the Arduino Uno board are provided, including its microcontroller chip, memory, analog and digital pins. The process of analog to digital conversion is explained. Basic Arduino programming concepts like data types, statements, operators, and control structures are covered. The bare minimum code structure of setup() and loop() functions is described.
This document provides an overview of Arduino programming and the Arduino platform. It discusses what Arduino is, what types of projects can be built with Arduino, and covers the basics of getting started, digital and analog inputs/outputs, Neopixels, and putting projects together. It also includes an agenda and summaries of the Arduino UNO board and common sensors that can be used.
Arduino is an open-source project that created microcontroller-based kits for building digital devices and interactive objects that can sense and control physical devices.
This document provides an overview of microcontrollers and introduces the Arduino microcontroller development platform. It discusses how microcontrollers can receive sensory input from the environment using sensors like light sensors. It also covers digital and analog input/output, serial communication, pulse width modulation (PWM) to control motors, and includes examples of coding with the Arduino.
The document provides an overview of learning objectives and topics for an introduction to Arduino lecture, including:
- How to use a potentiometer as a sensor and identify input/output ports of an Arduino.
- What an Arduino is, its boards and IDE software.
- Why Arduinos are popular for electronics projects.
- How Arduinos will be used in labs, including acquiring sensor data and sending signals to systems using code.
This document provides an overview and introduction to using Arduino boards for physical computing projects. It discusses installing the Arduino software, understanding analog and digital signals, basic programming concepts like inputs, outputs, and conditional statements. It also covers a sample "Blink" project to get started using Arduino boards and programming the onboard LED and buttons.
The document provides an overview of Arduino, including what it is, common Arduino boards, digital and analog input/output, and example projects. Arduino is an open-source electronics prototyping platform that can be used to create interactive objects. It uses a simple hardware and software environment to program and develop prototypes. The Arduino Uno is one of the most commonly used boards, which contains an Atmega328 microcontroller, digital and analog pins, and can be programmed via USB. The document describes how to connect various components like LEDs, buttons, sensors and motors to an Arduino board.
The document provides an overview of Arduino, including what it is, common Arduino boards, digital and analog input/output, and example projects. Arduino is an open-source electronics prototyping platform that allows users to create interactive objects and environments. It uses flexible, easy-to-use hardware and software. Common tasks demonstrated include blinking LEDs, reading buttons, and controlling motors. The document serves as an introduction to getting started with the Arduino platform.
The document provides instructions for connecting an Arduino board to a Windows computer and uploading a simple "Blink" sketch. It outlines downloading the Arduino IDE software, connecting the board via USB, installing the correct USB drivers, opening the Blink example sketch, selecting the board and serial port in the IDE, and uploading the program to make an on-board LED blink.
This document outlines the syllabus for a course on Internet of Things (IoT) technology taught by Dr. Syed Mustafa at HKBK College of Engineering, Bengaluru. It covers key modules including IoT physical devices and endpoints such as Arduino and Raspberry Pi. The Arduino section describes the Arduino microcontroller board and its components. It also covers Arduino programming basics like setup and loop functions, input/output functions, variables, conditional statements, and serial communication. The Raspberry Pi section provides an overview of the single-board computer and its hardware layout.
Intro to Arduino Class taught at CRASHspace by Quin (Qtechknow). Originally taught on August 11, 2012 at Crashspace, in LA. This revision patches the diagrams and fixes the code! Thanks to SparkFun who shared all of their original slides with me!
The introduction to Arduino labs at Malm旦 University. These slides have been handed down since the beginning of Arduino. They have more authors then i can remember and should by no means be considered mine.
The introduction to Arduino labs at Malm旦 University. These slides have been handed down since the beginning of Arduino. They have more authors then i can remember and should by no means be considered mine.
This document provides an introduction to using Arduino boards. It discusses getting started with the Arduino IDE, programming basics like digital I/O and timing functions. Examples are provided to blink an LED, read a digital sensor, read an analog sensor with a potentiometer, and fade an LED using pulse width modulation. Terminology around bits, bytes and serial communication is also explained. The document aims to teach Arduino fundamentals and provide practice examples for learning.
The document discusses Arduino, an open-source electronics prototyping platform. It describes Arduino Uno, including its processor, memory, input/output pins, and operating voltage. It provides steps for getting started with Arduino, including downloading the IDE, connecting the board, selecting options in the IDE, and uploading a basic blink program. The document also covers some key Arduino concepts like variables, conditional statements, loops, and functions.
SIMULATION OF FIR FILTER BASED ON CORDIC ALGORITHMVLSICS Design
油
Coordinate Rotation Digital Computer (CORDIC) discovered by Jack E Volder. It is a shift-add operation and iterative algorithm. CORDIC algorithm has wide area for several applications like digital signal processing, biomedical processing, image processing, radar signal processing, 8087 math coprocessor, the HP-35 calculator, Discrete Fourier, Discrete Hartley and Chirp-Z transforms, filtering, robotics, real time navigational system and also in communication systems. In this paper, we discussed about the CORDIC algorithm and CORDIC algorithm based finite impulse response low pass & high pass filter. We have generated the M-code for the CORDIC Algorithm and CORDIC Algorithm based FIR filter with the help of MATLAB 2010a.We also discussed about the frequency response characteristics of FIR filter.
Intro of Airport Engg..pptx-Definition of airport engineering and airport pla...Priyanka Dange
油
Definition of airport engineering and airport planning, Types of surveys required for airport site, Factors affecting the selection of site for Airport
More Related Content
Similar to Arduino board program for Mobile robotss (20)
The document provides an overview of the Arduino Uno microcontroller board. It describes the main components of the board including 14 digital input/output pins, 6 analog inputs, a 16MHz crystal oscillator, a USB connection, a power jack, and a reset button. It also explains how to power the board using a USB cable connected to a computer or an external power supply. The document then introduces some basic Arduino programming concepts like functions, data types, control structures, and input/output functions.
This document provides an overview of the Arduino Uno microcontroller board. It defines a microcontroller as a single-chip computer containing a CPU, memory, and input/output interfaces. The Arduino is an open-source electronics platform with easy-to-use hardware and software that allows anyone to develop interactive electronic projects. Key specifications of the Arduino Uno board are provided, including its microcontroller chip, memory, analog and digital pins. The process of analog to digital conversion is explained. Basic Arduino programming concepts like data types, statements, operators, and control structures are covered. The bare minimum code structure of setup() and loop() functions is described.
This document provides an overview of Arduino programming and the Arduino platform. It discusses what Arduino is, what types of projects can be built with Arduino, and covers the basics of getting started, digital and analog inputs/outputs, Neopixels, and putting projects together. It also includes an agenda and summaries of the Arduino UNO board and common sensors that can be used.
Arduino is an open-source project that created microcontroller-based kits for building digital devices and interactive objects that can sense and control physical devices.
This document provides an overview of microcontrollers and introduces the Arduino microcontroller development platform. It discusses how microcontrollers can receive sensory input from the environment using sensors like light sensors. It also covers digital and analog input/output, serial communication, pulse width modulation (PWM) to control motors, and includes examples of coding with the Arduino.
The document provides an overview of learning objectives and topics for an introduction to Arduino lecture, including:
- How to use a potentiometer as a sensor and identify input/output ports of an Arduino.
- What an Arduino is, its boards and IDE software.
- Why Arduinos are popular for electronics projects.
- How Arduinos will be used in labs, including acquiring sensor data and sending signals to systems using code.
This document provides an overview and introduction to using Arduino boards for physical computing projects. It discusses installing the Arduino software, understanding analog and digital signals, basic programming concepts like inputs, outputs, and conditional statements. It also covers a sample "Blink" project to get started using Arduino boards and programming the onboard LED and buttons.
The document provides an overview of Arduino, including what it is, common Arduino boards, digital and analog input/output, and example projects. Arduino is an open-source electronics prototyping platform that can be used to create interactive objects. It uses a simple hardware and software environment to program and develop prototypes. The Arduino Uno is one of the most commonly used boards, which contains an Atmega328 microcontroller, digital and analog pins, and can be programmed via USB. The document describes how to connect various components like LEDs, buttons, sensors and motors to an Arduino board.
The document provides an overview of Arduino, including what it is, common Arduino boards, digital and analog input/output, and example projects. Arduino is an open-source electronics prototyping platform that allows users to create interactive objects and environments. It uses flexible, easy-to-use hardware and software. Common tasks demonstrated include blinking LEDs, reading buttons, and controlling motors. The document serves as an introduction to getting started with the Arduino platform.
The document provides instructions for connecting an Arduino board to a Windows computer and uploading a simple "Blink" sketch. It outlines downloading the Arduino IDE software, connecting the board via USB, installing the correct USB drivers, opening the Blink example sketch, selecting the board and serial port in the IDE, and uploading the program to make an on-board LED blink.
This document outlines the syllabus for a course on Internet of Things (IoT) technology taught by Dr. Syed Mustafa at HKBK College of Engineering, Bengaluru. It covers key modules including IoT physical devices and endpoints such as Arduino and Raspberry Pi. The Arduino section describes the Arduino microcontroller board and its components. It also covers Arduino programming basics like setup and loop functions, input/output functions, variables, conditional statements, and serial communication. The Raspberry Pi section provides an overview of the single-board computer and its hardware layout.
Intro to Arduino Class taught at CRASHspace by Quin (Qtechknow). Originally taught on August 11, 2012 at Crashspace, in LA. This revision patches the diagrams and fixes the code! Thanks to SparkFun who shared all of their original slides with me!
The introduction to Arduino labs at Malm旦 University. These slides have been handed down since the beginning of Arduino. They have more authors then i can remember and should by no means be considered mine.
The introduction to Arduino labs at Malm旦 University. These slides have been handed down since the beginning of Arduino. They have more authors then i can remember and should by no means be considered mine.
This document provides an introduction to using Arduino boards. It discusses getting started with the Arduino IDE, programming basics like digital I/O and timing functions. Examples are provided to blink an LED, read a digital sensor, read an analog sensor with a potentiometer, and fade an LED using pulse width modulation. Terminology around bits, bytes and serial communication is also explained. The document aims to teach Arduino fundamentals and provide practice examples for learning.
The document discusses Arduino, an open-source electronics prototyping platform. It describes Arduino Uno, including its processor, memory, input/output pins, and operating voltage. It provides steps for getting started with Arduino, including downloading the IDE, connecting the board, selecting options in the IDE, and uploading a basic blink program. The document also covers some key Arduino concepts like variables, conditional statements, loops, and functions.
SIMULATION OF FIR FILTER BASED ON CORDIC ALGORITHMVLSICS Design
油
Coordinate Rotation Digital Computer (CORDIC) discovered by Jack E Volder. It is a shift-add operation and iterative algorithm. CORDIC algorithm has wide area for several applications like digital signal processing, biomedical processing, image processing, radar signal processing, 8087 math coprocessor, the HP-35 calculator, Discrete Fourier, Discrete Hartley and Chirp-Z transforms, filtering, robotics, real time navigational system and also in communication systems. In this paper, we discussed about the CORDIC algorithm and CORDIC algorithm based finite impulse response low pass & high pass filter. We have generated the M-code for the CORDIC Algorithm and CORDIC Algorithm based FIR filter with the help of MATLAB 2010a.We also discussed about the frequency response characteristics of FIR filter.
Intro of Airport Engg..pptx-Definition of airport engineering and airport pla...Priyanka Dange
油
Definition of airport engineering and airport planning, Types of surveys required for airport site, Factors affecting the selection of site for Airport
PROJECT REPORT ON PASTA MACHINE - KP AUTOMATIONS - PASTA MAKING MACHINE PROJE...yadavchandan322
油
All the materials and content contained in Project report is for educational purpose and reflect the views of the industry which are drawn from various research on pasta machine. PM FME- Detailed Project Report of Multigrain Pasta Making Unit. 3. 1. PROJECT ... A pasta extruder is a machine that makes pasta dough through dies to.The process is quite simple and requires not much skilled labour. The machine itself is high technology and provides the manufacturers to produce noodles with. In this article, you will be able to get all the detail about a pasta-making business unit in India and the financial status of this business as well.ENGINEERS INDIA RESEARCH INSTITUTE - Service Provider of Project Report on PASTA PRODUCTION PLANT (SHORT PASTA) [CODE NO. 1632] based in Delhi, India.
Macaroni Machines are used to produce pasta from the raw material. With ... The views expressed in this Project Report are advisory in nature. SAMADHAN.
Distillation is a widely used method for separating mixtures油based on differences in the conditions required to change the油phase of components of the mixture.
To separate a mixture of liquids, the liquid can be heated to force components, which have different boiling points, into the gas phase. The gas is then condensed back into liquid form and collected.
Distillation can be considered as a physical separation process not a chemical reaction.
Distillation involves selective evaporation and subsequent condensation of a component in a liquid mixture.
It is a separation technique that can be used to either increase the concentration of a particular component in the mixture or to obtain (almost) pure components from the mixture.
Under a given pressure, the temperature at which a pure liquid distills (or boils) is known as Boiling Point .
Technically, the boiling point of a liquid is the temperature at which the vapor pressure of a liquid equals to the surrounding atmospheric pressure, allowing bubbles of vapor to form and rise through the liquid.油
Distillation allows one of the liquid mixture's components into a gaseous state, taking advantage of the difference in their boiling points.
NFPA 70B & 70E Changes and Additions Webinar Presented By FlukeTranscat
油
Join us for this webinar about NFPA 70B & 70E changes and additions. NFPA 70B and NFPA 70E are both essential standards from the National Fire Protection Association (NFPA) that focus on electrical safety in the workplace. Both standards are critical for protecting workers, reducing the risk of electrical accidents, and ensuring compliance with safety regulations in industrial and commercial environments.
Fluke Sales Applications Manager Curt Geeting is presenting on this engaging topic:
Curt has worked for Fluke for 24 years. He currently is the Senior Sales Engineer in the NYC & Philadelphia Metro Markets. In total, Curt has worked 40 years in the industry consisting of 14 years in Test Equipment Distribution, 4+ years in Mfg. Representation, NAED Accreditation, Level 1 Thermographer, Level 1 Vibration Specialist, and Power Quality SME.
UHV UNIT-I INTRODUCTION TO VALUE EDUCATION .pptxariomthermal2031
油
Arduino board program for Mobile robotss
1. COIMBATORE 641 004
SESSION 1
PSG COLLEGE OF TECHNOLOGY
1
Selvaraj. K
Project Engineer
PSG-Robotics
2. OVERVIEW
Microcontroller Defined
Arduino Defined
Arduino Advantages
Arduino Applications
Types of Arduino Boards
Analog, Digital, Inputs and Outputs
3. MICROCONTROLLER
Microcontroller Like as
Brain
It make decision in the
Robots
It collect the information
from the Sensors and control
the actuator by the command
4. MICROCONTROLLER
Microcontroller It is a Decision maker
with help of ROM,RAM and
Arithmetic Logic Unit.
Input port- Eye(Sensor)
Output Port- Mouth(Actuators or
Speaker)
All input and output ports are
controlled by the programming
5. MICROCONTROLLER
Programmers work in the virtual world.
Machinery works in the physical world.
How does one connect the virtual world to the physical world?
A microcontroller is basically a small-scale computer with
generalized (and programmable) inputs and outputs.
The inputs and outputs can be manipulated by and can
manipulate the physical world
6. INTRODUCTION ABOUT ARDUINO
Based on a simple micro-controller board, and
A development environment (IDE) for writing software for the board
Open source electronics prototyping platform based on flexible ,Easy to use hardware
and software
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 be communicate with
software running on your computer (e.g. Flash, Processing, MaxMSP.) The boards can
be assembled by hand or purchased preassembled; the open-source IDE can be
downloaded for free.
The Arduino programming language is an implementation of Wiring, a similar physical
computing platform, which is based on the Processing multimedia programming
environment.
7. MAIN ADVANTAGES OF ARDUINO
Arduino microcontrollers have become the de facto standard.
Make Magazine features many projects using Arduino
microcontrollers.
Strives for the balance between ease of use and usefulness.
Programming languages seen as major obstacle.
Arduino C is a greatly simplified version of C++.
Unit price around Rs.1400
11. DUE
Much faster processor, many more pins
Operates on 3.3 volts
Similar to the Mega
12. MICRO
When size matters: Micro, Nano, Mini
Includes all functionality of the Leonardo
Easily usable on a breadboard
13. LILYPAD
LilyPad is popular for clothing-based projects.
It is a Low weight and flexible
14. ESPLORA
Game controller
Includes joystick, four buttons, linear potentiometer (slider), microphone,
light sensor, temperature sensor, three-axis accelerometer.
Not the standard set of IO pins.
15. MEGA
Compared to the Uno, the Mega:
Many more communication pins
More memory
16. ARDUINO MEGA
Physically larger than all the other boards
Offers significantly more digital and analog pins.
Uses a different processor allowing greater program size
Microcontroller: ATmega1280
Operating Voltage 5V
Input Voltage: 7-12V
Digital I/O Pins 54 (of which 14 provide PWM output)
17. ARDUINO MEGA
Analog Input Pins 16
Flash Memory 128 KB of which 4 KB used by boot loader
SRAM 8 KB
EEPROM 4 KB
Clock Speed 16 MHZ
18. ARDUINO UNO
The pins are in three groups:
Invented in 2010
14 digital pins
6 analog pins
power
19. ARDUINO UNO
Microcontroller ATmega 328
Operating Voltage 5V
Input Voltage (recommended) 7-12V
Input Voltage (limits) 6-20V
Digital I/O Pins 14 (of which 6 provide PWM output)
Analog Input Pins 6
DC Current per I/O Pin 40 mA
DC Current for 3.3V Pin 50 mA
Flash Memory 32 KB (of which 0.5 KB used by boot loader)
SRAM 2 KB (ATmega328)
EEPROM 1 KB (ATmega328)
Clock Speed 16 MHz
20. Totally Arduino Uno have 14 Digital Input and Output
pins. They are numbered 0 to 13.
Analog Input Pins are A0 to A5
22. UNDERSTANDING INPUT VS OUTPUT
INPUT PIN
Inputs is a signal / information
going into the board.
OUTPUT PIN
Output is any signal exiting
the board.
23. ANALOG VS DIGITAL
ANALOG
Microcontrollers are digital devices ON or OFF
DIGITAL
An Analog signal is anything that can be a full range of values.
What are some examples? Think of like a ramp or a hill.
24. INPUT and OUTPUT
1. analogRead-Analog INPUT
2. analogWrite-Analog OUTPUT
3. digitalRead- digital INPUT
4. digitalWrite- digital OUTPUT
25. BASIC KNOWLEDGE REQUIRED
Ohms LAW
Current
Voltage
Resister
Capacitor
Inductor
Voltage LAW
Current Law
Rheostat function
Transformer
Rectifier
Regulator
Inverter
Amplifier
Diode
Transistor
AC and DC Voltages
Types of Motors
Basic sensors
27. ANALOG VS DIGITAL
To create an analog signal, the microcontroller uses a technique
called PWM.
Pins 3, 5, 6, 9, 10, 11 are capable of producing an Analog
Output
Pulse Width Modulation (PWM)
29. OVERVIEW
Objectives
Startup Arduino IDE
Arduino Sketch Details
Commands ,Operators, Variables
Basic Repetitions
Settings and Configurations
30. OBJECTIVES
Provide a thorough introduction to the Arduino programming
environment.
Develop a use of simple functions to interact with the LEDs, light
sensor, push button, and buzzer on the Protosnap Pro Mini.
35. COMMENTS
Comments can be anywhere
Comments created with // or /* and */
Comments do not affect code
You may not need comments, but think about the community.
36. OPERATORS
The equals sign
= is used to assign a value
== is used to compare values
And & Or
&& is and
|| is or
41. SETUP
void setup ( ) { }
The setup function comes before the loop function and is necessary
for all Arduino sketches
42. SETUP
void setup ( ) { }
The setup header will never change, everything else that
occurs in setup happens inside the curly brackets
43. SETUP
void setup ( ) {
pinMode (13, OUTPUT); }
Outputs are declare in setup, this is done by using the pinMode
function
This particular example declares digital pin # 13 as an output,
remember to use CAPS
44. SETUP
void setup ( ) { Serial.begin;}
Serial communication also begins in setup
This particular example declares Serial communication at a baud
rate of 9600. More on Serial later...
45. Setup, Internal Pullup Resistors
void setup ( ) {
digitalWrite (12, HIGH); }
You can also create internal pullup resistors in setup, to do so digitalWrite
the pin HIGH
This takes the place of the pullup resistors currently on your circuit 7
buttons
46. Setup, Interrupts
void setup ( )
{
attachInterrupt (interrupt, function, mode) }
You can designate an interrupt function to Arduino pins # 2 and 3
volatile unsigned int L=1;
volatile double Le,Re;
void setup()
{
attachInterrupt(0, countpulsesL, FALLING);
Serial.begin(9600);}
void loop() {
Serial.println(L);
delay(1000);}
void countpulsesL() {L++;}
47. Setup, Interrupts
void setup ( )
{
attachInterrupt (interrupt, function, mode)
}
Interrupt: the number of the interrupt, 0 or 1, corresponding
to Arduino pins # 2 and 3 respectively
Function: the function to call when the interrupt occurs
Mode: defines when the interrupt should be triggered
48. Setup, Interrupts
void setup ( )
{
attachInterrupt (interrupt, function, mode)
}
LOW whenever pin state is low
CHANGE whenever pin changes value
RISING whenever pin goes from low to high
FALLING whenever pin goes from low to high
Dont forget to CAPITALIZE
49. Example program
volatile unsigned int L=1;
volatile double Le,Re;
void setup()
{
attachInterrupt(0, countpulsesL, FALLING);
Serial.begin(9600);}
void loop() {
Serial.println(L);
delay(1000);}
void countpulsesL()
{
L++;}
66. BASIC REPETITION
while ( count<10 )
{
//while action code goes here
//should include a way to change count
//variable so the computer is not stuck
//inside the while loop forever
}
67. BASIC REPETITION
while ( count<10 )
{
//looks basically like a for loop
//except the variable is declared before
//and incremented inside the while
//loop
}
77. CHALLENGES
Introduction to use Electronic components
LED Control by Arduino
Multiple LEDs Control by looping
Operators conditions test
Analog sensor test
Analog Sensor Value based LED control
81. ARDUINO PROGRAMMING INSTRUCTIONS
pinMode(pin, mode)
Designates the specified pin for input or output
digitalWrite(pin, value)
Sends a voltage level to the designated pin
digitalRead(pin)
Reads the current voltage level from the
designated pin
analog versions of above
analogRead's range is 0 to 1023
serial commands
print, println, write
82. ARDUINO USING SOLDERLESSBREADBOARD
Solderless Board is useful to build proto types.
Time consuming process of soldering parts together to make
connections
Most important thing in using a solder less breadboard in
understanding its connections
wiring underneath the white cover to be able to connect
parts in a way that complete and flawless lines are provided for
electricity flow
82
83. Instruction to Components handling
1. Doing circuit connection Dont power up Controller
board
2. Dont use metal surface and maintain at free surface
3. Circuit check before power up
4. Dont make short circuit
5. After completion of Experiments- all components put in
to box and cross check the list
84. LED PROGRAMMING FOR BLINKING
FUNCTIONS
Turn LED
ON
Wait
Turn LED
OFF
Wait Repeat
86. DIGITAL OUTPUT-LED
86
Digital pin 10 connected
with Resister.
Long leg connected with
resister end.
short Leg connected with
Ground.
Ground Pin
Digital Pin
87. LED FUNCTION INSTRUCTIONS
Connect the positive (+) lead of a power source to
the long leg of an LED.
Connect other leg of the LED to a resistor.
High resistance means a darker light.
Low resistance means brighter light.
No resistance means to the negative lead of the
power source. a burned out LED.
Connect other leg of the resistor
93. CHALLENGES IN LED CONTROL
Challenge 1A:
Blink LED Every one second
Challenge 1B:
Multiple LEDs Blink once at a time
Challenge 1C:
Multiple LEDs- Knight Riders Style
Challenge 1D:
Color Brightness control using PWM function
Challenge 1E:
Color Brightness control using potentiometer
Challenge 1F:
Arduino-Analog Output LED Dimming Using for Loop
Structure
105. LED CONTROLLED BY PUSH BUTTON
Switch output connected with Arduino pin2
Led pin connected with Arduino pin 6
106. PUSH BUTTON FUNCTION
SWITCH IN OPEN SWITCH IN CLOSED
If switch ON- circuit is closed, current will flow in the circuit
path. So input voltage is 5V.
Else switch OFF- circuit is open, no current flow in this path, so
input current 0V.
108. 2. CHALLENGES
CHALLENGE 2A:
LED ON When press any One push button at a time
CHALLENGE 2B:
LED ON when press all push button at a time
CHALLENGE 2C:
LED ON when press at least 2 push button at a time
in 4 push buttons using application
CHALLENGE 2D:
LED ON when press at least 3 push button at a time
in 4 push buttons using application
110. 3. SERIAL MONITOR
CONFIGURE BAUD RATE
Serial. begin (baud rate)
Some Examples Baud rate
4800,9600,14400,19200,28800,
38400,5760 and 115200 etc
AnalogRead Value is 0 to 1023
WATCHING OUTPUT AT SERIAL
MONITOR
Serial.println();
117. PROGRAM FOR LED BRIGHTNESS CONTROL
LED BRIGHT:
int pot = A0; // pin that the sensor is attached to pot
int LED=9;
void setup()
{
pinMode(LED, OUTPUT);
Serial.begin(9600);
}
void loop()
{
int analogValue = analogRead(pot)/4;
analogWrite(LED, analogValue);
Serial.println(analogValue);
delay(100);
}
118. LED ON/OFF CONTROLLED WITH RESPECT TO
COMPARISON OF THRESHOLD
Led on/off controlled with respect to comparison
of threshold and analog value from potentiometer
120. 5.Potentiometr Voltage -Voltage Display
Analog Read value is 0-1023
Divisions (0-5V)
1 Division= 5/ 1023 V= 0.00488 V
Formula:
int POT= analogRead(A0);
int Voltage = POT X 0.0049
121. HOME MADE AUTOMATION
If push button is pressed at once- Automatically
electrical fans and lights will ON
If again press the same push button
Automatically electrical fans and lights will OFF
Experiments: LED will ON/ OFF based on this condition
125. int inPin = 2; // the number of the input pin
int outPin = 6; // the number of the output pin
int state = HIGH; // the current state of the output pin
int reading; // the current reading from the input pin
int previous = LOW; // the previous reading from the input pin
long time = 0; // the last time the output pin was toggled
long debounce = 200; // the debounce time, increase if the output flickers
void setup()
{
pinMode(inPin, INPUT);
pinMode(outPin, OUTPUT);
}
void loop()
{
reading = digitalRead(inPin);
if (reading == HIGH && previous == LOW && millis() - time > debounce)
{
if (state == HIGH)
state = LOW;
else
state = HIGH;
time = millis();
}
digitalWrite(outPin, state);
previous = reading;
}
129. INTRODUCTION ABOUT SENSORS
Sensor
Types of sensors
IR sensor
Sound sensor
Temperature
sensor
How to use it?
Where to use it?
130. WHAT IS A SENSOR.?
A sensor is a device that measures a physical quantity and
converts it into a signal which can be read by an observer or
by an instrument
Sensors are used in everyday objects such as touch-sensitive
elevator buttons (tactile sensor) and lamps which dim or
brighten by touching the base
Applications include cars, machines, aerospace, medicine,
manufacturing and robotics
132. WORKING
IR sensor works on the principle of emitting IR
rays and receiving the reflected ray by a receiver
(Photo Diode)
IR source (LED) is used in forward bias
IR Receiver (Photodiode) is used in bias
134. VOLTAGE COMPARATOR
A Comparator is a device which compares two voltages or
currents and switches its output to indicate which is larger.
Comparator is an Op-amp.
PIN DIAGRAM LM 358
137. TIMER 555 IC
The 555 Timer IC is an integrated circuit (chip)
implementing a variety of timer and multivibrator
applications.
PIN DIAGRAM
138. Solar Cell
Digital Infrared Ranging
Compass
Touch Switch
Pressure Switch
Limit Switch
Magnetic Reed Switch
Magnetic Sensor
Miniature Polaroid Sensor
Polaroid Sensor Board
Piezo Ultrasonic Transducers
Pyroelectric Detector
Thyristor
Gas Sensor
Gieger-Muller
Radiation Sensor
Piezo Bend Sensor
Resistive Bend Sensors
Mechanical Tilt Sensors
Pendulum Resistive
Tilt Sensors
CDS Cell
Resistive Light Sensor
Hall Effect
Magnetic Field
Sensors
Compass
IRDA Transceiver
IR Amplifier Sensor
IR Modulator
Receiver
Lite-On IR
Remote Receiver
Radio Shack
Remote Receiver
IR Sensor w/lens
Gyro
Accelerometer
IR Reflection
Sensor
IR Pin
Diode
UV Detector
Metal Detector
139. A motor is any of a class of rotary electrical motors that
converts electrical energy into mechanical energy. The most
common types rely on the forces produced by magnetic fields.
INTRODUCTION ABOUT MOTOR
140. 16/11/2021 PSG College of Technology
TYPES OF MOTORS
AC motors
DC motors
DC geared motors
Stepper motors
Servo motors
141. 16/11/2021 PSG College of Technology
AC MOTOR
These are the motors which convert
alternating signal into rotational motion.
Examples are the motor in water pumps,
table fan, ceiling fan.
142. 16/11/2021 PSG College of Technology
DC MOTOR
These are the motors which convert DC
signals into rotational motion
In robotics applications they are preferred over
AC motors as the motor and the complete
circuit require same kind of supply i.e DC
supply
143. 16/11/2021 PSG College of Technology
DC GEARED MOTORS
These are the DC geared motors having external gear
arrangement attached with motor.
These are the motors that are most commonly used in
robotics as they are having considerable torque.
145. 16/11/2021 PSG College of Technology
STEPPER MOTOR
A type of motor which
takes DC pulse input and
gives rotating motion in
steps.
They are of two types :
Unipolar : which moves
in one direction only.
Bipolar : which moves in
both directions
148. 16/11/2021 PSG College of Technology
Servo motors are the most powerful motors for
robotic applications.
They comes in both variants , AC and DC.
They can change the direction with same
supply.
149. 16/11/2021 PSG College of Technology
A servomechanism, or servo is an automatic device that
uses error-sensing feedback to correct the performance of
a mechanism
The term correctly applies only to systems where the
feedback or error-correction signals help control
mechanical position or other parameters
150. For both way motion ( clockwise and anticlockwise ) of one DC motor, an
H-Bridge can be employed.
For both way motion of two DC motors
dual H-Bridge IC L293D can be employed.
16/11/2021 PSG College of Technology
S1-S4 ON, S2-S3 OFF (for one direction).
S2-s3 on and s1-s4 off (for other
direction).
ONLY POSSIBLE SWITCHES SETTING FOR ROTATION
158. DC MOTOR SPEED CONTROL BY USING
POTENTIOMETER
TASK EXPLANATION:
1. Speed Control by Potentiometer
2. Direction change when potentiometer value move less than
500
164. ULTRASONIC SENSOR
Measurement Principle of Ultrasonic Sensor
Ultrasonic sensors transmit ultrasonic waves from its
sensor head and again receives the ultrasonic waves
reflected from an object. By measuring the length of time
from the transmission to reception of the sonic wave, it
detects the position of the object.
176. Master Sender
#include <Wire.h>
void setup() {
Wire.begin(); // join i2c bus (address optional for master)
}
byte x = 0;
void loop() {
Wire.beginTransmission(8); // transmit to device #8
Wire.write("x is "); // sends five bytes
Wire.write(x); // sends one byte
Wire.endTransmission(); // stop transmitting
x++;
delay(500);
}
177. Slave Receiver
#include <Wire.h>
void setup() {
Wire.begin(8); // join i2c bus with address #8
Wire.onReceive(receiveEvent); // register event
Serial.begin(9600); // start serial for output
}
void loop() {
delay(100);
}
void receiveEvent(int howMany) {
while (1 < Wire.available()) { // loop through all but the last
char c = Wire.read(); // receive byte as a character
Serial.print(c); }
int x = Wire.read(); // receive byte as an integer
Serial.println(x); // print the integer
}