|
|
|
@ -1,5 +1,5 @@
|
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
<model version="5.2.1" links="1">
|
|
|
|
<model version="5.2.2" links="1">
|
|
|
|
<documentation>About this model:
|
|
|
|
<documentation>About this model:
|
|
|
|
-----------------
|
|
|
|
-----------------
|
|
|
|
The TimeBomb example from the video course "Modern Embedded Systems Programming":
|
|
|
|
The TimeBomb example from the video course "Modern Embedded Systems Programming":
|
|
|
|
@ -134,7 +134,8 @@ QTimeEvt_armX(&me->te, BSP_TICKS_PER_SEC/2, 0U);</entry>
|
|
|
|
<state name="boom">
|
|
|
|
<state name="boom">
|
|
|
|
<entry brief="all-LEDs=ON;">BSP_ledRedOn();
|
|
|
|
<entry brief="all-LEDs=ON;">BSP_ledRedOn();
|
|
|
|
BSP_ledGreenOn();
|
|
|
|
BSP_ledGreenOn();
|
|
|
|
BSP_ledBlueOn();</entry>
|
|
|
|
BSP_ledBlueOn();
|
|
|
|
|
|
|
|
MY_PRINTF("*** Boom!!!\n");</entry>
|
|
|
|
<state_glyph node="4,68,26,10">
|
|
|
|
<state_glyph node="4,68,26,10">
|
|
|
|
<entry box="1,2,17,3"/>
|
|
|
|
<entry box="1,2,17,3"/>
|
|
|
|
</state_glyph>
|
|
|
|
</state_glyph>
|
|
|
|
@ -155,6 +156,8 @@ BSP_ledBlueOn();</entry>
|
|
|
|
#include "qpc.h" /* QP/C API */
|
|
|
|
#include "qpc.h" /* QP/C API */
|
|
|
|
#include "bsp.h"
|
|
|
|
#include "bsp.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "my_printf.h" /* software tracing with printf() */
|
|
|
|
|
|
|
|
|
|
|
|
Q_DEFINE_THIS_MODULE("main") /* this module name for Q_ASSERT() */
|
|
|
|
Q_DEFINE_THIS_MODULE("main") /* this module name for Q_ASSERT() */
|
|
|
|
|
|
|
|
|
|
|
|
/* The TimeBomb AO =======================================================*/
|
|
|
|
/* The TimeBomb AO =======================================================*/
|
|
|
|
@ -183,8 +186,7 @@ int main() {
|
|
|
|
|
|
|
|
|
|
|
|
QF_run(); /* run QP/C... */
|
|
|
|
QF_run(); /* run QP/C... */
|
|
|
|
return 0; /* NOTE: the scheduler does NOT return */
|
|
|
|
return 0; /* NOTE: the scheduler does NOT return */
|
|
|
|
}
|
|
|
|
}</text>
|
|
|
|
</text>
|
|
|
|
|
|
|
|
</file>
|
|
|
|
</file>
|
|
|
|
</directory>
|
|
|
|
</directory>
|
|
|
|
</model>
|
|
|
|
</model>
|
|
|
|
|