2023-10-13 07:50:53 +00:00
|
|
|
#ifndef GLOBAL_H
|
|
|
|
#define GLOBAL_H
|
|
|
|
|
2023-10-29 21:19:30 +00:00
|
|
|
#include "PR/xstdio.h"
|
2023-10-23 20:02:01 +00:00
|
|
|
#include "PR/os_internal.h"
|
2023-10-29 21:19:30 +00:00
|
|
|
#include "PR/controller.h"
|
2023-10-23 20:02:01 +00:00
|
|
|
#include "libultra/ultra64.h"
|
|
|
|
#include "libc/math.h"
|
|
|
|
#include "libc/stdarg.h"
|
|
|
|
#include "libc/stdbool.h"
|
|
|
|
#include "libc/stdint.h"
|
|
|
|
#include "libc/stddef.h"
|
|
|
|
#include "libc/string.h"
|
2023-10-13 07:50:53 +00:00
|
|
|
#include "functions.h"
|
|
|
|
#include "variables.h"
|
2023-10-23 16:01:29 +00:00
|
|
|
#include "structs.h"
|
2023-10-13 07:50:53 +00:00
|
|
|
#include "macros.h"
|
2023-10-18 22:54:19 +00:00
|
|
|
#include "sf64math.h"
|
2023-11-13 16:18:43 +00:00
|
|
|
#include "gfx.h"
|
2023-10-13 07:50:53 +00:00
|
|
|
|
2023-11-12 22:49:03 +00:00
|
|
|
typedef enum {
|
2023-11-24 19:11:20 +00:00
|
|
|
SI_READ_CONTROLLER = 10,
|
|
|
|
SI_READ_SAVE,
|
|
|
|
SI_WRITE_SAVE,
|
|
|
|
SI_RUMBLE,
|
|
|
|
SI_SAVE_FAILED,
|
|
|
|
SI_SAVE_SUCCESS,
|
|
|
|
SI_CONT_READ_DONE,
|
2023-11-12 22:49:03 +00:00
|
|
|
} SerialMesg;
|
|
|
|
|
|
|
|
#define MSG_QUEUE_EMPTY -1
|
|
|
|
|
|
|
|
#define FAULT_MESG_BREAK 1
|
|
|
|
#define FAULT_MESG_FAULT 2
|
|
|
|
|
|
|
|
#define TASK_MESG_1 1
|
|
|
|
#define TASK_MESG_2 2
|
|
|
|
|
|
|
|
#define EVENT_MESG_SP 1
|
|
|
|
#define EVENT_MESG_DP 2
|
|
|
|
#define EVENT_MESG_VI 3
|
|
|
|
#define EVENT_MESG_PRENMI 4
|
|
|
|
|
2023-11-07 22:32:09 +00:00
|
|
|
typedef enum {
|
|
|
|
THREAD_ID_SYSTEM,
|
|
|
|
THREAD_ID_IDLE,
|
|
|
|
THREAD_ID_FAULT,
|
|
|
|
THREAD_ID_MAIN,
|
|
|
|
THREAD_ID_4,
|
|
|
|
THREAD_ID_AUDIO,
|
|
|
|
THREAD_ID_GRAPHICS,
|
|
|
|
THREAD_ID_7,
|
2023-11-12 22:49:03 +00:00
|
|
|
THREAD_ID_SERIAL,
|
2023-11-07 22:32:09 +00:00
|
|
|
} ThreadID;
|
|
|
|
|
2023-10-13 09:19:10 +00:00
|
|
|
#endif // GLOBAL_H
|