DYSTOPIANPIXEL

audioControl Driver

A complete game-audio system for the ZX Spectrum Next: music, effects, voices and ambience working together to bring a game world to life.

Coral code, lime and coral waveforms, and moving sound sources around a listener on charcoal
Music and effects, with the planned positional sound and wider stereo soundstage illustrated.

The sound of the whole game

I am building audioControl to give ZX Spectrum Next games one place to manage music, sound effects and the wider soundscape. The ambition is to support everything from familiar chip music and a simple jump sound to moving creatures, distant machinery, changing ambience and voices that belong to the world around the player.

BASIC will continue to organise the game and decide what happens. audioControl will take care of how those events sound, keeping time-sensitive playback and sound management out of the main game loop. The capabilities below describe the intended destination of the project; they are not all available yet.

Music and effects that respond to play

A game should be able to choose a tune, start or stop it, pause and resume it, and change music as the player enters a new area or reaches an important moment. Music and effects should work together, with independent controls and an overall mute option.

Jumping, firing, collecting an item, taking a hit or completing a level can each produce an appropriate response. The game will choose its own tracks and effect collections, and map actions to sounds without having to rewrite the systems that report those actions.

Make the important sounds count

Busy scenes need more than the ability to play several sounds. Important warnings should take priority, repeated events should not constantly restart the same effect, and actions with no assigned sound should simply remain silent.

The longer-term design includes finer control over competing effects, sound groups and simultaneous copies. Sustained sounds could support engines, wind, flowing water or an approaching-enemy warning. Music fades, transitions and temporary lowering are intended to help important sounds stand out while preserving the character of the music.

Hear where things are

The AY path already provides discrete left, centre and right placement with distance levels. The experimental DAC path has also demonstrated strong left, centre and right routing using a fixed 1 kHz tone on real hardware.

Smooth movement, world-based source and listener positions, and DAC distance processing remain future development. The intention is for sound to belong to the game world, so scrolling the camera does not move its apparent source. Height and front-to-back perception remain later work.

A wider, more atmospheric soundstage

Optional enhanced positioning will explore subtle differences in timing and tone to make direction more convincing. A separate stereo-expansion effect is intended to make the overall scene feel wider, drawing inspiration from the broad ideas behind Q-Sound and Q-Expander.

These will be independently developed, switchable effects. Cavern ambience, wind or ghostly whispers might benefit from a broad presentation, while a nearby character could remain more precisely placed. Games should be able to choose the treatment that suits each scene.

Recorded sound alongside familiar chip audio

On a KS3 ZX Spectrum Next, a standalone audioControl test streamed a complete 150.75-second mono track from SD. One RAM buffer fed the DAC while the other received the next part of the file. The tune played to its last sample with no reported gaps, skips or corruption.

Build 48 remains the AY reference for PT3 music and AYFX effects at 50 Hz and 60 Hz. Build 54 supplies the single-shot DAC path used in the PCM tests. The two baselines give future integration work independent checks for chip audio and sample playback.

The next research step at this milestone is stereo playback from RAM. The release design still needs a file service that can safely feed the resident driver.

Voices in the same audible world

Future cooperation with speechControl is intended to let dialogue share the same position, distance and soundscape conventions as effects. A speaking character could remain audible in the right place as either the character or the listener moves.

speechControl will retain responsibility for speaking and listening. audioControl’s role will be to coordinate how those voices fit with the rest of the game’s audio. Bringing Pi-delivered speech into that shared mix will require its own integration work.

Part of the driver ecosystem

playerControl, shipControl and enemyControl can report actions such as movement, firing, hits or changes in resources. scrollingControl can provide the view and world context. BASIC connects those events to the chosen audio response, while audioControl owns playback, priorities and sound management.

That separation should make the driver useful across platformers, shoot-em-ups and other game styles. A new game can use different sounds and rules while reusing the same audio foundation. Optional Pi features should extend the choices available without making a Pi essential for local music and effects.

Developed in manageable stages

The goal is a flexible, reusable audio system that remains approachable for BASIC developers. Reliable playback, clear examples and predictable behaviour matter as much as the more ambitious sound features.

The Ideas pages contain the detailed feature plans, current progress, known limitations and development stories. They distinguish what already works from what is still being designed or developed.

View project ideas ↗See the next steps ↗