keymap.c 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. /* Copyright 2017 MechMerlin
  2. *
  3. * This program is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #include "amj96.h"
  17. const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
  18. LAYOUT(
  19. ESC, F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, PSCR,PAUS, INS, DEL, PGUP,PGDN, \
  20. GRV, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, MINS,EQL, BSPC,NO, NLCK,PSLS,PAST,PMNS, \
  21. TAB, Q, W, E, R, T, Y, U, I, O, P, LBRC,RBRC, BSLS, P7, P8, P9, PPLS, \
  22. CAPS,A, S, D, F, G, H, J, K, L, SCLN,QUOT, ENT, P4, P5, P6, PPLS, \
  23. LSFT,NO, Z, X, C, V, B, N, M, COMM,DOT, SLSH, RSFT,UP, P1, P2, P3, PENT,\
  24. LCTL,LGUI,LALT, SPC, RALT,FN0, LEFT,DOWN, RGHT,P0, PDOT, PENT),
  25. LAYOUT(
  26. TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, TRNS,TRNS,TRNS,TRNS,\
  27. TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,NO, TRNS,TRNS,TRNS,TRNS,\
  28. TRNS,TRNS,TRNS, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, TRNS,TRNS,TRNS,TRNS, TRNS, TRNS,TRNS,TRNS,TRNS,\
  29. TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, TRNS, TRNS,TRNS,TRNS,TRNS,\
  30. TRNS,NO, TRNS,TRNS, TRNS, TRNS, TRNS, TRNS,TRNS,TRNS,TRNS, TRNS, TRNS,TRNS, TRNS,TRNS,TRNS,TRNS,\
  31. TRNS,TRNS,TRNS, TRNS, TRNS,TRNS, TRNS,TRNS, TRNS,TRNS,TRNS,TRNS)
  32. };
  33. const uint16_t PROGMEM fn_actions[] = {
  34. };
  35. const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
  36. {
  37. // MACRODOWN only works in this function
  38. switch(id) {
  39. case 0:
  40. if (record->event.pressed) {
  41. register_code(KC_RSFT);
  42. } else {
  43. unregister_code(KC_RSFT);
  44. }
  45. break;
  46. }
  47. return MACRO_NONE;
  48. };
  49. void matrix_init_user(void) {
  50. }
  51. void matrix_scan_user(void) {
  52. }
  53. bool process_record_user(uint16_t keycode, keyrecord_t *record) {
  54. return true;
  55. }
  56. void led_set_user(uint8_t usb_led) {
  57. }