#114559 - SukkoPera - Mon Jan 08, 2007 11:56 pm
My first NDS homebrew application has just been released. It's a collection of utilities useful for the maintenance of the media card you are using with your flashcart.
At the moment of this first release, two utilities are included:
- The first one checks, and optionally fixes, any errors found in the filesystem of your media card. This is basically the same thing that you do under Windows when you run "Scandisk", but it saves you the hassle of having to turn on your computer, remove your card, connect it to the PC, etc...
- The second utility will be mainly useful for users of Supercard family flashcarts. Such carts show ROMs and programs sorted by date. Many users (including me) prefer to have them sorted alphabetically, which is exactly what this utility does.
Please report any comments/bugs/appreciations :).
Disclaimer:
PLEASE NOTE THAT THIS PROGRAM MESSES WITH THE FILESYSTEM OF YOUR MEDIA CARD, WHICH MIGHT RESULT IN A DATA LOSS. THEREFORE, BEFORE USING IT, ALWAYS MAKE A BACKUP OF ANY IMPORTANT DATA.
Downloads:
- Binaries
- Source
The program uses a hacked version of Chishm's libfat to allow for raw I/O:
- Source
- NDS binaries
- GBA binaries (untested)
_________________
Nintendo DS Lite (White) + Supercard Lite + R4 + Sandisk 1 GB MicroSD
Sony PSP + Firmware 3.03 OE-A2
#114628 - dantheman - Tue Jan 09, 2007 5:00 pm
The scanning and fixing works fine for me, but sorting always hangs once it reaches my DSOrganize folders.
Quote: |
Sorting directory //DSOrganize/RESOURCES/
getFATEntry: Seek error!
sortClusterChain: Failed to get FAT entry!
sort_FAT16_rootdir: Failed to sort cluster chain!
sort_fs: Failed to sort FAT16 root directory!
fatsort:
Failed to sort file system! |
The files up to that point get sorted fine. I have not tried removing the directory and trying again, as I'm not on my home computer right now.
Just out of curiosity, what does the hacked version of libfat do?
#114635 - SukkoPera - Tue Jan 09, 2007 5:55 pm
Thanks for the testing.
That error shouldn't happen on a clean filesystem (and if you used the fix function, it should be clean now. It surely is if it reports no errors). What cart and card do you have, how big is the latter, and how full is it? Please do not delete that folder, it might help me fixing this bug.
The hacked version of libfat allows raw reading/writing of all the media cards supported by libfat. libfat itself, normally only allows reading/writing of files, but to do the sorting and fixing, I need to mess with the FAT structures myself. Look here for more details: http://forum.gbadev.org/viewtopic.php?t=12001&start=135
_________________
Nintendo DS Lite (White) + Supercard Lite + R4 + Sandisk 1 GB MicroSD
Sony PSP + Firmware 3.03 OE-A2
#114669 - dantheman - Tue Jan 09, 2007 11:33 pm
I formatted my card and then copied all my files back to it before running the program again, and it did the same thing. Your FAT tester claimed there were no errors in the filesystem at the time. However, upon scanning now I get some long file name errors related to "gggg.todo" which I recognize as a random file I created in DSOrganize. The error appears in both the checking and verification pass. Here's what is displayed:
Quote: |
Orphaned long file name part "gggg.todo"
Auto-deleting.
A new long file name starts with in an old one.
Not auto-correcting this. |
I just hit A to fix the errors and tried scanning again. Now I only get "A new long file name starts with in an old one. Not auto-correcting this" but now it claims that no errors were found. Sorting crashes at the same spot as before.
In any case, I have a 2 Gbyte PQI brand miniSD card (pretty much a no-name brand, but it was only $20 so I picked it up). I am using a Supercard MiniSD with firmware version 1.63b.
#114671 - SukkoPera - Tue Jan 09, 2007 11:44 pm
Thanks for the info, I'll look into that. However I don't have a 2 GB card so I can't do much. I have some ideas anyway...
_________________
Nintendo DS Lite (White) + Supercard Lite + R4 + Sandisk 1 GB MicroSD
Sony PSP + Firmware 3.03 OE-A2
#114677 - dantheman - Wed Jan 10, 2007 12:10 am
How strange. I removed the entire DSOrganize directory, and now it gets hung up on the directory right after that, "games"
Scanning gives a clean "no errors found" now.
EDIT: doing a full checkdisk under Windows shows no errors, and the problem still exists. Sorting inversely freezes after about the same amount of time, although at a different directory.
EDIT 2: okay, I think my card is just faulty. Fatsort used to work, but now it just closes out after about 2 minutes of inactivity (used to successfully sort within 30 seconds). Guess I'd better search for some good SD formatting tools.
#114682 - SukkoPera - Wed Jan 10, 2007 1:00 am
Mmmmh, when you got that "Not auto-correcting this.", had you run the scan with X or Y?
EDIT: Argh sorry, there's a stupid bug which won't allow you to correct certain errors. I'll fix that and release a new version soon. Try to fix your card meanwhile :). If you use any UNIX O/S, just use dd to zero the whole card and then format it again.
_________________
Nintendo DS Lite (White) + Supercard Lite + R4 + Sandisk 1 GB MicroSD
Sony PSP + Firmware 3.03 OE-A2
#114692 - dantheman - Wed Jan 10, 2007 4:20 am
Well this is just great. I spent half an hour using a full SD formatter and added back only a few files, including DSLinux and the folder for it. Sometimes sorting will fail in the DSLinux folder, and sometimes it will sort correctly. How strange. Of course, now that I keep trying to sort it to see which folder it was, every attempt is successful. Odd.
It'll probably fail more often though as I load up my miniSD card with more stuff.
EDIT: just as a status update, it now works fine. Once again, it froze up in the DSLinux folder, but I tried a few more times until it gave successfull sorts every time.
#115715 - sinclair44 - Thu Jan 18, 2007 5:04 pm
Hmm... seems neat. However, I cannot find the server www.sukkology.com in order to try out the program. :(
(Not having Windows, the alphabetizer on the DS itself would be awesome!)
EDIT: The download works now. Strange.
_________________
Inter arma enim silent leges
#116401 - HyperHacker - Thu Jan 25, 2007 8:30 am
I was hoping someone would make a program like this. Having your card corrupted when you're on vacation with no access to a computer to fix it is not fun!
_________________
I'm a PSP hacker now, but I still <3 DS.