Hacking cIOSX rev21d2x: Yet Another Hot Fix!!!!

Did d2x work for you?

  • Yes, I had an issue with the official cios and d2x fixed it

    Votes: 93 48.2%
  • Yes, but everything was already working for me with the official cios

    Votes: 82 42.5%
  • No, and I posted what goes wrong

    Votes: 9 4.7%
  • No, and I won't report what goes wrong because I am a troll

    Votes: 9 4.7%

  • Total voters
    193

xfcrowman

Well-Known Member
Member
Joined
Mar 14, 2009
Messages
431
Trophies
0
XP
205
Country
United States
Just tested COD3 and it works! If I remember correctly, the IOS reload for this game happen between missions, so I play through 2 missions without issue.
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
@xfcrowman
That's correct!
Thanks for testing.

@ anybody having a modchip installed on the drive
Please test ios reload block through USB/SD.
 

damysteryman

I am too busy IRL these days...
Member
Joined
Oct 4, 2007
Messages
1,223
Trophies
1
XP
1,026
Country
Antarctica
davebaol said:
@ anybody having a modchip installed on the drive
Please test ios reload block through USB/SD.
d2pro 9 wire modchip (on a wiiclip) installed.

Tested:
Call of Duty 3 (PAL)
NeoGamma R9 b48
running under cIOS249[56]-v21d2x5-alpha1,
with Block IOS reload setting set to : For Discs
Loading from 4GB USB drive, WBFS format

...WORKS. Levels load up fine instead of returning to System Menu.

Also tested exact same game with exact same setup, but with the modchip removed, and same results.
 

WiiPower

Well-Known Member
Member
Joined
Oct 17, 2008
Messages
8,165
Trophies
0
XP
345
Country
Gambia, The
davebaol said:
@WiiPower
Ok, forget it.
blush.gif

So it has never worked even for Waninkoko's cIOS, right?

@Fox888
Thanks for testing

I found the issue. The cIOS checks if the disc is a DVD5 or DVD9 directly after reading the disc id. But you can only set the audio config directly after reading the disc id, if there something read from drive in between, it fails. (if the cIOS doesn't know if a disc is DVD5 or DVD9, it's going to cause 001 error on one of them)

I have an idea how to fix it:
Don't call __DI_CheckDisc after reading the disc id
Put the code from __DI_CheckDisc into __DI_CheckOffset
Add a variable to the config "typechecked" with default false
Only execute the code from __DI_CheckDisc once and set typechecked to true

The change __DI_CheckDisc does to the config seems to only be required for __DI_CheckDisc, so the above should work and don't interfere with anything else. And it only checks once like it does now, so it doesn't cause a major slowdown, like always executing it would.

PS: Some anti piracy could call reset->read disc id->audio config for "fun" to check if a cIOS is running. At least i could identify if a cIOS is running this way, with the changes i suggested this wouldn't be possible anymore.
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
@damysteryman
Ok, thanks for confirming.
Initially with my wode I had a terrible slow down accessing the drive (blue led always on) when launching a new game after exiting a ios reloaded game.
Then the issue has disappeared after anticipating usb/sd initialization code in the same place where the dvd drive is initialized by the original DI module.

@WiiPower
Hmmm, it looks reasonable.
However I'd need your modified neogamma to test this mod.
I think you'd better modify waninkoko's dip module by yourself and send me the new source so that I can merge it with mine.

PS: Did you read my pm?
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
@WiiPower
Just an optimization.
I'm believe there's no need to add the field "typechecked" to the config.
You can merely reuse config.type to check whether the dvd type is already known.
Note that in plugin.h the enum constant DISC_UNKNOWN is already defined but never used in the entire module.
 

WiiPower

Well-Known Member
Member
Joined
Oct 17, 2008
Messages
8,165
Trophies
0
XP
345
Country
Gambia, The
davebaol said:
@WiiPower
Just an optimization.
I'm believe there's no need to add the field "typechecked" to the config.
You can merely reuse config.type to check whether the dvd type is already known.
Note that in plugin.h the enum constant DISC_UNKNOWN is already defined but never used in the entire module.

