Mac 128k/512k/Plus Keyboard pinout
.---------,
| 1 2 3 4 | 1 GND
| | 2 Clock
| | 3 Data
`---___---' 4 5V
from front of socket on keyboard
JMK, thanks for posting here again to share.
I tried the converter to test just now and it didn't register any keys at all without pull-up resistors.
Though I think it worked well without them last time, but it doesn't work today.
You might need to add two pull-up resistors on DATA and CLOCK lines in Teensy side in particular when you used long cable or coiled cable.
I used 1.5K Ohm resistors but 1K-10K will be OK.
Now I'm typing my M0110 through the converter with pull-up resistors. No problem.
My pull-up resistors is like this:Show Image(http://i.imgur.com/vJoVOm.jpg) (http://imgur.com/vJoVO.jpg)
I tried the mod once more using your hex file, and it didn't work at all.
And I did "make" after modifying the config.h file once again and tried the mod again. Nothing happened.
So I opened the keyboard and tested the controller. Please see the image.
(Attachment)
As shown in the image, I tested the connection between "1" and the controller part, and I found its direct connection.
But the bx in yellow rectangle are all connected, probably short-circuit. Is it normal? If it's not, I think this is definitely the problem.
I checked some other pins of the controller, and there are more short-circuit.
I think I just need a new controller rather than a converter. Lowpoly's mod will my last option then.
Please let me know your thoughts.
Thanks.
diff --git a/pjrc/usb.c b/pjrc/usb.c
index 2b69b6a..3e18144 100644
--- a/pjrc/usb.c
+++ b/pjrc/usb.c
@@ -657,6 +657,7 @@ ISR(USB_GEN_vect)
}
}
/* TODO: should keep IDLE rate on each keyboard interface */
+/*
#ifdef NKRO_ENABLE
if (!keyboard_nkro && usb_keyboard_idle_config && (++div4 & 3) == 0) {
#else
@@ -677,6 +678,7 @@ ISR(USB_GEN_vect)
}
}
}
+*/
}
}
* HHKB/WASD Layer:
* You can register Esc by hitting(press&release) Fn0 quickly.
* ,---------------------------------------------------------.
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet|
* |---------------------------------------------------------|
* |Caps |Hom| Up|PgU| | | | |Psc|Slk|Pau|Up |Ins| \|
* |---------------------------------------------------------|
* |Contro|Lef|Dow|Rig| | | | |Hom|PgU|Lef|Rig|Return|
* |---------------------------------------------------------|
* |Shift |End| |PgD| |VoD|VoU|Mut|End|PgD|Dow| Shift|
* `---------------------------------------------------------'
* |xxx|Alt | Space |Gui |xxx|
* `-----------------------------------------------'
* mouse key
* ,---------------------------------------------------------.
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet|
* |---------------------------------------------------------|
* |Caps | | | | | |WwL|MwD|MwU|MwR| | | | |
* |---------------------------------------------------------|
* |Contro|Vod|VoU|Mut| | |McL|McD|McU|McR|xxx| |Return|
* |---------------------------------------------------------|
* |Shift | | | | |Mb3|Mb2|Mb1| | | | Shift|
* `---------------------------------------------------------'
* | |Alt | Mb1 |Gui | |
* `-----------------------------------------------'
Mw: Mouse wheel
Mc: Mouse cursor
Mb: Mouse button(1: left, 2: right, 3: middle)
* cursor key
* ,---------------------------------------------------------.
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet|
* |---------------------------------------------------------|
* |Caps | | | | | |Hom|PgD|PgU|End| | | | |
* |---------------------------------------------------------|
* |Contro| | | | | |Lef|Dow|Up |Lef| | |Return|
* |---------------------------------------------------------|
* |Shift | | | | | |Hom|PgD|PgU|End|xxx| Shift|
* `---------------------------------------------------------'
* | |Alt | Space |Gui | |
* `-----------------------------------------------'
Hello there!
Yup, I'm the same skagon from GitHub.
I haven't yet understood if my fork works with your M0110A or not. Could you please elaborate on that?
Also, I don't have any Macintoshes around here -- well, I mean *modern* Macs -- so I don't know what's going on with those.
If everything works, after applying the Mac patch on my fork, I'd like you to do some tests for me. You could also read my (long) commentary from GitHub on the problems I ran into with the M0110A and shift keys and keypad and arrow keys. That should provide some insight on what to check. ;)
Thanks, guys!
Hi JMK! Well, that's the beauty of the Internets! :P You can be better friends with someone you met on-line rather than your next-door neighbour.
Anyway... onto the case now. You said you did something with the caps lock key and now the keyboard isn't working? Or was it because you changed the keymap?
I haven't touched the keys of my A, well, apart from cleaning and some TLC and desoldering the controller and soldering an IC socket in its place, and lots and lots of cleaning. And cleaning. I guess the previous owners were pigs and used the keyboard as a plate for pizza, burgers and chips.
Anyway... can you get a multimetre and verify that the Caps Lock isn't shorted? You can test it from the back side of the PCB, by targeting the two solder points of the switch.
Besides, you can always download a fresh copy of my fork and rebuild from there. Then, it should work again. I can say from experience that the keymaps are very touchy pieces of "code". Make sure the compiler is actually compiling and not producing errors, and also you can use the HID_listen and see what debug info it's spitting out.
Somehow, I don't think you 'killed' your A by removing the locking mechanism.
On another note... I just love typing on this little baby. Much better feel than the plain M0110. The difference in cinematic terms is like comparing the "War Games" keyboard with the "Star Trek 4" "hello computer" keyboard. Oh wait, the "hello computer" keyboard actually *is* the M0110A... *shrug* hey ho... :)
I seriously don't know what the hell's going on here... it's like groundhog day! You come back and everything's the same, posts missing etc.
...
Anyway, JMK you might want to recheck my code, just to be on the safe side... ;)
hasu, actually you were right about the first part: I had downloaded an older commit. Now, I did download the latest. Actually, the keys are working properly... sort of. Sorry to be raining on your parade, mate.
The arrow keys and keypad keys are working perfectly... on their own. However, the moment you combine them with shift, as I had experienced when debugging my code... it's like deja vu. You can see it yourself, with *all* the keypad and arrow keys. Press shift, press any keypad or arrow or calc key and try to release them simultaneously. After a few tries, you'll see what I mean. Just open notepad and input a few lines of text. Then try what I'm saying. Shift, any arrow/keypad/calc key, release together. What you'll get will be stuck keys repeating ad infinitum, until you press them again. Sometimes it's the shift stuck along with an arrow key, sometimes it's just a keypad key misinterpreted, sometimes a keypad key stuck. That's what all those "ifs" and checks in my code are for.
I mean, you've dealt with the multiple return codes in a different way than I have, but you still need those checks to correct the misinterpretations. And as you can see from my code, you'd need to be outside m0110.c to do that. In fact, you need to add those checks in the matrix.c file, so that you can add checks for already pressed keys that their release gets misinterpreted. I have noticed that you're really trying to keep the code additions inside m0110.c for some reason, which I don't know.
Also, I've noticed you're using only 'immediate' commands. I don't know, I don't like it, even though it *could* be somewhat helpful, in that it makes simultaneous key releases more improbable. However, I like to be doing things "by the book", as per Apple specifications, so I prefer to stick to the 'inquire' command for the most part. It also keeps the communication frequency down. With the 'immediate' command, you get a LOT more inquiries per second than with 'inquiry'. I estimate around 5-10x more, given that the 'inquiry' command results in around 5 scans per second (my code and your older code) and the 'instant' command gets around or more than 50. I don't think I like that a lot...
Anyhow... that's all for now. I hope you don't take it the wrong way, I'm not trying to discard your code or anything. I'm just reporting back.
Oh, one last thing: where the hell do you find all these keyboards? I'd like one or two more Mitsumi M0110As but I can't seem to find any (at a reasonable price).
Well, mate... thing is, there are none for sale in Europe right now, and they only come up once in a blue moon. And you never know if the one that comes up will be the correct one (i.e. made in Japan and with Mitsumi switches). So, I'd rather give you or Hasu the money and get it done.
Also, I don't really care about working PCB, since I want them for spare parts anyhow. Actually, I think Hasu should have the best deals, since there should be lots of non-working Mitsumis in Japan... Not so sure about shipping cost from Japan, though...
On the Shift-Backspace thing... uhm... actually, I think my code can very easily be adapted to provide that kind of functionality, even without a separate layer, since it's checking for Shift events all the time! :D
@Hasu: Taking things from the top, no, I can't think of any other tests I'd have you do. The whole problem is telling apart when the shift key is from a user-press or an automatic calc key, or both!
About the code... well, mate, you already have a separate matrix.c file for M0110, what's the problem in adding some more code in there? It's not like, we're adding code in some 'outside' general file! It's still kept inside the M0110/A bundle.
About the 'instant' vs 'inquire'... I can understand what you're saying. However, I don't know the consequences of over-using 'instant' and pushing the keyboard m/c in sending reports every 10msec or less, when it's supposed to send them once every 200-250msec or so.
Besides, I just use one extra layer, assigned to the switching Caps Lock, so I don't care about timing issues and pressing keys at the same time. Actually, the M0110A has enough keys so that you don't need many layers, since it's got a numpad, arrows etc. Essentially, the only reason you need layers is the F-keys, Escape and... that's about it! :D
/*
Handling for exceptional case of key combinations for M0110A
Shift and Calc/Arrow key could be operated simultaneously:
Case Shift Arrow Events Interpret
-------------------------------------------------------------------
1 Down Down 71, 79, DD Calc(d)*a *b
2 Down Up 71, 79, UU Arrow&Calc(u)*a
3 Up Down F1, 79, DD Shift(u) *c
4 Up Up F1, 79, UU Shift(u) and Arrow&Calc(u)*a
Case Shift Calc Events Interpret
-------------------------------------------------------------------
5(1) Down Down 71, 71, 79, DD Shift(d) and Cacl(d)
6(2) Down Up F1, 71, 79, UU Shift(u) and Arrow&Calc(u)*a
7(1) Up Down F1, 71, 79, DD Shift(u) and Calc(d)
8(4) Up Up F1, F1, 79, UU Shift(ux2) and Arrow&Calc(u)*a
During Calc key is hold:
Case Shift Arrow Events Interpret
-------------------------------------------------------------------
A(3) ---- Down F1, 79, DD Shift(u) *c
B ---- Up 79, UU Arrow&Calc(u)*a
C Down ---- F1, 71 Shift(u) and Shift(d)
D Up ---- F1 Shift(u)
E Hold Down 79, DD Normal
F Hold Up 79, UU Arrow&Calc(u)*a
G(1) Down Down F1, 71, 79, DD Shift(u)*b and Calc(d)*a
H(2) Down Up F1, 71, 79, UU Shift(u) and Arrow&Calc(u)*a
I(3) Up Down F1, F1, 79, DD Shift(ux2) *c
J(4) Up Up F1, 79, UU Shift(u) and Arrow&Calc(u)*a
Case Shift Calc Events Interpret
-------------------------------------------------------------------
K(1) ---- Down 71, 79, DD Calc(d)*a
L(4) ---- Up F1, 79, UU Shift(u) and Arrow&Calc(u)*a
M(1) Hold Down 71, 79, DD Calc(d)*a
N Hold Up 79, UU Arrow&Calc(u)*a
Where DD/UU indicates part of Keypad Down/Up event.
*a: Impossible to distinguish btween Arrow and Calc event.
*b: Shift(d) event is ignored.
*c: Arrow/Calc(d) event is ignored.
*/
Anyhow... the shipping prices are ok, especially the surface. What's that "SAL"? Sounds like "Sent And Lost" to me. :PPaypal is OK. Send a private message to me on GeekHack or GitHub to talk about this further.
So, would you be willing to get a couple of M0110A's for me? How do I pay you back? Paypal?
@YakMN: you can actually make an M0110 keyboard with Mitsumi switches yourself! Just unsolder the switches from one of your As and solder them onto an M0110 board (after you remove the old Alps, of course). Simple! Anyway... if you'd want to part with one or two of your keyboards... and match that Japan price... by all means. ;)
Now I have cursors on a layer, but the delay is a bit weird for me. If I only wanted one layer, and was only ever going to use the capslock key for it, is there a way I can remove the delay? (I mean, delay before the layer kicks in).
#define LAYER_ENTER_DELAY 0
Do you guys ever get situations where the keyboard stops responding? I have to unplug the USB and plug it back in every once in a while. Sometimes, I have to fire up teensy and hit the button on the board so it reloads or reboots or something. Maybe something wrong with my wiring? I didn't do the pullups.
My firmware finally supports M0110A now. Thank you, skagon.fantastic!!!!!!
BTW, did you receive a PM from me?
And fixed the delay of layer switching bug at commit 225de7a, you don't need a work around with latest firmware.
No, iMate supports only ADB not M0110.
slaction,
if you don't mind paying 40$US and shipping fee from Japan(maybe 5-10$), I can work for you.
You will get:
- converter and M0110 cable(Teensy 2.0 & cable with plug)
- no enclosure
- keymap customizing service
- generous 1-month money back guarantee($40) for any reason(You must pay shipping fee for sending back.)
I'm having issues with the converter software seemingly not working with either of my M0110s. The process of building and programming the firmware is pretty simple so I think that I've simply made a soldering error.
It's difficult to get good closeup photos of it, but I tried:
http://i.imgur.com/MkfAsDn.jpg
http://i.imgur.com/BAb73rf.jpg
So I've got the yellow wire hooked up to ground, black to VCC, red to F0 and green to F1. Is this correct? I'm using the Teensy 2.0
Ah, you should use PD0 and PD1 instead of PF0 and PF1.
Pin configuration changed a years ago.
2015/03: Add support for "International"(ISO) keyboard(keymap_intl.c)
2015/07: Update keymap editor(for Rev.1)
Thanks for the reply. You are right it was a hardware problem. I had a lot of tests (i have an oscilloscope or I made some real dirty arduino sketches to test the keyboard) I thought the keyboard was faulty (I stored it almost ten years in a basement) but at the end it was only the ground solder that was bad. So now everything is working super good. The only wierd thing is the upmost left key (£ and `) is not making what it should do it writes < and > instead but no big deal, I'll have a look later to the layout customisation. Anyway, the french layout is instantly recognized.
I decided to put my teensy inside the kbd as there is a lot of room and the teensy is incredibly small so here is a picture :Show Image(http://concombre.org/autre/M0110A_USB.jpg)
THanks again. I just have to figure what to do with this keyboard now. Maybe write a book, it has the feel of an old typewriter... :)
thanks
New keymap editor is available for M0110 converter now. Use new one instead of old in post above.
For M0110:
http://www.tmk-kbd.com/tmk_keyboard/editor/unimap/?m0110_usb
For M0110A:
http://www.tmk-kbd.com/tmk_keyboard/editor/unimap/?m0110_usb_m0110a
Seems like wrong connection? did you try reverse order of wires and swap DATA and CLK or 5V and GND?
Ahh yes it should be between VCC and D0 and VCC and D1. I wasn't thinking. Thanks!
Edit: Yup that was it. Typing on my m0110a right now. :). On to getting my IBM Model F XT to work :))
Is the M0110A firmware compatible with both M0110 and M0110A keyboards? Or do I need different firmware for each?
Needing some help here. I have Hasu's converter, but I wanted the converter inside the case. I removed both telephone Jack's and wired it without success.
My understanding is the wiring should be crossed over, as that's how the adapter was positioned. If that's right and I'm crossing the wires then from the keyboard I should have 1-4, 2-3, 3-2, and 4-1?
How do you jump into bootloader mode? In an ADB converter you just press Magic + Pause key and it goes to bootloader mode.
I've got 3 m0110a boards that I'm restoring and planning to build one of these, I'm fairly handy with a soldering iron but can I check if there are any concerns over compatibility with the different versions of the m0110a that exist?
I've got one USA board with the Alps switches, and two Mitsumi boards one from Japan and one from Malaysia, and just wanted to check if there are any special differences I might have missed?
README FIRST
https://github.com/tmk/tmk_keyboard
https://github.com/tmk/tmk_keyboard/tree/master/converter/adb_usb
and optionally,
https://github.com/tmk/tmk_keyboard/wiki
https://github.com/tmk/tmk_keyboard/labels/NOTE
NEED HELP: Your self-made converter doesn't work?
Don't ask help before placing pull-up resistor and trying solder on J1!
You are cheap and got Pro Micro from unreliable source, instead of Sparkfun? OK, but confirm it has 16MHz crystal. And probably you need to fill solder on jumper J1 to feed keyboard good power supply 5V if you are in trouble and J1 is not soldered yet. See this post (https://geekhack.org/index.php?topic=96236.msg2625899#msg2625899) and schematic (http://cdn.sparkfun.com/datasheets/Dev/Arduino/Boards/Pro_Micro_v13b.pdf).
In most cases your wiring is wrong. Check your wiring yourself again and again, one hundred times! And try swapping wires at your own risk, note that your wiring are already wrong at this point probably :D It won't break your keyboard unless you are extremely unlucky.
Now you need help? OK. If you are not sure about your wiring, post pics of your hardware and wriring this really save our time. Don't save your time by omitting this. Shots of controller side and ADB connector/keyboard side would be helpful. If you edit code post your code. Don't hesitate to show your dirty code! Also output from hid_listen command would be useful to debug hardware and firmware.
[rant]
Many people said they are sure their wiring is fine first but it became clear they failed to do that in the end many times in this thread :( And they often omit pull-up resistor for no reason, you must have it.
Don't take advantage of generosity of kind and helpful members(yes, including me, of course ;))! Their time is more precious than your time, use your time to learn and look into your problem first.
[/rant]
>>>: avrdude -u -c avr109 -p m32u4 -P COM11 -F -U flash:w:"D:\Downloads\m0110_usb_rev2_unimap.hex":a
Connecting to programmer: .
Found programmer: Id = "CATERIN"; type = S
Software Version = 1.0; No Hardware Version given.
Programmer supports auto addr increment.
Programmer supports buffered memory access with buffersize=128 bytes.
Programmer supports the following devices:
Device code: 0x44
avrdude.exe: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% -0.00s
avrdude.exe: Device signature = 0x1e9587 (probably m32u4)
avrdude.exe: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude.exe: erasing chip
avrdude.exe: reading input file "D:\Downloads\m0110_usb_rev2_unimap.hex"
avrdude.exe: input file D:\Downloads\m0110_usb_rev2_unimap.hex auto detected as Intel Hex
avrdude.exe: writing flash (27136 bytes):
Writing | ################################################## | 100% 1.45s
avrdude.exe: 27136 bytes of flash written
avrdude.exe: verifying flash memory against D:\Downloads\m0110_usb_rev2_unimap.hex:
avrdude.exe: load data flash data from input file D:\Downloads\m0110_usb_rev2_unimap.hex:
avrdude.exe: input file D:\Downloads\m0110_usb_rev2_unimap.hex auto detected as Intel Hex
avrdude.exe: input file D:\Downloads\m0110_usb_rev2_unimap.hex contains 27136 bytes
avrdude.exe: reading on-chip flash data:
Reading | ################################################## | 100% 0.18s
avrdude.exe: verifying ...
avrdude.exe: 27136 bytes of flash verified
avrdude.exe done. Thank you.
Waiting for new device:........
Listening:
TMK:ca021a/LUFA:d6a7df
USB configured.
Loop start.
model: 09