> while(REG_TM3D < 263){} //doesn't work
>
> while(REG_TM3D < 263){WaitVblank();} //works....
How is 'REG_TMD3D' defined? Is it volatile?
Waiting for Vblank within the while loop puts the CPU on halt until a Vblank
interrupt fires, so that happens at roughly 60Hz... That's probably not what
you want when you use a timer, because you won't be able to test the timer's
value while the CPU is on halt (you will only peek once a frame so the timer
will probably loop a few times in the meantime, depending on timer
frequency).
Jan-Lieuwe