Keyboard firmwares for Atmel AVR and Cortex-M
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

README 3.7KB

13 years ago
13 years ago
13 years ago
13 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. t.m.k. Keyboard Firmware
  2. ========================
  3. http://github.com/tmk/tmk_keyboard
  4. This is keyboard firmware for AVR USB MCUs or Teensy/Teensy++.
  5. http://www.pjrc.com/teensy
  6. The project is heavily based on PJRC USB Keyboard/Mouse Example and
  7. owes a debt to preceding keyboard firmware projects.
  8. This firmware is used in following projects:
  9. HHKB mod: http://geekhack.org/showwiki.php?title=Island:12047
  10. Macway mod: http://geekhack.org/showwiki.php?title=Island:11930
  11. Features
  12. --------
  13. Mouse key
  14. control mouse cursor from keyboard.
  15. System Control Key
  16. Power Down, Sleep, Wake Up & USB Remote Wake up
  17. Media Control Key
  18. Volume Down/Up, Mute
  19. USB NKRO
  20. send 120 keys(+ 8 modifiers) at most simultaneously.
  21. PS/2 mouse support
  22. integrate PS/2 mouse(TrackPoint) into keyboard as composite device.
  23. Limitations
  24. -----------
  25. Build
  26. -----
  27. To compile needs AVR GCC, AVR Libc and GNU make.
  28. You can use WinAVR on Windows. http://winavr.sourceforge.net/
  29. $ cd <target> (hhkb or macway currently)
  30. $ make
  31. The firmware will be compiled as a file tmk_<target>.hex.
  32. Build your own firmware
  33. -----------------------
  34. Copying exsistent target(macway) is easy way.
  35. 1. Copy contens of macway/ to your own target directory.
  36. 2. Edit Makefile. See next section.
  37. 3. Edit config.h. See next section.
  38. 4. Edit matrix.c. You will need to fix followings at least.
  39. matrix_init()
  40. matrix_scan()
  41. read_col()
  42. unselect_rows()
  43. select_row()
  44. 5. Edit keymap.c. NOTE: It is not final design and a bit messy.
  45. You will need to fix followings at least.
  46. KEYMAP
  47. fn_layer[]
  48. fn_keycode[]
  49. keymaps[]
  50. 6. Build.
  51. If you have a build error like following, comment out "--relax" option in Makefile.common.
  52. (.vectors+0x30): relocation truncated to fit: R_AVR_13_PCREL against symbol `__vector_12'
  53. Build Options
  54. -------------
  55. <target>/Makefile:
  56. 1. Set target name for your firmware.
  57. TARGET = tmk_<target>
  58. 2. Choose a MCU and its frequency.
  59. MCU = atmega32u4 # Teensy 2.0
  60. #MCU = at90usb1286 # Teensy++ 2.0
  61. F_CPU = 16000000
  62. 3. Choose optional modules as needed. Comment out to disable optional modules.
  63. MOUSEKEY_ENABLE = yes # Mouse keys
  64. PS2_MOUSE_ENABLE = yes # PS/2 mouse(TrackPoint) support
  65. USB_EXTRA_ENABLE = yes # Enhanced feature for Windows(Audio control and System control)
  66. USB_NKRO_ENABLE = yes # USB Nkey Rollover
  67. <target>/config.h:
  68. 1. USB vendor/product ID and device description
  69. #define VENDOR_ID 0xFEED
  70. #define PRODUCT_ID 0xBEEF
  71. /* device description */
  72. #define MANUFACTURER t.m.k.
  73. #define PRODUCT Macway mod
  74. #define DESCRIPTION t.m.k. keyboard firmware for Macway mod
  75. 2. Keyboard matrix configuration
  76. #define MATRIX_ROWS 8
  77. #define MATRIX_COLS 8
  78. #define MATRIX_HAS_GHOST
  79. 3. Mouse keys configuration if needed.
  80. 4. PS/2 mouse configuration if needed.
  81. Debuging & Rescue
  82. -----------------
  83. Use PJRC's hid_listen.exe to see debug messages.
  84. Press right Control + Shift + Alt + GUI + H to debug menu.
  85. Pressing any 3 keys when connected enables debug output.
  86. Pressing any 4 keys when connected makes bootloader comes up.
  87. Projects related
  88. ----------------
  89. PJRC USB Keyboard/Mouse Example
  90. http://www.pjrc.com/teensy/usb_keyboard.html
  91. http://www.pjrc.com/teensy/usb_mouse.html
  92. kbupgrade
  93. http://github.com/rhomann/kbupgrade
  94. http://geekhack.org/showwiki.php?title=Island:8406
  95. c64key
  96. http://symlink.dk/projects/c64key/
  97. rump
  98. http://mg8.org/rump/
  99. http://github.com/clee/rump
  100. dulcimer
  101. http://www.schatenseite.de/dulcimer.html
  102. humblehacker-keyboard
  103. http://github.com/humblehacker
  104. http://www.humblehacker.com/keyboard/
  105. http://geekhack.org/showwiki.php?title=Island:6292
  106. ps2avr
  107. http://sourceforge.net/projects/ps2avr/
  108. EOF