overdrivenpotato / rust-psp

Rust on PSP. Panic and allocation support. Access PSP system libraries.
Other
601 stars 33 forks source link

SceWlan Implementation and ethernet example. #8

Closed IridescentRose closed 4 years ago

IridescentRose commented 4 years ago

Added the SceWlan module alongside a simple example which prints your switch and wlan device status alongside the IPv6 ethernet address of your device.

IridescentRose commented 4 years ago

Alright, this pull request now also adds the sceRtc functions for real time clock functionality!

sajattack commented 4 years ago

Minor nits: Could you surround the parameter names in backticks, and remove the "return stutter" of

# Return value

Return <0 on error.

This could be just

# Return value

<0 on error.
sajattack commented 4 years ago

Also, I'm not entirely happy with sce_rtc_check_valid but I'm not sure how to improve it. Ideally we'd wrap it in a Result, but I don't think that's possible with our current setup. The issue is, i32 and CheckValidErrors are different types. Oh, also try not to pluralize enum names.

IridescentRose commented 4 years ago

I'm not sure the way you want the i32 to enum implementation, so I leave it to you for decision.