Replace BOOL by s32

This is for issue #18.
This commit is contained in:
Crayon2000 2017-10-02 22:50:17 -04:00
parent 8ded3004e8
commit 12aa7ca300
4 changed files with 43 additions and 43 deletions

View File

@ -273,18 +273,18 @@ void InitOSFunctionPointers(void)
OS_FIND_EXPORT(coreinit_handle, OSScreenPutPixelEx); OS_FIND_EXPORT(coreinit_handle, OSScreenPutPixelEx);
OS_FIND_EXPORT(coreinit_handle, DisassemblePPCRange); OS_FIND_EXPORT(coreinit_handle, DisassemblePPCRange);
OS_FIND_EXPORT(coreinit_handle, DisassemblePPCOpcode); OS_FIND_EXPORT(coreinit_handle, DisassemblePPCOpcode);
OS_FIND_EXPORT(coreinit_handle, OSGetSymbolName); OS_FIND_EXPORT(coreinit_handle, OSGetSymbolName);
OS_FIND_EXPORT(coreinit_handle, OSIsDebuggerInitialized); OS_FIND_EXPORT(coreinit_handle, OSIsDebuggerInitialized);
//!---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- //!----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
//! Thread functions //! Thread functions
//!---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- //!----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
OS_FIND_EXPORT(coreinit_handle, OSEnableInterrupts); OS_FIND_EXPORT(coreinit_handle, OSEnableInterrupts);
OS_FIND_EXPORT(coreinit_handle, __OSClearAndEnableInterrupt); OS_FIND_EXPORT(coreinit_handle, __OSClearAndEnableInterrupt);
OS_FIND_EXPORT(coreinit_handle, OSIsInterruptEnabled); OS_FIND_EXPORT(coreinit_handle, OSIsInterruptEnabled);
OS_FIND_EXPORT(coreinit_handle, OSIsDebuggerPresent); OS_FIND_EXPORT(coreinit_handle, OSIsDebuggerPresent);
OS_FIND_EXPORT(coreinit_handle, OSRestoreInterrupts); OS_FIND_EXPORT(coreinit_handle, OSRestoreInterrupts);
OS_FIND_EXPORT(coreinit_handle, OSSetDABR); OS_FIND_EXPORT(coreinit_handle, OSSetDABR);
OS_FIND_EXPORT(coreinit_handle, OSSetIABR); OS_FIND_EXPORT(coreinit_handle, OSSetIABR);
OS_FIND_EXPORT(coreinit_handle, OSCreateThread); OS_FIND_EXPORT(coreinit_handle, OSCreateThread);

View File

@ -35,10 +35,10 @@ typedef struct OSThreadLink_ {
} OSThreadLink; } OSThreadLink;
typedef struct OSThreadQueue_ { typedef struct OSThreadQueue_ {
OSThread *head; OSThread *head;
OSThread *tail; OSThread *tail;
void *parentStruct; void *parentStruct;
u32 reserved; u32 reserved;
} OSThreadQueue; } OSThreadQueue;
typedef struct OSMessage_ { typedef struct OSMessage_ {
@ -62,46 +62,46 @@ typedef struct OSMessageQueue_ {
} OSMessageQueue; } OSMessageQueue;
typedef struct OSContext_ { typedef struct OSContext_ {
char tag[8]; char tag[8];
u32 gpr[32]; u32 gpr[32];
u32 cr; u32 cr;
u32 lr; u32 lr;
u32 ctr; u32 ctr;
u32 xer; u32 xer;
u32 srr0; u32 srr0;
u32 srr1; u32 srr1;
u32 ex0; u32 ex0;
u32 ex1; u32 ex1;
u32 exception_type; u32 exception_type;
u32 reserved; u32 reserved;
double fpscr; double fpscr;
double fpr[32]; double fpr[32];
u16 spinLockCount; u16 spinLockCount;
u16 state; u16 state;
u32 gqr[8]; u32 gqr[8];
u32 pir; u32 pir;
double psf[32]; double psf[32];
u64 coretime[3]; u64 coretime[3];
u64 starttime; u64 starttime;
u32 error; u32 error;
u32 attributes; u32 attributes;
u32 pmc1; u32 pmc1;
u32 pmc2; u32 pmc2;
u32 pmc3; u32 pmc3;
u32 pmc4; u32 pmc4;
u32 mmcr0; u32 mmcr0;
u32 mmcr1; u32 mmcr1;
} OSContext; } OSContext;
typedef enum OSExceptionType typedef enum OSExceptionType
@ -137,7 +137,7 @@ struct OSThread_ {
int priority; int priority;
char _[0x394 - 0x330 - sizeof(OSThreadLink)]; char _[0x394 - 0x330 - sizeof(OSThreadLink)];
OSThreadLink linkActive; OSThreadLink linkActive;
void *stackBase; void *stackBase;
void *stackEnd; void *stackEnd;

View File

@ -53,7 +53,7 @@ extern u32 hostIpAddress;
#define SO_BROADCAST 0x0020 // broadcast #define SO_BROADCAST 0x0020 // broadcast
#define SO_NONBLOCK 0x1016 #define SO_NONBLOCK 0x1016
#define SO_MYADDR 0x1013 #define SO_MYADDR 0x1013
#define SO_RCVTIMEO 0x1006 #define SO_RCVTIMEO 0x1006
#define SOL_SOCKET -1 #define SOL_SOCKET -1
#define MSG_DONTWAIT 32 #define MSG_DONTWAIT 32

View File

@ -129,7 +129,7 @@ typedef struct
VPADTPData tpdata1; /* Modified touchscreen data 1 */ VPADTPData tpdata1; /* Modified touchscreen data 1 */
VPADTPData tpdata2; /* Modified touchscreen data 2 */ VPADTPData tpdata2; /* Modified touchscreen data 2 */
VPADDir dir; /* Orientation in three-dimensional space */ VPADDir dir; /* Orientation in three-dimensional space */
BOOL headphone; /* Set to TRUE if headphones are plugged in, FALSE otherwise */ s32 headphone; /* Set to TRUE if headphones are plugged in, FALSE otherwise */
Vec3D mag; /* Magnetometer data */ Vec3D mag; /* Magnetometer data */
u8 volume; /* 0 to 255 */ u8 volume; /* 0 to 255 */
u8 battery; /* 0 to 6 */ u8 battery; /* 0 to 6 */