(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
Arduino as an embedded industrial controller
1. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Jose-Luis Poza-Luján
Arduino as
embedded
industrial
controller
An introduction to the
Arduino as control
system
2. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
The teacher
• Ph D. Jose-Luis Poza-Luján
– Professor
• University: Technical University of Valencia-
Spain (www.upv.es)
• Research: University Institute of Control
Systems and Industrial Computing
(www.ai2.upv.es)
• Reaching: School of Informatics
(www.inf.upv.es)
• Management: Dept. of Computer Engineering
(www.disca.upv.es)
– Contact
• Web: http://jopolu.webs.upv.es
• Mail: jopolu@disca.upv.es
• Facebook, Twitter, LinkedIn, Google+ jopolu
2
3. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Aims
• How Arduino can work as platform to
develop simple control systems
– What’s a Control System?
– What’s Arduino?
• What I can do with an Arduino?
– Sensors?
– Actuators?
– Software?
• Where I can find documents?
3
4. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Aims
• Experiences with Arduino?
• What do you think can be done with
Arduino?
4
5. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Open hardware
• Open hardware
– Inspired on the free software? not, open software
– It’s not a new concept, first open hardware: early
70s (XX century)
• Definitions
– Hardware device whose specifications
and schematics can be accessed publically (free or
not free charges)
• Open Hardware Specification Program
– Limited form of free hardware.
– Enough information that allows a
programmer to make a driver.
5
6. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Project based on open hardware
– OpenSPARC (http://www.opensparc.net/)
• Sun Microsystems (Oracle)
• Complete 64 bits processor
– Openmoko
(http://wiki.openmoko.org/wiki/Main_Page)
• Open Mobile Phones (Free Hw and SW)
– Raspberry Pi (http://www.raspberrypi.org/)
• Complete embedded PC
– RepRap (http://reprap.org/wiki/RepRap)
• Free Hw and SW 3D printer
– Arduino (http://www.arduino.cc/es/)
• Free Microcontroller: analog/digital
input/output oriented.
6
7. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino background
• Origin of Name
– Its name comes from "Bar di Re
Arduino" where Massimo Banzi
spent a few hours (is the name of
an ancient European king (year
1002)
• History
– IEEE: The Making of Arduino
– Arduino: The documentary (2010)
(http://vimeo.com/18539129)
7
8. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Fundamentals of Arduino project
• Collaborative work(credits)
– David Cuartielles
– Gianluca Martino
– Tom Igoe
– David Mellis
– Massimo Banzi
• Motivations
– In 2005, a group of students, and
professors of the Institute of
Interactive Design of (Ivrea) in
Italy started to develop a
Hardware platform because
commercial platforms are
expensive and closed systems.
– Made entirely in Italy
– Target: price < 30 €
– Philosophy: DIY (Do It Yourself)8
9. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino: Present and future
• Evolution
– Web
• Source: Arduino
– Software
• Sorce: Gource
9
10. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Where Arduino is placed in Industrial
Systems?
10
Field bus
Redes de
planta
LAN &
WAN
Production
Network
Fourth floor:
Business
Third floor:
Management
(Warehouses)
Second floor: Field
level (PC)
First floor: Control level
(PLC/CNC)
Ground: devices (Sensors and
actuators)
11. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Where Arduino is placed in REAL Industrial
Systems?
• Bus integration
Source: Siemens 201311
12. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Where to place Arduino?
12
Arduino
Intel
Galileo
Raspberry
PI
PLC
Reliability
(and price)
Computing
13. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Where to place Arduino?
13
• Do you know any of the above systems
(PLC, Arduino, Intel Galileo, Raspberry
PI)?
14. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Overview
14
The programming environment
allows you to write, compile
and load the code that controls
the system.
The Arduino runs the code
through a control loop (infinite
loop), without using the
programming environment for
normal operation
From your home to the factory
15. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Hardware
• No hardware…. No software
– So that… It is important to know the
hardware on which the software will run.
15
Arduino ADK R3
10.16 cm
5.3cm
6.8 cm
5.3cm
Arduino Uno
Arduino Mega
1.8
cm
4.3cm
Arduino Diecimila
Arduino Duemilanove
5.0cm
Arduino LilyPad
Arduino Nano
Arduino Leonardo
Arduino Ethernet
http://arduino.cc/en/Main/Boards
17. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Programming environments
• Arduino IDE
– Depending on the Operative System, needs
a driver installation (Guide)
– Based on Processing language
• Part of the project “Design by numbers”, from
the MIT, to bring computer science to “no
programmers”.
• Processing is similar al C, but it is possible to
program Arduino in other languages
• Aimed at users who do not need to know high
level languages
• Oriented to programmers unfamiliar with the
hardware.
• Conditions GNU LGPL
17
18. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Programming environments
• Arduino IDE
• Google Code
18
19. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Programming environments
• It is possible to program Arduino by
means other estándar platforms
– Eclipse
• PlayGround (alternativas)
– VisualMicro
• Microsoft environment
– Atmel Studio
• Classic microprocessors programing
environment
– Minibloc, Compilador online
• More environments on Arduino site
19
20. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino simulators
• SFA
– Simulator for Arduino
– Windows
• VBBExpress
– Virtual Bread Board
– Windows
• Simuino
– Linux (Written on C)
• Arduino Simulator
– IOS
• Ardusim
– Working project
• Fritzing
– Arduino Design environment20
Simulator for Arduino
Virtual Bread Broad
21. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Mobile device software
21
Eight Control
Arduino
Ardumote
Arduino
Commander
Domotic Home
with Arduino
Arduino
Reference
Arduino Uno
Communicator
Arduino meets
Android
Arduino GR
Arduino
Control Free
Arduino
simulator
Hotkeys for
Arduino
And more…
22. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
References
– Arduino Programming Notebook.
• Brian Evans. 2011. (www.lulu.com)
22
arduino "creative commons" filetype:pdf
arduino "cheat sheet" filetype:pdf
23. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
References
– Arduino Cookbook
• Michael Margolis.
• 2012
– Getting Started with Arduino
• Massimo Banzi. 2011
– Make: Arduino Bots and Gadgets
• Tero Karvinen, Kimmo Karvinen
• 2011
– Environmental Monitoring with
Arduino
• Emily Gertz , Patrick Di Justo. 2012
23
24. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
References
• Arduino Playground
http://arduino.cc/playground/Main/HomePage
http://arduino.cc/en/Tutorial/HomePage
http://arduino.cc/playground/Es/Guias/
• Web sites
http://www.arduinobooks.com/
http://www.arduinodev.com/
And more…
http://en.wikipedia.org/wiki/Arduino
http://tronixstuff.wordpress.com/tutorials/
24
25. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
References
• Distributors list
– http://arduino.cc/es/Main/Buy
• Arduino oriented distributors
– Seedstudio
• http://www.seeedstudio.com
– RS
• http://nl.rs-online.com/web/
25
26. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
• Photoduino. http://photoduino.com/
– Photoduino is anOpen camera
Controller based on Arduino.
Used for taking pictures Automatically.
• PolarPlotter. http://roxen.github.io/polar-plotter/
– Plotter based on a single arm robot.
With greater performance area that
traditional plotters.
• ArduPilot. http://ardupilot.com/
– Arduino based drone.
Arduino based projects
26
http://makezine.com/http://www.instructables.com/ http://hacknmod.com/
28. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino based projects
28
• You think it's possible for you to learn to
do things with Arduino?
30. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino uno: communications
• Programming and communications pin
30
31. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Pin functionality
31
Pin (Link ) Functionality
[0,13] Digital Input/Output
0, 1 RX, TX. Serial TTL (ATmega8U2 USB-to-TTL chip)
2, 3 Extern interruptions (high or low level, and signalled rising or falling)
3,5,6,9,10,11 Analogic outputs PWM (pulse-width modulation).
10,11,12,13 Communications SPI (Serial Peripheral Interface)
GND Ground
AREF Analogic reference
[A0,A5] Analogical inputs 10 bits = from 0 to 1023
A4,A5 Communications TWI/I2C (Two Wire Interface)
Vin Extern power(combined with GND)
5V 5 V output (combined with GND)
3V3 3.3V, 50mA output (combined with GND)
RESET Restart the board
ICSP In Chip/Circuit Serial Programmer (to direct access to ATMega)
32. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Power supply
• USB
– 5V
• Extern
– Range
• Work: 7-12V
• Limits: 6-20V
– Connectors
• 2.1mm (+ centro)s
• Pins Vin, GND
• The selection of the power supply is
automatically
32
33. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Connecting components
• Breadboard
• Buses
– Carried on the same cable the sensor /
actuator signal and the power supply
33
34. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Danger
• Some ways to destroy an Arduino
– #1 Short circuit a I/O pin with GND
– #2 Short circuit two I/O pins
– #3 Apply overvoltage on I/O pins
– #4 Interchange polarity between Vin y GND
– #5 Short circuit Vin y GND
– #6 Apply voltage to output voltage pins (5V y 3V3)
– #7 Apply more than 12 V to reset pin de reset
– #8 Over charge the Arduino (connect to Arduino a
great amount of components without additional
power supply)
34
http://ruggedcircuits.com/html/ancp01.html
35. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Caution
• Hardware
– Assemble the circuits with the Arduino offline
– Review connections before connect the Arduino
– No force conectors
– In case of failure: Test every component
individually
– Do not desperate: it is difficult for a run at the
first assembly
• Software
– Save code frequently
– Comment the code
– One change… one test
35
36. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Programing
• Arduino programs are known as
“sketches
• References
– http://arduino.cc/es/Reference/HomePage
– http://arduino.cc/es/Reference/Extended
36
45. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Analogical actuator
• Mapping data
45
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorReading = analogRead(A0);
int thisPitch = map(sensorReading, 0,
1023, 120, 1500);
tone(8, thisPitch, 10);
Serial.print(sensorReading);
Serial.print(":");
Serial.println(thisPitch);
delay(1);
}
46. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Conclusions
• Arduino is born of the need to provide a
platform for the control that is open and
accessible
• Free Hardware philosophy has made
Arduino extends at high speed
• There are a wide variety of models,
consequently there is a wide variety of
applications
• There are also a wide variety of
programming environments and simulation
• In addition, more documentation can be
founded.46
47. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino projects
• Youtube test: search “Arduino”+…
– Led cube
– Quadcopter
– 3d printer
– Robot
– Rocket
– Telescope
– …
– Your interest
47
48. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino projects
• Test the examples that Arduino IDE
offers (asks the teacher the necessary
components)
• Propose a circuit
– A semaphore?
– A “Mini” Piano?
– Ask the teacher…
48
50. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Design your own project
• Arduino oriented sensors and actuators
50
http://www.cooking-hacks.com/
51. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino in real world?
• Arduino as PLC
51
www.controllino.cc
www.winkhel.com
www.industrialshields.com/plc-
arduino-ardbox-20ios-rele
52. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Arduino in real world?
• Looking for a job
– Arduino vs PLC
52
53. Arduino as an
embedded
industrial
controller
Jose-Luis Poza -Luján
Introduction
Overview
Hardware
Software
References
Connections
Programming
Conclusions
Project
Jose-Luis Poza-Luján
Thanks
For your attention and for your
patient