-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLEDS.c
More file actions
46 lines (44 loc) · 1.09 KB
/
LEDS.c
File metadata and controls
46 lines (44 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
* File: LEDS.c
* Author: Usuario
*
* Created on October 2, 2021, 1:10 PM
*/
#include "LEDS.h"
#include "PARAMETERS.h"
#include "mcc_generated_files/pin_manager.h"
void LEDS(void)
{
switch (ucASState)
{
//off
case AS_OFF:
Y_SIGNAL_SetLow();
B_SIGNAL_SetLow();
break;
//ready
case AS_READY:
B_SIGNAL_SetLow();
Y_SIGNAL_SetHigh();
break;
//driving
case AS_DRIVING:
B_SIGNAL_SetLow();
Y_SIGNAL_Toggle();
break;
//Emergency
case AS_EMERGENCY:
Y_SIGNAL_SetLow();
B_SIGNAL_Toggle();
break;
//Finished
case AS_FINISHED:
Y_SIGNAL_SetLow();
B_SIGNAL_SetHigh();
break;
default:
Y_SIGNAL_SetLow();
B_SIGNAL_SetLow();
break;
}
}