From 16884be0fda1908918adbef03ebc3949084839e7 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Sat, 22 May 2021 20:17:37 +0200 Subject: Handle LED via select-on-button --- guile/starlet/midi-control/button-utils.scm | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'guile') diff --git a/guile/starlet/midi-control/button-utils.scm b/guile/starlet/midi-control/button-utils.scm index 8dcfbf2..2f19c8d 100644 --- a/guile/starlet/midi-control/button-utils.scm +++ b/guile/starlet/midi-control/button-utils.scm @@ -78,8 +78,13 @@ (define* (select-on-button button fixture - #:key (channel #f)) + #:key + (channel #f) + (ready-note #f)) (register-midi-note-callback! - #:channel channel - #:note-number button - #:func (lambda () (sel fixture)))) + #:channel channel + #:note-number button + #:func (lambda () (sel fixture))) + + (when ready-note + (send-note-on ready-note))) -- cgit v1.2.3