You might not think it, but basic computer
keyboards have a surprisingly impressive amount of engineering inside. We’re not
talking about incredible engineering like a rocket that can land itself or a
stealth aircraft that can evade radar; rather, we’re talking about the engineering of
cost reduction. Specifically, this keyboard has only 8 critical parts inside, essentially removing
all the components’ costs so that you can buy them in bulk for as little as 1 dollar and 57 cents
each! Engineering something that is durable, functional, and costing next to nothing is
indeed a feat on its own. So, let’s look inside this dirt-cheap keyboard and see how only a few
critical components enables it to work. After that we’ll open a mechanical keyboard that costs over
50 times as much and see the difference as well as find out what causes that clicking sound inside
the mechanical keys. So, let’s jump right in. This inexpensive keyboard is assembled from 148
parts, and almost all the parts are the keys, screws, and the top and bottom plastic casing,
leaving us only 8 critical parts inside. These components are a rubber sheet with domes under
each key and three plastic sheets. The top and bottom sheets have conductive wires printed
onto them, with dots under each key, and the middle sheet acts as a spacer with holes cut out
of it. The remaining 4 components are 2 batteries, a bracket to clamp down the plastic sheets,
and a small printed circuit board which has a simple microprocessor, a crystal oscillator,
a switch, a 2.4 gigahertz planar antenna, a pair of wires to connect to the batteries, and
a set of conductive lines to connect to the wires printed on the top and bottom plastic sheets.
So now that we’ve seen the few components inside, how do they work? Well, the main idea is that
the batteries and microprocessor apply 3 volts to all the traces on the bottom sheet, while
all the traces on the top sheet are actively being monitored by the processor on the PCB. When
a key is pressed, it presses on the rubber dome, which pushes the conductive circle from the top
sheet down through the air gap created by the middle sheet and into the circle on the bottom
sheet, thereby bridging the connection between top and bottom plastic sheets. The 3 volts then
travels along the conductive trace of the bottom sheet through the hole of the key that has been
pressed, and into the top sheet’s trace, and then returns back to the PCB and microprocessor where
it’s sensed. When you let your finger off the key, the rubber dome returns the key to the un-pressed
position thereby opening the connection. On the top sheet of plastic are 12 traces
and on the bottom sheet are 11 traces, with each trace traveling to a different set of
keys. It’s visually hard to see here, so let’s reorganize these traces into a grid, also called
a keyboard matrix, with the bottom traces forming the columns and the top traces forming the rows.
Just as before the microprocessor outputs 3 volts along each column while actively monitoring the
in-puts along each row. With this reorganization, you can more easily see that, as you press the
Y key, 3 volts is sent out along the 4th column, and returned along the 2nd row, and thus the
processor can tell that the Y key was pressed. Or with the B key, 3 volts is output along
the 8th column, and input through the 1st row. With 11 columns and 12 rows, we can have
a maximum of 132 keys, which works out well, because the keyboard has only 111 keys.
However, if you haven’t noticed, there’s actually a major problem with this keyboard
matrix. That is: if we have 3 volts running along all these columns and we press a key, 3
volts will return along a row. However, because each of these columns output the same 3 volts, how
do we know which key in the row was pressed? Well, there are a few solutions to this problem. One
solution is to quickly scan 3 volts along each of the 11 columns, so that at any given time
only one column is active. By correlating the active column with when voltage is received on the
input row, we can determine the exact intersection of column and row and thus which key is pressed.
However, with this solution, we’re continuously scanning 3 volts across the columns, which takes
power thereby draining the batteries. So instead, we found that it’s more practical to have 3 volts
on each column, and when a key is pressed, a cycle of pulses of turning off one column at a time is
sent to determine which key in a row is pressed. These pulses are sent for 65 microseconds to each
column, once every 4 milliseconds. Therefore, if the G key were pressed, then the 3rd row would see
an input that looks like this. Whereas if the T, L, and A key were pressed, then the 2nd and 6th
row inputs would see a voltage that looks like this, and all the other rows would see nothing.
Now that the microprocessor knows which keys are pressed, it sends the data to the 2.4 gigahertz
transceiver using these printed planar antennas. We’ll cover these antennas as well as the
oscillator in another video, but for now let’s close this inexpensive keyboard and look inside a
mechanical keyboard that costs over 50 times more. But before exploring mechanical keyboards,
the next portion of this video is sponsored by Keysight’s virtual event, Keysight World:
Live from the Lab. In this livestream, Keysight will be exploring batteries, DC to DC converters,
and a wide range of IoT devices through hands-on design analysis and Q and A sessions with industry
experts. Sign up quickly because the next Keysight Live event is May 16th, and by attending this live
stream you’ll be entered to win an oscilloscope in their test gear giveaway. In fact, the only way
we were able to reverse engineer this keyboard was with an oscilloscope just like this one, where
we could easily see the cycling of OFF pulses whenever a key is pressed. At Keysight’s upcoming
Live from the Lab event, you’ll learn many useful tools such as how temperature can affect battery
and device life as well as techniques and tricks for using DC to DC converters in your designs.
Whether you’re an expert engineer or electronics newbie, there’ll be plenty of opportunities to
learn new things. Hurry up and register for the May 16th Keysight World livestream using
the Branch Education link, and you’ll get an extra entry into Keysight’s huge test gear
giveaway. Go check it out! But now let’s get back to the inside of this mechanical keyboard.
Instead of seeing plastic sheets, we find a rather large, printed circuit board, with mechanical keys
soldered to it. This PCB functions similarly to the keyboard matrix, but now we have an LED under
each key to create attractive designs. However, quite noticeable with the mechanical keyboard
is that these keys have a different tactile feel and make a clicking sound when pressed.
So, let’s look inside one of these keys where we find a keycap on top, the stem and slider
below that, a top and bottom switch housing, and inside are a spring and two metal
contacts which are also called metal contact leaves or gold crosspoint contacts.
The main mechanism is that when you press a key down, it moves the stem and slider. The
slider is uniquely shaped such that it pushes one of the contacts away from the other, and, when
pressed down, the slider moves out of the way, allowing for one of the metal contacts to spring
outwards and hit the other, thus creating a connection between the two pieces of metal and
causing a click sound when they hit. When you release the key, the spring pushes the slider,
the stem, and key back up and the slider reengages the metal contact, thus separating the two metal
contacts and opening the connection between them. The stem and slider are separate components, so
that if you accidentally brush a key, the keycap and stem can travel a small distance down before
the slider is engaged. However, once the slider is pushed a frac-tion of a millimeter down, the metal
contact quickly forces the slider to jump out of the way allowing the metal contacts to engage.
By having such a mechanism, each key has a more tactile feel when pressed, different from
the key hitting the rubber dome. That said, having a large PCB such as this, as well as an
intricate mechanism inside each key, causes this keyboard to be significantly more expensive, but
depending on your preferences, it can be worth it. Finally, there are laptop keyboards which
have a scissor switch mechanism along with rubber domes to allow it to have a lower
profile, but let’s wrap it up for now. This topic is moderately simple, but we think
it properly highlights the cost difference and engineering in two similar items. We’re working on
more videos that dive deeper into the engineering inside computer architecture and other complex
technologies, so be sure to subscribe, hit that like button, and share this video with others.
We believe the future will require a strong emphasis on engineering education and we’re
thankful to all our Patreon and YouTube Membership Sponsors for supporting this dream. If you want
to support us on YouTube Memberships, or Patreon, you can find the links in the description.
This is Branch Education, and we create 3D animations that dive deeply into the technology
that drives our modern world. Watch another Branch video by clicking one of these cards or click
here to subscribe. Thanks for watching to the end!