geekhack
geekhack Projects => Making Stuff Together! => Topic started by: cactusplants on Fri, 08 July 2016, 08:49:34
-
Hello. I've been asking around and I can't seem to find any way to solve my issues.
I've built a hand wired board and I'm using TMK w/ a teeny 2.0. My macbook will recognise the keyboard and will function. The spacebar and the capslock keys wont function and my "#" when pressed writes "\". When I connect the board to my windows 8.1 desktop, the keyboard does not type. It will only type "á".
Here are some photos and links to the pastebin containing my files for the KB.
Here are some photos of the underside and topside...
http://imgur.com/a/Ulcbh
And the code...
Keymap_poker.c
http://pastebin.com/T4kLEcM4
Keymap_common.h
http://pastebin.com/dfBZZMjW
matrix.c
http://pastebin.com/P7Z0dmc4
I'd really appriciate some help as I really want to get and use the glorious cherry switches. This rubber dome is killing me.
-
Couple of things I can see:
* Your keymap definition does not match the #define - the number of keys in each rows needs checking
* K4C. has a dot, not comma in the #define
* Your read_cols is ordered a bit funny (not really a functional problem, just my OCD)
* The #define uses k46 (lowercase K) for space, and KC_##46 (missing K)
* I cant see a caps lock - where it is usually is mapped to Left Ctrl
-
Couple of things I can see:
* Your keymap definition does not match the #define - the number of keys in each rows needs checking
* K4C. has a dot, not comma in the #define
* Your read_cols is ordered a bit funny (not really a functional problem, just my OCD)
* The #define uses k46 (lowercase K) for space, and KC_##46 (missing K)
* I cant see a caps lock - where it is usually is mapped to Left Ctrl
Sorry for the noob mistakes. I'm not a avid coder to be honest.
That solved most of the problems, but It still does refuse to work on the windows PC. I can type more or less freely. I forgot to re-flash the teensy with the correction of the caps though. But the caps key just creates havock. Half of the keys cease to function.
But in all honesty, working on the windows desktop is my main requirement, I just have no clue as to why it works.
-
I thought diodes weren't neccessary unless you had LED's?
-
I thought diodes weren't neccessary unless you had LED's?
Nope. The LED's do use a diode but a different one. The ones used for the switches allow for the controller to determine which row/colum the switches are on. Otherwise it would have no idea as to what switch is being pressed.
-
Are you including led.c in your make file? led.c in the gh60 folder assigns a caps lock status LED to B2, which is in your matrix.
-
the # problem is most likely the language you have on your pc. if you change it between english USA and english UK you will notice some keys are located other places.
-
the # problem is most likely the language you have on your pc. if you change it between english USA and english UK you will notice some keys are located other places.
I tried that, and it did not help. The keyboard continued to write "wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww" when no keys were pressed, I then plugged into the macbook and it works fine.
-
oh, maybe you compiled it on your macbook with mac compiler software which would make your keyboard not work on windows?
-Aran
-
It won't matter where it compiles as the output has to be the same or the program won't run on the Teensy. The codes sent by the keyboard are the same regardless of what OS is on the other end - I can't think of any way for it to behave differently on Mac vs Windows.
Have you ran Switch Hitter (https://elitekeyboards.com/switchhitter.php) to see what key(s) Windows thinks are pressed?
-
It won't matter where it compiles as the output has to be the same or the program won't run on the Teensy. The codes sent by the keyboard are the same regardless of what OS is on the other end - I can't think of any way for it to behave differently on Mac vs Windows.
Have you ran Switch Hitter (https://elitekeyboards.com/switchhitter.php) to see what key(s) Windows thinks are pressed?
Well, what has happened...
I ran switch hitter, and here is the log
49:44.0847 2 (0x32, BIOS 0x03) DOWN
49:44.0877 W (0x57, BIOS 0x11) DOWN
49:44.0894 S (0x53, BIOS 0x1F) DOWN
49:44.0902 Z (0x5A, BIOS 0x2C) DOWN
The rest of the keys work apart from the tab key and my right menu key. Again, plugged into the mac and it still works fine. I can't see any shorts and the connections seem sound.
-
That output looks like you've got a short causing the whole column to be pressed, but that should happen on both machines...
-
That output looks like you've got a short causing the whole column to be pressed, but that should happen on both machines...
Thats the reason I was ruling out a short. I've not got a Multi m handy, but I can't see any wires touching one another. When I had the board plugged in I was touching it with my finger, and when I touched the column 2 it would have an effect. I'll swap out the switch and diode as the switches are salvaged and there might be a bit of an issue with that. I'll report back one I get home from work as I've got to dash.
-
Are you including led.c in your make file? led.c in the gh60 folder assigns a caps lock status LED to B2, which is in your matrix.
Is the problem column connected to B2?
-
yeah, make sure your teensy pins correspond with the numbers on your code. like when i made my ADB converter for my first teensy project, i had the pin soldered in the wrong pin without changing the code which resulted in my mouse cursor flying everywhere. check for solder bridges etc.
-
Are you including led.c in your make file? led.c in the gh60 folder assigns a caps lock status LED to B2, which is in your matrix.
Is the problem column connected to B2?
Yes, it was. I skipped the LED stuff as I've no leds. I changed the code to output from a different pin and now im typing on this keyboard!
Still need to fix the stabiliser problem. As its hand wired, my board plate only accepts PCB mounted stabs, so my spacing is killing me as it doesn't register half of the time. Also I am noticing a lot of double characters. Is that just a result in habit when coming from rubber domes to say, cherry mx browns? Or is it a software issue?
you guys are the best!
-
Glad to hear it works!
If you handwire you need plate mounted stabs, not PCB mount. Or enablers (http://techkeys.us/collections/accessories/products/the-enabler) :)
-
Glad to hear it works!
If you handwire you need plate mounted stabs, not PCB mount. Or enablers (http://techkeys.us/collections/accessories/products/the-enabler) :)
It would have still been sitting there if it weren't for you guys.
I've got filco plate mounted and cherry plate mounted stabs, but the plate i bought on mass drop is pretty naff and the cutouts are too big to allow plate mount. The enabler looks amazing. I guess if I buy a few PCB mount stabs, I can use them with the enablers Correct?
-
Glad to hear it works!
If you handwire you need plate mounted stabs, not PCB mount. Or enablers (http://techkeys.us/collections/accessories/products/the-enabler) :)
It would have still been sitting there if it weren't for you guys.
I've got filco plate mounted and cherry plate mounted stabs, but the plate i bought on mass drop is pretty naff and the cutouts are too big to allow plate mount. The enabler looks amazing. I guess if I buy a few PCB mount stabs, I can use them with the enablers Correct?
Yup :)
-
Glad to hear it works!
If you handwire you need plate mounted stabs, not PCB mount. Or enablers (http://techkeys.us/collections/accessories/products/the-enabler) :)
It would have still been sitting there if it weren't for you guys.
I've got filco plate mounted and cherry plate mounted stabs, but the plate i bought on mass drop is pretty naff and the cutouts are too big to allow plate mount. The enabler looks amazing. I guess if I buy a few PCB mount stabs, I can use them with the enablers Correct?
Yup :)
That is great. I've got a silly armature question... What enablers do I buy? I've got a ISO enter key as well as a standard spacebar and a right standard shift that all wobble too much....
-
I've got a silly armature question... What enablers do I buy? I've got a ISO enter key as well as a standard spacebar and a right standard shift that all wobble too much....
The number is how many standard keys wide the key you're stabilising is, but for smaller keys (not spacebars) if you look you'll see the spaces between the stab mounts are the same so they are all 2x. A standard spacebar is either 6.25x or 7x which is why they are both available but from your pic yours is a 6.25 :thumb: