From 67a53cbb0814f2e306d329c522a174096ce9382c Mon Sep 17 00:00:00 2001 From: Peter L Date: Wed, 10 Nov 2021 14:49:43 +0100 Subject: [PATCH] debugging... --- micropizza/main.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/micropizza/main.py b/micropizza/main.py index 7d1fb84..3765273 100644 --- a/micropizza/main.py +++ b/micropizza/main.py @@ -206,12 +206,12 @@ def recording(timeout): return 'OK' def rewind(*opts): - scroll_h.speed = -100 - scroll_v.speed = -100 - while (scroll_h.speed + scroll_v.speed) > 0: - time.sleep_ms(10) - scroll_h.c = 0 - scroll_v.c = 0 + #scroll_h.speed = -100 + #scroll_v.speed = -100 + #while (scroll_h.speed + scroll_v.speed) > 0: + # time.sleep_ms(10) + #scroll_h.c = 0 + #scroll_v.c = 0 return 'OK' ############################################################################### @@ -232,8 +232,10 @@ def parseCmd(cmd_str: str): if len(parm_str) != 0: parms = [int(x) for x in parm_str.split('+')] if _DEBUG: - print(f'parsed command: {cmd}:{parms}') - resp = choice_map[cmd](*parms) + print(cmd, parms, sep=': ') + resp = 'OK' + else: + resp = choice_map[cmd](*parms) uart0.write(f'{resp}\n'.encode('utf-8')) def flash_led(times: int = 1, on_ms: int = 200, off_ms: int = 500):