]> git.sur5r.net Git - cc65/commitdiff
rename all waitvblank() to waitvsync()
authormrdudz <mrdudz@users.noreply.github.com>
Mon, 17 Jul 2017 21:15:05 +0000 (23:15 +0200)
committermrdudz <mrdudz@users.noreply.github.com>
Mon, 17 Jul 2017 21:15:05 +0000 (23:15 +0200)
24 files changed:
doc/funcref.sgml
doc/nes.sgml
doc/pce.sgml
doc/supervision.sgml
include/gamate.h
include/nes.h
include/pce.h
libsrc/c128/waitvblank.s [deleted file]
libsrc/c128/waitvsync.s [new file with mode: 0644]
libsrc/c64/waitvblank.s [deleted file]
libsrc/c64/waitvsync.s [new file with mode: 0644]
libsrc/cbm510/waitvblank.s [deleted file]
libsrc/cbm510/waitvsync.s [new file with mode: 0644]
libsrc/gamate/waitvblank.s [deleted file]
libsrc/gamate/waitvsync.s [new file with mode: 0644]
libsrc/nes/waitvblank.s [deleted file]
libsrc/nes/waitvsync.s [new file with mode: 0644]
libsrc/pce/waitvblank.s [deleted file]
libsrc/pce/waitvsync.s [new file with mode: 0644]
libsrc/vic20/waitvblank.s [deleted file]
libsrc/vic20/waitvsync.s [new file with mode: 0644]
testcode/lib/conio.c
testcode/lib/gamate/ctest.c
testcode/lib/pce/conio.c

index a2ccf6c73c653df3a0ddf395bbafd93085bea59c..b5295a63b28017b9e9890a593f98aae48270e1bc 100644 (file)
@@ -415,7 +415,7 @@ function.
 
 <!-- <itemize> -->
 <!-- <item><ref id="get_tv" name="get_tv"> -->
-<!-- <item><ref id="waitvblank" name="waitvblank"> -->
+<!-- <item><ref id="waitvsync" name="waitvsync"> -->
 <!-- </itemize> -->
 
 (incomplete)
index 98c25b6af934faebfab7f4bf3446f8f5fde2433b..31d1aa396c3b857960261d36ac262707462cc76b 100644 (file)
@@ -1,4 +1,4 @@
-<!doctype linuxdoc system>
+<!-- <!doctype linuxdoc system> //-->
 
 <article>
 
@@ -69,7 +69,7 @@ Programs containing NES specific code may use the <tt/nes.h/ header file.
 <sect1>NES specific functions<p>
 
 <itemize>
-<item>waitvblank - wait until the start of vblank
+<item>waitvsync - wait until the start of the next frame
 <item>get_tv
 </itemize>
 
index ba59c31a769a61f1e125b10208124f12c6db726e..124cb329eb34fdcb248c9bced3abec68908b03d8 100644 (file)
@@ -77,7 +77,7 @@ Programs containing PCE specific code may use the <tt/pce.h/ header file.
 <sect1>PCE specific functions<p>
 
 <itemize>
-<item>waitvblank</item>
+<item>waitvsync</item>
 <item>get_tv (since all PCE systems are NTSC, this always returns TV_NTSC)</item>
 </itemize>
 
index 97495dea58d2a8ef56d96b0350347f66c29a2688..2466aa480f1bf421e06baa5f1f2527c9951bd985 100644 (file)
@@ -66,7 +66,7 @@ Programs containing Supervision specific code may use the <tt/supervision.h/ hea
 <sect1>Supervision specific functions<p>
 
 <itemize>
-<item>waitvblank
+<item>waitvsync
 </itemize>
 
 
index 82bca08b1c5929efdf1278eaf9bff20f5ff9b174..96c70c9bcdeb1e12fb80742d0429e9ef5d5cccc8 100644 (file)
@@ -188,8 +188,8 @@ extern void gamate_stdjoy_joy[];   /* Referred to by joy_static_stddrv[] */
 #define JOY_START       6
 #define JOY_SELECT      7
 
