From 2c69fb3d4f90783efe9cab91f1d7ff65c852f88e Mon Sep 17 00:00:00 2001 From: ACC Murphy Date: Sun, 6 Jan 2008 06:11:33 +0000 Subject: [PATCH] note vis pyserial change of timeout --- sql-edition/servers/VendingMachine.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sql-edition/servers/VendingMachine.py b/sql-edition/servers/VendingMachine.py index 25d375b..d73eb4b 100644 --- a/sql-edition/servers/VendingMachine.py +++ b/sql-edition/servers/VendingMachine.py @@ -39,8 +39,13 @@ class VendingMachine: def await_prompt(self): self.wfh.flush() state = 1 + timeout = 0.5 prefix = '' s = '' + # mtearle - vending machine was dying wait for a response from + # the hardware, suspect it was missing characters + # + # fixed by migration to pyserial - but future good place to start while True: try: s = self.rfh.read(1) -- 2.20.1