GameBoy Advance Barebones: Difference between revisions
[unchecked revision] | [unchecked revision] |
Content deleted Content added
No edit summary |
|||
Line 146:
This is a quick and dirty explanation of the earlier code. Those previously mentioned warped minds for whom this section is intended will probably prefer it that way. A more detailed discussion will be given later.
As I said, GBA programming is low-level programming and sometimes goes right down to the bit. The ''0x04000000'' and ''0x06000000'' are parts of the accessible memory sections. These numbers themselves don't mean much, by the way; they just refer to different sections. There aren't really ''0x02000000'' between these two sections. As you can see in the memory map, these two sections are for the IO registers and VRAM, respectively.
To work with these sections in C, we have to make pointers out of them, which is what the
The word at ''0400:0000'' contains the main bits for the display control. By writing 0x0403 into it, we tell the GBA to use video mode 3 and activate background 2. What this actually means will be explained in the video and bitmap mode chapters.
In mode 3, VRAM is a 16-bit bitmap; when we make a halfword pointer for it, each entry is a pixel. This bitmap itself is the same size as the screen
== Links ==
|