-void waitvblank (void);
-/* Wait for the vertical blanking */
+void waitvsync (void);
+/* Wait for start of next frame */
 
 /* NOTE: all Gamate are "NTSC" */
 #define get_tv()        TV_NTSC
index a472a0f3c9cd587369163ae43a27cf54ca40ce1e..95e2fe93be3a5c5e6592e22c7fd4c579e3a02bc8 100644 (file)
@@ -163,8 +163,8 @@ extern void nes_64_56_2_tgi[];      /* Referred to by tgi_static_stddrv[] */
 
 
 
-void waitvblank (void);
-/* Wait for the vertical blanking */
+void waitvsync (void);
+/* Wait for start of the next frame */
 
 unsigned char get_tv (void);
 /* Return the video mode the machine is using. */
index 7700654c805244cebaab132934c10ae8c57c6760..856a2fa1d74ca2089ba3e7d3d695b4127153b219 100644 (file)
@@ -83,8 +83,8 @@ extern void pce_stdjoy_joy[];   /* Referred to by joy_static_stddrv[] */
 #define JOY_SELECT              6
 #define JOY_RUN                 7
 
-void waitvblank (void);
-/* Wait for the vertical blanking */
+void waitvsync (void);
+/* Wait for start of the next frame */
 
 /* NOTE: all PCE are NTSC */
 #define get_tv()                TV_NTSC
