PDA

View Full Version : DC SD Card Adaptor



_SD_
03-30-2009, 06:12 AM
http://img6.imageshack.us/img6/3308/2re72va.png



After turning several months, we've assembled an adapter to connect an SD card for the Dreamcast port of the link. The truth is that the speed is amazing and we already have a library to use. More info on our wiki.

But for the production of a few adapters and selling, we need to know how many people would be interested. Cost about 20 € with shipping to SPAIN (+10 € for some foreign countries) and sent with a CD with a program that will be able to exchange files with VMU BINS and launch from the SD card.

EDIT: The prices have been changed to make them accessible to the world, remember that this is not done for profit but for the common good. For this reason we have reset the price originally agreed to cover costs of materials, and assembly time.


Later we will use the library and implemented quickly to a pager for the big games of AES4ALL, load / save snapshots DCaSTaway all emulators and ROMS can be loaded from the SD card.

Are you interested? Book your already adapted in this thread!

-------------------------------------------------- -------------
Reason for development

The Dreamcast has support CD / GD, and visual memory card (VMU). The first one is read-only, and the latter has clear shortcomings: transmission speed and size. For this reason, are always looking for an alternative storage unit that saves the main support (save states) and other files, such as the configuration in our emulators. For a time it was speculated that the port expansion (G2) where the currently connected network adapter (or modem) is ideal for access via the new peripherals. But unfortunately, its architecture and requirements are far beyond our reach. Therefore, the serial port of an alternative that, while not enjoying all the privileges of the port allows for expansion if the most part, our wishes for a new carrier additional capacity and speed. This port allows us to use an SD card adapter that are usually used in mobile devices such as phones, MP3 players, etc..

-------------------------------------------------- -------------
Key Features

* Good transfer rate in both reading and writing (about 500 KBytes / s).
* Very low average access time for reading (a few milliseconds).
* Support for cards up to 2 GBytes of SDS (not tested with larger cards).
* Loading binary from the card as a backup utility dcload and to / from VMU.


-------------------------------------------------- -------------
Driver Software

Obviously the hardware is always in the hands of the software, otherwise their use is limited to decorate our desktop (because of the undesirable characteristics of the housing), so our first task was to create a driver / library to allow us to comfortably using our adapter. These are some of its features:

* Library FatFs by Chan: Support for file systems FAT12, FAT16 and FAT32. Directory Management (basic operations and navigation in trees).
* Control CRC32 Cyclic Redundancy Error.
* Extremely light: less than 30KBytes code.

-------------------------------------------------- -------------
Use and objectives

Primarily used to store saved games (save states), configuration files and read-only memories (ROMs). Is scheduled for implementation in the following emulators:

* AES4All: It will allow a better performance of the MMU, making it virtually emulation is fluid, without needing to access the CD reader, which produces a constant slowdown.
* DCastaway: We will use the saved game. Can store items not currently on a permanent basis.
* Gens4all: Items stored and load ROMs.

