Discussion:
IIgs sound from Applesoft
(too old to reply)
duhas...@gmail.com
2023-10-13 22:52:32 UTC
Permalink
Is there a sanctioned way to play a digitized sound on the IIgs in Applesoft basic? I have a read a few ways of loading square waves of 256 bytes, but the sounds I want to play are substantially larger.
fadden
2023-10-14 14:54:10 UTC
Permalink
Is there a sanctioned way to play a digitized sound on the IIgs in Applesoft basic? I have a read a few ways of loading square waves of 256 bytes, but the sounds I want to play are substantially larger.
Purely from Applesoft could be tricky. Is your goal to be 100% Applesoft, or just to do it without IIgs toolbox support?
duhas...@gmail.com
2023-10-16 02:56:38 UTC
Permalink
Is there a sanctioned way to play a digitized sound on the IIgs in Applesoft basic? I have a read a few ways of loading square waves of 256 bytes, but the sounds I want to play are substantially larger.
Purely from Applesoft could be tricky. Is your goal to be 100% Applesoft, or just to do it without IIgs toolbox support?
Purely from Applesoft I'm thinking. Bloading the sound file into memory and then setting up a transfer to the sound RAM. It seems possible, but just not explained clearly anywhere....
Michael J. Mahon
2023-10-18 16:29:04 UTC
Permalink
Post by ***@gmail.com
Post by ***@gmail.com
Is there a sanctioned way to play a digitized sound on the IIgs in
Applesoft basic? I have a read a few ways of loading square waves of
256 bytes, but the sounds I want to play are substantially larger.
Purely from Applesoft could be tricky. Is your goal to be 100%
Applesoft, or just to do it without IIgs toolbox support?
Purely from Applesoft I'm thinking. Bloading the sound file into memory
and then setting up a transfer to the sound RAM. It seems possible, but
just not explained clearly anywhere....
“Purely” is a non-starter, since PEEK and POKE can’t access sound
memory—there will *have* to be some machine code involved. So, the only
question is how much and how it’s loaded.

Where do you draw the line for *how* purely you feel you need it to be. ;-)


Are short sequences of machine code OK? How about a machine code library
of sound-related functions?
--
-michael - NadaNet 3.1 and AppleCrate II: http://michaeljmahon.com
duhas...@gmail.com
2023-10-18 22:43:56 UTC
Permalink
Post by Michael J. Mahon
Purely from Applesoft I'm thinking. Bloading the sound file into memory
and then setting up a transfer to the sound RAM. It seems possible, but
just not explained clearly anywhere....
“Purely” is a non-starter, since PEEK and POKE can’t access sound
memory—there will *have* to be some machine code involved. So, the only
question is how much and how it’s loaded.
Where do you draw the line for *how* purely you feel you need it to be. ;-)
Are short sequences of machine code OK? How about a machine code library
of sound-related functions?
--
-michael - NadaNet 3.1 and AppleCrate II: http://michaeljmahon.com
Purely? Apparently this guy can play some sound without using anything but peeks and pokes.

https://lateblt.tripod.com/appl2snd.htm

Looking at this, and Ampersound, 256 byte sound waves are loaded. What if I want to load, say an 8192 byte long wave form? Just change the for next loop and as long as the wave is padded with zeros to whatever weird page boundaries are needed it will work? Every example is a generated sine wave, if I download a digitized .WAV file of Curly going Nyuk, Nyuk, Nyuk, and strip the first few bytes of info, will that work?

