From 9dec7a1b9c8233ba711fb82a8cbd3c098f52d2ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Le=20Bihan?= Date: Fri, 10 Dec 2021 14:51:58 +0100 Subject: [PATCH] fixing intervals --- main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index e0d7ef0..6a50791 100644 --- a/main.py +++ b/main.py @@ -26,7 +26,7 @@ async def to_chroma_case(data): colored_pixels = notePixels[data["key"].lower()] for pixelId in colored_pixels: pixels[pixelId] = data["color"] - await asyncio.sleep((data['duration'] - 5) / 1000) + await asyncio.sleep(data['duration'] / 1000) for pixelId in colored_pixels: pixels[pixelId] = 0 @@ -38,7 +38,7 @@ async def printing(data): async def main(): - default_duration = 1000 + default_duration = 900 default_color = (255, 0, 0) p = Partition("test",