--- hatari/src/falcon/dsp.h 2019/04/09 08:48:47 1.1.1.4 +++ hatari/src/falcon/dsp.h 2019/04/09 08:58:17 1.1.1.10 @@ -16,8 +16,8 @@ GNU General Public License for more details. You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + along with this program; if not, write to the Free Software Foundation, + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA */ #ifndef DSP_H @@ -27,15 +27,20 @@ # include "dsp_core.h" #endif -#define DSP_FREQ (CPU_FREQ*4) +#define DSP_CPU_FREQ_RATIO 2 /* Dsp Freq = 2 * Cpu Freq (32 MHz vs 16 MHz on Falcon) */ extern bool bDspEnabled; extern bool bDspHostInterruptPending; +extern Uint64 DSP_CyclesGlobalClockCounter; + /* Dsp commands */ +extern bool DSP_ProcessIRQ(void); extern void DSP_Init(void); extern void DSP_UnInit(void); extern void DSP_Reset(void); +extern void DSP_Enable(void); +extern void DSP_Disable(void); extern void DSP_Run(int nHostCycles); /* Save Dsp state to snapshot */ @@ -43,13 +48,16 @@ extern void DSP_MemorySnapShot_Capture(b /* Dsp Debugger commands */ extern void DSP_SetDebugging(bool enabled); +extern Uint16 DSP_GetPC(void); +extern Uint16 DSP_GetNextPC(Uint16 pc); +extern Uint16 DSP_GetInstrCycles(void); extern Uint32 DSP_ReadMemory(Uint16 addr, char space, const char **mem_str); -extern Uint16 DSP_DisasmMemory(Uint16 dsp_memdump_addr, Uint16 dsp_memdump_upper, char space); -extern Uint32 DSP_DisasmAddress(Uint16 lowerAdr, Uint16 UpperAdr); -extern void DSP_DisasmRegisters(void); +extern Uint16 DSP_DisasmMemory(FILE *fp, Uint16 dsp_memdump_addr, Uint16 dsp_memdump_upper, char space); +extern Uint16 DSP_DisasmAddress(FILE *out, Uint16 lowerAdr, Uint16 UpperAdr); +extern void DSP_Info(FILE *fp, Uint32 dummy); +extern void DSP_DisasmRegisters(FILE *fp); extern int DSP_GetRegisterAddress(const char *arg, Uint32 **addr, Uint32 *mask); extern bool DSP_Disasm_SetRegister(const char *arg, Uint32 value); -extern Uint16 DSP_GetPC(void); /* Dsp SSI commands */ extern Uint32 DSP_SsiReadTxValue(void); @@ -67,7 +75,8 @@ extern void DSP_SsiTransmit_SCK(void); /* Dsp Host interface commands */ extern void DSP_HandleReadAccess(void); extern void DSP_HandleWriteAccess(void); -extern Uint16 DSP_Get_HREQ(void); +extern Uint8 DSP_GetHREQ ( void ); +extern int DSP_ProcessIACK ( void ); #endif /* DSP_H */