VOGONS


First post, by madaxe

User metadata
Rank Newbie
Rank
Newbie

Hi everyone!

I'm coding a MS-Dos game that will support AdLib, Sound Blaster and CMS/Game Blaster (Philips SAA1099).

I'm making some tests with the SAA1099 and I can produce lots of great sounds but I can't set the envelope duration properly. I have tried different values for frequency and octave of the channel 1 (I assume a 0-5 channel number) and in fact the length of the envelope varies but it's always very short. There is any way to produce long length envelopes like we do in AY-3-8912?

By the way, what is the meaning of the bit 5 (external/internal clock) and bit 4 (16/8 bit resolution) on the envelope registers?

Note: I am using DOSBox with the Game Blaster option.

Thanks in advance,
José Mário aka Madaxe.

Reply 1 of 14, by Benedikt

User metadata
Rank Oldbie
Rank
Oldbie

External clock might be exactly what you need. According to the datasheet, external clock means that it uses the address write pulse as envelope clock pulse, i.e. that it advances in the envelope wave form every time you select a register address. At least that is how I interpret it.
You would then have to make sure that you write register addresses at a regular interval, otherwise the result might sound weird.

Reply 3 of 14, by Benedikt

User metadata
Rank Oldbie
Rank
Oldbie

At least that is what I assume. Depending on the type of music, you might not even need these bogus register selections.
(I.e. if your music creates a sufficient number of more or less uniformly distributed register selection operations, already.)

Reply 4 of 14, by carlostex

User metadata
Rank l33t
Rank
l33t

Great to know more MS-DOS software homebrew is coming.

Besides AdLib and Game Blaster support would you consider Innovation SSI support? The SID chip should allow for great music despite 3 channels only. And you can always use DOSBox SVN to test, it supports Innovation SSI Sound.

Reply 6 of 14, by madaxe

User metadata
Rank Newbie
Rank
Newbie
Benedikt wrote on 2020-02-23, 19:26:

At least that is what I assume. Depending on the type of music, you might not even need these bogus register selections.
(I.e. if your music creates a sufficient number of more or less uniformly distributed register selection operations, already.)

@Benedikt

Thanks for your help. I'll make some more tests to understand the mechanism.

Long time ago I had a Sound Blaster 1.6 that was basically a SB 1.5 with the CMS chips included in it and do you believe the booklet with the CMS registers that came in the package didn't have any info at all about the envelope generators?

Attachments

Reply 7 of 14, by madaxe

User metadata
Rank Newbie
Rank
Newbie
carlostex wrote on 2020-02-23, 23:22:

Great to know more MS-DOS software homebrew is coming.

Besides AdLib and Game Blaster support would you consider Innovation SSI support? The SID chip should allow for great music despite 3 channels only. And you can always use DOSBox SVN to test, it supports Innovation SSI Sound.

Hi @carlostex

Yeap, the SID chip is very great and I love it but the my aim is to make a an old school retro game that uses the PCs hardware of the late 80s and early 90s 😀

You can find more info about my game here:
https://madaxe-pns.github.io/sardonic/

Last edited by madaxe on 2022-08-21, 13:29. Edited 1 time in total.

Reply 8 of 14, by root42

User metadata
Rank l33t
Rank
l33t

Well to be fair: the SSI Innovation was a PC card of the late 80s. It wasn’t widespread, but it was commercially available!

YouTube and Bonus
80486DX@33 MHz, 16 MiB RAM, Tseng ET4000 1 MiB, SnarkBarker & GUSar Lite, PC MIDI Card+X2+SC55+MT32, OSSC

Reply 9 of 14, by Benedikt

User metadata
Rank Oldbie
Rank
Oldbie
root42 wrote on 2020-02-24, 21:10:

Well to be fair: the SSI Innovation was a PC card of the late 80s. It wasn’t widespread, but it was commercially available!

I'd obviously love to see SSI-2001 support, as well, but one step at a time!
The SAA1099/CMS/Gameblaster is definitely a good choice for a game in the Space Invaders genre.

Reply 10 of 14, by root42

User metadata
Rank l33t
Rank
l33t
Benedikt wrote on 2020-02-25, 14:44:
root42 wrote on 2020-02-24, 21:10:

Well to be fair: the SSI Innovation was a PC card of the late 80s. It wasn’t widespread, but it was commercially available!

