Flowchart
Proyecto_Embebidos
Flowchart content
Inicio
estado = 0
random = 0
flancos = 0
eval = 0
t1 = 0
n = 0
mat_uart[5]
mat_random[5]
cuenta = 0
cuenta1 = 0
cuenta2 = 1000
Config interrupciones
Config. Timer 1 y Timer 2 a 1ms
IRQ Global
estado = 0
estado = 1
estado = 2
estado = 3
estado = 4
LEDV = 0
LEDR = 0
BE = 0
BF = 0
DTN = '0'
D7T = '0'
LEDV = 0
LEDR = 0
BE = 0
BF = 0
DTN = Num. Aleatorio
D7T = '0'
LEDV = 0
LEDR = 0
BE = 0
BF = 0
DTN = Resp.
D7T = Seg.
LEDV = 0
LEDR = 1
BE = 0
BF = 0
DTN = V. Final
D7T = T. Final
LEDV = 0
LEDR = 1
BE = 0
BF = 0
DTN = V. Final
D7T = T. Final
c = evaluar()
ISR_PULSADOR
estado = 2
t1 >= 3seg
estado = 0
flancos++
¿flancos es par?
Activar Timer 1
estado = 0
t1<=2seg
estado = 1
RETURN
TIMER 1
Desactivar Timer 1
cuenta++
RETURN
TIMER 2
cuenta1++
cuenta2 >= 1000
cuenta2++
estado = 1
estado = 2
random = random_num()
cuenta2 = 0
cuenta1 >= 5000
Habilitar UART
estado = 2
cuenta1 = 0
cuenta2 = 0
RETURN
cuenta1 >= 9000
estado = 4
Deshabilitar UART
UART
RETURN
comp <- UART
mat_uart[n] = comp
n++
evaluar()
RETURN c
c = 0
i = 0
mat_uart[i] = mat_random[i]
i<5
c++
i++
si
no
si
no
no
si
no
no
t1<=1seg
eval = 1
no
no
no
si
si
si
si
si
si
si
no
no
si
no
no
si
no
no
no
no
no
no
si
si
si
si
si
Habilitar Timer 2
random_num()
RETURN rn
rn = 0
rn <- Cuentas Timer 3
rn = rn & 0x000F
rn >= 10
rn = rn -10
si
no
Activar Timer 3
si
eval = 1
si
c=5
no
estado = 3
estado = 4
si
no
Information
- Description
- Flowchart on Proyecto_Embebidos, created by Christian Monterrey on 03/07/2017.
- Created by
- Christian Monterrey
- Views
- 0
- Rating