THE FOOD OF LOVE
Sample a byte of music...
After five years of joystick-bashing, the micro industry is breeding a new hobby. Cheap interfaces can now convert the Spectrum and other home computers into digital sound recorders — synthesizers that can convincingly mimic real sounds.
Once a sound has been read into a computer you can manipulate it with software in a virtually infinite number of ways. The results are immediate and repeatable. You don’t have to scrape strings, spit in tubes, or bash more than one key at a time.
Anyone who can hum or tap a pencil can make micro music, step by step. The only requirement is perseverance — you just keep fiddling till you get something you like.
Incidentally, we’re talking about precise digital recording here — not the buzz and beep of primitive organ chips like the AY-8912 in a Spectrum 128K, but controlled replay of almost any sound you can find in the real world.
A decade ago this was virtually impossible. When the Spectrum was launched the musical equipment which today is common at £25–£50 cost tens of thousands.
Music has (dare I say it?) more general appeal and more creative potential than arcade reaction games or the interactive fiction of computer adventures.
But the vast majority of the millions of people interested in music take a passive role. They have creative ideas, but most can’t express them because they lack the physical technique.
They’re drumming on their steering wheels or tapping their desk with a biro, because they can’t work the complicated, unergonomic, unforgiving old technology of music — the piano keyboard, instrument valves, mouthpieces, pedals and so on — or they can’t work them quickly and accurately enough to get the result they want.
New machines such as sound samplers are solving that problem. In principle these gadgets are cheaper and more flexible than conventional musical machinery, and anyone with ideas can express them after a process of successive approximations.
Some knowledge of music is useful, but it just takes a little playing around to pick up enough to be satisfied by what you’re doing. All that’s needed is time, a tape recorder and a Spectrum with a cheap interface.
A sound sampler is unlikely to turn you into a pop star, but it’s a brilliant open-ended toy.
Two principles are at the core of this revolution: the first is digital recording, or sound sampling. (The other is step-time — discussed later.)
Any sound can be represented as a wave — a fluctuation of air pressure. Microphones detect these waves, and convert them into changing currents. Loudspeakers convert currents back into waves.
A digital recorder consists of a conventional computer, with a processor and memory, plus two extra parts.
An analogue-to-digital converter measures the intensity of a fluctuating current, many times a second, under program control. The resultant stream of numbers is stored in computer memory.
A digital-to-analogue converter changes numbers back into current, which can be amplified and played through a loudspeaker — reproducing the original sound.
The quality of this process depends upon two things — the rate at which you test and store the input, and the accuracy with which you measure it.
A compact-disc (CD) player uses 44,100 measurements every second, fitting each ‘sample’ on a linear scale of 65,536 possible volumes.
Spectrum samplers use a similar sampling rate to CD, but are less precise. Exact speeds vary, but all the units reviewed in this article are 8-bit ones that recognise a range of 256 possible volumes.
The restricted range saves memory and makes hardware and software much simpler. As long as you adjust the recording level to make sure that the input signal uses most of the available range, the quality is quite good — comparable with a portable cassette or AM radio. Indeed, 8-bit devices are still sometimes used in recording studios.
If a signal attempts to go outside the allowed range the limits of the wave are cut off, using clipping — the sort of distortion you hear when you overdrive an amplifier.
If the signal is too weak you will hear quantisation noise — a crackling sound during quiet passages, caused by inaccurate conversion of the original signal.
It’s simple to arrange software to play back sounds at different speeds; this has the effect of shifting them up and down the musical scale. Once a sound, or ‘sample’, is in memory, it can be edited, reversed, mixed (by simple arithmetic) and manipulated in almost any way.
The memory capacity of small computers limits the duration of sound that can be recorded, but short spoken phrases, percussion noises and most keyboards sounds will fit into a home micro, from which they can be replayed in hundreds of different ways.
The CRASH Tech Tape includes a small program, ZX-FX, which shows how easy it is to process sounds with a computer. ZX-FX works with any Spectrum sampler, and demonstrates three simple, adjustable effects — echo, vibrato and a noise gate, which only passes sounds above a certain level, cutting out background hums and buzzes.
And ZX-FX uses a neat trick to avoid clipping and quantisation noise. If the level sample stays at either end of the allowed range, indicating an overload, ZX-FX puts coloured bars in the border of the screen. Slight overloads put rare flecks of colour in the border, and severe clipping is indicated by a flood of colour.
Thus you get a visual display of the proportion of distortion being added. This is very useful when you’re busy recording something, mixing in effects to build up the sound.
You can set things up quickly by sending the loudest signal you plan to use and adjusting the level to give a very small amount of colour in the border. On an 8-bit system it may be better to accept a little clipping than to guess at a lower level; unless you’re careful, quiet sounds can easily be crunched by quantisation noise just when the distortion is most obvious.
Sound processing programs must be written in machine code — they need to go very quickly and smoothly, so that lots of separate samples merge into a convincing continuous sound. But the programs can be very short — 15 or 20 lines is enough to get interesting effects. The machine-code part of ZX-FX is written in REMs in the program, so it’s easy to see how it works.
When you start to use ZX-FX it asks you to enter the port numbers your interface uses for triggering, input and output. The program works with any 8-bit sampler that uses port numbers between 0 and 255, so you can use it with almost any sampler on the market, including all those documented in the table of port details.
ZX-FX should also work with the other designs which have been published as magazine projects in the last few years. The quality of the results will depend on the filters in the sampler and their interaction with this software — so experiment!
A small micro can work fast enough to generate echoes and other effects in ‘real time’ — the effect is produced as the original sound is made. But anyone who has struggled to play an entire tune in perfect time and pitch on a conventional instrument will realise that real-time music-making is often a frustrating process.
Tape recorders can freeze music, as photocopiers can freeze print, but a digital recorder can do much more — it is the acoustic equivalent of a word processor, limited in power only by its software and memory capacity.
Most digital recorders let you work in ‘step time’; you make up music step by step, setting the pitch, intonation and rhythm. You can change sounds, adding and deleting notes at will, with instant replay to let you know how you’re getting on.
You don’t have to be able to play spot-on: software can ‘round’ notes to whatever degree you choose.
Step time is an idea just as revolutionary as sound sampling, and it is built into most of the new music machines. Like digital sound sampling, it is ideally suited to the computer; and together, step time and sampling are a powerful duo.