The ISA adapter board was designed by Bob Edwards. Unfortunately Bob had to rush off to a conference before we got it working, but Paul Mackerras was able to help out with the final bits of hardware debugging. The adapter board consists of a PCI edge connector for the proprietry bus on the TiVo (it uses a physical PCI connector but is completely different from PCI electronically) plus a 16 bit ISA connector. Between the two are a couple of buffers to take the voltage from the 3.3 used on the TiVo to the 5V for ISA, and a GAL which Paul programmed to map the TiVo logic to ISA logic. We've only mapped 11 address lines plus reset so we can't do shared memory yet - we might do that later.
On the TiVo we just had to setup the bank registers (we used BR5) to map the ISA bus into memory with appropriate timings and setup the interrupt controller to have the right settings for the ISA interrupt line. The end result is that the ISA bus appears in physical memory at 0xf4000000. This is mapped into virtual memory using a hardwired TLB entry kindly put there by the TiVo people for use by their own development ethernet board.
The ethernet card we used is a 3C503. I chose that card because it can be jumpered for no shared memory. I initially tried to get a WD8013 to work without shared memory but didn't have any luck (does anyone know if the 8013 can do that? Anyone have a data sheet?). After grabbing the 3c503 out of my wifes desktop things went much more smoothly and with only minor hacks to the normal Linux 3c503 driver we started getting packets through.
Right now the performance is not stunning. We get about 250 kbytes/sec each way (using a "ping -s 1000" test). There is still a lot of tuning to be done, particularly with the bus timings. We had to setup very wide bus timings in the bank registers for reliable operation. Maybe when we map in the ready-enable bit on the bus we can trim those down a bit.
It's all a bit "sticky tape and string" at the moment (I am using business cards to hold the ethernet board up!) but it will be pretty easy to build a proper bracket when it comes time to put the thing in my living room for normal use.
Here are some pictures:
Ahh, good. The ne2k board is now recognised as well. It must have wanted that RE line or the reset (paul setup the GAL so that a write to address 1 sets the reset line and a write to address 0 clears it - very useful). I haven't written a full driver for it, but at least it sees the regs on the card and passes the basic "this is a 8390" test. ne2k clones are really common so if we can get them properly working this should help people trying to reproduce our hack.
Bob arrived back from the US yesterday and we got his new TiVo setup. He brought some TiVo ramchips with him and soldered them onto my TiVo to give 32MB. On the 3rd attempt (surface mount by hand is pretty tricky) it worked and the memory tests passed.
The artwork for the ISA adapter board is here and here. NOTE: This artwork may have errors. The first adapter we built worked fine but the 2nd one didn't work (the TiVo didn't power on). We haven't worked out why yet. If the error is in the basic circuit then you may find it doesn't work. You have been warned!
We now have 4 working ISA adapters, and get over 950k/sec with both the 3c503 and ne2k. Bob is working on a new set of schamatics with all our mods included and I plan on sending some blank boards to another TiVo hacker so he can reproduce the hack (to make sure someone can follow our description!).
We have some code for playing video remotely over the ethernet and will release it when its been tested a bit more.
We've also got our network video playback pretty smooth. The ethernet can happily handle smooth playback of high quality recordings off the TiVo.
One nice thing is that we were sent 70 boards instead of the 50 we ordered.
Dan has put together a parts list and some parts placement diagrams for the current (rev1) board:
I've written a brief HOWTO that describes how to build and test your own adapter.