mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-29 01:03:41 +01:00
Implements a bunch of adhoc functions
This commit is contained in:
1 parent
122f19a3cf
commit
553f1d4e4e
3 files changed
+1788
-325
No files matched your search
@@ -806,3 +806,13 @@ template <int func(int, const char *, int)> void WrapI_ICI() {
|
||||
int retval = func(PARAM(0), Memory::GetCharPointer(PARAM(1)), PARAM(2));
|
||||
RETURN(retval);
|
||||
}
|
||||
|
||||
template<int func(int, void *, void *, void *, void *, u32, int)> void WrapI_IVVVVUI(){
|
||||
u32 retval = func(PARAM(0), Memory::GetPointer(PARAM(1)), Memory::GetPointer(PARAM(2)), Memory::GetPointer(PARAM(3)), Memory::GetPointer(PARAM(4)), PARAM(5), PARAM(6) );
|
||||
RETURN(retval);
|
||||
}
|
||||
|
||||
template<int func(int, const char *, u32, void *, int, int, int)> void WrapI_ICUVIII(){
|
||||
u32 retval = func(PARAM(0), Memory::GetCharPointer(PARAM(1)), PARAM(2), Memory::GetPointer(PARAM(3)), PARAM(4), PARAM(5), PARAM(6));
|
||||
RETURN(retval);
|
||||
}
|
||||
+8
-3
@@ -130,6 +130,7 @@ u32 sceNetTerm() {
|
||||
}
|
||||
|
||||
u32 sceWlanGetEtherAddr(u32 addrAddr) {
|
||||
// TODO: Read from config
|
||||
static const u8 fakeEtherAddr[6] = { 1, 2, 3, 4, 5, 6 };
|
||||
DEBUG_LOG(SCENET, "sceWlanGetEtherAddr(%08x)", addrAddr);
|
||||
for (int i = 0; i < 6; i++)
|
||||
@@ -138,14 +139,18 @@ u32 sceWlanGetEtherAddr(u32 addrAddr) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
u32 sceNetGetLocalEtherAddr(u32 addrAddr) {
|
||||
return sceWlanGetEtherAddr(addrAddr);
|
||||
}
|
||||
|
||||
u32 sceWlanDevIsPowerOn() {
|
||||
DEBUG_LOG(SCENET, "UNTESTED 0=sceWlanDevIsPowerOn()");
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
u32 sceWlanGetSwitchState() {
|
||||
DEBUG_LOG(SCENET, "UNTESTED sceWlanGetSwitchState()");
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
// Probably a void function, but often returns a useful value.
|
||||
@@ -348,7 +353,7 @@ const HLEFunction sceNet[] = {
|
||||
{0x281928A9, WrapU_V<sceNetTerm>, "sceNetTerm"},
|
||||
{0x89360950, WrapI_UU<sceNetEtherNtostr>, "sceNetEtherNtostr"},
|
||||
{0xd27961c9, WrapI_UU<sceNetEtherStrton>, "sceNetEtherStrton"},
|
||||
{0x0bf0a3ae, 0, "sceNetGetLocalEtherAddr"},
|
||||
{0x0bf0a3ae, WrapU_U<sceNetGetLocalEtherAddr>, "sceNetGetLocalEtherAddr"},
|
||||
{0x50647530, 0, "sceNetFreeThreadinfo"},
|
||||
{0xcc393e48, WrapI_U<sceNetGetMallocStat>, "sceNetGetMallocStat"},
|
||||
{0xad6844c6, 0, "sceNetThreadAbort"},
|
||||
|
||||
+1770
-322
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user