DC Emu forum thread to register interest. (http://www.dcemu.co.uk/vbulletin/showthread.php?t=192408)
Original Spanish article. (http://dreamcast.es/news.php?readmore=249)

neoblast
03-30-2009, 06:43 AM
Any help in finding lots of dc versus link cables would help much, and if they are cheap it will reduce the cable price a lot. Pm me if you have a lot of these or know where to get they cheap....

This is all based on jjd01m's work a lib has already been made to use it easily with homebrew and will be released soon.

_SD_
03-30-2009, 07:13 AM
I'd be happy with just getting my hands on the PCB so I could do an internal mod. I could solder directly to the serial port pins on the DC motherboard.

Quzar
03-30-2009, 07:48 AM
I'd be happy with just getting my hands on the PCB so I could do an internal mod. I could solder directly to the serial port pins on the DC motherboard.

There's no pcb needed. All you need is the actual slot receptical, a resistor and two capacitors (just for help with grounding).

raylyd
03-30-2009, 12:49 PM
nice find where do i get one from

alphagamer
03-30-2009, 03:47 PM
cool thing, beats my BBA-NAS idea. (less space, but far less expensive)

_SD_
03-31-2009, 06:05 AM
Dodgy Google translation of jj1odm's Japanese web page. (http://translate.google.co.uk/translate?hl=en&sl=ja&u=http://f17.aaa.livedoor.jp/~takotako/dcserial_ft232bm.php&ei=yGHRSYFJ0dGMB8L7sdMJ&sa=X&oi=translate&resnum=1&ct=result&prev=/search%3Fq%3Dhttp://f17.aaa.livedoor.jp/~takotako/dcserial_ft232bm.php%2523sdcard%26hl%3Den%26client %3Dfirefox-a%26rls%3Dorg.mozilla:en-US:official%26hs%3Dygm) Everything you need to know about doing wonderful things with a DC Serial port.

jj1odm's original, untranslated web page. (http://f17.aaa.livedoor.jp/~takotako/dcserial_ft232bm.php)

-=FamilyGuy=-
04-02-2009, 03:10 AM
ELF LOADER RELEASED !

http://f17.aaa.livedoor.jp/~takotako/dcserial_ft232bm.php#dcsdload

FamilyGuy

Treamcaster
04-02-2009, 03:22 AM
WOOOT! How can I buy this shit dude??
Edit: Good to see ya around FG. I need to talk to you about some mods ;)

wombat
04-02-2009, 04:18 PM
ELF LOADER RELEASED !

http://f17.aaa.livedoor.jp/~takotako/dcserial_ft232bm.php#dcsdload

FamilyGuy

mmmm this probally means that if you get the SD loader to run on a devkit, you can REALLY EASY rip GD-R's!

accel99
04-02-2009, 04:40 PM
where can you buy this thing anyway?is it going to be sold in limited amounts by 1st come 1st serve or what?

link83
04-02-2009, 09:09 PM
Id like to buy one of these cables too :nod:

Im also interested in adding an SD slot internally inside my Dreamcast as Quzar said:-

There's no pcb needed. All you need is the actual slot receptical, a resistor and two capacitors (just for help with grounding).

I looked at jj1odm's schematic but noticed there is also a diode (1N4148?) with a small arrow, but im not sure what thats connected to?

Also, the pre-made SD cable appears to be a combination of a versus cable and a USB SDHC card reader like this one from eBay:-
http://cgi.ebay.co.uk/SDHC-SD-USB-2-0-Memory-Card-Reader-for-2GB-4GB-8GB-16GB_W0QQitemZ260377314284

Now what im wondering is if all the neccessary components are already inside that card reader and its just a matter of 'connecting the dots', or are extra components still needed aswell?

Also, does the jj1odm's original circuit already support SDHC, or is that only possible when using a modified USB SDHC card reader like the one I linked to above?

I hope no one minds me asking, and thanks in advance :icon_bigg

<EDIT> Is it definitely just a resistor, 2 x capacitors, and a diode? I only ask as looking at jj1odm's site I notice the picture below the schematic shows a chip being used?

-=FamilyGuy=-
04-02-2009, 10:09 PM
The pre-made cable is really a hybrid between a versus-cable and a usb sdcard reader.

To make it yourself, you'd have to remove the USB part of the USB sd reader, this mean the usb connector and chips. Then it'd be pretty straightforward, I guess the diode is connected the same way as in jj1odm schematic as it should be generic. You might have to add the caps to the USB dongle.

JJ1ODM made an internal mod that's pretty cool IMO to his DC. My own cable is really ugly and consist of a breadboard with a sd-slot and 9-pin serial cable hanging out + Opened DC with other end of serial cable hanging out ... But it works really well!!!

The diode is connected just like in the diagram, follow the traces and you'll get where to connect it. Note that a lined triangle mean GROUND.

SDHC support is solely software-side ; so the cable could in theory handle it with not problem as long as a lib or driver for sdhc (FAT32) is made. AFAIK 4gig SDHC cards DO work with this cable as long as they are formatted to FAT16.

FG

link83
04-02-2009, 11:41 PM
Thanks for the help :nod:

I think I may have misunderstood the schematic :redface: I now think its a symbol for an LED(?) not a diode. Its not quite like any symbol I have seen for an LED before so thought it was a diode (You have to admit they are pretty similar symbols!)

So I guess if am not interested in adding an LED I should be able to leave out the resistor and the LED? In which case that circuit is incredibly simple :icon_bigg

Still curious why the photo below the schematic shows a chip being used though...

hmmm....Thinking about this some more, couldnt we do this in reverse? eg connect up the Dreamcast serial port to the USB SD card readers SD port, then we would have a simple Dreamcast<->USB connection?! Perhaps wishful thinking...

Nitro734
04-03-2009, 12:05 AM
Thanks for the help :nod:

I think I may have misunderstood the schematic :redface: I now think its a symbol for an LED(?) not a diode. Its not quite like any symbol I have seen for an LED before so thought it was a diode (You have to admit they are pretty similar symbols!)


LED = Light-Emitting Diode ;)

