Enable led when matrix button pressed. #1073
Replies: 2 comments 1 reply
-
Please do not create duplicate issues/discussions for the same question. You can use the |
Beta Was this translation helpful? Give feedback.
1 reply
-
Hello Pieter,
yes of course....i will not do it again.
I solve the problem with Shift register 74HC595 and leds works perfect.
I have a problem with the last button on Multiplexer (pin15) that returns two different values when press it...
I will try to solve this too.
…________________________________
From: Pieter P ***@***.***>
Sent: Saturday, September 21, 2024 3:37 PM
To: tttapa/Control-Surface ***@***.***>
Cc: Thomas ***@***.***>; State change ***@***.***>
Subject: Re: [tttapa/Control-Surface] Enable led when matrix button pressed. (Discussion #1073)
Please do not create duplicate issues/discussions for the same question.
You can use the NoteButtonMatrix::getPrevState(col, row)<https://tttapa.github.io/Control-Surface-doc/Doxygen/dd/d29/classAH_1_1ButtonMatrix.html#a62dac074b3767f9be91bc05f4e5a0638> function.
—
Reply to this email directly, view it on GitHub<#1073 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AEFLFTXWAGGWVPDCTVBGGA3ZXWHEZAVCNFSM6AAAAABOPITHZWVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTANZRGM2TSMQ>.
You are receiving this because you modified the open/close state.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello all,
can you please tell me how can i activate leds ON/OFF when a matrix button is pressed?
I mean how can i assign the matrix button address or matrix button pin to the code?
Thank you very much.
Code:
#include <Control_Surface.h>
USBMIDI_Interface midi;
// The note numbers corresponding to the buttons in the matrix
const AddressMatrix<4, 3> addresses {{
{1, 2, 3, 4},
{5, 6, 7, 8},
{9, 10, 11, 12},
}};
NoteButtonMatrix<4, 3> buttonmatrix {
{10, 16,14, 15,}, // row pins
{7, 8, 9}, // column pins
addresses, // address matrix
Channel_1, // channel and cable number
};
void setup() {
Control_Surface.begin();
}
void loop() {
Control_Surface.loop();
}
Beta Was this translation helpful? Give feedback.
All reactions