1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2024-05-28 23:41:32 +00:00
8bitworkshop/presets/c64/common.c
2022-08-09 13:28:55 -05:00

19 lines
286 B
C

#include "common.h"
void raster_wait(byte line) {
while (VIC.rasterline < line) ;
}
void wait_vblank(void) {
raster_wait(255);
}
static byte VIC_BANK_PAGE[4] = {
0xc0, 0x80, 0x40, 0x00
};
char* get_vic_bank_start(void) {
return (char*)(VIC_BANK_PAGE[CIA2.pra & 3] << 8);
}