Hello, in my new target myrdk I have a Sound Processor AY-3-8910. This is operated with its own clock of 2 Mhz at pin 22. The file psgtest.c is now running on my system.
The entire system with the Z80 CPU runs at a clock rate of 4 Mhz.
Question: in which file do I set the clock rate for the sound processor?
Is it the file psg.h with the lines
#ifdef __MYRDK__
#define psgT(hz) ((int)(2000000 / (hz)))
#endif
Answers are welcome
Sound Processor AY-3-8910, clock rate is different to CPU clock rate
Re: Sound Processor AY-3-8910, clock rate is different to CPU clock rate
You're right.
https://github.com/z88dk/z88dk/blob/mas ... lude/psg.h
The main CPU clock, for bit-banging code, in turn, would go here:
https://github.com/z88dk/z88dk/blob/mas ... de/sound.h
https://github.com/z88dk/z88dk/blob/mas ... lude/psg.h
The main CPU clock, for bit-banging code, in turn, would go here:
https://github.com/z88dk/z88dk/blob/mas ... de/sound.h