--- a/master/master.c Mon Mar 14 11:24:15 2011 +0100
+++ b/master/master.c Tue Apr 05 08:27:05 2011 +0200
@@ -228,6 +228,7 @@
}
// create state machine object
+ ec_mbox_init(&master->fsm_mbox,&master->fsm_datagram);
ec_fsm_master_init(&master->fsm, master, &master->fsm_datagram);
// init reference sync datagram
@@ -329,7 +330,7 @@
#endif
ec_cdev_clear(&master->cdev);
-
+
#ifdef EC_EOE
ec_master_clear_eoe_handlers(master);
#endif
@@ -341,6 +342,7 @@
ec_datagram_clear(&master->sync_datagram);
ec_datagram_clear(&master->ref_sync_datagram);
ec_fsm_master_clear(&master->fsm);
+ ec_mbox_clear(&master->fsm_mbox);
ec_datagram_clear(&master->fsm_datagram);
ec_device_clear(&master->backup_device);
ec_device_clear(&master->main_device);
@@ -1279,7 +1281,7 @@
if (ec_mutex_lock_interruptible(&master->master_mutex))
break;
if (ec_fsm_master_exec(&master->fsm)) {
- ec_master_queue_fsm_datagram(master, &master->fsm_datagram);
+ ec_master_mbox_queue_datagrams(master, &master->fsm_mbox);
}
for (slave = master->slaves;
slave < master->slaves + master->slave_count;
@@ -1343,7 +1345,7 @@
if (ec_mutex_lock_interruptible(&master->master_mutex))
break;
if (ec_fsm_master_exec(&master->fsm))
- ec_master_queue_fsm_datagram(master, &master->fsm_datagram);
+ ec_master_mbox_queue_datagrams(master, &master->fsm_mbox);
for (slave = master->slaves;
slave < master->slaves + master->slave_count;
slave++) {