I'm still trying to get through Sonix, but semi-tones and some other stuff is hanging me up at the moment.
Brian Patrie
2023-10-19 06:53:23 UTC
Permalink
if I download a digitized .WAV file of Curly going Nyuk, Nyuk, Nyuk, and
strip the first few bytes of info, will that work?
MS .wav files are RIFF (Resource Interchange File Format)--a structured
resource format similar in concept to a Macintosh or GS/OS resource fork
(but without being a forked file). They can contain all manner of
metadata. So getting the waveform data out of them is not as simple as
truncating a header off of them. You have to find at least the first
WAVE chunk (there can be more than one), and its associated geometry
metadata (sample width, sample rate, etc).
duhas...@gmail.com
2023-10-20 00:22:09 UTC
Permalink
Post by Brian Patrie
if I download a digitized .WAV file of Curly going Nyuk, Nyuk, Nyuk, and
strip the first few bytes of info, will that work?
MS .wav files are RIFF (Resource Interchange File Format)--a structured
resource format similar in concept to a Macintosh or GS/OS resource fork
(but without being a forked file). They can contain all manner of
metadata. So getting the waveform data out of them is not as simple as
truncating a header off of them. You have to find at least the first
WAVE chunk (there can be more than one), and its associated geometry
metadata (sample width, sample rate, etc).
Has the format changed over the years? I remember 25 years ago in college downloading .WAV and loading them up in Audiozap or similiar and cutting a little off the front and it playing just fine. I didn't examine them on a byte level, but regardless, if not loading a .WAV, then a raw sound file over 256 bytes long....
I am Rob
2023-10-14 16:21:45 UTC
Permalink
Is there a sanctioned way to play a digitized sound on the IIgs in Applesoft basic? I have a read a few ways of loading square waves of 256 bytes, but the sounds I want to play are substantially larger.
There are a few Applesoft programs on Asimov to study. Download the site list and look for the words, Ensoniq, Ampersound, Sounds, Frequency.
duhas...@gmail.com
2023-10-16 02:57:41 UTC
Permalink
Is there a sanctioned way to play a digitized sound on the IIgs in Applesoft basic? I have a read a few ways of loading square waves of 256 bytes, but the sounds I want to play are substantially larger.
There are a few Applesoft programs on Asimov to study. Download the site list and look for the words, Ensoniq, Ampersound, Sounds, Frequency.
None of those search terms return anything, or anything useful.

I've look at Ampersound, and quick peruse doesn't show it to do what I want.
.
laserac...@gmail.com
2023-10-17 08:03:49 UTC
Permalink
From Applesoft on a GS... is it possible to use more than 128kb?
If you are looking to create digitized sounds and play them back, you can use my AudioRecorder 3.13 ... you plug in an audio jack into the back of an Apple IIE, then record those sounds, with a simple binary you can play them back using simple Calls from Applesoft. If you want to get advanced, you can also use SFx 1Bit multi-tasking audio which I used in my games Dogfighters of Mars 2 and Pyramid of RA, but we'll get there after you do some experiments with sound recorder. If you do not have a IIE, I cant help you, a few years back I was trying to get information on how to record from an INPUT on an emulator, but nobody could help me at the time.

https://www.dropbox.com/s/7vc34y6iwx4ghzm/BEEP%20MOCK%20v.01.zip?dl=0

You can msg me facebook (tom.porter.3192) if this suits your needs for more information/questions ect, I dont program much anymore but still got it in me! take care- Tom
laserac...@gmail.com
2023-10-17 08:08:21 UTC
Permalink
From Applesoft on a GS... is it possible to use more than 128kb?
If you are looking to create digitized sounds and play them back, you can use my AudioRecorder 3.13 ... you plug in an audio jack into the back of an Apple IIE, then record those sounds, with a simple binary you can play them back using simple Calls from Applesoft. If you want to get advanced, you can also use SFx 1Bit multi-tasking audio which I used in my games Dogfighters of Mars 2 and Pyramid of RA, but we'll get there after you do some experiments with sound recorder. If you do not have a IIE, I cant help you, a few years back I was trying to get information on how to record from an INPUT on an emulator, but nobody could help me at the time.

https://www.dropbox.com/s/9nvew2q3ckjyzwh/AUDIO%20RECORDER%20v3.12%20%2B%20Instructions.zip?dl=0

You can msg me facebook (tom.porter.3192) if this suits your needs for more information/questions ect, I dont program much anymore but still got it in me! take care- Tom

***(If you see this post twice, I incorrectly listed the wrong link... this is the correct one)>
Antoine Vignau
2023-10-17 10:54:15 UTC
Permalink
Hi There,
Try Sonix @ https://www.whatisthe2gs.apple2.org.za/sonix.html
av
Loading...