Formula Student Electronics & Software
The code for the embedded software
Loading...
Searching...
No Matches
test_assi_car.cpp
Go to the documentation of this file.
1#include "metro.h"
3#include "unity.h"
5
6
7
8void setUp(void) {
10}
11
12
20 Metro test{5000};
23 while (!test.check()) {
25 }
26 TEST_PASS();
27}
28
36 Metro test{5000};
39 while (!test.check()) {
41 }
42 TEST_PASS();
43}
44
52 Metro test{5000};
55 while (!test.check()) {
56 }
57 TEST_PASS();
58}
59
67 Metro test{5000};
69 ds.enterReadyState();
70 while (!test.check()) {
71 }
72 TEST_PASS();
73}
74
75int main() {
76 UNITY_BEGIN();
81 return UNITY_END();
82}
Class responsible for controlling digital outputs in the Master Teensy.
static void enterReadyState()
ASSI yellow LED on, ebs valves activated, sdc closed.
static void enterFinishState()
ASSI blue LED on, ebs valves activated, sdc open.
void enterDrivingState()
ASSI LEDs yellow flashing, ebs valves deactivated, sdc closed.
void enterEmergencyState()
ASSI LEDs blue flashing, sdc open and buzzer ringing.
void blinkLED(int pin)
Blinks the LED at the given pin.
Our own implementation of Metro class.
Definition metro.h:13
#define ASSI_BLUE_PIN
#define ASSI_YELLOW_PIN
void test_enterDrivingState_and_turn_off_LEDS(void)
Test the enterDrivingState function PROTOCOL:
void test_enterReadyState_and_turn_off_LEDS(void)
Test the enterReadyState function PROTOCOL:
void test_enterFinishState_and_turn_off_LEDS(void)
Test the enterFinishState function PROTOCOL:
void setUp(void)
void test_enterEmergencyState_and_turn_off_LEDS(void)
Test the enterEmergency state function PROTOCOL:
int main()