7

The Nintendo Game Boy Advance had a Z80-like processor which was typically used for backwards compatibility with GB and GBC games. According to its Wikipedia page, an uncited comment claims that the Z80 was also used by GBA games to supplement audio (emphasis mine):

Backward compatibility for Game Boy and Game Boy Color games is provided by a custom 4.194/8.388 MHz Z80-based coprocessor (Game Boy Advance software can use the audio tone generators to supplement the primary sound system), while a link port at the top of the unit allows it to be connected to other devices using a Game Link cable or GameCube link cable.

This brings up two questions:

  1. Is this true? Was the Z80 ever used by GBA games to supplement the audio?
  2. How did the Nintendo DS (which has no Z80) deal with this when running GBA games?
  • 2
    That sounds to me like it's just saying that the original sound hardware can supplement the new, which somebody has confusingly decided to place next to comments about the old CPU? – Tommy Sep 15 '18 at 18:12
7

The Wikipedia comment is misleading. The Game Boy CPU has several components in one chip, including the Z80-alike CPU core and a sound generator among others. These components may all be in the same chip but they are functionally independent; you don't need the Z80 CPU to be able to produce audio.

The Nintendo DS inherited the Game Boy sound generator circuitry and dropped the Z80 and other associated components. This allows GBA games to produce audio, but original GameBoy games won't work.

The GBA shares the sound generator between whichever CPU is control of the system; the ARM for GBA games and the Z80 for Game Boy games. Note that when the ARM is in control the Z80 is disabled and can't perform any multi-processing tasks.

Then again the Z80 is so slow and the ARM is so fast that it is questionable how useful the Z80 could have been in that situation, and it would have required a lot of support circuitry to allow both to be active and share the bus without impacting the performance of each other.

12

None of the GameBoy series machine has a Z80, but instead a Sharp LR35902, which runs a "GBZ80" instruction set, which is if I'm not mistaking similar but incompatible with the genuine Z80, as it lacks the two registers sets (much like the 8080) and other instructions. Just like the 2A03 in the NES, the CPU is in the same chip as the sound generation hardware, even though both are separated.

The GBA had to be backward compatible with GameBoy and GameBoy Color games, so it included the Sharp LR35902 CPU as well. However Game Boy Advance games can only use the sound generation hardware.

The backward compatibility is actually a second machine in the same package. When inserting a Gameboy or Gameboy Color game in a Game Boy Advance, it presses a switch which change the voltage and which console is booted. It is possible to press that switch manually and boot as old Game Boy without inserting cartridge. Therefore completely different hardware is used when running a game in backward compatibility mode, the sound generation is the only thing both system have in common.

The Nintendo DS has only the sound generation hardware implemented, as the CPU wasn't needed anymore.

  • 1
    I'm aware that it's not a true Z80 chip, but it's similar enough that it's often referred to as a Z80. – forest Sep 16 '18 at 0:23
5

I developed few game on the GBA back in the days and I remember that I looked into using the Z80 but found nothing in the official documentation. Even if possible, it is an unsupported feature and therefore I doubt that any Nintendo approved game uses it.

  • It would be interesting to find out if it was physically possible. The Nintendo DS for example has both an ARM9 and ARM7 processor, and the latter is downclocked and used on its own to run GBA games, but even NDS games can make use of both processors simultaneously (although Nintendo requires that game makers only use the ARM7 to offload audio and networking processing). I wonder if the GBA can do that as well. – forest Jul 22 at 6:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.