You are on page 1of 12

READING PORTS

WITH DELAYS
TOPIC 7

AUTOMATION =
ROBOT
AUTOMATION is based on a process control that
includes
the following parts:

ACTUATOR
SENSOR
CONTROLLER / OR BRAIN
It does the action in the physical world
and it canbe an ENGINE

that measures the events


that occur in the physical
world and provides
feedback

is in charge of calculating all the information


and making decisions in order to tell the
actuator what to do.

Control structures =
FORKS
IF/ELSE

SWITCH

FOR

EXAMPLE

WHILE
DO

Not only are sensors


important for providing
feedback to automate
the process, but also
structures since they
work together with
sensors
DECADE COUNTER
objective:
EMENTS
REQUIR
R E (ID E )
S O FT W A
ARDU IN O D
N O B O A R
DU IN O U
AR C A BL E
SA L U S B
UNI VE R N T
E QU IP M E
M P U T ER
CO D I SP L AY
E G M E N T
A7 S
O B O A R D
PR OT
INSTRUCTIONS
- CREATE A PROGRAM TO CONTROL A 7 SEGMENT DISPLAY. (DISPLAY NUMBERS FROM 0 TO 9)
- DISPLAY 2 SECONDS EACH NUMBER.
CODE-ING
int a = 6;
int b = 7;
int c = 8;
//and so on

void setup() {
pinMode(a, OUTPUT);
//and you continue...

void loop() {
// ZERO
digitalWrite(a, HIGH);
digitalWrite(b, HIGH);
digitalWrite(c, HIGH);
digitalWrite(d, HIGH);
digitalWrite(e, HIGH);
digitalWrite(f, HIGH);
digitalWrite(g, LOW);
DIAGRAM

You might also like