| |||||||||
The Yamaha YM3812 also known as the OPL2 (OPL is an acronym for FM Operator Type-L) is a sound chip (i.e. integrated circuit) created by Yamaha Corporation and famous for its wide use in IBM PC-based sound cards such as the AdLib and Sound Blaster.
It is backwards compatible with the OPL1 aka YM3526, to which it is very similar - in fact, it only added 3 new waveforms. An upgraded version of the OPL2, the OPL3 aka YMF262, was also popular in later sound cards such as the Sounblaster 16.
The circuit has 244 different write-only registers. It can produce 9 channels of sound, each made of two oscillators. Each oscillator can produce sine waves which may also be modified into 3 other waveforms - the negative part of the sine can be muted or inversed, and pseudo sawtooth waves (1/4 sine waves upward only with silent sections inbetween) can also be produced. This odd way of producing waveforms give the YM3812 a characteristic sound. Each wave generator has its own ADSR enveloppe generator. It's main method of synthesis is Frequency modulation synthesis - where one of the channel's oscillators modulates the other.
Here's the overview of a channel's registers:
For the whole channel:
For each one of the 2 oscillators:
There's also a few parameters that can be set for the whole chip: