StateMachine *stateMachine = allocStateMachine("MyStateMachine", "[Pref]"); State *S_1, *S_2; setDbgParam(stateMachine, ALLOC_DBG | DEALLOC_DBG); //This will activate allocation AND deallocation debug S_1 = allocateState(stateMachine, "FirstState", stateMachine); //This will make a display due to allocation debug rmDbgParam(stateMachine, ALLOC_DBG); //This will deactivate allocation debug so, at this point only deallocation debug remain active S_2 = allocateState2(stateMachine, "SecondState", stateMachine); //This won't make any display as allocation debug has been turned off freeStateMachine(stateMachine); //This will make some display due to deallocation debug
If activated, a debug display will be done each time a new state or a new transition is created.
If activated, a debug display will be done during the deallocation of the state machine. Note that any unallocated state will be explicity dislayed but the history states and transitions won't trigger any display.
If activated, a debug display will be done each time The system have to realloc an array. It can be very usefull when you try to optimize the speed of the library. This way you can check if the space you allocate manually is enought for your state machine.
If activated, a debug display will be done while the system, after having received an event, try to determine if a transition should be triggered.
If activated, a debug display will be done each time a state is entered or exited.
If activated, a debug display will be done each time state become a default state.
If activated, a debug display will be done during transition showing the result of the tests on enter/exit funtion call.
Next: How to carefully handle the library
Previous : Using Parallel States to Avoid a Combinatorial Explosion of States