How are the many signals of a N64 or Wii joystick sent to the console by only 2 wires?

So the Wii Joystick uses a Blue Tooth interface which is a little different than the N64 controller. As a result this answer deals more with the latter than the former.


The N64 controller uses a single transmission wire on which it encodes bits to send signals back to the N64 console. To accomplish this bits are encoded on that wire as follows:

alt text

This encoding can then be used to multiplex the connection and allow 32 bit communication. In the case of the N64 controller these bits are encoded thus:

0   A
1   B
2   Z
3   Start
4   Directional Up
5   Directional Down
6   Directional Left
7   Directional Right
8   unknown (always 0)
9   unknown (always 0)
10  L
11  R
12  C Up
13  C Down
14  C Left
15  C Right

With the remaining 16 bits being used for the Analog Joystick (providing 8 degrees of control).

More over, certain codes are transmitted for specialized function:

To Init: send 03 80 01 followed by 34 80's
To Start Rumble: 03 c0 1b followed by 32 01's
To Stop Rumble: 03 c0 1b followed by 32 00's

You can find more information in this vein here


I'm not sure if this is on-topic or not, but digital devices like joysticks send a digital signal by constantly changing the voltage in the wire from ON (usually 5V) to OFF and back at a certain time interval.

A sequence of on/off values like this is interpreted as a bunch of bytes which have some kind of meaning to the device. For instance (totally invented example), pressing A might send "off off off off on on on on", which is the number 15 in binary. The console would know that "15" is a code meaning "A button was pressed".

This all happens so fast that it seems instantaneous.