Hacking WBFSSync

redia

Well-Known Member
Member
Joined
Mar 9, 2008
Messages
371
Trophies
0
XP
234
Country
Swaziland
Omega Frost,

thank you,
I will do some testing and give you some feedback,

Cheers,
R

**** edit ****

ok I am quickly taking a look.


******** console mode :
first thing : there are some error management issues. you will see later.


now a couple of comments :
list ---- >>> change it to 'help' or '?' ... it makes more sense, and 'list' will end up being confusing
verify ---- >>> gives me an error
?Opening Drive 'C:\Users\xxx\Desktop\device0.wbfs'...
?Failed to open device! Error 3
dump ---- >>> what do you mean by that.. I ran it and could not locate any resulting file
makerelease ---- >>> I don't get it, what is that ?
exit
listdrive ---- >>> maybe you could find another I had the feeling it would list all the drives connected. I get a crash if I do not give a drive letter (while never informed I should enter one)
Unhandled Exception: System.IndexOutOfRangeException: Index was outside the boun
ds of the array.
at DevConsole.Operations.CommList(String[] args)
at DevConsole.Program.Main(String[] args)
add ---- >>> could not make it work
extract ---- >>> working but need some clarification on the syntax. are you extracting ALL the wbfs game (including updates if existing ? )
scrub ---- >>> working great
unscrub ---- >>> working great
delete --- >>> working great
rename --- >>> could not make it work
format --- >>> working

general remark : on each screen requesting 'press any key' you should change it to 'press enter key' because that's the only thing that works...
wink.gif


here, I hope this helps.
the main improvements (aside from fixing the broken parts) could be :
- to make a clear list of the commands including the params (not yet done for everything)
- to manage the errors with clear message instead of crashing, or "error -12" (that's one I saw a couple of time)

******** gui mode :
haven't found any problem yet. (but I have spend a lot of time on the console. so I will dig in further later)
 

Omega Frost

Well-Known Member
Newcomer
Joined
Jun 27, 2009
Messages
84
Trophies
0
XP
46
Country
Brazil
Uow, thanks!

i will add the full description for the commands later, for now i'll just put them to work. Wait for me to upload the new version

Let's see...

list - changed to 'help', include also a useful note that might be your problem with rename and add:
when you have a composite string like C:\New Folder or Wii Play you must put them inside quotation marks

These commands are for debugging and development only and can be ignored:

verify : checks for corrupted disc table and try to fix it, the file in you error is my virtual drive used for tests

dump : makes a backup of the first sector of the disc, it helped me to understand a huge bug with the first versions of wbfssync

makerelease : it generates local files for update.ini file and copy the main files to the update folder, makes easy to upload an update to codeplex...

listdrive - renamed to 'listgames' and the errors were fixed

add - path's should be inside quotation marks to avoid the program split spaces in more arguments

extract - it will not extract updates because the updates partitions by default (or at least by the waninkoko's program and mine) aren't included in the add-to-wbfs process.

scrub - will include updates if you want to by the 'psX' argument

unscrub - will unscrub with updates if it was scrubbed with them

rename - same as 'add', you are probably trying to use a composite name

Please note that windows may lock access to external HDD's, the console will not guarantee itself to run as admin like Wbfssync does.
As for the error codes, well, the console was made to be independent of the language files, i will see what i can do.
 

redia

Well-Known Member
Member
Joined
Mar 9, 2008
Messages
371
Trophies
0
XP
234
Country
Swaziland
I will try again this "composite name" but if I am not mistaken I was already putting them in quotes..

for the extract, too bad, but again it is not very important.

for the debug and tools, I advise you to not list them in the 'help' because a lot of people are going to come with weird questions (like me... lol
wink.gif
)


about the GUI I noticed an error.
if I add a game to a wbfs while another one is being added, it works fine and goes to the queue.
but if I DELETE a game from the WBFS while another one is being added, your tool tries to delete it right away (with an error because the drive is locked) instead of going to the queue.

Cheers,
R
 

Omega Frost

Well-Known Member
Newcomer
Joined
Jun 27, 2009
Messages
84
Trophies
0
XP
46
Country
Brazil
Actually, the problem with deleted was expected, you see, the program only enqueue "slow" operations, quick operations are executed right away, i can "fix" that if it is really annoying...
 

redia

Well-Known Member
Member
Joined
Mar 9, 2008
Messages
371
Trophies
0
XP
234
Country
Swaziland
Omega Frost said:
Actually, the problem with deleted was expected, you see, the program only enqueue "slow" operations, quick operations are executed right away, i can "fix" that if it is really annoying...

it is not annoying per say (as long as you know it)
but it goes against the principle of having a queue..
it should not matter whether an operation is slow or fast.. it should all go to the queue.
this is my personal opinion.. and I will leave it up to you to modify it, if you don't make sure you add a comment in the readme so people are aware of that.

Cheers,
R
 

redia

Well-Known Member
Member
Joined
Mar 9, 2008
Messages
371
Trophies
0
XP
234
Country
Swaziland
Omega Frost,

ok, testing 2.0.0.05
I am putting all the comments in spoiler to make it easier to read..


help .... great
verify .... seems to work.
but I have to look into the WBFS format... even after a 'format' it still "finds" some games... but the problem is not with the 'format' of your tool as the 'verify' acts the same way when I use another tool to wipe the wbfs partition...
dump .... seems to work.
I would like to know if this actually creates a file or not ? and its location
makerelease .... not working.
I am still not understanding the value I am supposed to enter. I understand it is used for the update, but I do not get how it works
exit .... working
wink.gif

listgames .... working.
one remark.. the layout you are using is very hard to follow
I would advise you a format like (you can skip the "real size", if you implemented it is prevision of dual layer disk a simple * informing a disk is DL should be sufficiant)
gameid - gamename (padded to 32 caracters) - scrubbed size (padded)
for example
RC7P7J - Sea Montersxxxxxxxxxxxxxxxxxxxxxx - x'310'378'496
123456 - 12345678901234567890123456789012 - 1'234'567'890
(I added the x because padding does not show on the forum)
and maybe you could add two options :
1. titles.txt to grab the name (because a lot of us are using it)
2. export to a txt file
add .... working but with a tweak, problems with syncsrubbed file . see General Comment 3
from our previous discussions I believe you are only copying the game, this makes sense if you can only extract the game.. but if you find a way to extract the full disc, then you may want to add a parameter to select what you want to add.. I hope I am clear, but what I mean is they should work together.
NOT WORKING - if the game is already in the WBFS partition we get
1. if the game is an iso : an "error 10" you should change that to "game already in WBFS"
2. if the game is syncscrub : it adds the game again (don't know the risks)
extract .... working. see general comment 1 & 2
scrub .... working. see general comment 1 & 2
unscrub ... working... not working... working... not working... lol .. see general comment 1, 2 & 3
works right after launching console.exe,, but if I try to unscrub 2 in a row it give me "ERROR Not a syncscrub disc!"
same thing if I added a game to the drive before trying to unscrub
delete ... working
rename ... working
you should put the name argument optional... if missing you change only the gameID
and mention that the game name should be within quotes
format ... working


General Comment 1 :
there is a small thing you should look into.
when you do not enter the fullpath when extracting/scrubbing/unscrubbing your application does not react the same way :
extract ----> error 13
scrub ----> creates the file in the application directory
unscrub ----> error 2004

General Comment 2 :
you should look into the extension.
there should be a way to automatically add them if missing (specially when creating a file with extract/scrub/unscrub)

General Comment 3 :
after any action using a scrubbed file I am having problems with :
add / scrub / unscrub.
you should look into it.
for your test simply do two things and you will see what I mean.
try adding two syncscrubbed game in a row
try unscrubbing two syncscrubbed game in a row
try mixing this (adding a game and unscrubbing a game or vice versa)


I will bring more feedback as I have more testing to do.
on the GUI, I have not looked yet

Cheers,
R
 

quepaso

Well-Known Member
Member
Joined
May 4, 2008
Messages
438
Trophies
0
XP
154
Country
United States
I hate anything that uses NT Framework 3.5. 2.0 is fine. Why bother with 3.5? Thanks for the effort anyhow.
 

Omega Frost

Well-Known Member
Newcomer
Joined
Jun 27, 2009
Messages
84
Trophies
0
XP
46
Country
Brazil
@redia: i'm looking at the problems but here everything seems normal even using your test parameters, did you scrub the game with all partitions before adding it or Game-Only?

@quepaso: The .NET 3.5 is for the LinQ namespace that i use during the update the configuration file by the program.
 

Omega Frost

Well-Known Member
Newcomer
Joined
Jun 27, 2009
Messages
84
Trophies
0
XP
46
Country
Brazil
jelbo said:
albanibr said:
screens add!!

biggrin.gif
Thanks! And wow, that looks very smooth.. Shame I need to reinstall my OS to get it running X_X

i'll see what i can do, maybe i can put a separate release for these cases, but what's the problem with your OS to cause this?
 

redia

Well-Known Member
Member
Joined
Mar 9, 2008
Messages
371
Trophies
0
XP
234
Country
Swaziland
Omega Frost said:
@redia: i'm looking at the problems but here everything seems normal even using your test parameters, did you scrub the game with all partitions before adding it or Game-Only?

@quepaso: The .NET 3.5 is for the LinQ namespace that i use during the update the configuration file by the program.
I can't remember..
I will do extend testing and revert as soon as possible.

R
 

xzxero

♥bong milk does good for the brain♥
Member
Joined
Jul 18, 2008
Messages
3,831
Trophies
0
Age
14
Location
SB
Website
Visit site
XP
332
Country
United States
quepaso said:
I hate anything that uses NT Framework 3.5. 2.0 is fine. Why bother with 3.5? Thanks for the effort anyhow.
well pretty much everyone hates you so it all works out?
 

Omega Frost

Well-Known Member
Newcomer
Joined
Jun 27, 2009
Messages
84
Trophies
0
XP
46
Country
Brazil
Pakatus said:
Can we configure different sites to download covers? or are we "stuck" with wiiboxart?

For now, you can't, because in most of the time the sites have different ways to store the covers, but for future releases wbfssync will probably use http://wiitdb.com/ as the main covers / names / infos repository
 

jelbo

Well-Known Member
Member
Joined
Sep 12, 2003
Messages
877
Trophies
2
XP
918
Country
Netherlands
Omega Frost said:
jelbo said:
albanibr said:
screens add!!

biggrin.gif

Thanks! And wow, that looks very smooth.. Shame I need to reinstall my OS to get it running X_X


i'll see what i can do, maybe i can put a separate release for these cases, but what's the problem with your OS to cause this?
No idea, but it's broken beyond repair. I get this error when installing .NET 3.5 SP1:

CODE
[09/10/09,10:01:04] Microsoft .NET Framework 2.0SP1 (CBS): [2] Error: Installation failed for component Microsoft .NET Framework 2.0SP1 (CBS). MSI returned error code -2145116147
[09/10/09,10:01:14] WapUI: [2] DepCheck indicates Microsoft .NET Framework 2.0SP1 (CBS) is not installed.

I'm on Vista so the error makes no sense. I've Googled a lot and tried many things but I've given up.

Through Windows Update I get a failed message with error code 8024200D.

A WBFS tool that doesn't need .NET would be very cool and yours looks very cool and unique. If I understand you correctly .NET is used for only one small thing so maybe it's indeed possible to get rid of .NET altogether or release an alternative version.
smile.gif
 

warlord007

Well-Known Member
Newcomer
Joined
Mar 24, 2008
Messages
80
Trophies
0
XP
98
Country
running ok on windows 7 here
smile.gif
run as admin

not sure if this has been mentioned but

it dsoent list DL disk ?

i have Damnation on the drive but it isnt displayed in the list ?

is this a bug for all DL thats the only one i have

nice app though

warlord
 

giantpune

Well-Known Member
Member
Joined
Apr 10, 2009
Messages
2,860
Trophies
0
XP
213
Country
United States
Wow. This is gonna be sweet when it gets ironed out. I didn't really even test out the functions of the program. But I did put together a list of stuff I found while I was messing around.

1
My A: drive is not a floppy, but instead a 1TB drive. So to get games from it, I have to copy them to a higher letter drive first. I tried to get around this. I added A: to the library on the left. Then I clicked on the button for A: and got a crash.

************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at WBFSSync.FormWBFSSync.LoadPath(String path)
at WBFSSync.FormWBFSSync.quickLinksPanel_quicklinks_QuickLinkClick(QuickLink link)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at WBFSSync.AeroControls.QuickLink.OnClick(EventArgs e)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3082 (QFE.050727-3000)
CodeBase: file:///L:/WINDOWS/Microsoft.NET/Framework64/v2.0.50727/mscorlib.dll
----------------------------------------
WBFSSync
Assembly Version: 2.0.5.0
Win32 Version: 2.0.05.0
CodeBase: file:///L:/Documents%20and%20Settings/Administrator/Desktop/wbfsSync/WBFSSync.exe
----------------------------------------
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Core
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.1 built by: SP
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System.Core/3.5.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
Log
Assembly Version: 2.0.0.0
Win32 Version: 2.0.0.0
CodeBase: file:///L:/Documents%20and%20Settings/Administrator/Desktop/wbfsSync/Log.DLL
----------------------------------------
WiiBackupFileSystem
Assembly Version: 2.1.1.0
Win32 Version: 2.1.1.0
CodeBase: file:///L:/Documents%20and%20Settings/Administrator/Desktop/wbfsSync/WiiBackupFileSystem.DLL
----------------------------------------
DeviceManager
Assembly Version: 2.0.4.0
Win32 Version: 2.0.04.0
CodeBase: file:///L:/Documents%20and%20Settings/Administrator/Desktop/wbfsSync/DeviceManager.DLL
----------------------------------------
IOManager
Assembly Version: 2.0.3.0
Win32 Version: 2.0.03.0
CodeBase: file:///L:/Documents%20and%20Settings/Administrator/Desktop/wbfsSync/IOManager.DLL
----------------------------------------
System.Configuration
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Xml
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3082 (QFE.050727-3000)
CodeBase: file:///L:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------



2
Selecting a folder from the list of skins with no skin (I picked the _media skin) in it causes a crash and I am unable to open the program to change the setting. I had to do it by editing the config file.

3
I had a folder selected and clicked the "covers" button on the left. First, I assumed that it would load whatever folder it is putting images in. Second, it is showing big covers with list view still enabled.
errer.png

4
While in details view, The titles are cut off by the width of the heading. Even after I drag the heading divider to make it wider, the names are still cut off.

5
The file sizes are limited to 1 decimal place. For most things this fits. But for games, I think it is better to allow them to 2 decimal places... 4.37 instead of 4.4.

6
I can create, and reproduce, a crash by clicking the "covers" button on the left.
************** Exception Text **************
System.OutOfMemoryException: Out of memory.
at System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement)
at WBFSSync.Covers.LoadFullSizeCovers()
at WBFSSync.FormWBFSSync.LoadCovers()
at WBFSSync.FormWBFSSync.quickLinksPanel_quicklinks_QuickLinkClick(QuickLink link)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at WBFSSync.AeroControls.QuickLink.OnClick(EventArgs e)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


7
When I click the headings to resort the files, I have to click first to get focus on the heading and click again to sort. It should be 1 click, not 2.

8
This one really isn't anything wrong. It is just a couple suggestions. I make a lot of custom games based from real Wii games, and as a result, I am constantly changing the ID of the game. Rather than using lots of different apps, It would be nice to have a right-click option to do this. I cooked up a function to do this already in plain-Jane C. It is the equivalent of the u32 wbfs_ren_disc(wbfs_t*p, u8* discid, u8* newname) function in libwbfs, so it is used the same way.

Code:
u32 wbfs_rID_disc(wbfs_t*p, u8* discid, u8* newID)
{
ÂÂÂÂÂÂÂÂwbfs_disc_t *d = wbfs_open_disc(p,discid);
ÂÂÂÂÂÂÂÂint disc_info_sz_lba = p->disc_info_sz>>p->hd_sec_sz_s;

ÂÂÂÂÂÂÂÂif(!d)
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂreturn 1;

ÂÂÂÂÂÂÂÂmemset(d->header->disc_header_copy, 0, 0x10);
ÂÂÂÂÂÂÂÂstrncpy((char *) d->header->disc_header_copy, (char *) newID, 0x9);

ÂÂÂÂÂÂÂÂp->write_hdsector(p->callback_data,p->part_lba+1+d->i*disc_info_sz_lba,disc_info_sz_lba,d->header);
ÂÂÂÂÂÂÂÂwbfs_close_disc(d);
ÂÂÂÂÂÂÂÂreturn 0;
}
The NTFS version would be very similar, just editing the first bytes of the iso. That way one could alter the ID and names of games on both NTFS and WBFS partitions all from within 1 program.

Also, I wold like the ability to unblock my A: drive, and resize width of names while in list view.



Again, great program!
rolleyes.gif






EDIT>>>>>>
another crash....

I created a loader in the settings. When I click "edit", I get this crash...
************** Exception Text **************
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
at System.ThrowHelper.ThrowArgumentOutOfRangeException()
at System.Collections.Generic.List`1.get_Item(Int32 index)
at WBFSSync.AeroControls.ConfigurationPanel.ShowLoaderEditDialog(Boolean newItem)
at WBFSSync.AeroControls.ConfigurationPanel.button_loader_edit_Click(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • Xdqwerty @ Xdqwerty:
    @AncientBoi, gonna block you for real if you keep being like that
  • AncientBoi @ AncientBoi:
    Well.... Go ahead my "friend". If it makes you happy :mellow:
  • BigOnYa @ BigOnYa:
    Really, blocking him will only hurt you, we will see his messages, but you wont
  • Xdqwerty @ Xdqwerty:
    @BigOnYa, ok i'm not blocking him
  • BigOnYa @ BigOnYa:
    You just got to have thick skin and ignore people online if you don't agree or dislike. The internet is full of clowns.
    +2
  • AncientBoi @ AncientBoi:
    and an 👴 just having fun.
    +1
  • Xdqwerty @ Xdqwerty:
    Brb
  • Xdqwerty @ Xdqwerty:
    Going to the beach
  • AncientBoi @ AncientBoi:
    Cool :D Wait :unsure::unsure::unsure: Did you say Bleach? :O
  • Xdqwerty @ Xdqwerty:
    @AncientBoi, without the l
    +1
  • AncientBoi @ AncientBoi:
    Enjoy
  • SylverReZ @ SylverReZ:
    Enjoy wacking yourself off, old man?
    +1
  • AncientBoi @ AncientBoi:
    Always :D
  • K3Nv2 @ K3Nv2:
    Man bought a $20 a gauge at Amazon that was all fancy digital went to hook it up did t detect shit, then went back and bought an analog worked right away
    +1
  • ZeroT21 @ ZeroT21:
    @K3Nv2 Happens all the time when ordering these iffy things
  • ZeroT21 @ ZeroT21:
    watching xbox direct but the feed keeps getting dc'd, oh well
  • ZeroT21 @ ZeroT21:
    back to MH rise
  • K3Nv2 @ K3Nv2:
    It's AC Pro which is reputable but more a reason why I don't trust digital in cars
    K3Nv2 @ K3Nv2: It's AC Pro which is reputable but more a reason why I don't trust digital in cars