Easy way to map (computer) keyboard to send OSC/Midi

I see there is a "key binding" option in the "script" widget, which lets me set a keyboard shortcut to send specific OSC.

i think- if there were similar thing for buttons, switches and knobs, it would be so helpful... I could use my extra physical keyboard to send some signals.

suppose i want to remap nearly all my keybaord buttons to send some OSC/Midi signals. instead of making 58 scripts, is there any efficient way to map the keys?
--- for OSC, some sort of GUI for remapping buttons can be helpful.
for example:
a gui that shows a table with these columns:
-- Key (single key/multiple key combo),
-- address,
-- trigger type (on/off or push etc)
-- and etc.
you will have "record key" button, "address" text field and "type" dropdown for adding new shortcut. Also, the shortcuts already set on widgets will also be shown here, for easier view/editing.

and/or, some kind of external file that can be edited easily and loaded into the session to enable the remapping? like... a json file?

---- for Midi, some sort of GUI to remap CC controls?
for example:
a gui that shows a keybaord layout with buttons showing:
-- original key ("a"/"b"...etc)
-- channel
-- type (CC/PC/Note)
-- number (Control Number/Program number)

Use cases:

  1. I got my desktop and laptop connected on same wifi. i can control my DAW/Resolume with Open Stage Control. I can use the keyboard on my laptop to send some OSC/Midi messages
    (More buttons=more controls=more fun!)
  2. I will also be able to connect an external keyboard using OTG cable in my android phone, to have the fun of both touchscreen (phone) and physical buttons (keyboard).
    and many more!

Honestly I don't think the Gui part is going to happen as it seems a bit out of o-s-c's scope, but the good news is you can already do pretty much everything you described using a single script widget by setting the script's keyBinding property to [""] (processes all keystrokes) and dispatching the keys in the onKeyboard property:

switch (key) {
  case "a":
    // do something
  case "b":
    // do something else
  case "c":
    if (ctrl) {
      // hey
    } else {
      // hoo

:slightly_smiling_face: thank you for the reply.

  1. is there any other method i can use for it?
    for example: a csv that stores that table (lets say i make/edit the table on another software)
    because that much of switch cases, i think, will become messy and cumbersome to edit.
  2. if possible, please bring "key binding" functionality for buttons, switches and knobs etc... :pleading_face: it will be so much helpful to easily bind the keys... with "keyPressFocus" parameter (i named it, you can name it better...) basically it will help in this scenerio: if i press a keyboard button that is assigned to the button, switch or knob in another tab/modal, will it be brought to focus or not (that tab/modal will automatically be opened or not...)
    this can be i guess a part of this amazing software...