From 98cfe0a5a68267e2ccb9f459c81131065c0ba853 Mon Sep 17 00:00:00 2001 From: Andras Tantos Date: Wed, 3 Feb 2021 17:17:41 -0800 Subject: [PATCH] Changed handling of years for COS emulation. Instead of a constant offset, now we bracket the year to be within 1980 and 1999, which seems to be acceptable for COS. --- cos_117.cfg | 2 +- simulator/sim_lib/iop_expander.cpp | 5 +++-- simulator/sim_lib/iop_expander.h | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/cos_117.cfg b/cos_117.cfg index 7bf1b55..b496999 100644 --- a/cos_117.cfg +++ b/cos_117.cfg @@ -144,7 +144,7 @@ IopClusters { Interrupt 1 Name CK0 ResponseTimeout 500 - YearOffset 30 + YearLimit yes } } ;UseDummyDevices yes diff --git a/simulator/sim_lib/iop_expander.cpp b/simulator/sim_lib/iop_expander.cpp index 1ffe592..eb6a43a 100644 --- a/simulator/sim_lib/iop_expander.cpp +++ b/simulator/sim_lib/iop_expander.cpp @@ -556,7 +556,7 @@ IopExpClockDevice_c::IopExpClockDevice_c(const Configuration_c &aConfig, IopChan mPrimaryChannelIdx(aConfig.get("PrimaryChannelIdx")), mRequestChannelIdx(aConfig.get("RequestChannelIdx", mPrimaryChannelIdx+1)), mResponseChannelIdx(aConfig.get("ResponseChannelIdx", mPrimaryChannelIdx+0)), - mYearOffset(aConfig.get("YearOffset", 30)) + mYearLimit(aConfig.get("YearLimit", true)) { for(size_t i=0;i