From 9d3573134462335051e46b990e97e1d32bef4b29 Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Mon, 31 Mar 2008 13:03:47 +0200 Subject: * digital/io/src: - adapted FSM to AVR program. --- digital/io/src/fsm_templates/template_fsm.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 digital/io/src/fsm_templates/template_fsm.c (limited to 'digital/io/src/fsm_templates/template_fsm.c') diff --git a/digital/io/src/fsm_templates/template_fsm.c b/digital/io/src/fsm_templates/template_fsm.c new file mode 100644 index 00000000..87e52f33 --- /dev/null +++ b/digital/io/src/fsm_templates/template_fsm.c @@ -0,0 +1,25 @@ +/* + * THIS IS AN AUTOMATICALLY GENERATED FILE, DO NOT EDIT! + * + * %(name)s + * +%(*comments)s */ +#include "common.h" +#include "fsm.h" +#include "%(prefix)s_cb.h" + +#define NULL ((void *)0L) + +/* %(name)s transition table. */ +static const fsm_transition_t +%(prefix)s_transition_table[%(PREFIX)s_STATE_NB][%(PREFIX)s_EVENT_NB] = { +%(transition_table)s}; + +/* %(name)s context. */ +fsm_t %(prefix)s_fsm = { + &%(prefix)s_transition_table[0][0], + %(PREFIX)s_EVENT_NB, + %(PREFIX)s_STATE_%(initial)s, + %(PREFIX)s_STATE_%(initial)s, +}; + -- cgit v1.2.3