Grr, i can't do it the way i wanted to do it, infinite loop...
http://www.mediafire.com/?32kl16d41of9b7u

It's a bit dirty since i make it fall back to DVD5 while unknown and i don't check the type for disc id or bca reading. But for those it shouldn't be required. If you have a nicer way of solving this, i listen.

This NeoGamma will only print "Audio streaming set" on screen for gamecube games and if it could actually do it. If it can't do it, there's nothing on screen. 001 DL games might be worth checking now, Metroid Prime Triology for example. For me audio streaming + SL 001 games work.
 

old_darkness

Active Member
Newcomer
Joined
Sep 29, 2008
Messages
31
Trophies
0
XP
112
Country
Gambia, The
Hi,

CSI - dealy intent : This gives me a Error# 002 with a blue screen after selecting level 1 maybe patched here
CSI - Hard Evidence : seems to worked
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
@old_darkness
CSI Dealy Intent works perfectly here.
Error 002 on ios reload has been fixed in d2x v4 and nobody has reported any issue until now. Well, nobody else but you.
Also, some users have reported that the other 2 games of the same series are working properly.
And AFAIK there's only 1 type of ios reload, so theoretically all games should be supported the same manner.
TBH I don't know why you get error 002, maybe your game is patched somehow.

@WiiPower
Your test app works for me with MPT, so DL games seem to be recognized properly.
GC games not tested.
Also I have not looked at the source yet but I think I can say you did a great work.
I'll merge it with the upcoming v5 beta1 asap.
 

WiiPower

Well-Known Member
Member
Joined
Oct 17, 2008
Messages
8,165
Trophies
0
XP
345
Country
Gambia, The
davebaol said:
@old_darkness
CSI Dealy Intent works perfectly here.
Error 002 on ios reload has been fixed in d2x v4 and nobody has reported any issue until now. Well, nobody else but you.
Also, some users have reported that the other 2 games of the same series are working properly.
And AFAIK there's only 1 type of ios reload, so theoretically all games should be supported the same manner.
TBH I don't know why you get error 002, maybe your game is patched somehow.

@WiiPower
Your test app works for me with MPT, so DL games seem to be recognized properly.
GC games not tested.
Also I have not looked at the source yet but I think I can say you did a great work.
I'll merge it with the upcoming v5 beta1 asap.

Don't rush it, take your time and see if i did some mistake. I don't like it when someone blindly trusts me.

Does patching the game to use another IOS break the 002 error on ios reload fix? If yes, can the code be updated to fix 002 error in that situation as well? If a .iso is patched to use another IOS, the change is only in the tmd. Ok and the tmd is the info which is used to determine which IOS is to be loaded. But the info inside the apploader is the one used for the 002 check.

Can you post the part of the code that relates to the 002 error fix?
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
You can find the source in d2x v4 final package in the 1st post: ES module -> plugin.c -> lines 182-207 (IOCTL_ES_DIVERIFY).
wink2.gif

That code has been added by me only to fix error 002 and to avoid infinite ios reload loops if the wii crashes in the middle of an ios reload (title_id check).
 

WiiPower

Well-Known Member
Member
Joined
Oct 17, 2008
Messages
8,165
Trophies
0
XP
345
Country
Gambia, The
davebaol said:
You can find the source in d2x v4 final package in the 1st post: ES module -> plugin.c -> lines 182-207 (IOCTL_ES_DIVERIFY).
wink2.gif

That code has been added by me only to fix error 002 and to avoid infinite ios reload loops if the wii crashes in the middle of an ios reload (title_id check).

