rust3ds / ctru-rs

Rust wrapper for libctru
https://rust3ds.github.io/ctru-rs/
Other
116 stars 17 forks source link

Implement UDS service with example #156

Closed Jhynjhiruu closed 3 months ago

Jhynjhiruu commented 5 months ago

This PR adds basic local networking functionality with the UDS service. It's very much not feature-complete, but enough is implemented to be able to interface with the devkitPRO local networking example - i.e. joining a network, creating a network, sending and pulling packets, and basic configuration. This is probably enough functionality for most homebrew applications, and I plan to try and implement a Download Play sniffer with it.

Todo: finish implementing the rest of the functions; test properly; cleanup code?

An example is included (local-networking.rs; this is a mostly-but-not-entirely-complete port of the devkitPRO local networking example).

Jhynjhiruu commented 5 months ago

Is there any way I can test things out, maybe with an emulator?

I've looked a little bit into it and I think it's maybe possible to connect to a 3DS's network with another device, but it'd require more knowledge about how Wi-Fi works than I have. I think Citra supports relaying local networking data for multiplayer, but I don't know how to set it up.

Jhynjhiruu commented 5 months ago

Functions left to implement:

So, only about 5½ that would be actually useful, and they're mostly trivial.