From 75b5e6165672f7e8edc510b44879dbedabdb5eba Mon Sep 17 00:00:00 2001
From: rorist <rorist@0xcafe.ch>
Date: Mon, 21 Aug 2023 19:47:36 +0200
Subject: [PATCH] better lighting when pressing vs playing

---
 __init__.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/__init__.py b/__init__.py
index 4b3529f..14d4af3 100755
--- a/__init__.py
+++ b/__init__.py
@@ -160,7 +160,10 @@ class EndlessSequencer(Application):
         # Light petal
         for i in range(10):
 
-            if ct.petals[i].pressed or i-1 == self.current_sample:
+            if ct.petals[i].pressed or \
+                    (self.current_sample == i-1
+                     and not ct.petals[0].pressed
+                     and len(self.notes) > 0):
                 leds.set_all_rgb(0, 0, 0)
 
                 # Select led range
-- 
GitLab