X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=Pico%2FPicoInt.h;h=c7b72a2147f9e9c371e7996e64532cd95e1e770d;hb=1cd356a33daf2eec34e52c075b06d62866f5fb2f;hp=64768b17b55328467bdeb95010da49cc3f1b4013;hpb=b837b69b3fcff1737431c8be1c78d1cfd64003a6;p=picodrive.git diff --git a/Pico/PicoInt.h b/Pico/PicoInt.h index 64768b1..c7b72a2 100644 --- a/Pico/PicoInt.h +++ b/Pico/PicoInt.h @@ -164,12 +164,35 @@ struct PicoSRAM #include "cd/LC89510.h" #include "cd/gfx_cd.h" +struct mcd_pcm +{ + unsigned char control; // reg7 + unsigned char enabled; // reg8 + unsigned char cur_ch; + unsigned char bank; + int pad1; + + struct pcm_chan + { + unsigned char regs[8]; + unsigned int addr; // played sample address + int pad; + } ch[8]; +}; + struct mcd_misc { unsigned short hint_vector; unsigned char busreq; - unsigned char pad0; - + unsigned char s68k_pend_ints; + unsigned int state_flags; // emu state: reset_pending, + unsigned int counter75hz; + unsigned short audio_offset; // for savestates: play pointer offset (0-1023) + unsigned char audio_track; // playing audio track # (zero based) + char pad1; + int timer_int3; + unsigned int timer_stopwatch; + int pad[10]; }; typedef struct @@ -180,8 +203,14 @@ typedef struct unsigned char prg_ram_b[4][0x20000]; }; unsigned char word_ram[0x40000]; // 256K + union { + unsigned char pcm_ram[0x10000]; // 64K + unsigned char pcm_ram_b[0x10][0x1000]; + }; unsigned char bram[0x2000]; // 8K - unsigned char s68k_regs[0x200]; + unsigned char s68k_regs[0x200]; // GA, not CPU regs + struct mcd_pcm pcm; + _scd_toc TOC; // not to be saved CDD cdd; CDC cdc; _scd scd; @@ -191,6 +220,13 @@ typedef struct #define Pico_mcd ((mcd_state *)Pico.rom) +// Area.c +int PicoAreaPackCpu(unsigned char *cpu, int is_sub); +int PicoAreaUnpackCpu(unsigned char *cpu, int is_sub); + +// cd/Area.c +int PicoCdSaveState(void *file); +int PicoCdLoadState(void *file); // Draw.c int PicoLine(int scan);