 So, part 3 of the keyboard rework. The current state of the keyboard is that I have finished with the bulk of the electronics, the microcontroller works, I've mapped the keyboard matrix, I can sense keys and key presses, I haven't done the software yet to actually turn it into a USB keyboard but that's relatively trivial. Before I do that I actually want to make a few modifications to the keyboard, in particular I want to add more modifier keys. For use as a PC keyboard I really need stuff like a control key and an out key and another layer modifier key, which are actual modifiers and not just key switches. And to do this I'm going to have to make some adjustments, specifically what I want to do is to turn the cap slot key, which is this one, so that instead of simply latching the shift keys, which are these two, it is a modifier key in its own right and I also need to do the same to the repeat key, which is this one, turning that into a standalone modifier key and the code key, which is this one. And while I'm at it I want to hook up the LED to the microcontroller so that I can like, turn it on and off. So what I'm going to do now is do some tracing of tracks and see whether we can actually achieve this. So I'm going to start with the LED, because the LED ought to be relatively straight forward. So let us see what the LED is attached to, tangled wires. So the LED is connected to these two tracks here, which run around the board to here and this one. Yep. I actually cheated, I looked at this earlier. So this one is the resistor that makes the LED work, this one is just a link and so the link is connected to one pin of the logic chip here. The resistor is connected to positive, yeah so the resistor is connected to positive, yep. And the, so this is actually nice and straight forward. All I need to do is to remove this link, solder a wire from here to the microcontroller and then I can activate the LED by simply lowering the line using the built-in resistor for current limitation. So that's easy. The shift and caps lock keys. So I can see from just looking at the board that the caps lock key shares a terminal with the shift key. So this appears to connect, there's a maze of tracks and it goes up here somewhere so the pin 14 here. So what's this one connected to? This is common. So here's the other shift key. So it's common to there as well, in fact the two shift keys are just in parallel. So this connects to, there's a nice fat track here which is useful to grounds, excellent. So that this terminal is grounded, pressing the key will therefore ground the other side. So if I can wire the other terminal of the switches to the microcontroller via a pull-up resistor and I can do that in software in the microcontroller, so that's easy, then I am sorted. So I know the caps lock key goes to here, here and the shift keys go to here. That's straight forward. So I think what I need to do for the caps lock stuff is just remove all this logic circuitry and then just solder direct wires from the left of the holes to the microcontroller. Now I do have one line which is currently used for the shift key, it's the output from all this circuitry which is directed to the connector here. Just pin 19, so 3, 5, 7, 9, 11, 13, 15, 17, 19, this one. So this should be connected here somewhere, this one, yeah. So I can probably just re-use this for the existing shift keys. I did say previously that I wanted to have the two shift keys independent but I think that's now just more effort than it's worth. Let's just keep them in parallel. Now the repeat key and the code key are going to be more complex because they're actually part of the keyboard matrix. So I will need to somehow sever them from the keyboard matrix or do I? That's actually quite hard. For example, you can see that this pad here, there's a track coming in and a track going out. So this is actually connected to this link to this link, I think I've lost track of which track this was. So this link to this link, this one, which then this is connected to a whole bunch of other tracks, etc. So if I just, oh no, I was looking at this one, wasn't I? Yeah, I've lost that. Anyway, if I were to sever these tracks, I would end up severing whatever connection this was and I would take everything else in the keyboard matrix out of the circuit. Yeah, that's connected there and to, yeah, yeah. So I'm going to have to be smart about this. Now I do notice that the other side of this switch, this one, is one directional. So it's connected to the keyboard matrix this way, but not this way. So I, in fact, I could sever it here. This side would continue to be connected to the keyboard matrix, but if this was routed to a pin on the microcontroller, I could still make that work. It depends whether this is a row or a column, because I only probe one of the, so the way the sensing works is there's eight rows and eight columns. I energize each of the rows in one at a time and then look at columns to see which one are high. So if this is a row, then I, if I route this to the microcontroller in its own line, then I can sense when the key is pressed without interference from any other keys, which is what I need for a modify key. So what is this attached to? That's two, four, six, eight, two, four, six, eight, ten, twelve, fourteen, sixteen, eighteen. That is, I believe, that's a row, maybe, that's P. Yeah, I forgot to note down on my cheat sheet which lines were the rows and which were the columns actually. So let's just pretend that's a row for now. What about the other one? Just repeat here. So again I see that this pad is common, here, here, here, here, here, but this side is again one directional, so I can sever that, which is connected to. One, three, five, seven, nine. That is, that is K on my chart, which may be a column. So that's kind of problematic. No, it's not, no that's just right, because that means this side, this one must be a row. Two, four, six, eight, ten, twelve, fourteen, sixteen, sixteen is a column. Yeah, I'm not sure that will work. I can probably remap it all in software. OK, I'm going to have to go and check the actual firmware and like annotate my chart again, but let's do the caps lock and LED now. So I want to remove all this logic here. It's just completely surplus to requirements and having random capacitors and resistors and gates and stuff. It's just going to be a mess. So I'm going to use my desoldering tool for that, which will need a little bit of setup. OK, the tool should be hot now. So let's try with this link here. That's not particularly hot. It's not hot at all. Smells hot. It's not like I should really be adding solder to this to see. Does it just not like that metal wire? Hmm. OK, that one worked. I think it's just taking a long time to heat up. OK, so that has removed some of the solder, but not all. Let's see if we can get that link out. I'm starting with this because it's just a piece of wire and it's trivially replaceable. Yeah, that hasn't actually worked terribly well. I need to be a little bit more, a little bit rougher with this, I think. So of all the circuitry here, this is the resistor for the LED and all the rest of it is mysterious stuff. What I don't know what it does. It'll be all part of the caps lock latching mechanism. Not sure why there's a diode there, actually. Yeah, what's that connected to? This is a resistor. A, yeah, I don't need any of this. Just remove it all. Trying to avoid melting the other thing's strap. It worked really quite well. I'm impressed. OK, let's go for these three resistors here. I've yet to see any solder come out of this thing. I don't know where it goes. It was supplied with this tool for doing something, but it never seems to get blocked up. These will probably, they go into the salvage drawer for use elsewhere, but they are like 30 years old. So I'm not really sure I want to use them for anything. At the same time, I don't really want to just throw them away. OK, that was nice and clean. Oh, I'm so glad I got this. A nose desoldering. You get ones with powered pumps, which are even better. They are, of course, more expensive. That this, you know, this works just fine. Now, this is a Quad-Nand gate. So this one may actually be worth keeping. Now, is that going to come off? Still a little bit of salt in some of these legs. To be honest, I don't need any of this logic. I can just use the microcontroller for us instead. So it's just simpler not to have it, not to have it getting in the way. That's being less cooperative than I like. It's got nearly all the solder out of the joints, but there's just a little bit of traces. The pins on this side have got a bit. Yeah, even with this is slow, but it's doable. And with my soldering skills, yeah, that's brilliant. And it's even reasonably intact. That's probably usable. And with my soldering skills, without the solder sucker, that would have been a nightmare. OK, so a bit more work there. Let's try the big electrolytic here. Yeah, when this gets cool, I should dismantle the tip of this thing, try and figure out where all the solder's going. I expect it's all getting gunked up inside. And I should remove it. So nice, useful. Oh, so this row, these ones are negative, and these ones are positive. So if I ever want to put more electronics on, this gives me a nice set of rows with big fat tracks where I can get power. Don't think I ever will. Pull off. That's brilliant. Some of them are quite warm. This one needs a bit of help. Ouch, that was really quite warm. Yeah, I have no idea whether these are worth keeping. I don't actually have any of these little ceramic caps. So that's all the logic removed, all I need now is some wires. Right, I don't need the solder sucker anymore, so I need to turn it off and put it somewhere safe to cool because I only have one soldering stand. OK, time to solder some more stuff on. But first, let's double-check the sum of the connections. So the LED is going to start with that one. We want it to go, yeah, and that. Right, so we're going to solder a wire from here to the microcontroller. Here is a wire. The wire pushed through the board while I was soldering it. That should be easily fixable, what I can do without burning myself. And we're going to put that onto O4 here. That is a line with a capacitor on it, but this is an output LED, so we don't actually care. Let's cut that here, drip the end. Yeah, this wire is thicker than this stuff. And the wire stripper tool is actually working on this. There's a bulge in the end of the wire, and it's not going through the tiny hole. I don't want to apply too much heat to microcontroller boards because it is like full of components. There we go. Let's apply a little bit of fresh solder to this side. Right, OK, that should be the LED dealt with. Next, I want the caps lock or the control key, really. You seem to recall that this was ground. Yeah, so this is connected to pin 14 here. So again, we're going to run a wire from there to the microcontroller. There is, in fact, a solder bridge to two of these tracks. I don't think it matters, given they're not connected to anything, but double-check that pin. Of course, yeah, it is 14. Because the other side of the cap slot is ground, so I will need a pull-up resistor or a not gate in order to identify, in order to sense that. Now that one, this one, this one. And again, that's going to go to one of the pins with a capacitor on it. I'm not doing high-speed probing, so the delay caused by the capacitor is not actually an issue here. This is all happening at human speed. So you press the key, you release the key. And I'm slightly running out of pins, so I want to save the raw GPIO pins for anything in the future, which might actually need them. Beautiful. OK, that's done. I now have my caps lock key, or, as there's really called, the control key. OK, now let's think about these pads. I think that my main constraint is the geometry of the board. So I'm going to have to work with whatever's on the board and then rework things and software. I can always swap rows and columns if necessary. I mean, there's nothing on the board that identifies a row and a column. I just picked them randomly. The key switches are connected up in a grid like this. So it doesn't really matter which one I apply power to, as long as I sense the other one. Now, the other thing I do need to be careful of is the key switches, the big black plastic blocks, which cover most of the track. And these links here go in the gaps between the key switches. So I need to be very careful where I solder wires. Now, I spot there's a hole here, which is great, because I can put a wire through that hole and solder it up here somewhere. There's a big gap between the key switches, like so. So I think that if I cut the track, say here, and then the wire can come up here and solder on about here-ish, it should work. Now, to cut the track, I actually just need to scrape through this. This is not a good experience at all. Some sort of milling tool would be ideal. You know, I actually got a Dremel, which I've barely used. I wonder if that would work better. Yeah, I'm also getting grease all over these contact pads, so I'm gonna have to clean it again once I'm done. Yeah, this is a strip. This is an old PCB, and I think the tracks are pretty thick. I think I'm straight, actually. Yeah, I am through, but it's not... Like, it's still an electrical connection. It's gonna need a lot more scraping than that. It is actually broken, but I'm not happy. I'm going to go look for tools. Okay, let's give the Dremel a try. Perfect, nice big gap. I'm quite sure there's no electrical conductivity there. Good, good. Right, so I also want to burnish a little bit of just to get the solder mask off. That will give me something to solder on to, and we get a little bit of flux. The sacrificial piece of wire to poke with. So now we need more wire, tin the end, and we're also going to tin this, it's in flux. That hasn't actually spread the way I thought it would, so let's just check for conductivity. Let's think that's fine. So the wire through the hole, like so. It's flat over the joint, like so, and we hold it down with a pointy thing and just retract it a little, try it to there. So, perfect, completely professional and without floor in any way. And the other end goes to the microcontroller board. Before we put that on, I just want to check that I did, in fact, leave enough clearance. Pretty sure that I did, but yeah, I think that's fine. So this is going to go into the third of those three capacitor holes. So we want about that much wire. Strip, tin, that's not a brilliant joint. So I should now be able to get a decent electrical connection between. I'm terrible with knots except accidentally. Try to, okay, that works. And I don't have connection here, good. Right, I think that's good. So that is the code key, which is going to be a layer modifier to allow me to do stuff like cursor keys that the keyboard doesn't normally have. The other one is this one, which is going to be a out key. Now, this is a little bit trickier, but you wanted to use this pad. We're going to separate this pad from the matrix. The problem is that this pad is actually, doesn't have as big a spare area. So we can sever it about here. See the track actually runs. Oh, that's interesting. It connects to here. So this is actually a T. The track connects to this pin, which then goes up via this link here, et cetera, and also down this way, and this is this one, and this way. So we actually need to sever it between this pin and here. So it's going to be here somewhere. So our wire is going to have to come out of this hole and connect on just here because the black plastic key switch box is going to come down over the key. And in fact, there's actually a decent amount of space there. So it comes about here, so we can use all this stuff. Okay, that's doable. So that should have cut the track. I believe that has cut the track. It has indeed cut the track. So we now need to burnish here. Could probably go a little bit deeper, but I think that will do. And the flux, that's a lot of flux. Luckily, you can never have too much flux. Okay. And wire time. We should probably use some more green, but yeah. So the wire comes through the hole and it falls down over the mix-o and we got a joint. Probably. Okay, now this one. Is going to go to another pin that I know has a capacitor on it. It's another modifier key, which is 3.2. At least with these pins, I know that there is only one surprise. There is a possibility that the key coming up, it will remain energized for a bit before it's red, but I don't believe that's going to be an actual problem with these, because the reason for these having their own dedicated lines is to avoid crosstalk. And that's a reasonable joint. Okay, that's done. As always, let me just check that with the beeper. Okay, so what is left for me to do now is to clean it all with alcohol, reasonably thoroughly. Reassemble it and work on the phone, where I suppose. So you've got code, we've got repeat, you've got caps lock, the shift keys are separate, the LED is separate, a little bit of trimming. And I think that is it. Okay, so I'm just going to go and get some alcohol and clean it. Okay, there may be some ambient noise as I've opened the door to the outside. As I don't really want to, you know, pass out from absolute alcohol fumes. This stuff is distinctly aromatic. I don't know if IPA counts as a vock. And so, asking out on video, while it might be funny, I would probably collapse onto the board and break it. I need to check up to see whether you can clean the carbon pads with alcohol as well, because I think they're not in great shape. When I was a teenager, I had access to a Commodore PET. It had a decent keyboard, except the keyboard just stopped working one day. And eventually took the thing off and took the thing apart and discovered that the, the conductive rubber member, the conductive rubber pads on the bottom of the key switches had glazed with age and were no longer conductive. I cleaned the door with switch cleaner and it worked beautifully for about a week and then stopped working again. Okay, that wasn't so bad. Got a lot of spare alcohol there. I don't think anything else needs cleaning. So we wait a few moments for the alcohol to evaporate, a bit left up here, and then reassemble it. And then it's back to the firmware, which all have to happen offline because, you know, firmware. One reassembled keyboard. So now it's back to the firmware. That'll all have to happen offline. I'll be back hopefully with just one further video where I demonstrated all working, possibly two if I decided to demonstrate it in a box at the same time. But if you've been watching, I hope you enjoyed this video. Please let me know what you think in the comments. And I will see you next time.