link83
04-03-2009, 12:52 AM
LED = Light-Emitting Diode ;)
:lol: Yeah thanks, its just I knew the symbol was for a 'diode' but didnt understand what the small single zig-zag arrow was for. I have seen LED symbols before but usually they have two straight arrows. Perhaps its a Japanese specific LED symbol? (I believe the Japanese Capacitor symbol is different)

-=FamilyGuy=-
04-03-2009, 10:28 AM
Thanks for the help :nod:

I think I may have misunderstood the schematic :redface: I now think its a symbol for an LED(?) not a diode. Its not quite like any symbol I have seen for an LED before so thought it was a diode (You have to admit they are pretty similar symbols!)

So I guess if am not interested in adding an LED I should be able to leave out the resistor and the LED? In which case that circuit is incredibly simple :icon_bigg

Still curious why the photo below the schematic shows a chip being used though...

hmmm....Thinking about this some more, couldnt we do this in reverse? eg connect up the Dreamcast serial port to the USB SD card readers SD port, then we would have a simple Dreamcast<->USB connection?! Perhaps wishful thinking...

Yeah you can forget about the led if you want.

about the chip on a photo, read cartefully ( and translate) and you'll find out it was an old design that was really slower because of the chip timing and delay.

Foget about the reverse usb thing, I don't think it's that simple :P DC serail is 3v that 's why it's so easy to hack a sd-card reader into it, as sd cards are also 3v. USB is 5v and is a bit more complex than sd-card 'cause it's designed to do any thing you want to, usign the right drivers/hardware.

FG

Evangelion
04-03-2009, 01:59 PM
We can use 5v directly from the power supply

karsten
04-03-2009, 03:38 PM
so homebrew could be rewritten to used the new DC "harddisk"? that might spur out interesting linux news too

-=FamilyGuy=-
04-03-2009, 08:59 PM
We can use 5v directly from the power supply
No, since the serial port itself runs at 3v. look for the serial => USB cable schematic online and you'll see a how complex they are just to conver the voltage.

FG

link83
04-03-2009, 09:13 PM
SDHC support is solely software-side ; so the cable could in theory handle it with not problem as long as a lib or driver for sdhc (FAT32) is made. AFAIK 4gig SDHC cards DO work with this cable as long as they are formatted to FAT16.

It mentions in the Spanish 'release info' that FAT32 support has already been added, but do you happen to know if it works?


about the chip on a photo, read cartefully ( and translate) and you'll find out it was an old design that was really slower because of the chip timing and delay.
Sorry, I was having touble translating the page as Babelfish wouldnt work, but now I have managed to translate it with Google I understand. This picture by jj1odm shows how simply it can be done:-
http://img264.imageshack.us/img264/3003/sdtest4.th.jpg (http://img264.imageshack.us/my.php?image=sdtest4.jpg)
Hope to make one similar myself but directly wired to the serial port internally :icon_bigg

Also read about removing the EMI capacitors off the motherboard, but i'm not quite sure how necessary it is to do this? Will the SD slot simply work/not work if I dont remove them, or does it just increase the speed/efficiency/reliability if I take them off?


No, since the serial port itself runs at 3v. look for the serial => USB cable schematic online and you'll see a how complex they are just to conver the voltage.

FG

I just thought that the USB SD card reader must regulate the voltage to the correct level anyway for the SD card, so we could use an almost direct connection (although im unsure why we would need to connect up the Dreamcast 3V line?)
Anyway, I suppose if it were that easy then somebody would have done it already!

alecjahn
04-04-2009, 11:36 AM
Thread of the year and it's only April!

