USB Loader GX

Discussion in 'Wii - Backup Loaders' started by cyrex, Apr 19, 2009.

  1. smf

    smf GBAtemp Psycho!

    Member
    9
    Feb 23, 2009
    https://www.retrorgb.com/wii-480p-video-bug-discovered.html

    What we need now, is for launcher software such as USB Loader to include a real-time patch for this issue,

    I think they hope you'll scan the executable and patch it....
     
  2. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    That is what I am currently trying to implement in the USB-Loader GX but I wasn't able to get it to work yet (freezes at game boot) so that'll have to wait about two more weeks until I have access to a USB gecko again to debug this.
     
    Last edited by leseratte, Apr 29, 2019
    JacobM, MaeseJesus and alexander1970 like this.
  3. MaeseJesus

    MaeseJesus GBAtemp Fan

    Member
    6
    Apr 3, 2013
    Don't stress yourself, leseratte. We've gone years without even knowing this, we can wait a bit more.
     
    Cyan likes this.
  4. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    Got a first test version of the USB-Loader with the 480p patch to work. I tested it with MKWii, NSMB, Wii Sports and Wii Play (as these are the only four games I currently have on my flash drive). NSMB seems to be compiled with another version of the SDK than the other three games so it required a different patch.

    This debug version creates a log file "debug.txt" on the SD card. If the patch was successful, it will contain "Found offset for 480p patch - create branch from X to heap (Y)" with X and Y being some memory adresses. If it wasn't successful it will contain "Didn't find offset for 480p patch!". The patch will be applied all the time, without being tied to a specific video mode setting as it doesn't force any video mode and only has effect on 480p output.

    This version might break channel booting due to the debug logging (can only boot games, not channels) but this is just for testing anyways. It'd be cool if you could test some more games and check the log file to see if this patch works for most games or if there are more than these two variants that I need to add.
     

    Attached Files:

    Last edited by leseratte, Apr 29, 2019
    blackb0x, baco81, Cyan and 1 other person like this.
  5. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    thank you for your work.
    I tested it quickly, both MKWii PAL Last story PAL.
    I compared to 1271 but I didn't see what's different :(

    I checked the log, and it said it worked.
    Last story : Found offset for 480p patch - create branch from 0x806072e4 to heap (0x8179aaa0)
    MKWii : Found offset for 480p patch - create branch from 0x801bcddc to heap (0x817f0500)

    I forced PAL480p in the settings to be sure, I'm using hdtv+Wide option.
    I'll have to understand what I have to compare and how to see it. for now, the patch said it worked, but my eyes didn't see anything different in the game. I must be blind :lol:
     
    Last edited by Cyan, Apr 29, 2019
  6. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    It depends on the console as well. On WiiU and on newer Wiis the patch is useless (Nintendo seems to have fixed the bug in hardware), it only seems to change something on older Wiis.
     
  7. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    It's a launch day Wii, so I guess I just don't know what I have to look for.
    but if you tested it, it means it works.

    do you need help to find the address for older SDK? maybe having some log at game launch we can provide?

    Attention, some games have memory patching detection like Kirby. These games shouldn't have the patch applied unless they are using gameconfig.txt to bypass the check.
    I don't know if your patch will be detected or not. I don't have that game to test, but I have prince of persia I can test with. I suppose making it an option will be required in that case.

    edit:
    first test, bad result. the game didn't even boot. usually it boots, but freeze at the intro when memory is patched.
    second test without the patch, the game works fine.
    third test with patch again : I confirm prince of persia forgotten sands doesn't boot at all with the patch. it's worse than the usual memory patch detection.
    Found offset for 480p patch - create branch from 0x80777314 to heap (0x817e67e0)
     
    Last edited by Cyan, Apr 29, 2019
  8. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    I don't know if there are other versions of the SDK than the two I've already found. There is no easy way for me to make the loader print any useful information for games where it doesn't find anything (because, well, it didn't find anything). So if there are other versions of the SDK where that code part differs (If there are games where that patch says that it failed) I would need the main.dol from the game to manually add a proper detection for that version to the loader.

    I didn't know there are games that check for memory modification - how is that handled with gecko codes? Does the loader then apply a patch to remove that detection and do I need to somehow trigger it from my code as well?
    Yeah, might be useful making it an option then.
     
    Last edited by leseratte, Apr 29, 2019
  9. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    each game with that patch detection function (Meta fortress) needs a specific gameconfig or cheat to patch it. I don't think it's a common function that you can detect, but maybe I'm wrong.
    if you want to take a look, I joined kirby's files (Crediar's work).

    geckocodes provides the needed gameconfig.txt when it exists.
    if nobody did a patch, then users can't apply some of the cheatcodes. for example, there's no cheatcode for prince of persia forgotten sands.
    if you check for kirby, you'll see that some cheatcodes can work without the patch, some require it.
    https://geckocodes.org/index.php?c=SUKE01

    games with Meta fortress are also broken with video mode patch, aspect ratio, game from another region, language patch, cheats, old "return to loader" method before using d2x method, etc.
     

    Attached Files:

    Last edited by Cyan, Apr 29, 2019
  10. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    That doesn't look like it could easily be done generically. I guess the best way would then be to make the 480p fix a setting and not apply it all the time so it can be disabled for these games.
     
  11. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    yes, I'll add an option in individual game settings.
    let's wait for more users to test your patch :)
     
    baco81 likes this.
  12. baco81

    baco81 Member

    Newcomer
    3
    Jan 19, 2017
    I have limited free time but I'll try the debug version as soon as possible.

    Recommended games to test? or just random ones?
     
    Last edited by baco81, May 2, 2019
  13. leseratte

    leseratte Wiimmfi Team

    Member
    5
    Jun 2, 2012
    Germany
    Yeah, any game. Test if it still boots, then check the debug.txt file to see if the patch worked.
     
  14. ThaCrip

    ThaCrip Member

    Newcomer
    1
    Nov 28, 2018
    United States
    I noticed a moment ago when updating the .xml file with parental lock that it claims it's up to date and won't let me attempt any further updates, which I need to do as the parental controls are not filtering properly.

    that's a problem now because before I had to update it after adding new games so parental lock would work. but it appears they must have done something with that .xml website as after you update it, it won't let you update it again as it claims it's up to date and that's a problem because I need to do that to get it working properly with the parental controls.

    any suggestions?

    is there anyway to wipe the .xml file info and re-download it clean etc?

    p.s. basically it's in relation to my previous post here... https://gbatemp.net/threads/usb-loader-gx.149922/page-1281#post-8431743
     
    Last edited by ThaCrip, May 3, 2019
  15. baco81

    baco81 Member

    Newcomer
    3
    Jan 19, 2017
    Ok, I tested a few games. Just two failed to boot.
    Tested games
    I checked the debug text file and it says that the offset for 480p patch was found on all of them.
     
    Last edited by baco81, May 3, 2019
    leseratte likes this.
  16. rafaelsb

    rafaelsb Member

    Newcomer
    2
    Sep 12, 2009
    Brazil
    Hey @Cyan, found that the SFX or effect volume option isn't saving its settings, the number is saved if you change it, but every time you reenter USBLoaderGX the volume is low.
     
  17. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    hmm, I'll check, but that's possible there aren't any volume option in GXGlobal config file.

    Ohh, I would have thought Kirby wouldn't work. did you try playing it until the usual crash spot in case of cheatcode use? do you have gameconfig.txt to allow patches? maybe the 480p patch doesn't trigger the MetaFortress protection.
    I wouldn't have thought the two non working games would be these ones.

    But, more importantly : Did you notice any visual change with/without the patch?
    I still don't see what improvement that patch does.
    I have a launch PAL Wii from 2006, on a 4k TV, using component cable, 480p wide screen option.

    probably because that's the case : it's up to date, and there's no new update to that database.
    I don't know why you have to update it manually to grab the data from it for newly added games. In my mind, the data were checked every time at loader's boot, and taken directly from the xml for new never added games, or from gamecache.bin file for existing/deleted/readded games.
    I don't know if there's a refresh button. I could check to add one instead of having to redownload the xml.
    until then, you'll have to delete the xml manually and re-update it from the update menu.
     
    Last edited by Cyan, May 3, 2019
  18. ThaCrip

    ThaCrip Member

    Newcomer
    1
    Nov 28, 2018
    United States
    But the last I knew you could still update it regardless of that. now it appears it will only update if there is a newer one which is why I now have a problem.

    Okay, ill have to play around with this soon and see what I can figure out. ill see if I can get things working again and then report back here probably in the next day or so as if I get that working, at least there is a temporary work around.
     
  19. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    22
    Oct 27, 2002
    France
    Engine room, learning
    probably because there were really an update.
    if a game has been added, or edited (even a single letter), the database version is incremented and the loader allows its update. if the database version is exactly the same number than the one on the website, it's refusing to update.
    it's not a website issue (unless unavailable, or broken), the version check is done on the loader's side to prevent waste bandwidth for the site.
     
  20. ThaCrip

    ThaCrip Member

    Newcomer
    1
    Nov 28, 2018
    United States
    @Cyan ; Even after a total removal of the USBLoaderGX v1271 program and refresh install, it still does the same thing pretty much.

    like after the basic clean install of v1271, I updated the covers for the games, then downloaded the .xml file and adjusted the settings to show only the games of Everyone (10+ and younger) (i.e. Controllevel = 1 (Child 7+)) and it still does not work as when you LOCK and UNLOCK the system, it still shows the same amount of games, which is everything on the system from E through M.

    any suggestions?

    p.s. is there anyway to manually select which games are removed from showing up on the menu when it's LOCKED vs UNLOCKED?
     
    Last edited by ThaCrip, May 3, 2019
Loading...