Another XR88C681 module

342 views
Skip to first unread message

Tadeusz Pycio

unread,
Aug 30, 2023, 12:52:31 PM8/30/23
to retro-comp
I am planning to build a new version of the XR88C681 module which will already support the IM2 mode of the Z80 processor. Below is the concept I want to use and hopefully it will work in reality. There is quite little information in the documentation about the timing requirements after accepting an interrupt and the exposed vector on the bus. I'm hoping the XR88C681 will replace my CTC and SIO for MP/M and provide, with its built-in FIFO and automatic handshake, a seamless implementation of the XMODEM protocol for this OS.

Schematic:

XR88C681SH.jpg
Time waveforms

XR88C681.jpg

Tadeusz Pycio

unread,
Aug 31, 2023, 5:36:04 PM8/31/23
to retro-comp
Initial attempts to use the XR88C681 as a replacement for the CTC and SIO have shown promise on existing modules in IM1 interrupt mode. I've been thinking about how to use the GPIO lines and I think adding an RTC would be a good idea. I originally wanted to use them as an SPI interface to the SD card modules, but the performance of this solution is poor.

XR88C681SH_RTC.jpg

Chris Odorjan

unread,
Aug 31, 2023, 9:19:23 PM8/31/23
to retro-comp
On Thursday, 31 August 2023 at 17:36:04 UTC-4 Tadeusz Pycio wrote:
I originally wanted to use them as an SPI interface to the SD card modules, but the performance of this solution is poor.

I did this with an 8085-based SBC I've been working on (thinking "great, the GPIO lines on the XR88C681 can be used for memory banking and I'll still have enough left over to bit-bang an SD card!"). Yeah, it's slow: raw read speed was around 12.3 kilobytes/sec (9.8K/sec with CP/M overhead). From what I remember a floppy should be around 16K/sec.

The most recent revision of the SBC uses a Texas Instruments TP3465 Microwire Interface Device since it speaks enough of a subset of SPI to drive an SD card (multiple ones too, although I haven't tested that). Now I'm getting 40.1K/sec (28.4K/sec in CP/M) which is more tolerable ("slow hard drive on an XT-class PC speeds" or thereabouts).

I also ended up using the '681 to interface with an RTC, except it's speaking I2C to a DS1307 (with the help of a couple gates from a 74HCT125). (I'm actually not sure why I used the '1307 instead of a '1302, I suppose it was to use its square wave output as an additional timing source and so I could say my homebrew computer has an I2C bus.)

(I need to document all of this...)

--
Chris Odorjan

Tom Storey

unread,
Sep 14, 2023, 2:49:39 AM9/14/23
to Chris Odorjan, retro-comp
If you can find some, the PCA9564 is a parallel bus I2C controller that can act as both master and slave.

--
You received this message because you are subscribed to the Google Groups "retro-comp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to retro-comp+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/retro-comp/48c537a2-cd7b-4307-99a1-621fdeca6568n%40googlegroups.com.

Alan Cox

unread,
Sep 14, 2023, 4:58:03 AM9/14/23
to Tadeusz Pycio, retro-comp
On Thu, 31 Aug 2023 at 22:36, Tadeusz Pycio <ta...@wp.pl> wrote:
>
> Initial attempts to use the XR88C681 as a replacement for the CTC and SIO have shown promise on existing modules in IM1 interrupt mode. I've been thinking about how to use the GPIO lines and I think adding an RTC would be a good idea. I originally wanted to use them as an SPI interface to the SD card modules, but the performance of this solution is poor.

It will certainly drive an SPI RTC. I've been using it for disks with
the SIO and it's not fast but it's floppy disk speed which is fine.
There is a fast 4bit data transfer mode on SD cards but no hobby board
in the US uses it because of patent issues. Outside the USA it
shouldn't be a problem.

With a couple of diodes you can bitbang PS/2 (which isn't great for a
real OS but fine for CP/M), and add a couple of resistors as well and
you can do I2C. It's a bit slow for a Wiznet ethernet link. It's also
possible to use them for joystick, cassette tape and sound. Lots of
options.

Alan

Tadeusz Pycio

unread,
Feb 14, 2025, 6:41:00 PMFeb 14
to retro-comp
I have resumed the completion of an overdue project. In the meantime, I managed to get hold of SCN2681 and SC26C92 chips (the one in a PLCC enclosure), so I decided to make another universal module that can use chips in a DIP40 or PLCC44 enclosure. It will have an XR88C681 chip to handle the IM2 vector interrupts (to be checked). I will forgo the use of GPIOs as it will be difficult to maintain versatility on a dual layer PCB.
Of interest, the SCN2681 is not detected by checking the value written to the ‘xC’ address register, so under RomWBW it is detected as XR88C681. A cursory look at the documentation, you will be hard pressed to find any other way to distinguish between these chips.

DUART2.png

7alken

unread,
May 14, 2025, 10:04:35 PMMay 14
to retro-comp
cool fusion ))

Tadeusz Pycio

unread,
Jul 17, 2025, 1:55:43 PMJul 17
to retro-comp
The experimental version of DUART 2.0 has been assembled. I hope that the accepted concept of IM2 vector interrupt handling for the XR88C681 is correct. Tests will verify this. I have high hopes for this, because if the concept is correct, I will be able to build a computer for MP/M on Z80 from 4 RCBus modules.

duart20.jpg

Tadeusz Pycio

unread,
Sep 1, 2025, 7:25:23 PMSep 1
to retro-comp
I found some time to test the new module in IM2 interrupt mode. The module works as expected, sending a vector requires generating an RD signal for the XR88C681. I am a little disappointed with the counter handling by this chip. After reaching the interrupt condition (value 0), the counter needs to be restarted, which loads the initial values. For this reason, the initial values must take into account the interrupt handling time until the Start Counter command is issued. It's a pity that this doesn't happen automatically.

Tadeusz Pycio

unread,
Sep 7, 2025, 1:10:27 PM (13 days ago) Sep 7
to retro-comp
It seems that I have managed to build a computer running MP/M using my four modules. Better results can be achieved by using Sergey's Z80-512k (version supporting Zeta2-compatible MMUs will also be developed).

set1.jpg

Zrzut ekranu 2025-09-07 184541.png
Reply all
Reply to author
Forward
0 new messages