Engineers Mini Notebook
Engineers Mini Notebook
Engineers Mini Notebook
hardware
Pritish M. Vibhute
Open source
• Why to use open source?
• We’d like to minimize our investment in time required
for this task.
• After all, we usually are not paid based on how well we
understand every hardware detail of a given processor, but
rather on our ability to deliver a working solution in a
timely manner.
• Indeed, this is one of the primary reasons open source has
flourished.
• Open Source Hardware
Introduction to...
Arduino Board
-Mr. Pritish M. Vibhute
Content of course
• Introduction to Arduino Board
– Concept of prototyping & Open source boards
• Different types of Arduino Board
• IDE:- Who to download, install and procedure
• Procedure to write & execute program
• Sample projects!
• Upload program to Arduino Uno
• Demonstration of different programs
Course Structure
• Session 1(TH 2Hrs): Introduction to the concept of • Session 5(PR 2Hrs): Implementation of simple
– Open source hardware projects
– Prototyping board • Calculator
– Arduino and it types • Simple Audio Player
– Shields • Line Follower and different type of Robots
• Session 2 (TH + PR 2Hrs): Introduction to IDE and • Session 6(PR 2Hrs): Introduction to the concept
programming of IOT & its implementation
• Introduction to IDE and programming style / Language • Concept of IOT
• Implementation of simple problem statement • Opportunities in IOT
• Session 3(PR 2Hrs): Interfacing with hardware • Uploading Sensor parameter on internet and
(Simple) monitoring using cloud based services
• Interfacing LED • Session 7(TH 2 Hrs): Alternatives to Arduino
• Interfacing LDR and their capabilities
• Interfacing LM35 Temperature Sensor • Raspberry Pi
• Interfacing Ultrasonic Sensor • Beaglebone Black
• Interfacing PIR Motion Sensor • Intel Galileo
• Interfacing on board peripherals • TI LaunchPad
• Session 4(PR 2Hrs): Interfacing with hardware • Panda Board
(Complex) • Session 8(PR 2 Hrs): Exploring capabilities of
• Interfacing GSM module Raspberry Pi 2 B+
• Interfacing GPS module • Introduction to Raspberry Pi
• Interfacing ZigBee module • Raspberry Pi 2 B+ as a single board computer
• Interfacing Keypad • Introduction to OS supported by Raspberry Pi-
• Interfacing RF module Raspbian, Noobs, Windows 10 IOT
• Interfacing LCD 16 X 2 • Applications of Raspberry Pi
Prerequisites : Microcontroller
•It is a micro-computer(small).
•As any computer it has internal
CPU, RAM, IOs interface etc.
•It is used for control purposes,
and for data analysis.
•One who executes program
•Famous microcontroller
manufacturers are
MicroChip, Atmel, Intel,
Analog devices, and more.
Prerequisites : Microprocessor
Bluetooth
Module
Shields
LCD
Shields
Shields
Temperature &
Humidity Sensor
RFID Module
Wave Shield
Touchscreen
Shield
More Shields…
Trackduino
APRS Shield
Arduino Shields usage procedure
PCB Built Shield Inserted Shield
Arduino Uno
SCL\SDA
(I2C Bus)
& PWM(3, 5, 6, 9, 10, 11)
Arduino Board Overview
Specifications: Arduino Uno
• Microcontroller: ATmega 328(8 BIT)
• RISC @ 16 Mhz, 20 MIPS
• Operating Voltage 5V(regulated Voltage)
• Input Voltage (recommended) 7-12V
• Input Voltage (limits) 6-20V
• Digital I/O Pins 14 (6 -PWM output)
• Analog Input Pins 6 Channels (10 Bit resolution)
• DC Current per I/O Pin 40 mA
• DC Current for 3.3V Pin 50 mA
• Flash Memory 32 KB (0.5 KB used bootloader)
• SRAM 2 KB (ATmega328)
• EEPROM 1 KB (ATmega328)
• Clock Speed 16 MHz
• PWM, I2C, SPI
Specifications: Arduino Mega
• Microcontroller: ATmega1280
• Operating Voltage 5V
• Input Voltage: 7-12V
• Digital I/O Pins 54 (of which 14 provide PWM output)
• Analog Input Pins 16
• Flash Memory 128 KB (4 KB used by bootloader)
• SRAM 8 KB
• EEPROM 4 KB
• Clock Speed 16 MHZ
Getting Started
1. Download & install the Arduino environment (IDE)
http://arduino.cc/en/Main/Software
2. Connect the board to your computer via the USB cable
3. If needed, install the drivers
4. Launch the Arduino IDE
5. Select your board
6. Select your serial port
7. Open the blink example
8. Upload the program
Arduino IDE
Select Serial Port and Board
Input Output:- Digital or Analog
Digital and analog.
• All physical quantities are analog.
• Analog means that the quantity can take any value between its minimum
value and maximum value(Eg:- temperature, sine wave)
• Digital means that the quantity can take specific levels of values with specific
offset between each other(like true of false, square wave).
Digital Input/Output
1
• Digital IO is binary
valued—it’s either on or
0
off, 1 or 0
• Internally, all
microprocessors are
digital, why?
Data Types and operators
• What is a Sketch?
• What is libraries
• Void setup(){}
• Used to indicate the initial values of
system on starting.
• Void loop(){}
• Contains the statements that will run
whenever the system is powered after
setup.
Includes
Globals
void setup()
void loop()
Arduino Digital
I/0
pinMode(pin, mode)
Sets pin to either INPUT or OUTPUT
digitalRead(pin)
Reads HIGH or LOW from a pin
digitalWrite(pin, value)
Writes HIGH or LOW to a pin
Electronic stuff
Output pins can provide 40 mA of current
Writing HIGH to an input pin installs a 20KΩ pullup
eg1:- Blink an LED
eg2: Digital IO
Gas Sensor
Photo Diode:
Sensors
Photo Transistor:
- Base-emitter junction is
controlled by the incident light
density, has an amplification
effect.
Analog Output
• Can a digital devise produce analog output?
• Command:
analogWrite(pin,value)
analogWrite(11, 64)
for a 25% duty cycle
eg3: Analog IO
A light Theremin
eg4: Analog IO
Add an LED
• Add a 330 ohm resistor and an LED to pin 9
• Using the analogWrite() command, set the
intensity of the LED as a function of the value
of prReading
Serial Communication
Serial Communication
• Compiling turns your program into
binary data (ones and zeros)
• Uploading sends the bits through
USB cable to the Arduino
• The two LEDs near the USB
connector blink when data is
transmitted
Serial to USB • RX blinks when the Arduino is
Chip:- receiving data
As ATMEGA don’t
support USB
• TX blinks when the Arduino is
transmitting data
Open the Serial Monitor and Upload
the Program
Some Commands
• Serial.begin()
- e.g., Serial.begin(9600)
• Serial.print() or
Serial.println()
- e.g., Serial.print(value)
• Serial.read()
• Serial.available()
• Serial.write()
• Serial.parseInt()
Two different communication
protocols
Serial (TTL):
Applications
• Light control
• Motor control
• Automation
• Robotics
• Networking
• Custom protocols
• Your imagination is the limit…
eg5: Serial Communication
Modify your program from in-class
exercise 2-part 2 to control the intensity
of the LED attached to pin 9 based on
keyboard input.
SD Card Slot
(supports SD cards up to 32GB)
Applications
Programming tools
Web server
Tor router
Game
Console
HTPC
Supercomputer
PiBot!
Clock
VLSI EGY- I.GEEK – S3Geeks
Thanks for coming