fwpatcher: fw.img patcher for WiiU WiiVC firmware image

Discussion in 'Wii U - Tutorials' started by leseratte, Sep 16, 2017.

  1. leseratte
    OP

    leseratte GBAtemp Regular

    Member
    2
    Jun 2, 2012
    Gambia, The
    fwpatcher: fw.img patcher for WiiU WiiVC firmware image

    Since about two weeks, it is possible to inject custom ISO files and homebrew into the WiiU WiiVC games, as seen in this thread: https://gbatemp.net/threads/wii-on-wii-u-virtual-console-injecting-games.483007/

    The main piece of software that is responsible for handling all the differences between WiiU mode and vWii is a file called "fw.img". That file has been released by Nintendo in three different versions: r569, r570 and r590.

    Because there are now quite a few different patches for this file, including a Trucha patch for non-signed content, all hidden in some posts in the thread above, I have decided to create a small tool called "fwpatcher". I have read the whole thread and other related threads and embedded all the patching info into that tool. Most patches have also been ported to it doesn't matter which version of the fw.img you use (although I still recommend using r590. The ported patches are not tested yet, and not all patches are ported).

    How does this work?

    For an exact description on how to edit the WiiU VC game contents, please refer to the thread linked above. This thread is only about patching the fw.img file.

    To patch that file, first download my tool: https://download.florian-bach.de/fwpatcher_0.01_current.zip

    If you have followed the tutorial above until step 1, you should have a "fw.img" somewhere. Open a command line and execute "fwpatcher-win64.exe INTERACTIVE fw.img" (obviously replace program name if you use another OS).

    The patcher will give you a list of patches and ask which ones you want to apply. If you don't understand a patch, press "h" for help and it will be explained. Otherwise, press "y" or "n" to select the patches you want to apply. The patched file will be stored as "fw-new.img".

    The tool also supports the command CHECK ("fwpatcher-win64.exe CHECK fw.img"), that command analyzes an fw.img and tells you which patches have been applied.

    Supported patches

    - Trucha (all versions)
    - ES_Identify (all versions)
    - HW_AHBPROT (all versions)
    - HW_MEMPROT (all versions)
    - Wiimotes in Gamepad mode (all versions)
    - Gamepad Cache flush (r590 only) to use Gamepad in homebrew
    - Emulate Wiimote only instead of Classic Controller (all versions)
    - Emulate sideways Wiimote (all versions)
    - Swap L&R with ZL&ZR buttons (r590 only)
    - Nintendont patches (r590 only)

    Changelog

    Code:
    fwpatcher v0.01 r20-31a911a2 - 2017-09-16:
    - Unknown patches will be recognized by the CHECK command and a warning
      message will be printed.
    
    fwpatcher v0.01 r19-16520666 - 2017-09-16:
    - Help and recommended value for each patch added.
    - Patch combinations are now validated (some patches require another,
      some are incompatible)
    
    fwpatcher v0.01 r17-ea6c6acd - 2017-09-15:
    - New Nintendont patch (fix94) added
    - Bugfix where certain patches weren't always recognized
    
    fwpatcher v0.01 r16-3108dffd - 2017-09-15:
    - Initial release
    - Can patch an fw.img file
    - Can check which patches have been applied
    - "Gamepad Cache flush" and "L-R -> ZL-ZR" patch are not ported to all versions
      yet (r590) needed for those.
    - Not all ported patches have been tested. 
     
    Last edited by leseratte, Sep 16, 2017
  2. LaPingas

    LaPingas let's go mangoooooo

    Member
    2
    Nov 2, 2016
    Israel
    Armada's Mustache
    Neat. Bookmarked.
    A lil question
    Nintendont patches = GCC adapter in vWii? Or I'm just making up things
     
  3. CatmanFan

    CatmanFan Top 10 Most Lit Trends

    Member
    6
    Aug 14, 2016
    Morocco
    Impressive. So can we forward GameCube games from Wii U Menu now?
     
  4. leseratte
    OP

    leseratte GBAtemp Regular

    Member
    2
    Jun 2, 2012
    Gambia, The
    The newest Build of Nintendont supports the gamepad, if you add the Nintendont patches to the fw.img. This has nothing to do with the Gamecube adapter.
     
  5. CatmanFan

    CatmanFan Top 10 Most Lit Trends

    Member
    6
    Aug 14, 2016
    Morocco
    So what does this mean? I still don't get it.
     
  6. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    20
    Oct 27, 2002
    France
    Engine room, learning
    for people who didn't read the last few days progress, I made a quick resume here :
    https://gbatemp.net/threads/savegame-manager-gx.210111/page-88#post-7577590

    This patcher is used to patch the "IOS255", this is the IOS used by WiiVC channels, and the patches are used to make a "cIOS255". that cIOS is not installed on vWii but build into the WiiU channel.
    this is still in development, and probably more patches will be found and could be applied to the IOS255 (aka fw.img) to unlock more features, like maybe USB support one day.

    Currently, the patches can :
    Allows WiiU Gamepad button support in Wii homebrew ! (homebrew need to be recompiled with new library)
    unlock hardware access (NAND, SD, etc.)
    unlock RAM access (patch memory in real time, etc.)
    Patch wiimote support to work ALONG the gamepad support
    etc.


    This does not mean you can launch gamecube directly from WiiU.
    the current progress is : you can launch nintendont directly from WiiU, and nintendont will load games from SD once in vwii mode.
    future progress will be :
    1. you can launch Forwarder from WiiU, which will load homebrew on SD (easier to work and test new homebrew version without rebuilding and reinstalling the WiiU channel everytime) Fix94 is working on it.
    2. you can launch gamecube from WiiU (hidden nintendont with autoboot, or gamecube ISO inside the WiiVC, not sure yet. fix94 is working on something...)
     
    Last edited by Cyan, Sep 16, 2017
    gamecaptor and Azel like this.
  7. CatmanFan

    CatmanFan Top 10 Most Lit Trends

    Member
    6
    Aug 14, 2016
    Morocco
    How can you do this?
     
  8. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    20
    Oct 27, 2002
    France
    Engine room, learning
    hmm, read my previous post, there's a link to the explanation and to a nintendont version you can install on WiiU ;)
    Nintendont v5.453 (yeah, Nintendont just got to v5.x)

    or, just read Nintendont thread, it was released there.
     
    CatmanFan likes this.
  9. kid sampson

    kid sampson GBAtemp Regular

    Member
    3
    Jul 20, 2006
    United States
    Thanks for the summary. Is this also applicable to WiiWare games like Contra Rebirth?
     
    CatmanFan likes this.
  10. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    20
    Oct 27, 2002
    France
    Engine room, learning
    I don't think so, WiiVC is only launching Wii disc ISO.

    Wii channels are not disc ISO, but extracted data installed on the console.
    it would require you to convert the channel to disc (hmm, don't remember if possible).

    a workaround is to currently install the game on your vWii, and make a vWii forwarder to that channel installed on WiiU.
    like using hbl2hbc with a config.txt pointing to that channel's titleID, or mod it to install as individual WiiU channel loading that vWii channel.
    another solution could be to inject a Wii channel loader or game launcher (not USBLoaders, they are currently not compatible) which still launch installed channels. but I don't know if it will work as IOS reload is blocked until a patch is found.
     
    Last edited by Cyan, Sep 16, 2017
    CatmanFan and KiiWii like this.
  11. KiiWii

    KiiWii GBAtemp Guru

    Member
    13
    Nov 17, 2008
    United Kingdom
    Last edited by KiiWii, Sep 16, 2017
    CatmanFan likes this.
  12. Cyan

    Cyan GBATemp's lurking knight

    Global Moderator
    20
    Oct 27, 2002
    France
    Engine room, learning
    ahh, there's such a tool ?
    I knew I forgotten something!

    if you can convert a channel wad to iso, please test it :)
    it might failed on first try, it's not necessarily because it's not compatible but maybe just requires more patches or different fw.img, etc.

    edit:
    sorry, I don't think this is what I thought
    it will not work.
    wad2iso is only a channel launcher homebrew packed inside a disc ISO. not the channel itself.

    to work, it would require path rewriting to replace NAND path to ISO path. not sure it's possible.
     
    Last edited by Cyan, Sep 16, 2017
  13. KiiWii

    KiiWii GBAtemp Guru

    Member
    13
    Nov 17, 2008
    United Kingdom
    Yeah its weird i had a flash back and thought i remembered a tool for this. Turns out not.

    Sorry.

    @Cyan seems we need the opposite of CRAP.... wiigsc...

    Edit 2

    What about wadunpacker, wadtools etc to extract wads. Then wiimms wbfstool?

    Out of interest does anyone know how dolphin handles wads as isos? (It doesnt require you to install them before use) etc?

    Edit 3:

    Showmiiwads + makekeybin.exe = converts wad to .app/.tik/.cert/.tmd/.trailer files ... after that the question is: how can we (decrypt further: like wiiu's NUS *.app etc to loadiine style method &) repack to wbfs or iso...
     
    Last edited by KiiWii, Sep 16, 2017
  14. LuisGerdez

    LuisGerdez Advanced Member

    Newcomer
    1
    May 27, 2016
    Venezuela
    What parameters do I have to activate and deactivate in order to play games like DBZ: BT3 and RE4 through the gamepad?
     
  15. huma_dawii

    huma_dawii GBAtemp Advanced Maniac

    Member
    6
    Apr 3, 2014
    United States
    Florida
    Can someone make the Homebrew Channel Gamepad friendly?
     
    nicolo01 likes this.
  16. CatmanFan

    CatmanFan Top 10 Most Lit Trends

    Member
    6
    Aug 14, 2016
    Morocco
    It's not possible now yet.
     
  17. N7Kopper

    N7Kopper Proud lover of a three-inch girlfriend

    Member
    3
    Aug 24, 2014
    The Homebrew Channel is open source, so I don't see why it couldn't happen. You might need to deal with the traps that check for an unmodified IOS 58 if they're still in the open source version, though.
     
  18. LuisGerdez

    LuisGerdez Advanced Member

    Newcomer
    1
    May 27, 2016
    Venezuela
    ? u.u
     
  19. CatmanFan

    CatmanFan Top 10 Most Lit Trends

    Member
    6
    Aug 14, 2016
    Morocco
    @leseratte
    Also, it's against the rules to bump here.
     
  20. gudenau

    gudenau Largely ignored

    Member
    8
    GBAtemp Patron
    gudenau is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    Jul 7, 2010
    United States
    /dev/random
    Any documentation on the format of the FW images?
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice