X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=Pico%2FPicoInt.h;h=0daac2e094bb61354fc313414f0afc27948563d2;hb=2b1f0e25193de382c6578fcf8e5edeaa37a21555;hp=664c2f2b4343fcf1677e36bc9176e79dda23441e;hpb=2aa27095f2dbf5b38950fcb1f856d5ffc6a70361;p=picodrive.git diff --git a/Pico/PicoInt.h b/Pico/PicoInt.h index 664c2f2..0daac2e 100644 --- a/Pico/PicoInt.h +++ b/Pico/PicoInt.h @@ -237,7 +237,8 @@ struct PicoVideo int status; // Status bits unsigned char pending_ints; // pending interrupts: ??VH???? signed char lwrite_cnt; // VDP write count during active display line - unsigned char pad[0x12]; + unsigned short v_counter; // V-counter + unsigned char pad[0x10]; }; struct PicoMisc @@ -436,7 +437,7 @@ extern struct Pico Pico; extern struct PicoSRAM SRam; extern int emustatus; extern void (*PicoResetHook)(void); -extern void (*PicoLineHook)(int count); +extern void (*PicoLineHook)(void); PICO_INTERNAL int CheckDMA(void); PICO_INTERNAL void PicoDetectRegion(void); PICO_INTERNAL void PicoSyncZ80(int m68k_cycles_done); @@ -475,8 +476,8 @@ PICO_INTERNAL void cdda_start_play(); extern short cdda_out_buffer[2*1152]; extern int PsndLen_exc_cnt; extern int PsndLen_exc_add; -extern int timer_a_next_oflow, timer_a_step, timer_a_offset; // in z80 cycles -extern int timer_b_next_oflow, timer_b_step, timer_b_offset; +extern int timer_a_next_oflow, timer_a_step; // in z80 cycles +extern int timer_b_next_oflow, timer_b_step; void ym2612_sync_timers(int z80_cycles, int mode_old, int mode_new); void ym2612_pack_state(void); @@ -497,13 +498,14 @@ void ym2612_unpack_state(void); #define timers_reset() \ timer_a_next_oflow = timer_b_next_oflow = TIMER_NO_OFLOW; \ - timer_a_step = timer_a_offset = TIMER_A_TICK_ZCYCLES * 1024; \ - timer_b_step = timer_b_offset = TIMER_B_TICK_ZCYCLES * 256; + timer_a_step = TIMER_A_TICK_ZCYCLES * 1024; \ + timer_b_step = TIMER_B_TICK_ZCYCLES * 256; // VideoPort.c PICO_INTERNAL_ASM void PicoVideoWrite(unsigned int a,unsigned short d); PICO_INTERNAL_ASM unsigned int PicoVideoRead(unsigned int a); +PICO_INTERNAL_ASM unsigned int PicoVideoRead8(unsigned int a); extern int (*PicoDmaHook)(unsigned int source, int len, unsigned short **srcp, unsigned short **limitp); // Misc.c