Hacking USB Loader GX

  • Thread starter cyrex
  • Start date
  • Views 7,161,270
  • Replies 29,357
  • Likes 47

Cyan

GBATemp's lurking knight
Former Staff
Joined
Oct 27, 2002
Messages
23,749
Trophies
4
Age
45
Location
Engine room, learning
XP
15,649
Country
France
oh, thanks for that info :)

edit:
I see you set "3" instead of "2" for viMod.
to patch a game, I need to add 1 to its viMode? viMode |= 1
480p prog are all using value "2" or "16"

The loader can patch all the video modes listed in a game's dol, so the game will use the correct values when reloaded.
I'm not sure this is enough, nor if this is what I understood. sorry, I always fear to make mistakes. I suppose I can just try and see.

Code:
                                       ViMode
TVNtsc480Prog: 				02 0280 01e0 01e0 0028 0000 0280 01e0 00000000 0000 0000 060606060606060606060606060606060606060606060606 00001516150000 
TVNtsc480ProgSoft: 			02 0280 01e0 01e0 0028 0000 0280 01e0 00000000 0000 0000 060606060606060606060606060606060606060606060606 08080a0c0a0808 
TVNtsc480ProgAa: 			02 0280 00f2 01e0 0028 0000 0280 01e0 00000000 0000 0001 03090303090309030909030902060a02060a02060a02060a 04080c100c0804 

TVEurgb60Hz480Prog:                     16 0280 01e0 01e0 0006 0000 02c4 01e0 00000000 0000 0000 060606060606060606060606060606060606060606060606 00001516150000 
TVEurgb60Hz480ProgSoft:                 16 0280 01e0 01e0 0028 0000 0280 01e0 00000000 0000 0000 03090303090309030909030902060a02060a02060a02060a 04080c100c0804 
TVEurgb60Hz480ProgAa:                   16 0280 00f2 01e0 0028 0000 0280 01e0 00000000 0000 0001 060606060606060606060606060606060606060606060606 08080a0c0a0808



edit:
https://wiibrew.org/wiki/Hardware/AV_Encoder#Register_65h

I don't want to edit and mess wiibrew technical data myself, but I guess it could be helpful to add your info.
 
Last edited by Cyan,

bm123456

Well-Known Member
Member
Joined
Jun 7, 2011
Messages
576
Trophies
1
Age
46
Location
Houston
XP
1,312
Country
United States
Hey guys. I have a NTSC WII and trying to get Just Dance 2018 Pal working with Rev1253. I was wondering if the video patch or forcing NTSC has been changed since my revision. I load the game and it is black and white . The usual way was to force NTSC but all i get is black screen. Any help would be appreciated.
 

uyjulian

Homebrewer
Member
Joined
Nov 26, 2012
Messages
2,567
Trophies
2
Location
United States
Website
sites.google.com
XP
3,879
Country
United States
@Cyan here is a cheat code for Mario Kart Wii that implements the 480p fix: http://wiki.tockdom.com/wiki/User:Leseratte#480p_graphics_fix

Code:
480p fix PAL [Leseratte]
C21BCDDC 00000002
38600003 98610019
60000000 00000000

480p fix USA [Leseratte]
C21BCD3C 00000002
38600003 98610019
60000000 00000000

480p fix JAP [Leseratte]
C21BCCFC 00000002
38600003 98610019
60000000 00000000

480p fix KOR [Leseratte]
C21BD138 00000002
38600003 98610019
60000000 00000000
 

KB89

Active Member
Newcomer
Joined
Jun 7, 2014
Messages
31
Trophies
0
Age
35
XP
103
Country
United States
So I got my WD hdd in. It works great.

I used Wii Backup Manager to transfer the ISO's. It converted them to that wbfs format. Then I used WBFStoFat formatter.

Here is what I'm confused on... the installation and running of WADS on hdd. When USBGX loads up it loads from the SD card from what I can tell when I use the Homebrew Channel or the forwarder. USBGX boots and I see my ISOs (hdd) and any WADS (sd) I have installed using EmuNAND Wad Manager.

I can install a WAD to the HDD, but it won't run. It brings me back to the Wii Menu. It boots fine if installed to an SD Card.

I believe my WADS should get installed (usb)(sd):/NANDs folder correct?

I think USBGX is booting up from the SD card and running from the SD Card. So the WADS must be installed and ran from the SD Card as well. How do I boot USBGX from an HDD? Or am I mistaken on how to do this?

EDIT: I have no issue to use an SD Card to boot WADS, but before I buy a bigger SD card. I thought I might ask what I'm doing wrong.
EDIT: And is there a way to launch a game in 480i? So i could use the official button combinations to get 240p out of the console if I wanted it.
 
Last edited by KB89,

Cyan

GBATemp's lurking knight
Former Staff
Joined
Oct 27, 2002
Messages
23,749
Trophies
4
Age
45
Location
Engine room, learning
XP
15,649
Country
France
I think USBGX is booting up from the SD card and running from the SD Card. So the WADS must be installed and ran from the SD Card as well. How do I boot USBGX from an HDD? Or am I mistaken on how to do this?
the place where the boot.dol is located has nothing to do with compatibility.

