mirror of
https://github.com/QuantumLeaps/qpcpp.git
synced 2025-01-28 06:02:56 +08:00
34cdcc7929
major release 7.0.0 release candidate 1
21 lines
484 B
C++
21 lines
484 B
C++
// state handler function for the Blinky HSM ..................................
|
|
Q_STATE_DEF(Blinky, off) {
|
|
QState status;
|
|
switch (e->sig) {
|
|
case Q_ENTRY_SIG: {
|
|
BSP_ledOff();
|
|
status = Q_RET_HANDLED;
|
|
break;
|
|
}
|
|
case TIMEOUT_SIG: {
|
|
status = tran(&on); // <--- transition
|
|
break;
|
|
}
|
|
default: {
|
|
status = super(&top);
|
|
break;
|
|
}
|
|
}
|
|
return status;
|
|
}
|