diff --git a/libsrc/c128/waitvblank.s b/libsrc/c128/waitvblank.s
deleted file mode 100644 (file)
index c144e11..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-
-        .export         _waitvblank
-
-        .include        "c128.inc"
-
-_waitvblank:
-
-        bit     MODE
-        bmi     @c80
-
-@l1:
-        bit     VIC_CTRL1
-        bpl     @l1
-@l2:
-        bit     VIC_CTRL1
-        bmi     @l2
-        rts
-
-@c80:
-        ;FIXME: do we have to switch banks?
-@l3:
-        lda     VDC_INDEX
-        and     #$20
-        beq     @l3
-        rts
diff --git a/libsrc/c128/waitvsync.s b/libsrc/c128/waitvsync.s
new file mode 100644 (file)
index 0000000..1597e5f
--- /dev/null
@@ -0,0 +1,25 @@
+
+        .export         _waitvsync
+
+        .include        "c128.inc"
+
+_waitvsync:
+
+        bit     MODE
+        bmi     @c80
+
+@l1:
+        bit     VIC_CTRL1
+        bpl     @l1
+@l2:
+        bit     VIC_CTRL1
+        bmi     @l2
+        rts
+
+@c80:
+        ;FIXME: do we have to switch banks?
+@l3:
+        lda     VDC_INDEX
+        and     #$20
+        beq     @l3
+        rts
diff --git a/libsrc/c64/waitvblank.s b/libsrc/c64/waitvblank.s
deleted file mode 100644 (file)
index dd90878..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-
-        .export         _waitvblank
-
-        .include        "c64.inc"
-
-_waitvblank:
-@l1:
-        bit     VIC_CTRL1
-        bpl     @l1
-@l2:
-        bit     VIC_CTRL1
-        bmi     @l2
-        rts
diff --git a/libsrc/c64/waitvsync.s b/libsrc/c64/waitvsync.s
new file mode 100644 (file)
index 0000000..15ef61b
--- /dev/null
@@ -0,0 +1,13 @@
+
+        .export         _waitvsync
+
+        .include        "c64.inc"
+
+_waitvsync:
+@l1:
+        bit     VIC_CTRL1
+        bpl     @l1
+@l2:
+        bit     VIC_CTRL1
+        bmi     @l2
+        rts
diff --git a/libsrc/cbm510/waitvblank.s b/libsrc/cbm510/waitvblank.s
deleted file mode 100644 (file)
index 975861f..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-
-        .export         _waitvblank
-        .import         PALFLAG
-        .import         sys_bank, restore_bank
-
-        .importzp       vic
-
-        .include        "cbm510.inc"
-
-_waitvblank:
-        rts     ; FIXME
-
-        jsr    sys_bank                ; Switch to the system bank
-
-        sei
-
-        ldy #VIC_CTRL1
-@l1:
-        lda (vic),y
-        bpl @l1
-@l2:
-        lda (vic),y
-        bmi @l2
-
-        cli
-        jmp    restore_bank
diff --git a/libsrc/cbm510/waitvsync.s b/libsrc/cbm510/waitvsync.s
new file mode 100644 (file)
index 0000000..bd631e4
--- /dev/null
@@ -0,0 +1,26 @@
+
+        .export         _waitvsync
+        .import         PALFLAG
+        .import         sys_bank, restore_bank
+
+        .importzp       vic
+
+        .include        "cbm510.inc"
+
+_waitvsync:
+        rts     ; FIXME
+
+        jsr    sys_bank                ; Switch to the system bank
+
+        sei
+
+        ldy #VIC_CTRL1
+@l1:
+        lda (vic),y
+        bpl @l1
+@l2:
+        lda (vic),y
+        bmi @l2
+
+        cli
+        jmp    restore_bank
diff --git a/libsrc/gamate/waitvblank.s b/libsrc/gamate/waitvblank.s
deleted file mode 100644 (file)
index 66686c0..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-;
-; void waitvblank (void);
-;
-
-        .include        "gamate.inc"
-        .include        "extzp.inc"
-
-        .forceimport    ticktock
-        .export         _waitvblank
-
-; FIXME: is this actually correct?
-
-.proc   _waitvblank
-
-        lda     tickcount
-@lp:    cmp     tickcount
-        beq     @lp
-        rts
-
-.endproc
diff --git a/libsrc/gamate/waitvsync.s b/libsrc/gamate/waitvsync.s
new file mode 100644 (file)
index 0000000..9b11990
--- /dev/null
@@ -0,0 +1,20 @@
+;
+; void waitvsync (void);
+;
+
+        .include        "gamate.inc"
+        .include        "extzp.inc"
+
+        .forceimport    ticktock
+        .export         _waitvsync
+
+; FIXME: is this actually correct?
+
+.proc   _waitvsync
+
+        lda     tickcount
+@lp:    cmp     tickcount
+        beq     @lp
+        rts
+
+.endproc
diff --git a/libsrc/nes/waitvblank.s b/libsrc/nes/waitvblank.s
deleted file mode 100644 (file)
index 4086469..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-;
-; Written by Groepaz/Hitmen <groepaz@gmx.net>
-; Cleanup by Ullrich von Bassewitz <uz@cc65.org>
-;
-; void waitvblank(void);
-;
-
-        .export _waitvblank
-
-        .include "nes.inc"
-
-.proc   _waitvblank
-
-wait:   lda     PPU_STATUS
-        bpl     wait
-        rts
-
-.endproc
diff --git a/libsrc/nes/waitvsync.s b/libsrc/nes/waitvsync.s
new file mode 100644 (file)
index 0000000..11a231a
--- /dev/null
@@ -0,0 +1,18 @@
+;
+; Written by Groepaz/Hitmen <groepaz@gmx.net>
+; Cleanup by Ullrich von Bassewitz <uz@cc65.org>
+;
+; void waitvsync(void);
+;
+
+        .export _waitvsync
+
+        .include "nes.inc"
+
+.proc   _waitvsync
+
+wait:   lda     PPU_STATUS
+        bpl     wait
+        rts
+
+.endproc
diff --git a/libsrc/pce/waitvblank.s b/libsrc/pce/waitvblank.s
deleted file mode 100644 (file)
index b9f0f90..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-;
-; void waitvblank (void);
-;
-
-        .include        "pce.inc"
-        .include        "extzp.inc"
-
-        .forceimport    ticktock
-        .export         _waitvblank
-
-.proc   _waitvblank
-
-        lda     tickcount
-@lp:    cmp     tickcount
-        beq     @lp
-        rts
-
-.endproc
diff --git a/libsrc/pce/waitvsync.s b/libsrc/pce/waitvsync.s
new file mode 100644 (file)
index 0000000..f1eab36
--- /dev/null
@@ -0,0 +1,18 @@
+;
+; void waitvsync (void);
+;
+
+        .include        "pce.inc"
+        .include        "extzp.inc"
+
+        .forceimport    ticktock
+        .export         _waitvsync
+
+.proc   _waitvsync
+
+        lda     tickcount
+@lp:    cmp     tickcount
+        beq     @lp
+        rts
+
+.endproc
diff --git a/libsrc/vic20/waitvblank.s b/libsrc/vic20/waitvblank.s
deleted file mode 100644 (file)
index 246c446..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-        .export         _waitvblank
-
-        .include        "vic20.inc"
-
-; FIXME
-; this flag doesnt work on vic20!!!
-; it will have to be filled by a get_tv() constructor or so
-PALFLAG                = $2A6          ; $01 = PAL, $00 = NTSC
-
-_waitvblank:
-        lda     PALFLAG
-        beq     @ntsc
-        ldx     #(312-8)/2
-        .byte $2c
-@ntsc:
-        ldx     #(262-8)/2
-@l2:
-        cpx     VIC_HLINE
-        bcs     @l2
-        rts
-
diff --git a/libsrc/vic20/waitvsync.s b/libsrc/vic20/waitvsync.s
new file mode 100644 (file)
index 0000000..9f0d505
--- /dev/null
@@ -0,0 +1,21 @@
+        .export         _waitvsync
+
+        .include        "vic20.inc"
+
+; FIXME
+; this flag doesnt work on vic20!!!
+; it will have to be filled by a get_tv() constructor or so
+PALFLAG                = $2A6          ; $01 = PAL, $00 = NTSC
+
+_waitvsync:
+        lda     PALFLAG
+        beq     @ntsc
+        ldx     #(312-8)/2
+        .byte $2c
+@ntsc:
+        ldx     #(262-8)/2
+@l2:
+        cpx     VIC_HLINE
+        bcs     @l2
+        rts
+
index fe977ec08ca2d11f45a7a32deb6e2359959732b7..13188d1cda650e9bf30d4605c637037b39c07a2b 100644 (file)
@@ -117,8 +117,8 @@ void main(void)
                 gotoxy(7 + inpos,1);
 
 #if defined(__NES__) || defined(__PCE__) || defined(__GAMATE__)
-                /* not all targets have waitvblank */
-                waitvblank();
+                /* not all targets have waitvsync */
+                waitvsync();
                 /* for targets that do not have a keyboard, read the first
                    joystick */
                 joy = joy_read(JOY_1);
index dfebd9befc8a12e31db163bbb96a0e0415554a4d..793770cee5615971b65adb75f55f819a18f3e8fd 100644 (file)
@@ -41,7 +41,7 @@ int main(int argc, char *argv[])
                 break;
         }
 
-        waitvblank();
+        waitvsync();
 
         (*((unsigned char*)LCD_XPOS)) = x;
         (*((unsigned char*)LCD_YPOS)) = y;
index a4bd63b153d03131ea4b57338e9a8816beccc85c..00ae3c15770a2b621d5f79d6b486a92778bc67fa 100644 (file)
@@ -123,7 +123,7 @@ void main(void)
                                 p[8],p[9],p[10],p[11],p[12],p[13],p[14],p[15]);
                 }
 
-                waitvblank();
+                waitvsync();
                 ++n;
         }
 }