I'd obviously love to see SSI-2001 support, as well, but one step at a time!
The SAA1099/CMS/Gameblaster is definitely a good choice for a game in the Space Invaders genre.

I think the CMS was never used to its fullest extent. Surely it was less flexible than the OPL2, but there are great demos for the Sam Coupé, which also uses the SAA1099. So I would be glad to see some top notch music done with it. My Snark Barker is waiting!

YouTube and Bonus
80486DX@33 MHz, 16 MiB RAM, Tseng ET4000 1 MiB, SnarkBarker & GUSar Lite, PC MIDI Card+X2+SC55+MT32, OSSC

Reply 11 of 14, by madaxe

User metadata
Rank Newbie
Rank
Newbie
root42 wrote on 2020-02-25, 22:05:

I think the CMS was never used to its fullest extent. Surely it was less flexible than the OPL2, but there are great demos for the Sam Coupé, which also uses the SAA1099. So I would be glad to see some top notch music done with it. My Snark Barker is waiting!

Yeap, unfortunately the CMS Card never was pushed to its limits and most of the time the programmers used it as a multi channel Beeper.
But there are good tunes like Budokan and Ultima VI (also very good on SSI-2001).
I'll do my best to make a good usage of the SAA1099 in my little game 😀

Reply 12 of 14, by OPLx

User metadata
Rank Member
Rank
Member
madaxe wrote on 2020-02-22, 18:33:
Hi everyone! […]
Show full quote

Hi everyone!

I'm coding a MS-Dos game that will support AdLib, Sound Blaster and CMS/Game Blaster (Philips SAA1099).

I'm making some tests with the SAA1099 and I can produce lots of great sounds but I can't set the envelope duration properly. I have tried different values for frequency and octave of the channel 1 (I assume a 0-5 channel number) and in fact the length of the envelope varies but it's always very short. There is any way to produce long length envelopes like we do in AY-3-8912?

By the way, what is the meaning of the bit 5 (external/internal clock) and bit 4 (16/8 bit resolution) on the envelope registers?

Note: I am using DOSBox with the Game Blaster option.

Thanks in advance,
José Mário aka Madaxe.

The envelope generator emulation under DOSBox doesn't work properly so you will have to test that on actual hardware. The present implementation assumes that in order to use the envelope generator, it is necessary to enable it and also enable the frequency generator on the corresponding channel. On actual hardware, it's possible to enable just the envelope generator's waveform and not have the channel's square wave mixed in with the final output.

Bit 4 affects the effective frequency range (pitch) of the envelope generator; if you want to get very low pitches leave it clear and for the "normal" pitch ranges set it. I could never figure it out how, but I think Bit 5 can be used to supply a custom envelope shape to the generator.

The best usage of the SAA1099 has been on the Sam Coupe hardware platform. While the envelope generators on the SAA1099 aren't as varied as the AY-3-8912, I think there are some interesting things that can be done with the chip.

You can download the CMSVIEW program I made a while back to play around with the register settings (for the first three channels on the SAA1099) to get a feel for what the chip does (apart from the usage of Bit 5) here.

Reply 13 of 14, by Benedikt

User metadata
Rank Oldbie
Rank
Oldbie
OPLx wrote on 2020-06-22, 08:14:

I could never figure it out how, but I think Bit 5 can be used to supply a custom envelope shape to the generator.

If I read the datasheet correctly, you cannot supply a custom envelope shape, but control how quickly the envelope generator advances through the envelope shape.
You'd basically clock the envelope generator manually with every write access to the chip rather than at a fixed clock rate.

Reply 14 of 14, by OPLx

User metadata
Rank Member
Rank
Member
Benedikt wrote on 2020-07-03, 19:52:
OPLx wrote on 2020-06-22, 08:14:

I could never figure it out how, but I think Bit 5 can be used to supply a custom envelope shape to the generator.

If I read the datasheet correctly, you cannot supply a custom envelope shape, but control how quickly the envelope generator advances through the envelope shape.
You'd basically clock the envelope generator manually with every write access to the chip rather than at a fixed clock rate.

Looking at the datasheet, I believe you are correct. Presently I can't think of what this could be used for (perhaps sample playback?); maybe one of these days I will have time to play around with the registers and see what happens. Thank you for the feedback.