FsmVCR.h File Reference
`#include "ES2_V4_app.h"`
Include dependency graph for FsmVCR.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Typedefs

typedef enum fsmVCRevents | eEventsVCR_t
| Enumeration holds all possible events for this state machine. More...
typedef enum fsmVCRstates | eStatesVCR_t
| Enumeration holds all defined states for video recorder state machine. More...

## Enumerations

enum | fsmVCRevents { evPlaybutton = 0, evStopbutton, evFastforwardbutton, evRecordbutton, evRewindbutton, evBegintape, evEndtape, evTapeout, EV_LAST_VCR }
| Enumeration holds all possible events for this state machine. More...
enum | fsmVCRstates { sStandby = 0, sRecord, sPlay, sRewind, sFastForward, STATE_LAST_VCR }
| Enumeration holds all defined states for video recorder state machine. More...

## Functions

_Bool | bFsmVCRInitialize (void)
| Wrapper function to statemachine_init(). More...
_Bool | bFsmVCRDispatchEvent (int32_t event)
| Sends an event to the state machine. More...
int32_t | s32FsmVCRGetState (void)
| Returns the current state of the fsm. More...
_Bool | bFsmVCRIsStateChanged (void)
| Indicates if a state changed happend. More...
const char * | pcFsmVCRGetStateName (void)
| Get the name of the current state. More...
_Bool | bGuard_tapein_andnot_atend (void)
| guard for Tape in and not at end More...
_Bool | bGuard_tapein_andnot_atbegin (void)
| guard for Tape in and not at begin More...
void | vEntry_sStandby (void)
| entry for sStandby More...
void | vEntry_sRecord (void)
| entry for sRecord More...
void | vExit_sRecord (void)
| exit for sRecord More...
void | vEntry_sPlay (void)
| entry for sPlay More...
void | vExit_sPlay (void)
| exit for sPlay More...
void | vEntry_sRewind (void)
| entry for sRewind More...
void | vExit_sRewind (void)
| entry for sRewind More...
void | vEntry_sFastForward (void)
| entry for sFastForward More...
void | vExit_sFastForward (void)
| exit for sFastForward More...

## Typedef Documentation

## eEventsVCR_t

typedef enum fsmVCRevents eEventsVCR_t

Enumeration holds all possible events for this state machine.

## eStatesVCR_t

typedef enum fsmVCRstates eStatesVCR_t

Enumeration holds all defined states for video recorder state machine.

## Enumeration Type Documentation

## fsmVCRevents

enum fsmVCRevents

Enumeration holds all possible events for this state machine.

Enumerator
evPlaybutton |
evStopbutton |
evFastforwardbutton |
evRecordbutton |
evRewindbutton |
evBegintape |
evEndtape |
evTapeout |
EV_LAST_VCR |

## fsmVCRstates

enum fsmVCRstates

Enumeration holds all defined states for video recorder state machine.

Enumerator
sStandby | video recorder in standby
sRecord | recording a tape
sPlay | play a tape
sRewind | rewind a tape
sFastForward | fast forward a tape
STATE_LAST_VCR |

## Function Documentation

## bFsmVCRDispatchEvent()

_Bool bFsmVCRDispatchEvent | ( | int32_t | s32Event | ) |

Sends an event to the state machine.

This functions wrapps the statemachine_dispatchEvent() function, overgives the event id and returns the return value of statemachine_dispatchEvent().

Parameters

  event | Event for the state machine.

Returns
  Returns the return value of statemachine_dispatchEvent().

Sends an event to the state machine.

Parameters

  FSM | event

Returns
  _Bool

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:
Here is the caller graph for this function:

## bFsmVCRInitialize()

_Bool bFsmVCRInitialize | ( | void |  | ) |

Wrapper function to statemachine_init().

Initializes the state machine with the state table, the number of states and events and the start state. Returns the return value of the statemachine_init() function.

Returns
  Returns the return value from the statemachine_init().

Wrapper function to statemachine_init().

Parameters

  void |

Returns
  _Bool

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:
Here is the caller graph for this function:

## bFsmVCRIsStateChanged()

_Bool bFsmVCRIsStateChanged | ( | void |  | ) |

Indicates if a state changed happend.

This function returns a TRUE if the state of the fsm changed initiated by the last event

Returns
  Returns the current state of the fsm

Indicates if a state changed happend.

Parameters

  voids |

Returns
  _Bool

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:
Here is the caller graph for this function:

## bGuard_tapein_andnot_atbegin()

_Bool bGuard_tapein_andnot_atbegin | ( | void |  | ) |

guard for Tape in and not at begin

Parameters

  void |

Returns
  _Bool

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:

## bGuard_tapein_andnot_atend()

_Bool bGuard_tapein_andnot_atend | ( | void |  | ) |

guard for Tape in and not at end

Parameters

  void |

Returns
  _Bool

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:

## pcFsmVCRGetStateName()

const char* pcFsmVCRGetStateName | ( | void |  | ) |

Get the name of the current state.

Returns
  Returns a pointer to the current state namen

Get the name of the current state.

Parameters

  void |

Returns
  const char* State Name

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:

## s32FsmVCRGetState()

int32_t s32FsmVCRGetState | ( | void |  | ) |

Returns the current state of the fsm.

Returns
  Returns current state of the fsm.

Returns the current state of the fsm.

Parameters

  voids |

Returns
  int32_t FSM state

Author
  hendrik schutter

Date
  24.10.2020

Here is the call graph for this function:

## vEntry_sFastForward()

void vEntry_sFastForward | ( | void |  | ) |

entry for sFastForward

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vEntry_sPlay()

void vEntry_sPlay | ( | void |  | ) |

entry for sPlay

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vEntry_sRecord()

void vEntry_sRecord | ( | void |  | ) |

entry for sRecord

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vEntry_sRewind()

void vEntry_sRewind | ( | void |  | ) |

entry for sRewind

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vEntry_sStandby()

void vEntry_sStandby | ( | void |  | ) |

entry for sStandby

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vExit_sFastForward()

void vExit_sFastForward | ( | void |  | ) |

exit for sFastForward

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vExit_sPlay()

void vExit_sPlay | ( | void |  | ) |

exit for sPlay

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vExit_sRecord()

void vExit_sRecord | ( | void |  | ) |

exit for sRecord

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020

## vExit_sRewind()

void vExit_sRewind | ( | void |  | ) |

entry for sRewind

Parameters

  void |

Returns
  void

Author
  hendrik schutter

Date
  24.10.2020