Review DLDI Tutorial

  • Thread starter Thread starter Opium
  • Start date Start date
  • Views Views 218,789
  • Replies Replies 81

Opium

PogoShell it to me ™
Former Staff
Joined
Dec 22, 2002
Messages
8,202
Reaction score
115
Trophies
3
Age
38
Location
Australia
Website
www.gbatemp.net
XP
1,259
Country
Australia
dlditut.jpg

Official DLDI Website
Linux DLDI Tutorial

What is DLDI? (how did it come about?)

DLDI stands for ‘Dynamically Linked Device Interface’. It is an interface for libfat that homebrew developers attached to their projects.

I’ll break it down to more understandable terms. Let’s say a homebrew developer makes a DS game where you can draw a picture and save the image to your flash cart. To save this image on the flash cart the developer would have to know the specific piece of code that allows you to write things to the cart. And if you wanted to read the image so you can edit it again you’d need access to the read capabilities of the flash cart. This forms the read/write commands which are essentially what libfat is.

There is a big problem however. Every flash cart uses different read/write commands. That would mean to get your game working on four different flashcarts you’d need to code it with all four different write/write methods. This is a big hassle for developers and flash cart owners a like. Under the old system homebrew projects that used read/write commands (FAT access) only worked on the flashcarts they were specifically coded for. As there are so many flash carts on the market many were left out because to keep your homebrew project working on 15 + different kits would be a nightmare!

Along came DLDI. This interface developed by Chishm unifies everything. It is a single interface that homebrew developers attach to their projects. The developers don’t have to worry about making their project compatible with a whole range of different carts. Instead each flashcart has a specific DLDI patch made for it which houses all the read/write commands. You would then simply patch the homebrew game or application with your cart’s DLDI patch and it will work on your cart. So if you have an R4 DS you apply the R4 DS DLDI patch to the homebrew .nds file. The beauty is that once a DLDI patch has been made for your cart it’ll be compatible with every piece of homebrew that has DLDI support.


What carts are supported?

As of the time of writing the following carts have a DLDI patch:

AceKard+
DSLink
DS-Xtreme
Ewin2
EZ-Flash IV
EZ-Flash V
G6-Flash (Lite)
M3 Adapter (CF)
M3 Adapter (SD)
Max Media Dock
GBA Movie Player (CF)
GBA Movie Player (SD)
NEO flash MK2 & MK3
NEO2
Ninja DS
NinjaPass X9
R4 DS
M3 DS Simply
Supercard (CF)
Supercard (SD)
Supercard Lite
Supercard DS One

You can download DLDI patches from the official site here.

Important note
: many of the current slot-1 flashcarts now patch homebrew automatically, so you won't need to patch anything (providing you have the latest firmware/loader/updates for your cart). These carts feature automatic DLDI patching: CycloDS evolution, R4, M3 Simply, and other might add up to this list later.


What Homebrew games/apps do I need to patch?[/color]

Any homebrew game or application that uses FAT access and supports DLDI. Homebrew games/apps that do not read or write to your card do not need to be patched.


How do I patch my homebrew games/apps?

1. Download a DLDI patcher from the homepage. I recommend this one.
2. Download the appropriate DLDI patch for your flash cart.
3. Select the DLDI file you want to use.
4. Select the homebrew you want to patch in the ‘binaries’ section.
5. Click ‘Patch’ and you’re done.

dldipatcher.gif


Note: EZ-Flash V users will need to use a separate DLDI patcher to make DLDI work. If you have an EZ-Flash V please use this DLDI patcher. No other files are needed, simply drag and drop the homebrew onto the exe file.
 
Nice one, it confused me at the start too, but Ive found it out myself. I'm glad I'm not doing it wrong, I do it exactly the way you guys do!

BTW does it any harm if you patch a homebrew that doesnt need DLDI?
 
Nice little guide, will help alot of users for sure.

I myself prefer to read about DLDI and find out how it works by myself. But thats just geeky me
tongue.gif
 
Great explanation etc, thank you!

Just wondering where can I get a DLDI for my card though? It's a G6 Lite, doesn't seem to mention it anywhere above.

Thanks again!
 
Nice guide Opium, but why did you leave out DS-X?

Is it because it's listed as 'No' under 'Tested?'
 
ok, pretty straightforward I would think, and I've had some success, but why can't I seem to get most homebrew working on my SC SD Lite Rumble? Is it something to do with the lack of GBA ROM support on this flashcard?

Using DLDI Tool 32, the "Supercard (SD card)" DLDI patch (scsd.dldi) and patching ROMs, specifically the newest Tower Defense, Blubb3D, and Flashback. DSOrganize is OK, as is MoonShell, but other than that I have yet to get any homebrew working. Oh, and DSFTP worked, at least it started but I was having other issues beyond that. "DSOrganize.nds" works without DLDI patching it, but it does that "Checking for Ninja something" startup that takes a lot longer, after DLDI patching it pops right open. And "DSOrganize.sc.nds" pops right open without DLDI patching, guess that means it's just pre-patched?

One problem is that they all seem to come with multiple versions, like Blubb3d has "Blubb3D.nds" and "Blubb3D.ds.gba".

TowerDefense has the _FAT and _PAFS versions, and it says since I'm using a Slot 2 card to use _FAT, but then in the _FAT folder there is "TowerDefense.ds.gba", "TowerDefense.nds" and "TowerDefense.sc.nds".

And Flashback has "FlashbackDS.ds.gba" and "FlashbackDS.nds".

Which files should I be using with a SCSD Lite Rumble? And does the file extension matter, like if I rename a ".sc.nds" to ".nds" is that going to muck things up?

I've tried a ton of combinations of things here, patched each a couple of times, tried the alternate MoonShell SCSD DLDI driver, nothing seems to work.
 
For me DLDI Patcher just gives a note: "file does not have a DLDI section." What does that mean? What am I doing wrong?
 

Site & Scene News

Popular threads in this forum