clocksync: Fix multi-mcu frequency adjustments with long moves

Commit 02ae2ab9 had a typo causing the new long move handling logic to
not take effect.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2018-03-03 21:54:25 -05:00
parent fc60bda4d1
commit 7290ed5f73
1 changed files with 1 additions and 1 deletions

View File

@ -203,7 +203,7 @@ class SecondarySync(ClockSync):
# Determine sync1_print_time and sync2_print_time # Determine sync1_print_time and sync2_print_time
sync1_print_time = max(print_time, est_print_time) sync1_print_time = max(print_time, est_print_time)
sync2_print_time = max(sync1_print_time + 4., self.last_sync_time, sync2_print_time = max(sync1_print_time + 4., self.last_sync_time,
2.5 * (print_time - est_print_time)) print_time + 2.5 * (print_time - est_print_time))
# Calc sync2_sys_time (inverse of main_sync.estimatated_print_time) # Calc sync2_sys_time (inverse of main_sync.estimatated_print_time)
sync2_main_clock = sync2_print_time * main_mcu_freq sync2_main_clock = sync2_print_time * main_mcu_freq
sync2_sys_time = ser_time + (sync2_main_clock - ser_clock) / ser_freq sync2_sys_time = ser_time + (sync2_main_clock - ser_clock) / ser_freq