mirror of
https://github.com/wiidev/usbloadergx.git
synced 2024-11-18 09:19:17 +01:00
*Another HDD spin up loop fix
*Changed default cIOS back to 249. It is now recommended to use cIOS 249 Rev20.
This commit is contained in:
parent
f1afcda6af
commit
bd7ce32a8b
@ -2,8 +2,8 @@
|
|||||||
<app version="1">
|
<app version="1">
|
||||||
<name> USB Loader GX</name>
|
<name> USB Loader GX</name>
|
||||||
<coder>USB Loader GX Team</coder>
|
<coder>USB Loader GX Team</coder>
|
||||||
<version>1.0 r1000</version>
|
<version>1.0 r1004</version>
|
||||||
<release_date>201011141520</release_date>
|
<release_date>201011281641</release_date>
|
||||||
<short_description>Loads games from USB-devices</short_description>
|
<short_description>Loads games from USB-devices</short_description>
|
||||||
<long_description>USB Loader GX is a libwiigui based USB iso loader with a wii-like GUI. You can install games to your HDDs and boot them with shorter loading times.
|
<long_description>USB Loader GX is a libwiigui based USB iso loader with a wii-like GUI. You can install games to your HDDs and boot them with shorter loading times.
|
||||||
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.
|
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.
|
||||||
|
@ -57,7 +57,7 @@ int USBDevice_Init()
|
|||||||
// wait 0.5 sec for the USB to spin up...stupid slow ass HDD
|
// wait 0.5 sec for the USB to spin up...stupid slow ass HDD
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
started = (!__io_usbstorage2.startup() || !__io_usbstorage2.isInserted());
|
started = (__io_usbstorage2.startup() && __io_usbstorage2.isInserted());
|
||||||
usleep(50000);
|
usleep(50000);
|
||||||
--retries;
|
--retries;
|
||||||
}
|
}
|
||||||
@ -79,29 +79,34 @@ int USBDevice_Init_Loop()
|
|||||||
{
|
{
|
||||||
time_t starttime = time(0);
|
time_t starttime = time(0);
|
||||||
time_t timenow = starttime;
|
time_t timenow = starttime;
|
||||||
int ret = -1;
|
bool StatusPrinted = false;
|
||||||
bool printStart = true;
|
bool started = false;
|
||||||
|
|
||||||
while(timenow-starttime < 30 && ret < 0)
|
do
|
||||||
{
|
{
|
||||||
ret = USBDevice_Init();
|
started = (__io_usbstorage2.startup() && __io_usbstorage2.isInserted());
|
||||||
if(ret < 0)
|
|
||||||
{
|
|
||||||
if(printStart)
|
|
||||||
{
|
|
||||||
printf("failed\n");
|
|
||||||
printf("\tWaiting for slow HDD...");
|
|
||||||
printStart = false;
|
|
||||||
}
|
|
||||||
printf("%i ", (int) (timenow-starttime+1));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
if(!started)
|
||||||
|
{
|
||||||
|
if(timenow != time(0))
|
||||||
|
{
|
||||||
timenow = time(0);
|
timenow = time(0);
|
||||||
|
if(!StatusPrinted)
|
||||||
|
{
|
||||||
|
printf("\tWaiting for slow HDD...");
|
||||||
|
StatusPrinted = true;
|
||||||
}
|
}
|
||||||
|
printf("%i ", (int) (timenow-starttime));
|
||||||
|
}
|
||||||
|
usleep(100000);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
while(!started && timenow-starttime < 30);
|
||||||
|
|
||||||
|
if(StatusPrinted)
|
||||||
printf("\n");
|
printf("\n");
|
||||||
|
|
||||||
return ret;
|
return USBDevice_Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
void USBDevice_deInit()
|
void USBDevice_deInit()
|
||||||
|
@ -82,7 +82,7 @@ void CSettings::SetDefault()
|
|||||||
gamesound = 1;
|
gamesound = 1;
|
||||||
parentalcontrol = 0;
|
parentalcontrol = 0;
|
||||||
lockedgames = 0;
|
lockedgames = 0;
|
||||||
cios = 222;
|
cios = 249;
|
||||||
xflip = XFLIP_NO;
|
xflip = XFLIP_NO;
|
||||||
quickboot = OFF;
|
quickboot = OFF;
|
||||||
wiilight = 1;
|
wiilight = 1;
|
||||||
|
@ -54,10 +54,8 @@ s32 IosLoader::LoadAppCios()
|
|||||||
// Unmount fat before reloading IOS.
|
// Unmount fat before reloading IOS.
|
||||||
SDCard_deInit();
|
SDCard_deInit();
|
||||||
USBDevice_deInit();
|
USBDevice_deInit();
|
||||||
__io_usbstorage.shutdown();
|
|
||||||
USB_Deinitialize();
|
|
||||||
|
|
||||||
u32 ciosLoadPriority[] = { 250, 222, 249, Settings.cios }; // Descending.
|
u32 ciosLoadPriority[] = { 250, 249, 222, Settings.cios }; // Descending.
|
||||||
|
|
||||||
|
|
||||||
for (u8 i = (sizeof(ciosLoadPriority)/sizeof(ciosLoadPriority[0]))-1; i >= 0; i--)
|
for (u8 i = (sizeof(ciosLoadPriority)/sizeof(ciosLoadPriority[0]))-1; i >= 0; i--)
|
||||||
@ -97,9 +95,6 @@ s32 IosLoader::LoadGameCios(s32 ios)
|
|||||||
SDCard_deInit();
|
SDCard_deInit();
|
||||||
USBDevice_deInit();
|
USBDevice_deInit();
|
||||||
WDVD_Close();
|
WDVD_Close();
|
||||||
__io_usbstorage.shutdown(); // libogc usb
|
|
||||||
__io_usbstorage2.shutdown(); // cios usb
|
|
||||||
USB_Deinitialize(); // main usb handle
|
|
||||||
|
|
||||||
ret = ReloadIosSafe(ios);
|
ret = ReloadIosSafe(ios);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user