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.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

README.md 5.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. Alternative Controller for HHKB Pro
  2. ===================================
  3. I wanted to add some features like vi cursor and mouse keys to my [HHKB][HHKB] but its controller is not programmable and
  4. firmware source code is not open, of course. This means customizing this keyboard needs to replace original
  5. controller with programmable one. This controller can work with HHKB Professional and Professional 2 model.
  6. See [this thread][AltController] in geekhack.org.
  7. [HHKB]: http://www.pfu.fujitsu.com/hhkeyboard/
  8. [AltController]: http://geekhack.org/index.php?topic=12047.0
  9. [Teensy]: http://www.pjrc.com/teensy/
  10. ##Features
  11. * Customizable keymap
  12. * More keymap layers(more Fn keys)
  13. * Mouse keys
  14. * USB NKRO
  15. See README of [tmk_keyboard] for more.
  16. [tmk_keyboard]: http://github.com/tmk/tmk_keyboard
  17. ###Pros
  18. * No risk: Everything is all reversible
  19. * Without PCB trace cutting, case mod or any destructives
  20. * Can keep original controller intact
  21. * Can change all HHKB behaviour as you like
  22. ###Cons
  23. * Void your warranty
  24. * Lose USB hub function of Pro2
  25. ##DISCLAIMER
  26. I'm not a professional of electronics nor MCU programming. This may damage your HHKB.
  27. And my English writing is poor, I'm not sure I can convey my notions accurately.
  28. ##Documents
  29. See [doc/HHKB.txt](doc/HHKB.txt) and files under [doc/](doc/) for internal of HHKB and this controller.
  30. ##Build Firmware & Program
  31. You can choose some combination of hardware and USB protocol stack([LUFA], [PJRC]).
  32. ### Install Tools
  33. See [this document](../../doc/build.md).
  34. ### TMK Alt Controller Board
  35. $ make -f Makefile.tmk
  36. This programs the controller with [dfu-programmer] if the tool is intalled and configured properly.
  37. $ make -f Makefile.tmk dfu
  38. Push reset button and program with [FLIP]. The tool should be intalled and configured properly.
  39. $ make -f Makefile.tmk flip
  40. Or you can also program with FLIP GUI.
  41. [dfu-programmer]: http://dfu-programmer.sourceforge.net/
  42. [FLIP]: http://www.atmel.com/tools/FLIP.aspx
  43. ### PJRC Teensy++
  44. Build with [LUFA] USB stack:
  45. $ make -f Makefile.lufa
  46. or with [PJRC] USB stack:
  47. $ make -f Makefile.pjrc
  48. Push reset button and program with [Teensy Loader(command line)]. The tool should be intalled and configured properly.
  49. $ make -f Makefile.lufa teensy
  50. $ make -f Makefile.pjrc teensy
  51. Or you can also program with [Teensy Loader(GUI)].
  52. [LUFA]: http://www.fourwalledcubicle.com/LUFA.php
  53. [PJRC]: http://www.pjrc.com/teensy/usb_keyboard.html
  54. [Teensy Loader(command line)]: http://www.pjrc.com/teensy/loader_cli.html
  55. [Teensy Loader(GUI)]: http://www.pjrc.com/teensy/loader.html
  56. ###AVR Mega with [V-USB]
  57. Build:
  58. $ make -f Makefile.vusb
  59. Program [USBaspLoader] on MCU with AVR programmer like [AVRISPmkII] and tool like [avrdude].
  60. You can programs with [avrdude] once you have programmed [USBaspLoader] on MCU.
  61. $ make -f Makefile.vusb program
  62. [AVRISPmkII]: http://www.atmel.com/tools/AVRISPMKII.aspx
  63. [avrdude]: http://www.nongnu.org/avrdude/
  64. ##How to Customize
  65. See [tmk_keyboard] documents.
  66. ##Hardware
  67. You have some options for hardware. Development boards with USB AVR family(ATMega32U4, AT90USB1286) like Teensy will work while MegaAVR with V-USB library is also cheapear option for DIY.
  68. ###1. TMK Alt Controller Board
  69. TMK designed [Keyboard Controller Board for HHKB Pro2(KiCad project)](https://github.com/tmk/HHKB_controller).
  70. See [this post](http://geekhack.org/index.php?topic=12047.msg948923#msg948923).
  71. ###2. PJRC Teensy++ 2.0 connection
  72. +---------------+
  73. | Teensy++ |
  74. | |
  75. | | HHKB pro HHKB pro2
  76. | | ~~~~~~~~ ~~~~~~~~~
  77. | PB0-2|------->ROW (6-8) (5-7)
  78. | PB3-5|------->COL (9-11) (8-10)
  79. | PB6|------->ENABLE (12) (11)
  80. | PE6|<-------KEY (4) (3)
  81. | PE7|------->PREV (5) (4)
  82. | |
  83. | | 5V--- (1-3) (1-2)
  84. | | GND--- (13-14) (12-13)
  85. +---------------+
  86. - NOTE: PJRC [Teensy](http://www.pjrc.com/teensy/)
  87. [Teensy Loader]: http://www.pjrc.com/teensy/loader.html
  88. ###3. V-USB connection
  89. +---+ +---------------+
  90. USB GND | | ATmega328p |
  91. ~~~ C3 | |
  92. 5V <-------+--------+---|Vcc,AVCC | HHKB pro pro2
  93. R1 | | ~~~~~~~~ ~~~~
  94. D- <----+--+-----R2-----|INT1 PB2-4|------->ROW (6-8) (5-7)
  95. D+ <----|---+----R3-----|INT0 PC0-2|------->COL (9-11) (8-10)
  96. Z1 Z2 | PC3|------->ENABLE (12) (11)
  97. GND<----+---+-----------|GND PB0|<-------KEY (4) (3)
  98. | PB1|------->PREV (5) (4)
  99. | |
  100. GND+-C2--+--|XTAL1 RXD|------->Debug Console
  101. X1 | TXD|<-------Debug Console
  102. GND+-C3--+--|XTAL2 RST|---SW--+GND
  103. +---------------+
  104. R1: 1.5K Ohm
  105. R2,R3: 68 Ohm
  106. Z1,Z2: Zener 3.6V
  107. C1,C2: 22pF
  108. C3: 0.1uF
  109. X1: Crystal 12MHz
  110. SW: Push Switch(for bootloader)
  111. - NOTE: See [V-USB] documentation for more detail of hardware and the USB stack.
  112. - NOTE: [USBaspLoader] is very useful for firmware update.
  113. [V-USB]: http://www.obdev.at/products/vusb/index.html
  114. [USBaspLoader]: http://www.obdev.at/products/vusb/usbasploader.html