From gens.txt
* Custom YM2612 chip emulation :
- Special mode channel 3 supported
- AMS & FMS LFO supported
- High Quality emulation mode (sound calculation at the correct rate)
i don't know how usable this code is but the source of Gens is freely avaible...
Gens is...