installing channels without having a complete system copy on your device will not work.
if you want the emuNAND on USB, you need to change the path in the loader's settings.
settings > custom path > emuNAND Channel : usb1:/nands/nand1/ (or anything else)

then, you need to either :
- make a new full NAND dump
or
- move your emuNAND folder from SD to USB (be sure the path is correct in the settings!).



I don't understand why you had to use WBFS2FAT.
wiibackupmanager works with FAT32 can can convert iso to wbfs files, you didn't need to go through the WBFS partition format.
 
Last edited by Cyan,

leseratte

Wiimmfi Team
Member
Joined
Jun 2, 2012
Messages
453
Trophies
1
XP
1,859
Country
Germany
@Cyan if you want, I can try to implement the 480p display fix cheatcode directly in the USB-Loader (game-independantly), similar to how I implemented the new Wiimmfi patcher. If I read the in-game code correctly, messing with the video mode in the loader won't really help at all as the game resets all that at boot.
 
Last edited by leseratte,

Cyan

GBATemp's lurking knight
Former Staff
Joined
Oct 27, 2002
Messages
23,749
Trophies
4
Age
45
Location
Engine room, learning
XP
15,649
Country
France
Thank you for the proposition :)

I thought patching the video mode information inside the game's dol would be enough to set the registers correctly at game launch. I'm not talking about just changing the current video mode before launching the game, but really the video info used by the game at boot.
The loader already has an option to patch internal dol's video mode info that the game uses to init the video mode, but Extrems said it wouldn't work.
I'm not sure what the viMode info are used for in the dol if not for initializing the video. maybe they don't hold the oversampling info, or the game's SDK is just not designed to set that register even if supposed to.

if it needs an asm patch to communicate with I2C, then I'd gladly accept your help to add that oversampling option in the loader.
or do you think it should always be enabled if 480p is detected? I feel an option would be better to let the user revert it if needed, or if a game doesn't work with it.
if you do, could you please detail the ASM commands/values in the sources ? to see what it's doing, just by curiosity.
 
Last edited by Cyan,
  • Like
Reactions: Maeson

leseratte

Wiimmfi Team
Member
Joined
Jun 2, 2012
Messages
453
Trophies
1
XP
1,859
Country
Germany
In Mario Kart Wii (and other Wii games) there is "EGG::Video::initialize(GXRenderModeObj * r3)", which calls "VIInit()", which in turn calls "__VISetRevolutionModeSimple()", which contains the call to "__VISendI2CData()" with the wrong parameters. I just need to write some code that dynamically finds that code path in a game and patches it.

The loader functions to force a game mode can - if I remember correctly - only used to force the general video mode (PAL, PAL60, NTSC, ...), not the specific settings. The wrong parameter is directly embedded in the assembly code of the game and not loaded from any VI register so any normal video mode patches from the loader won't help with that.

Anyways, that function should be easy to localize in a generic patch. I'll test if that works. In my opinion it should definitely be a configurable option (and not just enabled by default) until we are sure that that automatic patch won't break any games.
 
Last edited by leseratte,

leseratte

Wiimmfi Team
Member
Joined
Jun 2, 2012
Messages
453
Trophies
1
XP
1,859
Country
Germany
That would probably be a task for someone more familiar with all the VI and display stuff than me. What are all these other patches for? Or are these already included in the USB-Loader GX anyways?
 
  • Like
Reactions: Maeson

JacobM

Well-Known Member
Member
Joined
Jun 16, 2017
Messages
242
Trophies
0
XP
599
Country
United States
Thank you Leseratte, Extrems, and Cyan for trying to hash this out! I am excited to test anything you guys cook up! I have a Wii with boot 2 (composite & component) and a WiiU (HDMI, but unaffected).

@leseratte I'm assuming MrBean is now in the loop about the 480p fix for MKWii? I mentioned it to him in his twitch stream when Extrems first discovered it, but his response sounded like he thought I was trolling him, haha :rofl:
 
Last edited by JacobM,

leseratte

Wiimmfi Team
Member
Joined
Jun 2, 2012
Messages
453
Trophies
1
XP
1,859
Country
Germany
I did tell MrBean about the fact that such a bug exists and that I made a patch for it, over a week ago. If he thought you were trolling then maybe he already forgot it again, or didn't understand what you meant.
 

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,180
Trophies
1
XP
3,386
Country
Spain
Recently I set up a Emu Nand (pretty straightforward, actually), and I have a couple questions I hope someone can answer:

I've noticed that the light of the disc drive flashes ever so often once I'm playing something through Emu Nand. Is this normal behavior?

GBAtemp has a compatibility list here:
https://wiki.gbatemp.net/wiki/Wii_cIOS_EmuNAND_Compatibility_List

What do rev17, rev19 and other version mean? I imagine that as of today, the column of 2dx 8/10 beta 52 is the one to follow, right?

Lastly, and this one is not really important: when I did the Emu NAND, obviously all my channels and such got copied, alongside their save files. I erased them because I didn't want duplicates, but if for some reason I wanted to have the save files back on the Emu NAND, I would need to dump the entire thing again, correct?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    K3Nv2 @ K3Nv2: Least they got head in the end