Arduino OPL2 v2.1.0
In this version the following changes are made:
- Instrument definitions are changed to take up less space (1 byte less per 2-OP instrument and 3 bytes less per 4-OP instrument)
- The
loadDrumInstrument
function is removed. Drum instruments for percussive mode are also loaded using the regularloadInstrument
. An additional parameterdrumType
is added tosetDrumInstrument
- Instrument
struct
s no longer hanve atype
as it was only used for percussive mode instruments - Instruments now use the
transpose
property. Currently this is only used by drum instruments to define the note to be played - All instrument definitions are updated.
- All examples are updated to use the new instrument definitions
- The reset sequence of the OPL3 and OPL3Duo have been corrected. This would've failed if there was no hard reset of the chips due to resetting OPL3 mode before resetting the registers
- Small improvements to send less data when going to OPL3 mode on all channels
- The
playNote
function no longer resets the KEY-ON if no note is playing. This was giving some glitches with drum sounds - Allow for debugging of the data being sent to the OPL2 board or OPL3 Duo! by defining
OPL_SERIAL_DEBUG
in OPL2.h - The MIDI example now also handles the modulation wheel and can handle channel after touch
- A new example is added for the OPL3 Duo! board that shows a simple 16 step drum sequencer
This update contains the following fixes:
- #70 fixed by @isnotinvain - Stop note would only be applied to channel 1
- #72 fixed by @isnotinvain - OPL2 bitmasks were used when setting OPL3 instruments
- #73 - Compilation would fail on Raspberry Pi when using
std::min
orstd::max
due to Arduino macros - #74 fixed by @jonkerj - OPL3.cpp was missing
setChipRegister
and had mistakes insetChannelRegister
andsetOperatorRegister