From: notaz Date: Tue, 27 Jun 2023 22:12:08 +0000 (+0300) Subject: testpico: more messing to better understand timers X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=438648dc884712056ad7cb0c02279c74f55f3c51;p=megadrive.git testpico: more messing to better understand timers --- diff --git a/testpico/asmtools.S b/testpico/asmtools.S index 807ac9a..6be859a 100644 --- a/testpico/asmtools.S +++ b/testpico/asmtools.S @@ -498,9 +498,16 @@ test_ym_ab_sync: beq 0b /* 10|8 */ 0: move.b #0x3f, (a1) /* 12 start a, clear */ - moveq.l #3, d1 /* 12 cycles for old flag to clear itself */ - nop - nop + move.w #(1800/10-1), d0 /* waste cycles */ +0: + dbra d0, 0b + + ymwrite a0, a1, #0x24, #0x00 /* 30 show that rewriting count */ + ymwrite a0, a1, #0x25, #0x00 /* 30 does nothing */ + ymwrite a0, a1, #0x26, #0x00 /* 30 */ + ymwrite a0, a1, #0x27, #0x0f /* 30 setting already set bits too */ + moveq.l #0, d0 + moveq.l #3, d1 0: move.b (a0), d0 and.b d1, d0