YAWM-ModMii-Edition/source/sys.h

52 lines
1.1 KiB
C
Raw Normal View History

2017-10-16 11:55:29 +02:00
#ifndef _SYS_H_
#define _SYS_H_
2024-03-23 05:43:32 +01:00
/* /shared1/content.map entry */
typedef struct
{
char filename[8];
sha1 hash;
} ATTRIBUTE_PACKED SharedContent;
/* "cIOS build tag" */
enum
{
CIOS_INFO_MAGIC = 0x1EE7C105,
CIOS_INFO_VERSION = 1
};
typedef struct
{
u32 hdr_magic; // 0x1EE7C105
u32 hdr_version; // 1
u32 cios_version; // Eg. 11
u32 ios_base; // Eg. 60
char name[16];
char cios_version_str[16];
char _padding[16];
} cIOSInfo;
2024-04-22 15:06:01 +02:00
// _Static_assert(sizeof(cIOSInfo) == 0x40, "Incorrect cIOSInfo struct size, do i really need to pack this..?");
#define IS_WIIU (*(vu16*)0xCD005A0 == 0xCAFE)
2024-03-23 05:43:32 +01:00
extern u32 boot2version;
2024-04-22 15:06:01 +02:00
2017-10-16 11:55:29 +02:00
/* Prototypes */
bool isIOSstub(u8 ios_number);
bool tmdIsStubIOS(tmd*);
2017-10-16 11:55:29 +02:00
bool loadIOS(int ios);
2024-03-23 05:43:32 +01:00
bool ES_CheckHasKoreanKey(void);
2017-10-16 11:55:29 +02:00
void Sys_Init(void);
void Sys_Reboot(void);
void Sys_Shutdown(void);
void Sys_LoadMenu(void);
s32 Sys_GetCerts(signed_blob **, u32 *);
2024-03-23 05:43:32 +01:00
bool Sys_GetcIOSInfo(int IOS, cIOSInfo*);
s32 Sys_GetSharedContents(SharedContent** out, u32* count);
bool Sys_SharedContentPresent(tmd_content* content, SharedContent shared[], u32 count);
void SetPRButtons(bool enabled);
2017-10-16 11:55:29 +02:00
#endif