The k project

Sound Driver

Description

The PC Speaker is used to play some sound in k. It is used by moduling the frequency to produce sound with the channel 2 of the PIT.

Syscall interface

NAME
    playsound - play a melody
SYNOPSIS
    int playsound(t_melody *melody, int repeat);
DESCRIPTION
    playsound() launches the given melody, and repeats it, if the repeat
    flag is set.
RETURN VALUE
    playsound() returns 0 on success or -1 otherwise.

Possible bug causes

Notes

The creation of each t_melody can be found in sdk/mkksf/mkksf.c