#124251 - chishm - Wed Apr 04, 2007 1:43 pm
I noticed all the requests for an NDS file loader, and decided to finish mine. It uses DLDI, and should be able to run from any DLDI based card. I don't really feel like writing documentation right now, so just poke through the source and see how it works. If you have any questions, post them here.
NDS loader
To try the test, you must patch the NDS file with a DLDI. The loader uses this to patch the exec stub when it loads it. The example NDS file will run "runme.nds" from the root of your media card.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
#124252 - Lick - Wed Apr 04, 2007 2:05 pm
Nice work! And.. O MY GOD.. It's running from ARM7, which means you somehow worked around the obstacle I faced when I tried mine.
Quote: |
To try the test, you must patch the NDS file with a DLDI. The loader uses this to patch the exec stub when it loads it. |
Hey, wasn't that my idea? :p
By the way, works on Supercard miniSD.
_________________
http://licklick.wordpress.com
Last edited by Lick on Wed Apr 04, 2007 2:21 pm; edited 1 time in total
#124255 - Sektor - Wed Apr 04, 2007 2:14 pm
Tested on DS-X with dsx.dldi. It displayed a white screen for about 9 seconds and then started SpoutEx. I tried starting dslinux but it just stays on white screens.
_________________
GTAMP.com/DS
Last edited by Sektor on Wed Apr 04, 2007 3:05 pm; edited 1 time in total
#124258 - chishm - Wed Apr 04, 2007 2:37 pm
I forgot to include a license before. The load.bin source (contained in the BootLoader directory) is licensed under the following terms: Quote: |
Feel free to use and redistribute my library freely, as long as you
a) credit me for this library and
b) publish all your modifications to this library (if any are made) |
The wrapper code (contained in the arm9 and arm7 directories) is public domain.
Sektor:
I just tried it on my GBAMP with an old build of DSLinux and it worked okay. Make sure you are using the DS-X DLDI from my site, or some other one that doesn't have the unaligned read bug.
Lick:
Well I started this a few weeks ago, so I guess we independently came up with the idea. However my code doesn't have to search main memory for the source DLDI patch. It uses some trickery to get it directly from libfat: Code: |
extern const u32* _io_dldi;
pDH = (data_t*)(((u32*)(&_io_dldi)) -24);
|
EDIT: Removed confusing clause c from license.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
Last edited by chishm on Thu Apr 05, 2007 12:25 pm; edited 1 time in total
#124261 - Diddl - Wed Apr 04, 2007 3:26 pm
Cool, many thanks to you Chishm, I will test it!
#124264 - OOPMan - Wed Apr 04, 2007 4:24 pm
Very cool. I guess we'll see this being used in some apps (DSO, maybe...)
_________________
"My boot, your face..." - Attributed to OOPMan, Emperor of Eroticon VI
You can find my NDS homebrew projects here...
#124268 - Lick - Wed Apr 04, 2007 5:41 pm
The example project (and all other projects) fails when you build it with an ARM-mode ARM9.
Try removing '-mthumb' from the ARM9 Makefile, build and run. It will fail, because the inline assembly in the stub fails in ARM mode, I'm guessing.
I'm not sure if that's the precise cause of the failure, but it fails nonetheless.
_________________
http://licklick.wordpress.com
#124271 - Diddl - Wed Apr 04, 2007 7:17 pm
test report for NDS-Loader:
runme.nds is a giana sisters homebrew (giana.nds)
Supercard DS-one v2 ---------- ok
DS-Xtreme 4GB ------------------- ok
DS Link (on flashed NDS) -------- fails
DS Linker (MK5) 4G -------------- fails
DS Linker (MK5) 16G ------------- fails
Ninja X9 ---------------------------- fails
DS simply (R4) -------------------- fails
EZ Flash 5 -------------------------- fails
runme.nds runs fine on all cards.
#124284 - tepples - Wed Apr 04, 2007 9:19 pm
chishm wrote: |
I forgot to include a license before. The load.bin source (contained in the BootLoader directory) is licensed under the following terms: Quote: | Feel free to use and redistribute my library freely, as long as you
a) credit me for this library and
b) publish all your modifications to this library (if any are made) and
c) do not create any damaging software with this library. |
|
It looks like an MPL/LGPL style weak copyleft. I'm trying to evaluate clause c) for compatibility with other popular licenses (such as GNU GPL). Is "damaging software" defined elsewhere in the common law? Could it be defined as software intended for use as a tool of data interference (see Wikipedia:Computer crime)?
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.
#124318 - HyperHacker - Thu Apr 05, 2007 2:25 am
Yeah, the license is a bit vague. "Damaging" could be, for example, homebrew clones of commercial games, software that unintentionally causes a problem, a game that's so frustrating it causes you to throw the DS across the room, etc.
Can we manually patch the stub so it doesn't have to spend time patching it every time it's used?
_________________
I'm a PSP hacker now, but I still <3 DS.
#124330 - Fling - Thu Apr 05, 2007 3:02 am
Nice work!
I took a stab at extending this into an HTTP bootloader.
http://files.blarg.ca/projects/httpexec.tar.bz2
Works fine for me with my DS-X, except it has issues with anything that uses a version of libfat pre-DLDI, and anything using libdswifi (they will boot, but the libs mentioned do not work correctly in the program that is loaded). There may be more issues that I haven't noticed, but aside from those two, I haven't come across anything else yet. As I'll be using this to develop from now on, I'm sure I'll see it gets a bunch of testing over the next while.
#124355 - Lick - Thu Apr 05, 2007 10:28 am
HyperHacker wrote: |
Can we manually patch the stub so it doesn't have to spend time patching it every time it's used? |
Don't you see the beauty of this? And from the looks of it, patching is pertty fast! It's all the other stuff that takes most of the time, but those are also in MightMax's exec_stub.
So DLDI copying doesn't affect the speed.
Fling: nice work! I'm using it locally with lighttpd now! :D I also modified it to load a txt file instead.
_________________
http://licklick.wordpress.com
#124364 - chishm - Thu Apr 05, 2007 12:33 pm
Lick: I'll move the inline ASM to a separate .s file when I get the chance.
Diddl:
Do those failed cards just give white screens, or does it say "failed" on screen? If it's the later, I suspect that they are using the IO identifier of 'DLDI' for the DLDI patches.
tepples & HyperHacker:
Removed clause c from the license. The license now given in the above post is the current license.
HyperHacker:
The DLDI patching is very quick. Any speed issues that you notice are due to the hardware IO. My GBAMP CF loads files quite fast from my 50x CF card.
Fling:
It needs DLDI to function, as that that is what the exec stub uses to read the file. It can't use any of the built in libfat IO drivers, as they aren't easily copied into loaded code.
I suppose the next step would be for the exec stub to try DLDI patching the loaded file, and to fix the inline ASM.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
#124371 - Diddl - Thu Apr 05, 2007 2:20 pm
chishm wrote: |
Do those failed cards just give white screens, or does it say "failed" on screen? If it's the later, I suspect that they are using the IO identifier of 'DLDI' for the DLDI patches. |
As far as I remember none of them give the text "failed" but most of them give two white screens.
I will repeat tests at evening and write better error reports for each failed.
thanks for your effort
###
do I guess correct - the maximum size for the loaded .nds file is nearly 4MB? .nds files with appended filesystem which exceeds 4MB wouldn't work cause slot 1 card cannot access the file with "normal" SPI commands?
#124375 - chishm - Thu Apr 05, 2007 3:31 pm
Diddl wrote: |
do I guess correct - the maximum size for the loaded .nds file is nearly 4MB? .nds files with appended filesystem which exceeds 4MB wouldn't work cause slot 1 card cannot access the file with "normal" SPI commands? |
That's mostly correct. If the NDS file is loaded from a non-media based GBA flash cart, using the FCSR IO driver, then the FCSR file system is considered an appended file system. The simple answer is only NDS files that would be bootable from the GBAMP will be usable.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
#124377 - Fling - Thu Apr 05, 2007 3:44 pm
chishm wrote: |
Fling:
It needs DLDI to function, as that that is what the exec stub uses to read the file. It can't use any of the built in libfat IO drivers, as they aren't easily copied into loaded code. |
Sorry, maybe I wasn't clear. I meant that it has problems when I use my httpexec to download & run another NDS binary which uses an older version of libfat (I had a couple old projects sitting around). I didn't recompile your exec stub or anything, I just left it as is.
#124410 - Diddl - Thu Apr 05, 2007 8:48 pm
Code: |
DS Link (on flashed NDS) -------- fails |
cannot test, have no flashme DS today ...
Code: |
DS Linker (MK5) 4G -------------- fails
DS Linker (MK5) 16G ------------- fails |
After key "A" both screens white.
Code: |
Ninja X9 ---------------------------- fails |
on display is "press A to start ..." and stays (nothing happens)
Code: |
DS simply (R4) -------------------- fails |
on display is "press A to start ..." and stays (nothing happens)
Code: |
EZ Flash 5 -------------------------- fails |
on display is "press A to start ..." and stays (nothing happens)
#124527 - chip19 - Fri Apr 06, 2007 4:27 pm
I also tested it on an M3 Simply with the same result --- at the "Press A to start" screen, it just hangs. The top screen is white (I'm guessing that's normal), but the bottom screen continues to say Press A no matter how many times I press it. No "failed" message; it just freezes.
_________________
Linux Kernel Hacker since '01
bh = sb_bread(sb, le32_to_cpu(p->key));
#124572 - Tets - Sat Apr 07, 2007 12:10 am
Technically this succeeds in booting anything I've tried on my MMD, but whatever boots ends up freezing shortly thereafter (about half a second after, by my best guess).
#124576 - Lick - Sat Apr 07, 2007 12:46 am
Tets wrote: |
Technically this succeeds in booting anything I've tried on my MMD, but whatever boots ends up freezing shortly thereafter (about half a second after, by my best guess). |
Probably the conflict of the older fatlib that Fling mentioned above. Basically, the booted app can't initialize fat.
_________________
http://licklick.wordpress.com
#124721 - tondopie - Sat Apr 07, 2007 11:49 pm
This is definatley the best loader. I just used it in my app. Here: http://forum.gbadev.org/viewtopic.php?p=124720#124720
#124789 - Diddl - Sun Apr 08, 2007 6:07 pm
cannot load the zip file, get always an error mesage (PHP anything)
the best loader (open source loader) is that in EZ-Flash V. it can load everything including gba homebrew if extension is in slot 2. problem of this loader is, it only works in EZ-V cartridge.
#124835 - tondopie - Mon Apr 09, 2007 12:44 am
Diddl wrote: |
cannot load the zip file, get always an error mesage (PHP anything)
the best loader (open source loader) is that in EZ-Flash V. it can load everything including gba homebrew if extension is in slot 2. problem of this loader is, it only works in EZ-V cartridge. |
yeah... that is kind of a problem
#137631 - calcprogrammer1 - Tue Aug 14, 2007 5:57 am
Sorry for being half a year late, but I was pointed to this topic. How might I go about implementing this? I am using only an ARM9 program, how do I implement this into my program so that I can use the runNdsFile() command? I tried including "nds_loader_arm9.h" but it gives the error error: load_bin.h No such file or directory. I put the load.bin file in my data directory (devkitPro/Projects/DSFile2/DSFile2/data) and I put the stuff from arm9/source in .../DSFile2/source.
I'm using PAlib, is there a way to add the ARM7 functions that this uses to PAlib's ARM7 code?
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#137643 - spinal_cord - Tue Aug 14, 2007 9:55 am
I'm having problems with palib also.
I got the arm7 part to build into the palib arm7 no problem(I think), but ?I had the same thing with the load_bin.h I built the whole thing without palib, the load_bin.h appeared in the directory (i then just copied this to my project source directory in palib. I have heard that palib manages .bin files differently/wrong.
The problem I have now is
nds_loader_arm9.c:228: error: 'REG_EXEMEMCNT' undeclared (first use in this function)
I have just 'googled' that and it seems REG_EXEMEMCNT has sins been renamed in libnds to REG_EXMEMCNT. I am going to change that, see if it makes a difference.
[edit] palib does not add _bin to the filename, so I renamed load.bin to load_bin.bin and dropped it into the data folder. I also renamed REG_EXEMEMCNT to REG_EXMEMCNT in nds_loader_arm9.c added #include "nds_loader_arm9.c" in my main.c and runNdsFile("/runme.nds"); to load the file.
in the arm7 (c:\devkitpro\palib\lib\arm7\main.c) I did -
#include "nds_loader_arm7.h"
and added runNdsLoaderCheck(); to the main loop
I think the rest of the stuff is already in the palib arm7 code.
I then rebuild palib (c:\devkitpro\palib\fastbuild.bat)
the aprogram then compiled without a problem, but it will not load runme.nds
any ideas?
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#137647 - tondopie - Tue Aug 14, 2007 11:05 am
it has to do with how PAlib handles .bin files. You will experiance that with what ever bootloader you try to use with the exception of maybe the SC and GBAMP built in bootloaders. You could try changing stuff in the makefile, but you might have to change how you use your data files.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#137664 - PypeBros - Tue Aug 14, 2007 4:32 pm
I've been checking your sources yesterday, but there's something that i'm still missing... I see a fifo-reader that understands 'copy' and 'exec' commands on the ARM7, but apparently nothing issueing those commands in exec.cpp on the ARM9 side ...
or is there some kind of stub-to-main7.c interaction i am missing?
_________________
SEDS: Sprite Edition on DS :: modplayer
#137904 - PypeBros - Fri Aug 17, 2007 8:52 am
PypeBros wrote: |
Nice work!
or is there some kind of stub-to-main7.c interaction i am missing? |
Okay, i tried to make sense of those stubs, downloaded the dschannels source code and tried to documents its internal working.
here is the result so far. Comments are welcome.
_________________
SEDS: Sprite Edition on DS :: modplayer
#137976 - calcprogrammer1 - Sat Aug 18, 2007 4:26 am
chishm wrote: |
It needs DLDI to function, as that that is what the exec stub uses to read the file. It can't use any of the built in libfat IO drivers, as they aren't easily copied into loaded code. |
Is there any way to load a separate DLDI? I would really like it if I could boot from either slot, but seeing as this doesn't support standard libfat "fat1:/" and "fat2:/", and loading stuff from supported cards, is there a way to load in a DLDI file externally, or have the GBAMP and other libfat native devices' DLDIs stored in the program?
What I'm looking for is a boot menu replacement that could directly boot files from either a DLDI patched SLOT-1 or a native (or, if possible, a second DLDI) SLOT-2.
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#137982 - DragonMinded - Sat Aug 18, 2007 5:13 am
Calcprogrammer1 yes its easy. Look at the booting code in DSO.
_________________
Enter the mind of the dragon.
http://dragonminded.blogspot.com
Seriously guys, how hard is it to simply TRY something yourself?
#137985 - calcprogrammer1 - Sat Aug 18, 2007 5:28 am
Hmm...now that I think of it, you can use a separate DLDI in DSO, I'll look at it when I get home, I only have my laptop (no dev stuff on it) right now.
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138057 - chishm - Sun Aug 19, 2007 5:27 am
New version uploaded at the same location (NDS_loader.zip). It should fix any problems booting apps created with the latest DKA. It also now has a simple menu, and runs _BOOT_DS.NDS by default.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
#138082 - calcprogrammer1 - Sun Aug 19, 2007 4:51 pm
I know this may be off topic, but if you can tell this to use a certain DLDI file like DragonMinded said, could the same be done with libfat? Such as, patch with the DLDI for a slot-1 (in my case, GnM), boot on the slot-1, then choose a DLDI on the slot-1 for the slot-2 (say, SuperCard Lite or something that's not natively supported in libfat). Could libfat be told to use that DLDI loaded off the card? It wouldn't help me any, but some people said they'd want that ability on DSFile.
Also, if not, what devices are natively supported by libfat (I know GBAMP, but that's all), and is there a way to compile their DLDI files into the .nds itself?
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138087 - Lick - Sun Aug 19, 2007 5:49 pm
It's totally possible, but no one has written a file browser with that option yet.
_________________
http://licklick.wordpress.com
#138140 - calcprogrammer1 - Mon Aug 20, 2007 4:04 am
Can it be done with the current libfat, or would you need to use an edited libfat? I don't know anything about how libfat works or how DLDI patching works, so I probably wouldn't be able to use a modded libfat.
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138156 - Lick - Mon Aug 20, 2007 11:35 am
You just need to open an NDS file, search for its DLDI section and write over it with a new one.
_________________
http://licklick.wordpress.com
#138196 - calcprogrammer1 - Tue Aug 21, 2007 12:34 am
Ok, I'm clueless about that one.
I mean within one program, such as have the program use two DLDI's at a time. I don't think it could rewrite it's own DLDI, could it? Even if so, I don't know how to search through files and stuff, or what to look for.
Though, if I knew how to search for a DLDI in an NDS like you mentioned, it'd be possible to make an on-DS DLDI patcher, wouldn't it, maybe I'll download the source to the command line patcher and see how it would translate to libfat, though not exactly what I was looking for.
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138197 - calcprogrammer1 - Tue Aug 21, 2007 12:58 am
About putting this into PAlib:
I downloaded the .zip. Now I'm trying to put this into my PAlib library so I can use it in DSFile.
First, I copied the files "nds_loader_arm7.c" and "nds_loader_arm7.h" from "arm7/source" in the zip to C:\devkitPro\PAlib\lib\arm7.
Then I opened main.c (already there, not from the Zip) and added:
#include "nds_loader_arm7.h"
under the rest of the includes. Then I added:
runNdsLoaderCheck();
to main(), after the lines:
u32 fifo_temp;
while(1) { // wait for magic number
Then I recompiled it, didn't give me any errors (fastbuild.bat) on compiling it, but I haven't tried compiling an app with it yet. How do I go about putting the ARM9 code in, and do I need to put #include "nds_loader_arm7.c" in as well?
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138198 - spinal_cord - Tue Aug 21, 2007 1:06 am
just the .h i think it loads the .c itself, i might be wrong about that though. I didnt get any errors when i did it.
when you but load.bin in your data directory, palib doesnt add _bin to it, so all the functions will be named wrong. To get around this i renamed it to load_bin.bin.
If you get this working, let me know, I reald don't see how it should be any different using palib though. But I cant get it to load anything.
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#138199 - calcprogrammer1 - Tue Aug 21, 2007 1:13 am
So you're saying to add the "nds_loader_arm9.c" and "nds_loader_arm9.h" files (from arm9/source in zip) to C:\devkitPro\PAlib\lib\arm9?
If so, then do you do the same:
#include "nds_loader_arm9.h" in ...\PAlib\lib\arm9\main.c?
then copy arm9/data/load.bin to ...\PAlib\lib\arm9\data and rename it to load_bin.bin?
Then do the fastbuild?
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138238 - tondopie - Tue Aug 21, 2007 4:58 pm
You should try messing around with your makefile. It will change the way PAlib deals with .bin files.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#138242 - calcprogrammer1 - Tue Aug 21, 2007 5:10 pm
I'm not sure that it's the .bin file, when I build, it produces a load_bin.h and a load.o file just fine. It doesn't give me any errors about this, just a bunch of undefined reference to <something>.
I changed the makefile to add nds_loader_arm9.o and load_bin.h and load.o to the archiving thing, which apparently did something, because now it gives me a new error:
nds_loader_arm9.c: (.text+0x550): undefined reference to '_io_dldi'
nds_loader_arm9.c: (.text+0x564): undefined reference to '_io_dldi'
Where is this _io_dldi thing, and how do I add it to PAlib?
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#138248 - tondopie - Tue Aug 21, 2007 7:49 pm
I'm pretty ure it is the .bin file. It is the only thing that is a problem when switching from libnds to PAlib.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#138471 - PypeBros - Fri Aug 24, 2007 1:52 pm
tondopie wrote: |
I'm pretty ure it is the .bin file. It is the only thing that is a problem when switching from libnds to PAlib. |
I'd rather say it should be in the FAT support library. I saw such error messages when i was trying to compile the rebootlib while using an old revision of the devkitpro (where libfat had no DLDI support).
_________________
SEDS: Sprite Edition on DS :: modplayer
#140384 - spinal_cord - Sun Sep 16, 2007 12:17 am
If I use this unaltered in a project, do I need to do anything other than give credit? I have not changed the loader in any way.
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#140390 - tondopie - Sun Sep 16, 2007 1:16 am
just give credit and you're fine.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#140403 - chishm - Sun Sep 16, 2007 4:07 am
The loader binary is distributed under the GNU GPL v2, so if you change that in any way then you'll need to supply source code on request.
Although I forgot to explicitly license it in the source code (meaning it automatically has full copyright to me), consider the loader stub (nds_loader_*) to be distributed under 3-clause BSD. All that is required is credit in the documentation.
This is all assuming that you load the binary from disc and don't statically link it into your main application, at which point your application would have to be licensed under GPL v2 or above too.
_________________
http://chishm.drunkencoders.com
http://dldi.drunkencoders.com
#141663 - spinal_cord - Fri Sep 28, 2007 2:26 am
I'm haveing a little trouble with this loader. Now and then when I mess with my menu, it will not load. Is this a memory problem? I've tried free()ing all my variables, including my struct for the filenames etc. (after copying the filename to a string)
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#142794 - spinal_cord - Sat Oct 13, 2007 3:52 pm
some of you will hate me for bumping this, with the double post and everything, but i did edit my last post, and as it isn't on the front page anymore, i guess nobody even tried to look.
Can someone tell me of any reasons that this loader would not load on a card that it actually works on. Do I need a specific area or amount of memory free? or wear a particular pair of socks?
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#142819 - tondopie - Sat Oct 13, 2007 11:30 pm
don't quote me on it, but you might need to clear all the memory you can before loading the binary you are trying to launch. I'm not sure if his loader already does this yet. I haven't really looked around at the source.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#142872 - spinal_cord - Sun Oct 14, 2007 8:21 pm
I have tried free()ing all of my variables, but I dont know how to go about freeing other memory up.
_________________
I'm not a boring person, it's just that boring things keep happening to me.
Homepage
#142880 - calcprogrammer1 - Sun Oct 14, 2007 8:32 pm
In DSFile, it works fine on all the files I've loaded with it. DSFile comes out around 351KB and it works fine. I've tested it patched for Games n' music and GBAMP (but it can't do both at the same time).
Does anyone have any idea how you might use this to load a file from a different card than it's DLDI patch (load DSFile (patched GnM) from GnM and boot files off of GBAMP)? I want to know how to boot it (as in, how to use the runNds() command or whatever you'd need) and how to include the GBAMP DLDI patch in the .nds itself.
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#142884 - tondopie - Sun Oct 14, 2007 8:54 pm
calcprogrammer1 wrote: |
In DSFile, it works fine on all the files I've loaded with it. DSFile comes out around 351KB and it works fine. I've tested it patched for Games n' music and GBAMP (but it can't do both at the same time).
Does anyone have any idea how you might use this to load a file from a different card than it's DLDI patch (load DSFile (patched GnM) from GnM and boot files off of GBAMP)? I want to know how to boot it (as in, how to use the runNds() command or whatever you'd need) and how to include the GBAMP DLDI patch in the .nds itself. |
try patching a new DLDI to it when you load the homebrew, idk otherwise.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net
#142888 - calcprogrammer1 - Sun Oct 14, 2007 9:00 pm
Is there a way for the running application to patch itself? That's mainly what I want to do (not patch the app being loaded, but patch the loading app itself).
_________________
DS Firmware 1, Datel Games n' Music card / Chism's FW hacked GBA MP v2 CF
There's no place like 127.0.0.1.
#142889 - tondopie - Sun Oct 14, 2007 9:08 pm
I don't really know... maybe copy itself into the RAM then patch the binary left on the card? I'm not positive that would work though..
EDIT: Try porting CHishm's DLDI patcher to DS.
_________________
Development Blog: http://teendev.org
Homebrew Podcast: http://homebrewcast.net
Web Design: http://xtendesign.net