Browse Source

Enable USB keyboard support

master
Dejvino 1 year ago
parent
commit
596278e625
1 changed files with 11 additions and 3 deletions
  1. +11
    -3
      terminal_keyboard_emulator.ino

+ 11
- 3
terminal_keyboard_emulator.ino View File

@@ -2,6 +2,12 @@
// [Consul 262.4 Converter] https://deskthority.net/viewtopic.php?t=26908
// [Consul 262.5 manual in CS] http://www.sapi.cz/prislusenstvi/c262-5.php#odkazp4

#define KEYBOARD

#ifdef KEYBOARD
#include <Keyboard.h>
#endif

#include <TimerOne.h>

// pinout config
@@ -350,9 +356,11 @@ void processKbdByte(int data) {
}
#ifdef KEYBOARD
Keyboard.press(keyChar);
delay(10);
Keyboard.release(keyChar);
if (!hostOnline) {
Keyboard.press(keyChar);
delay(10);
Keyboard.release(keyChar);
}
#endif

typeKey(keyChar);


Loading…
Cancel
Save