aboutsummaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c25
1 files changed, 24 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index 658fc94..d8191b6 100644
--- a/src/main.c
+++ b/src/main.c
@@ -12,7 +12,30 @@ void hh_ppu_vblank_interrupt() {
#ifdef HH_TARGET_DESKTOP
if (g_hh_test_complete) return;
#endif
- hh_ppu_vram_dwrite((uint8_t*) HH_PPUINTDEMO_ARR, HH_PPUINTDEMO_LENGTH);
+ // // uint8_t test[4] = { 0x0f, 0x0f, 0xf0, 0xf0 };
+ // uint8_t* test = malloc(4);
+ // test[0] = 0x00;
+ // test[1] = 0x00;
+ // test[2] = 0x00;
+ // test[3] = 0x00;
+ // while (1)
+ // hh_ppu_vram_dwrite(test, 4);
+ // return;
+ if (1) {
+ hh_ppu_vram_dwrite((uint8_t*) HH_PPUINTDEMO_ARR, HH_PPUINTDEMO_LENGTH);
+ }
+ if (0) {
+ for (size_t i = 0; i < HH_PPUINTDEMO_LENGTH; i += 4) {
+ if (i+4 > HH_PPUINTDEMO_LENGTH) break;
+ uint8_t test[4] = {
+ HH_PPUINTDEMO_ARR[i+0],
+ HH_PPUINTDEMO_ARR[i+1],
+ HH_PPUINTDEMO_ARR[i+2],
+ HH_PPUINTDEMO_ARR[i+3],
+ };
+ hh_ppu_vram_dwrite(test, 4);
+ }
+ }
g_hh_test_complete = true;
}