Building an "Xfer" style serial card.

Updated 2006-01-05 : Tests with a speedy rs232 transceiver.
Updated 2004-10-03 : I received the uart and quartz and added some pictures.
Updated 2004-09-21 (after spleeping ;-) : Added how it works.
First version 2004-09-21

The name "Xfer card" comes from :
It seems I'm reinventing the wheel,but in fact this page will be more detailed and there'll be more modifications on the card I'm working on (that's not the same card they used on doubledutch, it should be easy to adapt it on other ones).

The goal of the modifications is to alter a standard serial card to achieve a transfer rate of 1.5625 Mbps. So how do you do it ? The main chip is called an uart (Universal Asynchronous Receiver Transmitter), it uses a clock that's divided by a user value to give a desired transfer rate. In fact there's a minimum divider hardwired in the uart, on standard 16450, 16550. uarts, the clock is divided by at least 16, the top transfer speed is clock/16. One can program the uart to have clock/32, clock/48, clock/64 etc...
The dreamcast's top transfer speed is 1562500 bps. 1562500*16 = 25000000. So using a 25Mhz quartz on an uart should do the trick. I looked at some 16550 datasheets :
Texas instrument's TL16C550 can be driven up to 16Mhz for 1Mbps transfer rate, that's to low.
Exar ST16C550 and National semiconductor PC16550 can be driven up to 24Mhz for 1.5Mbps, overclocking them to 25Mhz for an exact 1.5625 Mbps transfer rate should be acceptable, eventually with heatsink.
Last Philips's SC16C550 can be driven up to 48Mhz, no problem for 25Mhz.

For this mod, I used an old isa card. It's got two serial ports a joystick port and a parallel one.
After trying many combinations, I managed to set it to 278h for the parallel port and 3E8h (that's COM3 under dos) for the serial port.
Here's another picture with the main chips identified
uA1488 and MC1489 are line drivers, adapting ttl levels from the uarts to rs232 levels in both directions.
The quartz reads 18.432Mhz
Uarts are 16c450 from Mosic, I couldn't find their datasheets, well I'll test them anyway at 5Mhz (standard 16450 can be driven up to 9Mhz).
The Pal 16L8 decodes isa addresses to enable the chips of the card.
74LS32, 74LS125, 74LS244 and NE558 must be the joystick components, I don't care.
74LS245 is a buffer for isa input/outputs.
Last, the UMC82C11 gives the parallel functions and the clock for the uarts. On pin 3 we've got a clock at the same frequency as the quartz and on pin 4 the same clock divided by ten, it's this clock (/10) that feeds the uarts (so they receive a 1,8432Mhz clock that gives the max transfer rate of  115200 bps because the uart divides it by at least 16)

For testing purposes while I'm waiting for a 16550 and a 25Mhz quartz, I changed the provided quartz by a 5Mhz one, then I cut the wire coming from pin 4 of the UMC82C11 (bottom arrow on this picture) and strapped the pin 3 on a via (up arrow) to feed the uarts with a 5Mhz clock.

As for now I'm having troubles building dc-tool, either under linux or cygwin. And the card doesn't seem to work at all under linux (but it does with win98se).
Update : the card works under linux, I didn't check the interrupt number...

Now I've got a
National semiconductor PC16550 and a 25Mhz quartz, here's a picture of the modified card. I also added a small radiator just in case.

Some tests with my standard dreamcast "coders cable" I built with a Max3232 show it can sustain the rate of 520833 bps (not so bad for a chip garanteed at 115200 bps).

Next step will be to use a faster transceiver or to remove the line drivers on the card.

Erwan was working on a high speed coders cable, it uses a faster max3225, so I built it, coupled with the latest dc-tool, I could push the speed at its maximum.

Here are some speed tests I made with a 4MB uncompressible file :
At 115200bps (standard coders cable) : 365s, effective speed : 11490.52 Bps
At 520833bps : 82s, effective speed : 51204.85 Bps
At 781250bps : 55s, effective speed : 76522.36 Bps
At 1562500bps : 30s, effective speed : 143419.75 Bps

Some help to configure Linux now :
You must use setserial to define the card's base baud rate, something like :
setserial /dev/ttyS2 baud_base 1562500

Be sure to use the correct irq/port, redefine them with setserial if needed (autodetection isn't safe). Stick to spd_normal flag. With these settings if you ask dc-tool for 1.5Mbps, you'll get 1.5625Mbps, if you ask for 1Mbps, you'll get 781250bps, if you ask for 500kbps, you'll get 520833bps.

That's it, I'm quite happy with these settings and am too lazy to test/modify dc-tool under cygwin for now, so I think this project is finished.