How is digital data represented in analog waves?

If you want to know how 'A' from from keyboard via Bluetooth to your computer starting from 1s and 0s on an analogue wave, then it's far too complicated for any person to think about all at once.

So we divide it into layers. Each layer uses the services of the layer below, and provides services for the layer above. This allows us to concentrate on just a few simple problems at a time.

The lowest layer is called the physical layer. This handles the radio signal. Start with wikipedia, and look up, in this order, simplest to more complex, Amplitude-shift_keying, Frequency-shift_keying, Quadrature_amplitude_modulation. We rarely use ASK, it's too inefficient. There are more modulation types, more efficient and much more complicated than QAM, but those three will do to get your started.

The highest layers are the applications in the keyboard and computer. The keyboard app asks the layer below to 'send 'A' to a machine with this identity', which happens to be your computer. That layer then calls a lower layer, which resolves the identity to an address, formats the message, and eventually the data trickles down to the physical layer and becomes variations on an RF carrier.

There's a whole bunch of layers in between that handle the connection, know about identities, get messages resent if parts are missing or garbled, and a whole lot more. Have a look at OSI Model or the TCP/IP stack if you want an idea of all the stuff that can happen in between, but don't expect to understand it or the need for it at a first reading.


There are quite a few basic ways to do it. Important ones include:

The earliest radio systems used pulse-width modulation on some carrier frequency (possibly just the natural resonant frequency of the antenna), broadcasting short and long pulses in the dot-dash code of Samuel Morse. This turns the carrier signal abruptly on and off, which causes problems in high-power applications, so the next two are continuous-power systems.

Frequency modulation is common; broadcasting the 1s on one frequency and the 0s on another. This was used by the original line modems, by the first Bluetooth standard and by GSM "2G" mobiles and several subsequent standards, for example.

Phase-shifting is also used, in which the timing of the pulses carries the data, with 0s and 1s having a different fractional delay or phase shift in the signal. This is available in later Bluetooth standards.

In all of the above, the pulses are overlaid on a carrier signal whose frequency, according to Shannon's law, must be at least twice the data rate and is often considerably higher.

In spread-spectrum systems there is no identifiable carrier frequency, i.e. no specific analogue wave as such. Instead a fast train of varying-width square-wave pulses is broadcast directly. Encoding systems can vary, but typically the pulse width represents a 0 or a 1, as with Morse code. This varying signal is inherently spread over a range or spectrum of (analogue) frequencies. This is used by CDMA 3G and 4G mobile systems, in which the data is overlaid on a pseudorandom pulse train and is allowed to mix with other signals on the airwaves. It then gets decoded at the other end to identify both the sender and the data.

Each of these has a myriad complications and variations.