Recently got hold of a keybow2040 which I’m having a lot of fun with. What I’d like to do it be able to send multiple keys in response to a single key press (for example I press a single key on the keybow and it sends ALT+F4).
I put this code together -
combo_1 = [Keycode.ALT,Keycode.F4]
for k in combo_1:
keyboard.send(k)
However that has the the effect of sending the ALT keycode followed by the F4 keycode - not at the same time.
require "keybow"
function handle_key_00(pressed)
if pressed then
keybow.set_modifier(keybow.LEFT_META, keybow.KEY_DOWN)
keybow.tap_key("r", pressed)
keybow.set_modifier(keybow.LEFT_META, keybow.KEY_UP)
end
end
Thanks for the swift response. Thats an example for the keybow hardware and I’m using the keybow2040. I dont believe the code is cross compatible as thats written in lua and I believe the keybow2040 can only use CircuitPython.
That could come in handy for me, thanks for posting the solution. I have the PICO RGB Keypad base, and have it running a port of Keybow 2040 Circuit Python. I have plans for multi key on button press code.