VOGONS


First post, by boomlinde

User metadata
Rank Newbie
Rank
Newbie

I've been trying out the rhythm mode for OPL2 and OPL3 (the mode where the operators of the last three channels are used to generate percussion sounds), but I can't seem to work it out. The only drum I can get to make a sound at all is the hi-hat (bit 1 in register 0xBD). Yesterday I got to a point where I was just filling the OPL registers with random data (except the gate bits were unset) and playing through the drum sounds, but still I only get the hi-hat to work. Thinking it must have been a bug in DOSBox, I tried it with a real OPL (on a toshiba libretto) with the same results.

There is very little documentation on this mode; was it ever used by anyone at all? Is there any source code I can read on the subject, or any easily parseable register dumps of a typical rhythm mode setup? I'm sorry if this isn't the most appropriate sub-forum, but this is the only place I can think of where I can ask a question like this and get a knowledgable answer. I used the rhythm mode on OPLL chips before, which had its hassles, but was a no-brainer compared to figuring out how to do it on the OPL2 or OPL3.

Reply 1 of 3, by sklawz

User metadata
Rank Member
Rank
Member

Hi.

Here is how I get a drum sound out of the OPL3:

1. enable rhythm mode (YMF262.PDF page 11)
2. configure ADSR envelope for operators corresponding to required sound
3. reset drum bit in $BD
4. configure BLOCK FNUM for voice
5. set drum bit in $BD to hear sound

I won't tell you the register addresses for all the above, you will need
to work it out yourself.

If you want to play around with the OPL3 drum kit on a real card, or
with a DLL emulator you can use my windows 95+ application found here:
http://fm801.kewl.org/
This could help you visualise it better.

Bye.

Reply 2 of 3, by boomlinde

User metadata
Rank Newbie
Rank
Newbie

Thanks for the help, I ended up writing a DRO parser to figure out the register writes in the dumps I found here: Re: DOSbox' OPL Emulation - Rhythm Sounds. And hey, I like your fm801 work. Bought a ForteMedia card a couple of years ago just to try it out. Great stuff!

Anyway, if anyone is interested in analyzing DRO v2 files, here's the quick hack I did: https://bitbucket.org/boomlinde/dro2