comparison genesis.c @ 2466:b5640ac9aea9

Initial stab at PCM/ADPCM support in YMZ263B emulation
author Michael Pavone <pavone@retrodev.com>
date Sat, 24 Feb 2024 20:41:02 -0800
parents a4f8fa24764b
children aaf7bb58ffca
comparison
equal deleted inserted replaced
2465:b0408f38f464 2466:b5640ac9aea9
3178 if (stype == SYSTEM_COPERA) { 3178 if (stype == SYSTEM_COPERA) {
3179 gen->ymz = calloc(1, sizeof(*gen->ymz)); 3179 gen->ymz = calloc(1, sizeof(*gen->ymz));
3180 //This divider is just a guess, PCB diagram in MAME shows no other crystal 3180 //This divider is just a guess, PCB diagram in MAME shows no other crystal
3181 //Datasheet says the typical clock is 16.9344 MHz 3181 //Datasheet says the typical clock is 16.9344 MHz
3182 //Master clock / 3 is 17.897725 MHz which is reasonably close 3182 //Master clock / 3 is 17.897725 MHz which is reasonably close
3183 ymz263b_init(gen->ymz, 3); 3183 ymz263b_init(gen->ymz, gen->master_clock, 3);
3184 } 3184 }
3185 3185
3186 gen->work_ram = calloc(2, RAM_WORDS); 3186 gen->work_ram = calloc(2, RAM_WORDS);
3187 if (!strcmp("random", tern_find_path_default(config, "system\0ram_init\0", (tern_val){.ptrval = "zero"}, TVAL_PTR).ptrval)) 3187 if (!strcmp("random", tern_find_path_default(config, "system\0ram_init\0", (tern_val){.ptrval = "zero"}, TVAL_PTR).ptrval))
3188 { 3188 {