Ok, i found it and i don't see any reason why it would fail for patched .isos. You could determine if the tmd info matches the info from the apploader at this point, but it would lead to the same *(u32 *)0x00003140 = (*((u32 *)0x00003188)) | 0xFFFF; anyways. Maybe the IOS Reload block is disabled in this situation for some reason? Too bad i don't have a 002 IOS reloading game here right now. That would be something i would like to debug with my usb gecko.
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
And that lines are unchanged in d2x v5alpha1.
The only mod I made to ES in v5alpha1 is a few lines above in IOCTL_ES_LAUNCH to call a new DI ioctl that saves the config state for DI itself.
So nothing to do with 002 error.
 

IceIceBird

Well-Known Member
Member
Joined
Nov 14, 2009
Messages
407
Trophies
0
XP
119
Country
davebaol:
The game "Sakura Wars - So long, my Love" (SAKPNS) doesn't work with the d2x cIOS.
When starting the game with NeoGamma or CFG the "An error has occurred, Press the EJECT button, remove the disc, and turn of the power to the console. Please refer to the Wii Operations Manual for details" shows. But when I run the game in CFG with hermes5.1base57cIOS it works.
Maybe this is something to add to the to do list (not high priority though). By the way the game is a DL game but without IOS Reload.
Could someone else also confim the above statement?
 

WiiPower

Well-Known Member
Member
Joined
Oct 17, 2008
Messages
8,165
Trophies
0
XP
345
Country
Gambia, The
IceIceBird said:
davebaol:
The game "Sakura Wars - So long, my Love" (SAKPNS) doesn't work with the d2x cIOS.
When starting the game with NeoGamma or CFG the "An error has occurred, Press the EJECT button, remove the disc, and turn of the power to the console. Please refer to the Wii Operations Manual for details" shows. But when I run the game in CFG with hermes5.1base57cIOS it works.
Maybe this is something to add to the to do list (not high priority though). By the way the game is a DL game but without IOS Reload.
Could someone else also confim the above statement?

Which IOS does the game use when started from disc channel? I hope i don't need to ask, but i'll do it anyways:
Since hermes cIOS with IOS57 as base works, did you try the same base for d2x as well?
 

IceIceBird

Well-Known Member
Member
Joined
Nov 14, 2009
Messages
407
Trophies
0
XP
119
Country
WiiPower said:
IceIceBird said:
davebaol:
The game "Sakura Wars - So long, my Love" (SAKPNS) doesn't work with the d2x cIOS.
When starting the game with NeoGamma or CFG the "An error has occurred, Press the EJECT button, remove the disc, and turn of the power to the console. Please refer to the Wii Operations Manual for details" shows. But when I run the game in CFG(not the 222 version) with the game set to use hermes5.1base57cIOS it works.
Maybe this is something to add to the to do list (not high priority though). By the way the game is a DL game but without IOS Reload.
Could someone else also confim the above statement?

Which IOS does the game use when started from disc channel? I hope i don't need to ask, but i'll do it anyways:
Since hermes cIOS with IOS57 as base works, did you try the same base for d2x as well?
Hehe of course I tested that
wink.gif
(with both r21 & d2x v4 with different bases, and d2x v5alpha1base56)
Actually I havn't checked what IOS the game "normaly" uses yet
tongue.gif
 

davebaol

Well-Known Member
OP
Member
Joined
Sep 3, 2010
Messages
912
Trophies
0
XP
192
Country
Italy
Yeah, I can confirm.
However d2x doesn't seem to be responsible for that (maybe).

The PAL version of Sakura Wars works for me with d2x v5 alpha1 (base 56) and GX 2.1 via USB from a FAT partition (I'm assuming gx is actually using its own dip module to manage the fraglist, just like cfg does).

Unfortunately it doesn't work with the same cios and NeoGamma R9 beta48 via SD from a WBFS partition.

PS: Sakura Wars specifies ios 53 in tmd.
 

IceIceBird

Well-Known Member
Member
Joined
Nov 14, 2009
Messages
407
Trophies
0
XP
119
Country
davebaol said:
Yeah, I can confirm.
However d2x doesn't seem to be responsible for that (maybe).

The PAL version of Sakura Wars works for me with d2x v5 alpha1 (base 56) and GX 2.1 via USB from a FAT partition (I'm assuming gx is actually using its own dip module to manage the fraglist, just like cfg does).

Unfortunately it doesn't work with the same cios and NeoGamma R9 beta48 via SD from a WBFS partition.

PS: Sakura Wars specifies ios 53 in tmd.
And if you try with an WBFS partition in GX ?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • Xdqwerty @ Xdqwerty:
    good night
  • BakerMan @ BakerMan:
    as to you
  • K3Nv2 @ K3Nv2:
    How do you know if the night will be good when you're asleep
  • BakerMan @ BakerMan:
    because i didn't say i was asleep
  • BakerMan @ BakerMan:
    i said i was sleeping...
  • BakerMan @ BakerMan:
    sleeping with uremum
  • K3Nv2 @ K3Nv2:
    Even my mum slept on that uremum
  • TwoSpikedHands @ TwoSpikedHands:
    yall im torn... ive been hacking away at tales of phantasia GBA (the USA version) and have so many documents of reverse engineering i've done
  • TwoSpikedHands @ TwoSpikedHands:
    I just found out that the EU version is better in literally every way, better sound quality, better lighting, and there's even a patch someone made to make the text look nicer
  • TwoSpikedHands @ TwoSpikedHands:
    Do I restart now using what i've learned on the EU version since it's a better overall experience? or do I continue with the US version since that is what ive been using, and if someone decides to play my hack, it would most likely be that version?
  • Sicklyboy @ Sicklyboy:
    @TwoSpikedHands, I'll preface this with the fact that I know nothing about the game, but, I think it depends on what your goals are. Are you trying to make a definitive version of the game? You may want to refocus your efforts on the EU version then. Or, are you trying to make a better US version? In which case, the only way to make a better US version is to keep on plugging away at that one ;)
  • Sicklyboy @ Sicklyboy:
    I'm not familiar with the technicalities of the differences between the two versions, but I'm wondering if at least some of those differences are things that you could port over to the US version in your patch without having to include copyrighted assets from the EU version
  • TwoSpikedHands @ TwoSpikedHands:
    @Sicklyboy I am wanting to fully change the game and bend it to my will lol. I would like to eventually have the ability to add more characters, enemies, even have a completely different story if i wanted. I already have the ability to change the tilemaps in the US version, so I can basically make my own map and warp to it in game - so I'm pretty far into it!
  • TwoSpikedHands @ TwoSpikedHands:
    I really would like to make a hack that I would enjoy playing, and maybe other people would too. swapping to the EU version would also mean my US friends could not legally play it
  • TwoSpikedHands @ TwoSpikedHands:
    I am definitely considering porting over some of the EU features without using the actual ROM itself, tbh that would probably be the best way to go about it... but i'm sad that the voice acting is so.... not good on the US version. May not be a way around that though
  • TwoSpikedHands @ TwoSpikedHands:
    I appreciate the insight!
  • The Real Jdbye @ The Real Jdbye:
    @TwoSpikedHands just switch, all the knowledge you learned still applies and most of the code and assets should be the same anyway
  • The Real Jdbye @ The Real Jdbye:
    and realistically they wouldn't

    be able to play it legally anyway since they need a ROM and they probably don't have the means to dump it themselves
  • The Real Jdbye @ The Real Jdbye:
    why the shit does the shitbox randomly insert newlines in my messages
  • Veho @ Veho:
    It does that when I edit a post.
  • Veho @ Veho:
    It inserts a newline in a random spot.
  • The Real Jdbye @ The Real Jdbye:
    never had that i don't think
  • Karma177 @ Karma177:
    do y'all think having an sd card that has a write speed of 700kb/s is a bad idea?
    trying to restore emunand rn but it's taking ages... (also when I finished the first time hekate decided to delete all my fucking files :wacko:)
    Karma177 @ Karma177: do y'all think having an sd card that has a write speed of 700kb/s is a bad idea? trying to...