Forces an emission of PDO by resetting the COB of the last message
authorpeter
Fri, 14 Mar 2008 10:55:34 +0100
changeset 417 ae068232859c
parent 416 9ef58fa2c66a
child 418 64a8c24b61a5
Forces an emission of PDO by resetting the COB of the last message
examples/AVR/Slave/ds401.c
--- a/examples/AVR/Slave/ds401.c	Wed Mar 12 10:08:43 2008 +0100
+++ b/examples/AVR/Slave/ds401.c	Fri Mar 14 10:55:34 2008 +0100
@@ -49,7 +49,11 @@
     newInput++;
   }
   if (transmission)
+  {
+  /* force emission of PDO by artificially changing last emitted*/
+    d->PDO_status[0].last_message.cob_id = 0;
     sendPDOevent(d);
+  }
 
   return 1;
 }