[DEV] Wad Manager MOD

Discussion in 'Wii - Emulation and Homebrew' started by RiderFx3, Dec 8, 2010.

Dec 8, 2010

[DEV] Wad Manager MOD by RiderFx3 at 7:20 PM (1,219 Views / 0 Likes) 6 replies

  1. RiderFx3
    OP

    Newcomer RiderFx3 Advanced Member

    Joined:
    Mar 8, 2009
    Messages:
    59
    Country:
    France
    [RESOLVED]​

    Hi everybody,

    I need help for my MOD of WAd Manager: Ultimate Installer

    I would like reboot the wii when I press HOME > OK it works fine !
    I would like return to HBC when I press 2 > NOT OK when i launch the homebrew with a forwarder.

    If i launch the homebrew with HBC, it return to HBC correctly when I press 2.

    I would like that the user can choose to reboot, or to launch HBC, few imports that the way is launched the homebrew at the begining (Forwarder or HBC)

    There is the code for return to HBC in SYS.C:
    Code:
    void GoToHBC(void)
    {
    ÂÂÂÂu32 *stub = (u32 *)0x80001800;
    
    ÂÂÂÂ/* Go to Homebrew Channel */
    ÂÂÂÂif (*stub)
    ÂÂÂÂÂÂÂÂexit(0);
    }
    And there is the code for the button 2:
    Code:
    /* 2 button */
    ÂÂÂÂÂÂÂÂif (buttons & WPAD_BUTTON_2)
    ÂÂÂÂÂÂÂÂÂÂÂÂGoToHBC();
    Anyone can help me to call HBC when the homebrew is launch with a forwarder?

    Excuse me for my bad english [​IMG]
     
  2. giantpune

    Member giantpune GBAtemp Addict

    Joined:
    Apr 10, 2009
    Messages:
    2,860
    Country:
    United States
    you cant just blindly exit to 0x80001800 if there happens to be something there. check it for the stub signature STUBBHAXX. and then make sure you have something that happens after the

    if (buttons & WPAD_BUTTON_2)
    GoToHBC();

    fails.

    the system menu wont magically start itself.
    and if you want to go to HBC without using the reload stub, use the WII_Launch...() stuff in libogc
     
  3. tueidj

    Member tueidj I R Expert

    Joined:
    Jan 8, 2009
    Messages:
    2,569
    Country:
    libogc's existing behaviour for exit():
    - check if the reloader stub exists, if so run it
    - otherwise launch the system menu

    If you want to unconditionally jump to HBC and make your program future proof against any future HBC title id changes at the same time, you have to do the following:
    - get a list of all channels on the wii
    - check their TMDviews one at a time and find one that uses "HB" for the group id
    - launch that channel using WII_Launch (or just use the appropriate /dev/es ioctlv)
     
  4. RiderFx3
    OP

    Newcomer RiderFx3 Advanced Member

    Joined:
    Mar 8, 2009
    Messages:
    59
    Country:
    France
    Thanks Guys !

    I don't want "Return" to HBC, because the homebrew is launched with forwarder.

    I want "launch" HBC directly.

    I try to write:

    #define HBC_IOS 58


    /* 2 button */
    if (buttons & WPAD_BUTTON_2)
    __IOS_LaunchNewIOS(HBC_IOS);

    But the homebrew freeze.

    Code:
    - get a list of all channels on the wii
    - check their TMDviews one at a time and find one that uses "HB" for the group id
    - launch that channel using WII_Launch (or just use the appropriate /dev/es ioctlv)
    How i can use Wii launch, and wich software can list all of my channels for find the TMD of HBC.
    When i got the TMD of HBC, wich code i do write exaclty ? I modify the page "sys.c" and "wadmanager.c"

    Sorry but im noob in dev ... [​IMG]
     
  5. RiderFx3
    OP

    Newcomer RiderFx3 Advanced Member

    Joined:
    Mar 8, 2009
    Messages:
    59
    Country:
    France
    someone can help me to launch HBC 1.0.8 with his title ID and Wii_LaunchTitle(); ?
     
  6. RiderFx3
    OP

    Newcomer RiderFx3 Advanced Member

    Joined:
    Mar 8, 2009
    Messages:
    59
    Country:
    France
    Thanks for helping!

    I try this:
    CODE#define TITLE_ID(x,y)ÂÂÂÂÂÂÂÂ(((u64)(x) > 32))
    #define TITLE_LOW(x)ÂÂÂÂÂÂÂÂ((u32)(x))

    With this:
    CODEvoid GoToHBC(void)
    {
    ÂÂÂÂ/* Go to Homebrew Channel */
    ÂÂÂÂWII_Initialize();
    ÂÂÂÂ(WII_LaunchTitle(HBC_108)
     
  7. RiderFx3
    OP

    Newcomer RiderFx3 Advanced Member

    Joined:
    Mar 8, 2009
    Messages:
    59
    Country:
    France
    It's OKAY i fix it !!!! [​IMG] I'm Happy !


    in SYS.C:
    CODE#define TITLE_ID(x,y)ÂÂÂÂÂÂÂÂ(((u64)(x) > 32))
    #define TITLE_LOW(x)ÂÂÂÂÂÂÂÂ((u32)(x))
    Code:
    void GoToHBC(void)
    {
    ÂÂÂÂ/* Go to Homebrew Channel */
    ÂÂÂÂWII_Initialize();
    ÂÂÂÂWII_LaunchTitle(TITLE_ID(0x00010001,0xAF1BF516));
    ÂÂÂÂÂÂÂÂif(WII_LaunchTitle(TITLE_ID(0x00010001,0x48415858)));
    ÂÂÂÂÂÂÂÂÂÂÂÂif(WII_LaunchTitle(TITLE_ID(0x00010001,0x4A4F4449)));
    ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂSYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
    }

    and in main.c:

    Code:
    /* 2 button */
    ÂÂÂÂÂÂÂÂif (buttons & WPAD_BUTTON_2)
    ÂÂÂÂÂÂÂÂÂÂÂÂGoToHBC();

    Thanks all !!!
     

Share This Page