Thread View: alt.lang.basic
1 messages
1 total messages
Started by Blair Trosper
Mon, 15 Nov 1999 00:00
Sound question
Author: Blair Trosper
Date: Mon, 15 Nov 1999 00:00
Date: Mon, 15 Nov 1999 00:00
32 lines
2108 bytes
2108 bytes
I have been unable in my attempts to get QBasic to be able to sample sound
(specifically my CD player playing a cd) via &H20. The script I am using:
From "The Revolutionary Guide To QBasic" by Wrox Press:
---
CONST screenmode = 12, xmax = 640
CONST BaseAddr = &H240
CONST commaddr = BaseAddr + &HC, DataAddr = BaseAddr + &HA
DEFINT A-Z
DIM byte(xmax)
SCREEN screenmode
DO
OUT commaddr, &H20
PRESET (i, byte(i))
byte(i) = INP(DataAddr)
PSET (i, byte(i))
i = (i + 1) MOD xmax
LOOP
----
If I have winamp or any program open using WaveMapper, I get an error that
the sound card is already in use and that I cannot "play the sound." If I
am using my CD player, nothing happens except a straight line. The program
is supposed to be an oscilliscope of sorts. My sound cards base address is
240 (CONST BaseAddr = &H240), but I have tried using 220 and a range of
other numbers.
Can anyone provide some insight into this problem, what might be wrong
and/or how I can get it to work?
Blair
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads