From 1c0b79d3156488e6a3797b541c5b87e8eb338215 Mon Sep 17 00:00:00 2001 From: ian Date: Sat, 13 May 2006 18:10:31 +0000 Subject: [PATCH] Revised Settling state --- hostside/startup.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/hostside/startup.c b/hostside/startup.c index d9235bd..64c53d3 100644 --- a/hostside/startup.c +++ b/hostside/startup.c @@ -16,6 +16,10 @@ static void sta_goto(StartupState new_state); static void timedout_onward(TimeoutEvent *toev) { assert(sta_state != Sta_Run); + if (sta_state == Sta_Settling) { + enco_pic_off(&piob); + serial_transmit(&piob); + } sta_goto(sta_state == Sta_Flush ? Sta_Ping : sta_state + 1); } @@ -61,7 +65,7 @@ static void sta_goto(StartupState new_state) { case Sta_Off: break; case Sta_Ping: break; case Sta_Fault: break; - case Sta_Settling: sta_toev.duration= 2000; break; + case Sta_Settling: sta_toev.duration= 750; break; case Sta_Resolving: sta_toev.duration= 500; break; case Sta_Run: break; } @@ -161,7 +165,7 @@ void on_pic_pong(const PicInsnInfo *pii, const PicInsn *pi, int objnum) { void on_pic_fixed(const PicInsnInfo *pii, const PicInsn *pi, int objnum) { if (sta_state >= Sta_Resolving) die("PIC sent unexpected FIXED"); - if (sta_state == Sta_Fault) sta_goto(Sta_Settling); + if (sta_state == Sta_Fault) sta_goto(Sta_Resolving); } void on_pic_fault(const PicInsnInfo *pii, const PicInsn *pi, int objnum) { -- 2.30.2