Declare Function OpenSound% Lib "sound.drv" () Declare Function VoiceQueueSize% Lib "sound.drv" (ByVal nVoice%, ByVal nByteS) Declare Function SetVoiceSound% Lib "sound.drv" (ByVal nSource%, ByVal Freq&, ByVal nDuration%) Declare Function StartSound% Lib "sound.drv" () Declare Function CloseSound% Lib "sound.drv" () Declare Function WaitSoundState% Lib "sound.drv" (ByVal State%) £§ Add this routine, to be used with SirenSound1 routine Sub Sound(ByVal Freq As Long, ByVal Duration As Integer) Dim s As Integer £§ Shift frequency to high byte. Freq = Freq * 2 ^ 16 s = SetVoiceSound(1, Freq, Duration) s = StartSound() While (WaitSoundState(1) <> 0): Wend End Sub £§ Here are the 4 sound routines: £§* Attention Sound #1 * Sub AttenSound1() Dim Succ, s As Integer Succ = OpenSound() s = SetVoiceSound(1, 1500 * 2 ^ 16, 50) s = SetVoiceSound(1, 1000 * 2 ^ 16, 50) s = SetVoiceSound(1, 1500 * 2 ^ 16, 100) s = SetVoiceSound(1, 1000 * 2 ^ 16, 100) s = SetVoiceSound(1, 800 * 2 ^ 16, 40) s = StartSound() While (WaitSoundState(1) <> 0): Wend Succ = CloseSound() End Sub £§* Click Sound #1 * Sub ClickSound1() Dim Succ, s As Integer Succ = OpenSound() s = SetVoiceSound(1, 200 * 2 ^ 16, 2) s = StartSound() While (WaitSoundState(1) <> 0): Wend Succ = CloseSound() End Sub £§* Error Sound #1 * Sub ErrorSound1() Dim Succ, s As Integer Succ = OpenSound() s = SetVoiceSound(1, 200 * 2 ^ 16, 150) s = SetVoiceSound(1, 100 * 2 ^ 16, 100) s = SetVoiceSound(1, 80 * 2 ^ 16, 90) s = StartSound() While (WaitSoundState(1) <> 0): Wend Succ = CloseSound() End Sub £§* SirenSound #1 * Sub SirenSound1() Dim Succ As Integer Dim j As Long Succ = OpenSound() For j = 440 To 1000 Step 5 Call Sound(j, j / 100) Next j For j = 1000 To 440 Step -5 Call Sound(j, j / 100) Next j Succ = CloseSound() End Sub