From 738dd2a250c02086f159fccc5bccec80e860e6c0 Mon Sep 17 00:00:00 2001
From: Florian Pose <fp@igh-essen.com>
Date: Thu, 30 Apr 2009 16:04:44 +0000
Subject: [PATCH] Set system time transmission delay during config.

---
 master/fsm_slave_config.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/master/fsm_slave_config.c b/master/fsm_slave_config.c
index 415a9f5a..4954c638 100644
--- a/master/fsm_slave_config.c
+++ b/master/fsm_slave_config.c
@@ -438,9 +438,10 @@ void ec_fsm_slave_config_state_dc_read_offset(
                 slave->ring_position, system_time, old_offset,
                 slave->master->app_time, new_offset);
 
-    // set DC system time offset
-    ec_datagram_fpwr(datagram, slave->station_address, 0x0920, 8);
+    // set DC system time offset and transmission delay
+    ec_datagram_fpwr(datagram, slave->station_address, 0x0920, 12);
     EC_WRITE_U64(datagram->data, new_offset);
+	EC_WRITE_U32(datagram->data + 8, slave->transmission_delay);
     fsm->retries = EC_FSM_RETRIES;
     fsm->state = ec_fsm_slave_config_state_dc_write_offset;
 }
-- 
GitLab