Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nn/dlp: Add initial headers #389

Merged
merged 1 commit into from
Jul 13, 2024
Merged

Conversation

DaniElectra
Copy link
Contributor

@DaniElectra DaniElectra commented Jul 10, 2024

This is an initial implementation of Download Play (nn_dlp) on the Wii U. Research has revealed that there aren't any Wii U games that used this feature nor there could have been any, because the IOSU requires system archives that aren't present on the Wii U in order to initialize.

Homebrew that want to use this library must use Aroma 22 or later, as it adds the necessary permission group to let homebrew access DLP, and applies the necessary patches to make DLP usable. Otherwise, the console would crash as it doesn't have permission to use DLP.

The name of the DLP child MUST be like this: 00040001XXXXXXYY.cia, where XXXXXX is the input uniqueId and YY is the childIndex from the Initialize functions.

It should be noted that while the DLP child that is distributed is intended to be stored at /vol/content/dlp/app/TITLE_ID.cia, the reading of the file is performed on IOSU land, so Aroma's content redirection doesn't work here. This is worked around in Aroma 22 or later, which tries to read the DLP child from the SD card instead, inside sd:/dlp/app/TITLE_ID.cia.

Most of the input parameters have been named using the print logging that was present on the IOSU.

The mangled symbols of DLP seem to have the static label on them. Because of that, it's very likely that Server and ServerPrivate are classes, so they have been classified that way. I'm not sure if ServerPrivate should inherit Server, so at the moment it doesn't.

Research note: the State functions output the state as a uint32_t. However, they are stored internally as a uint8_t

This PR has been tested successfully using the Download Play client from the 3DS. A working example can be found here: https://github.com/DaniElectra/dlp-wiiu-test

@GaryOderNichts GaryOderNichts merged commit 0ae8f8a into devkitPro:master Jul 13, 2024
1 check passed
@GaryOderNichts
Copy link
Contributor

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants