Jump to content

Yamaha YM2612

From Wikipedia, the free encyclopedia
Yamaha YM2612

The YM2612, a.k.a. OPN2, is a sound chip developed by Yamaha. It is a member of Yamaha's OPN family of FM synthesis chips, and is derived from the YM2203.[1]

The YM2612 is a six-channel FM synthesizer used in several game and computer systems, most notably in Sega's Mega Drive/Genesis video game console[2] as well as Fujitsu's FM Towns computer series.[3] It was also available in CMOS form as the YM3438, a.k.a. OPN2C.[1]

As with the YM3438, it was used by Sega in various arcade game systems, including the Mega-Play, Sega System C and Sega System 32; the YM3438 core was also integrated into an ASIC in later revisions of the Mega Drive/Genesis.

Features

[edit]

The YM2612 has the following features:[1]

  • Six concurrent FM synthesis channels (voices)
  • Four operators per channel[4]
  • Two interval timers
  • A sine-wave low frequency oscillator (LFO)
  • Integrated stereo output digital-to-analog converter (most other contemporary Yamaha FM chips require a separate external D/A converter chip)
  • Per-channel programmable stereo sound (left, right, or both left and right resulting in centre)
  • For channel three, operator frequencies can be set independently, making dissonant harmonics possible. (Normally, they would have a simple relation like e.g. 2× or 3× relative to a common base frequency) This is a common feature of the OPN family of chips.

Technical details

[edit]

The YM2612's FM synthesis block is an extended version of the FM block featured in the YM2203, adding three additional FM channels and integrating a stereo output DAC.[1] The YM2612 removes the SSG component (although retaining its envelope generators) and GPIO ports found in the YM2203 and YM2608,[1] which were elements of the integrated YM2149F core on the other OPN chips. While the YM2612 is mainly based on the YM2203, it was often referred to as being based on the YM2608 due to a number of similarities made between the two sound chips, only lacking the latter's ADPCM channels among other aforementioned changes.

While high-end chips in the OPN series have dedicated ADPCM channels for playing sampled audio (i.e. YM2608 and YM2610), the YM2612 does not. However, its sixth channel can act as a basic PCM channel by means of the 'DAC Enable' register, disabling FM output for that channel but allowing it to play 8-bit pulse-code modulation sound samples.[1] Unlike other OPN chips with ADPCM support, the YM2612 does not provide any timing or buffering of samples, so all frequency control and buffering must be done in software by the host processor.[2]

Low volume distortion of the built-in DAC

[edit]
An example of the low volume distortion created by the peculiar qualities of the YM2612's built-in DAC. This sample is from the Mega Drive game Beyond Oasis.
In some cases, this low volume distortion can affect the loudness, and to some degree the timbres, of certain sounds. This sample is from the Mega Drive game Streets of Rage 2.

Unlike most Yamaha FM chips which require an external floating-point DAC, the YM2612 features a built-in 9-bit DAC, which uses time-division multiplexing to play one sample of each channel in sequence, similar to the YM2413.

Due to an error with the amplitude voltage in the original chip design, a peculiar form of crossover distortion known as low volume distortion (and historically given the terms "ladder effect" and "TDM distortion") is introduced in the output. In this case, any output that is sufficiently low in volume undergoes an exaggerated quantization, including any usage of fades in video game music.

Some early games in the Mega Drive/Genesis' lifespan such as After Burner II had their music written around this distortion to generate unique timbres or effects. As a consequence, games that used this musical trick would sound too quiet on later Mega Drive/Genesis consoles using the integrated YM3438 core on the ASIC. Also, because of the reduced dynamic range of the built-in DAC, additional distortion may be generated when playing sounds with a very high volume.[1]

Variants

[edit]

Yamaha YM3438

[edit]

The YM3438,[1] a.k.a. OPN2C, is a modified CMOS version of the YM2612, commonly used in Sega's arcade system boards as well as being used in Fujitsu's FM Towns Marty. This version has an improved built-in DAC that significantly reduces the presence of crossover distortion from the original chip with a higher signal-to-noise ratio than the YM2612. It is not a direct, drop-in replacement for the YM2612 however, as the sound outputs have higher impedance.

Yamaha YMF276

[edit]

The YMF276,[5] a.k.a. OPN2L, is a low-powered version of the YM3438, used in later models of Fujitsu's FM Towns series (particularly the FM Towns II models). It came in a smaller 24-pin SOP package. Unlike the YM2612 and YM3438, the YMF276 requires an external DAC chip, similar to most other Yamaha FM chips. This is usually a YM3433B external DAC chip (as used in the FM Towns II models) or other equivalent DAC chips. As such, it does not produce significant low volume distortion as with the YM2612/YM3438 chips due to its usage of an external DAC chip.

Yamaha-created ASICs

[edit]

The YM3438 core was also integrated in custom ASICs made by Yamaha for use with Sega's Mega Drive/Genesis,[6] which were used in the final revision of the original model and most revisions of the revised models (FC1004, FF1004 and FJ3002) as well as the Genesis 3 released by Majesco (FJ3002 and FQ8007). The ASIC contained both the video and sound chips (and later the main CPU and sound CPU) combined into one chip, which also includes the YM7101 VDP that houses the integrated Texas Instruments SN76489 PSG. The YM3438 core in these revisions further reduced the presence of the low volume distortion bug more so than with standalone YM3438 chips.

Emulation

[edit]

In recent years, with the advent of emulation, the YM2612 and its variants have been faithfully replicated in software, with various improvements in accuracy of the emulation of the sound chips being made over time. Such changes included the implementation of the low volume distortion bug in the YM2612, as well as certain features such as the SSG envelope generator and undocumented registers. Cycle-accurate emulation of the YM2612 and its variants have also been done as well, using die shot reverse engineering of the chips. Many video game console emulators (especially those for the Mega Drive/Genesis) and even arcade game emulators such as MAME implemented various emulated versions of the YM2612, with most modern Mega Drive/Genesis emulators having the option to replicate the sound outputs of the original and revised models of the Mega Drive/Genesis using the emulated YM2612 or YM3438 cores (which can also be used in conjunction with a low-pass filter to further simulate an original model Mega Drive/Genesis).

Game audio

[edit]

Used in conjunction with the Texas Instruments SN76489 PSG as the main sound generators of the Sega Mega Drive/Genesis console, the YM2612 was prominently utilized by numerous prolific video game music composers, most notably Yuzo Koshiro.[4][7]

See also

[edit]

References

[edit]
  1. ^ a b c d e f g h YM3438 Application Manual (Japanese)
  2. ^ a b Sega Genesis Technical Manual - YM2612 section (updated with errors corrected)
  3. ^ Purcaru, Bogdan Ion (13 March 2014). Games vs. Hardware. The History of PC video games: The 80's. p. 527. Retrieved 14 December 2017.
  4. ^ a b "Super Sonic: Creating the new sound of Sega's hedgehog hit". TheGuardian.com. 13 February 2020.
  5. ^ Undocumented Sound Chips - Yamaha YMF276
  6. ^ Sega Genesis 2 / Sega Mega Drive II Service Manual
  7. ^ "Sega Mega Drive Mini review – a legacy truly honoured". TheGuardian.com. 19 September 2019.
[edit]