how do commands on a screen direct electrical currents in a computer?

203 views

I’m not asking what computer code is. I’m asking how typing in commands physically opens/closes the little switches in computers?

In: 2

7 Answers

Anonymous 0 Comments

A “switch” in a computer is a tiny piece of semiconducting silicone, with a few connections running to and from it. The “semiconductor” part is important: give it little bit of electrical nudge and it will conduct. Nudge it the other way and it won’t conduct. Voila! We have a switch which we can control electronically.

We can arrange a number of these switches into a slightly more complicated switch which takes two input signals rather than one, and it will set the switch to ON if (and only if) the inputs are not both ON.

And we can arrange a number of *those* little circuits to do all manner of wonderful things.

One thing we can do is to store the ON or OFF state of a tiny little circuit. Put a bunch of those little tykes next to each other and you can store a binary number, the 0’s and 1’s you asked about. Next to those switches which represent the number will be *more* groups of switches which do something with that number. In some areas of the chip ww treat the number as a value. In others, we treat it as an instruction. The particular combination of ON/OFF values of the switches (the 0’s and 1’s) will activate a specific set of switches, and that specific set of switches will cause a bunch of *other* switches to fire, and the end result will be that the particular instruction corresponding to that binary number has been executed.

Sooooo… you type a ‘1’ on the keyboard. Pressing the key closes a bunch of switches inside the keyboard, sending a particular set of voltages (ONs and OFFs) to the computer. To the computer, they cause a “keyboard interrupt” signal, which says there’s new info from the keyboard, and an arrangement of ONs and OFFs to tell the computer which key was pressed. Somewhere some switches are hooked together in such a way as to say “if you’re not in the middle of something uninterruptable, route the value on the keyboard input to the appropriate place”.

Hope this helps.

You are viewing 1 out of 7 answers, click here to view all answers.