-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from Powerbyte7/appvars
Refactor and store macros as AppVars
- Loading branch information
Showing
8 changed files
with
236 additions
and
215 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
#include "keymap.h" | ||
|
||
const uint8_t map[60] = { | ||
[sk_2nd ] = KEY_LEFTSHIFT, | ||
[sk_Alpha ] = KEY_LEFTCTRL, | ||
[sk_GraphVar] = KEY_LEFTALT, | ||
[sk_Vars ] = KEY_LEFTMETA, | ||
[sk_Up ] = KEY_UP, | ||
[sk_Down ] = KEY_DOWN, | ||
[sk_Left ] = KEY_LEFT, | ||
[sk_Right ] = KEY_RIGHT, | ||
[sk_Del ] = KEY_BACKSPACE, | ||
[sk_Clear ] = KEY_NONE, | ||
[sk_Math ] = KEY_A, | ||
[sk_Apps ] = KEY_B, | ||
[sk_Prgm ] = KEY_C, | ||
[sk_Recip ] = KEY_D, | ||
[sk_Sin ] = KEY_E, | ||
[sk_Cos ] = KEY_F, | ||
[sk_Tan ] = KEY_G, | ||
[sk_Power ] = KEY_H, | ||
[sk_Square ] = KEY_I, | ||
[sk_Comma ] = KEY_J, | ||
[sk_LParen ] = KEY_K, | ||
[sk_RParen ] = KEY_L, | ||
[sk_Div ] = KEY_M, | ||
[sk_Log ] = KEY_N, | ||
[sk_7 ] = KEY_O, | ||
[sk_8 ] = KEY_P, | ||
[sk_9 ] = KEY_Q, | ||
[sk_Mul ] = KEY_R, | ||
[sk_Ln ] = KEY_S, | ||
[sk_4 ] = KEY_T, | ||
[sk_5 ] = KEY_U, | ||
[sk_6 ] = KEY_V, | ||
[sk_Sub ] = KEY_W, | ||
[sk_Store ] = KEY_X, | ||
[sk_1 ] = KEY_Y, | ||
[sk_2 ] = KEY_Z, | ||
[sk_3 ] = KEY_CAPSLOCK, | ||
[sk_Add ] = KEY_APOSTROPHE, | ||
[sk_0 ] = KEY_SPACE, | ||
[sk_DecPnt ] = KEY_SEMICOLON, | ||
[sk_Chs ] = KEY_SLASH, | ||
[sk_Enter ] = KEY_ENTER, | ||
[sk_Stat ] = KEY_TAB, | ||
}; | ||
|
||
const uint8_t special_map[60] = { | ||
[sk_2nd ] = KEY_LEFTSHIFT, | ||
[sk_Alpha ] = KEY_LEFTCTRL, | ||
[sk_GraphVar] = KEY_LEFTALT, | ||
[sk_Vars ] = KEY_LEFTMETA, | ||
[sk_Up ] = KEY_VOLUMEUP, | ||
[sk_Down ] = KEY_VOLUMEDOWN, | ||
[sk_Left ] = KEY_MEDIA_BACK, | ||
[sk_Right ] = KEY_MEDIA_FORWARD, | ||
[sk_Del ] = KEY_BACKSPACE, | ||
[sk_Clear ] = KEY_NONE, | ||
[sk_Math ] = KEY_F1, | ||
[sk_Apps ] = KEY_F2, | ||
[sk_Prgm ] = KEY_F3, | ||
[sk_Recip ] = KEY_F4, | ||
[sk_Sin ] = KEY_F5, | ||
[sk_Cos ] = KEY_F6, | ||
[sk_Tan ] = KEY_F7, | ||
[sk_Power ] = KEY_F8, | ||
[sk_Square ] = KEY_HOME, | ||
[sk_Comma ] = KEY_COMMA, | ||
[sk_LParen ] = KEY_KPLEFTPAREN, | ||
[sk_RParen ] = KEY_KPRIGHTPAREN, | ||
[sk_Div ] = KEY_ESC, | ||
[sk_Log ] = KEY_PAGEUP, | ||
[sk_7 ] = KEY_7, | ||
[sk_8 ] = KEY_8, | ||
[sk_9 ] = KEY_9, | ||
[sk_Mul ] = KEY_KPASTERISK, | ||
[sk_Ln ] = KEY_PAGEDOWN, | ||
[sk_4 ] = KEY_4, | ||
[sk_5 ] = KEY_5, | ||
[sk_6 ] = KEY_6, | ||
[sk_Sub ] = KEY_MINUS, | ||
[sk_Store ] = KEY_END, | ||
[sk_1 ] = KEY_1, | ||
[sk_2 ] = KEY_2, | ||
[sk_3 ] = KEY_3, | ||
[sk_Add ] = KEY_EQUAL, | ||
[sk_0 ] = KEY_0, | ||
[sk_DecPnt ] = KEY_SEMICOLON, | ||
[sk_Chs ] = KEY_SLASH, | ||
[sk_Enter ] = KEY_ENTER, | ||
[sk_Stat ] = KEY_TAB, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <keypadc.h> | ||
#include <tice.h> | ||
#include "usb_hid_keys.h" | ||
|
||
extern const uint8_t map[60]; | ||
extern const uint8_t special_map[60]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#include "macros.h" | ||
|
||
const uint8_t macro1[1] = { | ||
KEY_F1 | ||
}; | ||
|
||
const uint8_t macro2[1] = { | ||
KEY_F2 | ||
}; | ||
|
||
const uint8_t macro3[1] = { | ||
KEY_F3 | ||
}; | ||
|
||
const uint8_t macro4[1] = { | ||
KEY_F4, | ||
}; | ||
|
||
const uint8_t macro5[1] = { | ||
KEY_F5 | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#include "usb_hid_keys.h" | ||
#include <tice.h> | ||
|
||
extern const uint8_t macro1[1]; | ||
extern const uint8_t macro2[1]; | ||
extern const uint8_t macro3[1]; | ||
extern const uint8_t macro4[1]; | ||
extern const uint8_t macro5[1]; |
Oops, something went wrong.