![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
This is car control simulation by using Mbed controller and real time operating system.
Dependencies: MCP23017 Servo WattBob_TextLCD mbed-rtos mbed
Fork of Ass3 by
CAR.h@12:8eb2c1cccee6, 2014-05-06 (annotated)
- Committer:
- muaiyd
- Date:
- Tue May 06 09:49:08 2014 +0000
- Revision:
- 12:8eb2c1cccee6
- Parent:
- 9:d86a6b8cdfa4
- Child:
- 13:e5b22bfbe67b
Make all input in the Simulation Task
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
muaiyd | 0:68ce46607848 | 1 | #ifndef CAR_H |
muaiyd | 0:68ce46607848 | 2 | #define CAR_H |
muaiyd | 0:68ce46607848 | 3 | #include "rtos.h" |
muaiyd | 0:68ce46607848 | 4 | #include "CommonVariable.h" |
muaiyd | 0:68ce46607848 | 5 | |
muaiyd | 9:d86a6b8cdfa4 | 6 | typedef struct { |
muaiyd | 9:d86a6b8cdfa4 | 7 | uint8_t Mail_Average_Speed; |
muaiyd | 9:d86a6b8cdfa4 | 8 | float Mail_Accelerometer_Value; |
muaiyd | 9:d86a6b8cdfa4 | 9 | float Mail_Brake_Value; |
muaiyd | 9:d86a6b8cdfa4 | 10 | int Counter; |
muaiyd | 9:d86a6b8cdfa4 | 11 | } CAR_MAIL; |
muaiyd | 12:8eb2c1cccee6 | 12 | |
muaiyd | 0:68ce46607848 | 13 | class CAR { |
muaiyd | 0:68ce46607848 | 14 | public: |
muaiyd | 1:b409ad65466a | 15 | CAR(); |
muaiyd | 1:b409ad65466a | 16 | static void SAVE_ODO(float value); |
muaiyd | 1:b409ad65466a | 17 | static float GET_ODO(); |
muaiyd | 12:8eb2c1cccee6 | 18 | |
muaiyd | 12:8eb2c1cccee6 | 19 | static void Car_Simulation(void const *args); |
muaiyd | 12:8eb2c1cccee6 | 20 | static uint8_t Get_Speed(); |
muaiyd | 12:8eb2c1cccee6 | 21 | |
muaiyd | 1:b409ad65466a | 22 | static void Average_Speed_Measure(void const *args); |
muaiyd | 1:b409ad65466a | 23 | static void Average_Speed_Show(void const *args); |
muaiyd | 1:b409ad65466a | 24 | static void OverSpeed(void const *args); |
muaiyd | 7:a92da438d06c | 25 | static void Odo_Show_Indicator_Switch_Read(void const *args); |
muaiyd | 1:b409ad65466a | 26 | static void SEND_CAR_VALUES (void const *args); |
muaiyd | 1:b409ad65466a | 27 | static void DUMP_CAR_VALUES_En (void const *args); |
muaiyd | 1:b409ad65466a | 28 | static void DUMP_CAR_VALUES(); |
muaiyd | 7:a92da438d06c | 29 | static void Side_Light_Flash(void const *args); |
muaiyd | 8:6e55db96c11c | 30 | static void Side_Light(void const *args); |
muaiyd | 0:68ce46607848 | 31 | private: |
muaiyd | 0:68ce46607848 | 32 | |
muaiyd | 0:68ce46607848 | 33 | }; |
muaiyd | 0:68ce46607848 | 34 | |
muaiyd | 0:68ce46607848 | 35 | #endif |