PS2SDK
PS2 Homebrew Libraries
iopdebug.h
Go to the documentation of this file.
1 /*
2 # _____ ___ ____ ___ ____
3 # ____| | ____| | | |____|
4 # | ___| |____ ___| ____| | \ PS2DEV Open Source Project.
5 #-----------------------------------------------------------------------
6 # Copyright 2001-2009, ps2dev - http://www.ps2dev.org
7 # Licenced under Academic Free License version 2.0
8 # Review ps2sdk README & LICENSE files for further details.
9 */
10 
17 #ifndef __IOPDEBUG_H__
18 #define __IOPDEBUG_H__
19 
20 #include <types.h>
21 #include <irx.h>
22 #include <iop_cop0_defs.h>
23 #include <ps2_debug.h>
24 
25 typedef void (IOP_ExceptionHandler)(IOP_RegFrame *);
26 
27 extern int iop_dbg_install(void);
28 extern int iop_dbg_remove(void);
29 extern IOP_ExceptionHandler *iop_dbg_get_handler(int cause);
30 extern IOP_ExceptionHandler *iop_dbg_set_handler(int cause, IOP_ExceptionHandler *handler);
31 extern void iop_dbg_get_reg_frames(IOP_RegFrame **def_frame_ptr, IOP_RegFrame **dbg_frame_ptr);
32 extern u32 iop_dbg_get_dcic(void);
33 extern void iop_dbg_set_dcic(u32 v);
34 
35 extern u32 iop_dbg_get_bpc(void);
36 extern void iop_dbg_set_bpc(u32 v);
37 
38 extern u32 iop_dbg_get_bpcm(void);
39 extern void iop_dbg_set_bpcm(u32 v);
40 
41 extern u32 iop_dbg_get_bda(void);
42 extern void iop_dbg_set_bda(u32 v);
43 extern u32 iop_dbg_get_bdam(void);
44 extern void iop_dbg_set_bdam(u32 v);
45 
46 extern void iop_dbg_set_bpr(u32 addr, u32 mask, u32 user_mask);
47 extern void iop_dbg_set_bpw(u32 addr, u32 mask, u32 user_mask);
48 extern void iop_dbg_set_bpx(u32 addr, u32 mask, u32 user_mask);
49 
50 extern void iop_dbg_clr_bps(void);
51 extern void iop_dbg_clr_bpda(void);
52 extern void iop_dbg_clr_bpx(void);
53 
54 #define iopdebug_IMPORTS_start DECLARE_IMPORT_TABLE(iopdebug, 1, 1)
55 #define iopdebug_IMPORTS_end END_IMPORT_TABLE
56 
57 #define I_iop_dbg_install DECLARE_IMPORT(5, iop_dbg_install)
58 #define I_iop_dbg_remove DECLARE_IMPORT(6, iop_dbg_remove)
59 #define I_iop_dbg_get_handler DECLARE_IMPORT(7, iop_dbg_get_handler)
60 #define I_iop_dbg_set_handler DECLARE_IMPORT(8, iop_dbg_set_handler)
61 #define I_iop_dbg_get_reg_frames DECLARE_IMPORT(9, iop_dbg_get_reg_frames)
62 #define I_iop_dbg_get_dcic DECLARE_IMPORT(10, iop_dbg_get_dcic)
63 #define I_iop_dbg_set_dcic DECLARE_IMPORT(11, iop_dbg_set_dcic)
64 #define I_iop_dbg_get_bpc DECLARE_IMPORT(12, iop_dbg_get_bpc)
65 #define I_iop_dbg_set_bpc DECLARE_IMPORT(13, iop_dbg_set_bpc)
66 #define I_iop_dbg_get_bpcm DECLARE_IMPORT(14, iop_dbg_get_bpcm)
67 #define I_iop_dbg_set_bpcm DECLARE_IMPORT(15, iop_dbg_set_bpcm)
68 #define I_iop_dbg_bda DECLARE_IMPORT(16, iop_dbg_bda)
69 #define I_iop_dbg_set_bda DECLARE_IMPORT(17, iop_dbg_set_bda)
70 #define I_iop_dbg_bdam DECLARE_IMPORT(18, iop_dbg_bdam)
71 #define I_iop_dbg_set_bdam DECLARE_IMPORT(19, iop_dbg_bdam)
72 #define I_iop_dbg_set_bpr DECLARE_IMPORT(20, iop_dbg_set_bpr)
73 #define I_iop_dbg_set_bpw DECLARE_IMPORT(21, iop_dbg_set_bpw)
74 #define I_iop_dbg_set_bpx DECLARE_IMPORT(22, iop_dbg_bpx)
75 #define I_iop_dbg_clr_bps DECLARE_IMPORT(23, iop_dbg_clr_bps)
76 #define I_iop_dbg_clr_bpda DECLARE_IMPORT(24, iop_dbg_clr_bpda)
77 #define I_iop_dbg_clr_bpx DECLARE_IMPORT(25, iop_dbg_clr_bpx)
78 
79 #endif /* __IOPDEBUG_H__ */
st_IOP_RegFrame
Definition: ps2_debug.h:11
irx.h
iop_cop0_defs.h
ps2_debug.h