![]() |
libElysianVMU 1.6.0
Full-featured, accurate, cross-platform library emulating the Dreamcast's Visual Memory Unit
|
Map of the VMU's various memory spaces.
The VMU is a strange beast with multiple disjoint address spaces for data, instructions, and more. Understanding the various segments of the memory map and their layout is required to master the VMU's architecture from a software perspective.
The following table shows the various segments and banks of the main RAM or the internal data address space. This address space is the target of regular data transfer instructions, unless otherwise specified. Spanning the memory space is XRAM, SFRs, and RAM. XRAM has 3 banks of 64, 64, and 16 bytes respectively. The SFR range spans 143 bytes. Main system memory is broken into two banks of 256 bytes each. Bank 0 contains the stack and is reserved for use by the BIOS and OS routines exclusively. Bank 1 is where the user's generic application memory resides.
Address | Bank 0 | Bank 1 | Bank 2 |
---|---|---|---|
1B0-1BF | XRAM - Upper Half of Framebuffer | XRAM - Lower Half of Framebuffer | UNUSED |
1A0-1AF | |||
190-19F | |||
180-18F | XRAM - Icons | ||
170-17F | Special Function Registers | UNUSED | UNUSED |
160-16F | |||
150-15F | |||
140-14F | |||
130-13F | |||
120-12F | |||
110-11F | |||
100-10F | |||
0F0-0FF | Stack Area | Application/User RAM | |
0E0-0EF | |||
0D0-0DF | |||
0C0-0CF | |||
0B0-0BF | |||
0A0-0AF | |||
090-09F | |||
080-08F | System/BIOS RAM | ||
070-07F | |||
060-06F | |||
050-05F | |||
040-04F | |||
030-03F | |||
020-02F | |||
010-01F | |||
000-00F |
Due to the fact that the VMU can execute either directly from the BIOS, residing on a built-in ROM chip, or from a GAME user application residing in flash, the device treats the instruction space as a generic memory space, which can swap between sourcing instructions between ROM and flash depending on the CPU state. ROM is a single chip spanning 64KB of space, while flash is 2 banks of 64KB each.
Address | ROM | Flash (Bank 0) | Flash (Bank 1) |
---|---|---|---|
F0FF-FFFF | UNUSED | For GAME/DATA Use | For DATA Use Only |
E000-EFFF | OS Program Area | ||
4000-DFFF | Reserved Area | ||
0000-3FFF | System Program Area |
Work RAM is an additional, separate memory space from main RAM. It offers the VMU an additional 512 bytes which can be utilized as more general-purpose storage when in standalone mode. While connected to a Dreamcast, this storage functions as a Maple TX/RX packet buffer for the Maple communications stack. WRAM is accessed one byte at a time, with a target address given by the two VRMAD SFRs (VRMAD1 and VRMAD2) and read/writes being issued via accessing the VTRBF SFR.
Address | Description |
---|---|
1FF | 512 Bytes Additional Work RAM |
... | |
000 |