Skip to content

Commit 2763428

Browse files
committed
Belgian keyboard
1 parent 07e82b5 commit 2763428

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

digistump-avr/libraries/DigisparkKeyboard/DigiKeyboard-be.h

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
*
44
* TODO: Make a proper file header. :-)
55
* Modified for Digispark by Digistump
6+
* Version working with belgian keyboards
67
*/
78
#ifndef __DigiKeyboard_h__
89
#define __DigiKeyboard_h__
@@ -201,12 +202,13 @@ class DigiKeyboardDevice : public Print {
201202
}
202203

203204
size_t write(uint8_t chr) {
205+
// Scan codes which use 7 bits
204206
if(chr == '<')
205-
sendKeyStroke(100);
207+
sendKeyStroke(0x64);
206208
else if(chr == '>')
207-
sendKeyStroke(100, MOD_SHIFT_RIGHT);
209+
sendKeyStroke(0x64, MOD_SHIFT_RIGHT);
208210
else if(chr == '\\')
209-
sendKeyStroke(100, MOD_ALT_RIGHT);
211+
sendKeyStroke(0x64, MOD_ALT_RIGHT);
210212

211213
else
212214
{

digistump-avr/libraries/DigisparkKeyboard/scancode-ascii-table-be.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#define AltGr 0x40
1010

1111
const unsigned char ascii_to_scan_code_table[] PROGMEM = {
12-
// ASCII Code HID Usage Key pos on a US Keyboard
12+
// Code HID Usage Key pos on a US Keyboard
1313
// /* ASCII: 0 */ 0,
1414
// /* ASCII: 1 */ 0,
1515
// /* ASCII: 2 */ 0,

0 commit comments

Comments
 (0)