I'm so glad I have the day off tomorrow so I can fiddle with this stuff.

Since I don't have a DC in front of me,I ask: Is the serial port wide enough to justify mounting the reader inside the DC in place of the serial port? I've got a DC ready for some semi-sacrifice and definitely don't mind losing the port for something I would actually use a lot. I suppose you could dremel thin extensions on the slot if its too skinny and then still have the extra room above and below to get your fingers on the card for removal...

-=FamilyGuy=-
04-05-2009, 04:01 AM
It mentions in the Spanish 'release info' that FAT32 support has already been added, but do you happen to know if it works?


Sorry, I was having touble translating the page as Babelfish wouldnt work, but now I have managed to translate it with Google I understand. This picture by jj1odm shows how simply it can be done:-
http://img264.imageshack.us/img264/3003/sdtest4.th.jpg (http://img264.imageshack.us/my.php?image=sdtest4.jpg)
Hope to make one similar myself but directly wired to the serial port internally :icon_bigg

Also read about removing the EMI capacitors off the motherboard, but i'm not quite sure how necessary it is to do this? Will the SD slot simply work/not work if I dont remove them, or does it just increase the speed/efficiency/reliability if I take them off?



I just thought that the USB SD card reader must regulate the voltage to the correct level anyway for the SD card, so we could use an almost direct connection (although im unsure why we would need to connect up the Dreamcast 3V line?)
Anyway, I suppose if it were that easy then somebody would have done it already!

I dunno if the FAT32 support mean SDHC support but It'd be really cool!

I've tested jj1odm's elf/bin loader today and it works well :P

I had the caps problem, with them I got read errors all the time, without them I got none. However the spanish dudes had no problems about this. Maybe it's driver/lib side or maybe they simply are lucky (or I ain't) however it's really easy to remove and doesn't break anything.

I should get a test utility from the spanish guys soon so I'll let you know if SDHC works!

FG

neoblast
04-05-2009, 06:42 AM
we have nicknames just like everyone else FG, we're not just those "spanish guys" for god's sake LOL.
Sure contact me, I have the test app ready.
Fox69k with chui made a lib based on jjd01m's works which now uses KOS and is easier to use.

marshallh
04-05-2009, 07:38 AM
FG, on the page it says he tested SDHC cards to work.

This is cool news. I know very little about the DC architecture, but could a disc emulator be running to grab GDROM data from SD cards? This is the only reason I havent made a DC portable yet

Quzar
04-05-2009, 10:05 AM
FG, on the page it says he tested SDHC cards to work.

This is cool news. I know very little about the DC architecture, but could a disc emulator be running to grab GDROM data from SD cards? This is the only reason I havent made a DC portable yet
Either way you'd still need to boot code from somewhere, so without other extensive mods (new bios) you wouldn't be able to have a disc-less DC.

Ponder on this: if it's possible to boot games from SD (commercial) then why hasn't it been done over coder's cable, where we actually have virtual 'smart' storage?

Calpis
04-05-2009, 11:02 AM
Beyond the complications of hooking GDROM functions, there's also the issue that the serial port is around 3x slower than the GDROM... Really a shame!

link83
04-05-2009, 10:19 PM
Beyond the complications of hooking GDROM functions, there's also the issue that the serial port is around 3x slower than the GDROM... Really a shame!

Actually, what is the maximum read speed of this SD card slot? I can only find mention on jj1odm's site of write speeds between 500kB/s-650kB/s, but theres no mention of read speeds, which are usually quite abit higher than write speeds.

As I understand it the Dreamcast GD-ROM Drive is a CAV drive with reading between 4x-12x (600kB/s-1800kB/s) So with the lower average access times for reading SD cards im thinking that the SD card slot might not be all that slow...

:shrug:

-=FamilyGuy=-
04-05-2009, 10:56 PM
we have nicknames just like everyone else FG, we're not just those "spanish guys" for god's sake LOL.
Sure contact me, I have the test app ready.
Fox69k with chui made a lib based on jjd01m's works which now uses KOS and is easier to use.
Lol I just didn't want to enumerate all the people involved in this :P
Send me the test app via email! I'll test it as soon as I'll get it!

@marshallh: Yeah but I can't answer this question myself as I didn,t tested it, and jj1odm's apps doesn't support it, for now...
PS: Do you happen to be Mathieulh ?

