mirror of
https://github.com/zeldaret/oot.git
synced 2025-02-21 22:35:23 +00:00
Revert "Remove ASCII_TO_U32
, use 'IS64'
"
This reverts commit c801337dde
.
This commit is contained in:
parent
3a4374f266
commit
10b09e62c1
1 changed files with 3 additions and 2 deletions
|
@ -3,12 +3,13 @@
|
||||||
OSPiHandle* sISVHandle; // official name : is_Handle
|
OSPiHandle* sISVHandle; // official name : is_Handle
|
||||||
|
|
||||||
#define gISVDbgPrnAdrs ((ISVDbg*)0xB3FF0000)
|
#define gISVDbgPrnAdrs ((ISVDbg*)0xB3FF0000)
|
||||||
|
#define ASCII_TO_U32(a, b, c, d) ((u32)((a << 24) | (b << 16) | (c << 8) | (d << 0)))
|
||||||
|
|
||||||
void isPrintfInit(void) {
|
void isPrintfInit(void) {
|
||||||
sISVHandle = osCartRomInit();
|
sISVHandle = osCartRomInit();
|
||||||
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->put, 0);
|
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->put, 0);
|
||||||
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->get, 0);
|
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->get, 0);
|
||||||
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->magic, 'IS64');
|
osEPiWriteIo(sISVHandle, (u32)&gISVDbgPrnAdrs->magic, ASCII_TO_U32('I', 'S', '6', '4'));
|
||||||
}
|
}
|
||||||
|
|
||||||
void osSyncPrintfUnused(const char* fmt, ...) {
|
void osSyncPrintfUnused(const char* fmt, ...) {
|
||||||
|
@ -46,7 +47,7 @@ void* is_proutSyncPrintf(void* arg, const char* str, u32 count) {
|
||||||
s32 end;
|
s32 end;
|
||||||
|
|
||||||
osEPiReadIo(sISVHandle, (u32)&gISVDbgPrnAdrs->magic, &data);
|
osEPiReadIo(sISVHandle, (u32)&gISVDbgPrnAdrs->magic, &data);
|
||||||
if (data != 'IS64') {
|
if (data != ASCII_TO_U32('I', 'S', '6', '4')) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
osEPiReadIo(sISVHandle, (u32)&gISVDbgPrnAdrs->get, &data);
|
osEPiReadIo(sISVHandle, (u32)&gISVDbgPrnAdrs->get, &data);
|
||||||
|
|
Loading…
Add table
Reference in a new issue