gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

ASM > black screen

#21182 - realV - Tue May 25, 2004 2:24 pm

I got a question:

this is my asm code:

@include image.asm

init:
ldr r0,=0x4000000
ldr r1,=0x3
add r1,r1,=0x400
str r1,[r0]

ldr r0,=0x6000000
ldr r1,=gbaBitmap
ldr r2,=19200

load:

ldr r3,[r1]+4!
str r3,[r0]+4!
subs r2,r2,=0x1
bne load

loop:
b loop


i compile it with goldroad1.7 and ok i got a file main.gba

but when i test this programm on VisualBoyAdvance i god just a black screen and nothing more , the bitmap is loaded into memory but i dont know wats wrong ?

PS: Sorry for my anglish :)

#21185 - sasq - Tue May 25, 2004 3:17 pm

you should do a strh (not str) to set the DISPCNT register.

#21239 - realV - Wed May 26, 2004 10:19 am

hmm it works but only if i start VisualBoyAdvance from command line , i will try some other emu

#21271 - dagamer34 - Wed May 26, 2004 4:22 pm

I had the same problem too until I switched to GAS. It must be something with Goldroad.
_________________
Little kids and Playstation 2's don't mix. :(