FG

Calpis
04-05-2009, 11:58 PM
Actually, what is the maximum read speed of this SD card slot? I can only find mention on jj1odm's site of write speeds between 500kB/s-650kB/s, but theres no mention of read speeds, which are usually quite abit higher than the write speeds.
Approximately the same, the SD card isn't the bottleneck, it's the serial port (and SPI protocol).

-=FamilyGuy=-
04-06-2009, 12:40 AM
Well, theorically the serail port can go up to 1.5MB/s I think (the USB coder cable could reach this I beleive). Maybe, and don't quote me on that, some improvements could be done to reach this speed with teh sd-card, but i'd be the limit.

FG

link83
04-06-2009, 01:23 AM
I could be totally wrong here as the translation isnt very good, but jj1odm's site seems to suggest that the SH4 can probably handle upto 3MB/s using an external clock (on Pin 2?) to set the baud rate, but you need to remove the EMI capacitors and the software needs to support this feature.


FT232BM this circuit is based 1.5Mpbs x 16 = 24Mhz We have built-in clock.

Why 2Mbps: 32MHz or maximum of 3Mbps: 48MHz may also affect the results of the cable and actually tried it in DC and did not have quite the long distance routing patterns in the motherboard itself, affect the parts of the anti-EMI The limit was 24MHz.

(Usually number 10 in the cable that supplies the logic signal from the external clock with the Mega will not. It should be mounted on the DC itself.)

SH4 interface itself is probably the SCI 3Mbps (48MHz) and it appears to work.
(Note that im not sure if the the lowercase Mbps (Megabit) instead of MBps (Megabyte) is a result of mistranslation, or simply an error)

So is there any way we could add an external crystal to the SD Cart slot mod circuit to improve speeds?

Calpis
04-06-2009, 04:14 AM
Well, theorically the serail port can go up to 1.5MB/s I think (the USB coder cable could reach this I beleive).
That is 1.5 megabits/s, reaching the limit of RS232.


I could be totally wrong here as the translation isnt very good, but jj1odm's site seems to suggest that the SH4 can probably handle upto 3MB/s using an external clock (on Pin 2?) to set the baud rate, but you need to remove the EMI capacitors and the software needs to support this feature.
I think it's more like you can't go faster than 2 megabits/s with an external clock before the signal degrades, the UART however has no problems with 3 megabit operation if you bring the oscillator inside.


So is there any way we could add an external crystal to the SD Cart slot mod circuit to improve speeds?
No, the baud rate is completely irrelevant to the SD card circuit, it uses the parallel I/O test register where toggling an output clocks the data. Speed is limited by 1) how fast the CPU can serialize/arrange the data and 2) how fast the CPU can access the register (any waitstates). Obviously unbuffered serial I/O at this speed is a very CPU intensive task so it should be pointed out it can't be done transparently (and can't remotely replace the buffered GDROM).

-=FamilyGuy=-
04-06-2009, 05:24 AM
That is 1.5 megabits/s, reaching the limit of RS232.

My bad, sorry!

Hey I just read the emuforge page on the sd-card, and it says SDHC is supported up to 4GB only, this is normal and JJ1ODM's apps support 4gb SDHC too.
http://www.emuforge.com/wiki/index.php?title=Adaptador_Dreamcast_SD

FG

Quzar
04-06-2009, 02:38 PM
My bad, sorry!

Hey I just read the emuforge page on the sd-card, and it says SDHC is supported up to 4GB only, this is normal and JJ1ODM's apps support 4gb SDHC too.
http://www.emuforge.com/wiki/index.php?title=Adaptador_Dreamcast_SD

FG

They've also quoted a price when they don't even know how they're getting the end connectors yet, so...

Evangelion
04-06-2009, 11:39 PM
I have my old DC Coder Cable, I think I can mod it to be a Coder cable AND a SD reader :)

SegaFan4Life
06-20-2009, 06:41 PM
any updates on this thing?

SirGadget
06-23-2009, 09:32 PM
Does anyone have a picture of a DC where the SD slot is modded in the back, instead of the serial port?:-)

Johnny
06-23-2009, 11:18 PM
That is just cool! Nice to see the DC alive and running!

