thumb|yamaha ym3812 thumb|200px|right|yamaha ym3812-f smd. thumb|an audio sample of music written for and played on ym3812 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 in 1985 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 opl aka ym3526, to which it is very similar â in fact, it only adds 3 new waveforms. an upgraded version of the opl2, the opl3 aka ymf262, was also popular in later sound cards such as the soundblaster 16. another related chip is the ym2413 (opll), which is a cut down version. the circuit has 244 different write-only registers. it can produce 9 channels of sound, each made of two oscillators or 6 channels with 5 percussion instruments available. 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 inverted, and pseudo sawtooth waves (1/4 sine waves upward only with silent sections in between) can also be produced. this odd way of producing waveforms give the ym3812 a characteristic sound. each wave generator has its own adsr envelope generator. its main method of synthesis is frequency modulation synthesis, done by phase modulation of the phase of one of the channel's oscillators by the output of the other. frame|ym3812 oscillator waveforms overview of a channel's registers: for the whole channel: * main frequency (10 bits) * octave (3 bits) * note on/off * synthesis mode (fm or just additive) * feedback (0â7, the modulator modulating itself) for each one of the 2 oscillators: * frequency multiply (can be set to 1/2, 1 to 10, 12 or 15) * waveform (sine, half-sine, absolute-sine, quarter-sine) * volume (0â63, logarithmic) * attack, decay, sustain, release (4 bits each, logarithmic) * tremolo (on or off) * vibrato (on or off) * sustain (on or off) * envelope scaling per key (on or off) * volume scaling per key (0â3) there are also a few parameters that can be set for the whole chip: * vibrato depth * tremolo depth * percussion mode (uses 3 channels to provide 5 percussion sounds) * composite sine mode (retrigs all voices periodically using a timer; very rarely used; doesn't work on the opl3) ==internal operation==  the internal operation of the chip is completely digital. each fm-tone is generated by a digital oscillator using a form of direct digital synthesis. a quarter of the log-transforme
Yamaha_sound_chips