APE
06-25-2009, 03:30 AM
This thing uses bit banging, not a standard implementation of the SD spec due to the fact it needs to be licensed.

Translation: it's going to be A LOT slower than the SD card in your phone/camera/USB reader.

-=FamilyGuy=-
06-25-2009, 09:54 PM
This thing uses bit banging, not a standard implementation of the SD spec due to the fact it needs to be licensed.

Translation: it's going to be A LOT slower than the SD card in your phone/camera/USB reader.

I dumped games in raw mode on a sd-card in about 35minutes, for a 3tracks game (data only) that mean, wihout taking in consideration the 2 first tracks (real speed will be greater than the calculated one):
[(549150-45000)sectors * 2352bytes/sectors]/(35minutes*60seconds/minutes) = 551kB/s

It's still slower than the card's maximum rate, but it's really good FOR A DREAMCAST!
Reading speed should be a bit better too, if the serial port doesn't limits it.

That's pretty great actually, almost 3.7x in cd-rom speed.

You should all get one, it's cool :P

FG

SirGadget
06-26-2009, 02:44 AM
I dumped games in raw mode on a sd-card in about 35minutes, for a 3tracks game (data only) that mean, wihout taking in consideration the 2 first tracks (real speed will be greater than the calculated one):
[(549150-45000)sectors * 2352bytes/sectors]/(35minutes*60seconds/minutes) = 551kB/s

It's still slower than the card's maximum rate, but it's really good FOR A DREAMCAST!
Reading speed should be a bit better too, if the serial port doesn't limits it.

That's pretty great actually, almost 3.7x in cd-rom speed.

You should all get one, it's cool :P

FG

So how did you end going about this?

Did you buy a finished one in a housing?

Did you big one yourself?

If so, did you built it in?

Did you have to remove the capacitors mentioned earlier?

Pics?

Thanks:-)

APE
06-26-2009, 03:40 AM
I dumped games in raw mode on a sd-card in about 35minutes, for a 3tracks game (data only) that mean, wihout taking in consideration the 2 first tracks (real speed will be greater than the calculated one):
[(549150-45000)sectors * 2352bytes/sectors]/(35minutes*60seconds/minutes) = 551kB/s

It's still slower than the card's maximum rate, but it's really good FOR A DREAMCAST!
Reading speed should be a bit better too, if the serial port doesn't limits it.

That's pretty great actually, almost 3.7x in cd-rom speed.

You should all get one, it's cool :P

FG

I was under the impression bit banging was a lot slower than that. Not bad. Think I will go through with my plans to fabricate some PCBs.

Calpis
06-26-2009, 06:44 AM
"Bit banging" is really slow but remember the CPU is 200 MHz with a relatively deep pipeline. Pseudocode:

byte = *buffer;
buffer++;

out((byte & bitmask) | clkbit);
clkbit ^= clkmask;
out((byte & bitmask) | clkbit);
byte >>= 1;

out((byte & bitmask) | clkbit);
clkbit ^= clkmask;
out((byte & bitmask) | clkbit);
byte >>= 1;

etc etc

-=FamilyGuy=-
06-26-2009, 04:36 PM
So how did you end going about this?

Did you buy a finished one in a housing?

Did you big one yourself?

If so, did you built it in?

Did you have to remove the capacitors mentioned earlier?

Pics?

Thanks:-)

I didn't bough a finished housing.
I built it myself (one of the first one beside JJ1ODM).
I soldered directly to the motherboard, but let the cable hang out of the DC.
Yes I had to remove the caps
Well mine is pretty ugly so far, it's fully working but completely ugly. I'll take pics of one I might build for a friend soon, this one will looks more professionnal as I'll do it for someone else, in opposition of the first one I did "to check out if it worked".

@APE: Some PCBs would be cool, but keep in mind that 2$ USB SD-CARD readers can be used as a replacement of a PCB.

Cheers,

FG

SirGadget
06-26-2009, 04:41 PM
Kewl:)

I thinking of building two.

Buying me a cheap DC in which I can built it in directly, as a replace men tfor the serial port.

And one, where I just soler a standard reader to a Serial cable, to test if it'll work with my Biohazard DC, without having to open it, which I obviously am not going to do:-)