KIORC, KIO for RC2014

544 views
Skip to first unread message

Bill Shen

unread,
Nov 27, 2022, 7:47:36 AM11/27/22
to RC2014-Z80
This board was designed in 2019; other than proving the design worked, I didn't get around to play with it until now.  It was designed to replace SIO, CTC, and PIO boards with one integrated Z84C90, aka KIO.  The glue logic is a small 32-macrocell CPLD, EPM7032S (or ATF1502) which has enough logic to support a RC2014 compatible DS1302-based RTC.  Originally there was another motivation for using the CPLD which is to emulate 3 boards; SIO2 (original RC2014 SIO2) at 0x80-0x83, CTC (SC102) at 0x88-0x8B, and PIO (SC103) at 0x68-0x6B.  That capability still exists, but over the 3 years since it was designed, KIO software support is getting much better.  Currently it works with the Z80 board and 512K ROM/RAM board to run ROMWBW-KIO.

Beside integrated SIO/CTC/PIO with internal interrupt daisy chains, another advantage of KIO is faster clock operation.  KIO is nominally rated at 12MHz, but I was successful operating it to 29.5MHz when integrated to a single-board Z80 computer.  On a backplane with Z80 board, 512K RAM/ROM board, and KIORC board, it can operate reliably at 16MHz.
  Bill
DSC_70901126.jpg

Bill Shen

unread,
Nov 28, 2022, 9:07:46 PM11/28/22
to RC2014-Z80
The following posts will show KIORC installed in various RC2014 hardware platforms and the associated application software.  Home page for KIORC is here.

This is KIORC with the original RC2014 512K RAM/ROM board and a Z80 board with on-board oscillator (Karlab 23c) installed on a 5-slot RC2014 backplane.  The oscillator frequency is 14.7MHz which is twice the nominal RC2014 operating frequency.  The RomWBW software is the RCZ80 with KIO option that is standard with the current RomWBW distribution.  Note the DS1302 RTC is automatically detected by RomWBW.  The RTC.com utility included in RomWBW's ZSystem can initialize the DS1302 RTC.

I believe this is a good hardware platform to explore Ladislau Szilagyi's RTM-Z80
  Bill
KIO_512RAMROM_Z80_14MHz.jpg
DSC_71001128.jpg
Message has been deleted

Bill Shen

unread,
Nov 30, 2022, 7:44:37 AM11/30/22
to RC2014-Z80
In this setup the 512K RAM/ROM board is replaced with a FRR512K configured to 32x16K banks memory scheme.  Therefore the same RomWBW-KIO that ran in 512K RAM/ROM board will also run in this setup with FRR512K.  The FRR512K board has the system clock and voltage supervisor so the clock in CPU board is removed.  FRR512K also has a compact flash interface so a separate CF board is not needed resulting in a 3-board stack to implement the full CP/M capability.  The photo shows a system clock of 22MHz but the setup can run up to 25MHz making it a very fast RomWBW-capble Z80 computer.
  Bill
DSC_71071129.jpg

Bill Shen

unread,
Dec 1, 2022, 12:31:15 PM12/1/22
to RC2014-Z80
Another setup with KIORC is 2-board stack with Steve Cousin's SC108.  Many people already have experience with SC108 which combined several RC2014 boards into one board including Z80, pageable ROM, RAM and clock function.  All SC108 needed is an I/O board for communication and a CF board to run CP/M.  In this case the I/O board is KIORC.

In absence of a CF board (which will be added in next post), SC108 + KIORC can execute 32K BASIC, 56K BASIC, ROM monitor and SCMonitor.  These software for either SIO2 or 68B50 boards were provided in the factory ROM.  To support KIORC, which is basically SIO2 with different I/O addresses, the factory ROM were edited using the hex editor in TL866II programmer substuting the original SIO2 addresses with new KIO addresses.  An additional initialization of KIO's daisy chain register is also added to the factory ROM programs.  The updated ROM are saved in KIORC homepage.  

The photo shows SC108+KIORC setup running the mandelbrot benchmark with 56K BASIC.  Instead of using one-time programmable 27C256, I used W27C512 instead which can be erased and reprogrammed multiple times.  I also overclocked (of course!) SC108 to 20MHz.  The next step is to install a CF board and have CP/M running.
  Bill
DSC_71121130.jpg
KIORC_56KBASIC_SC108_SIO_bug_fixed.jpg

Bill Shen

unread,
Dec 3, 2022, 6:48:32 AM12/3/22
to RC2014-Z80
In this setup a CF board is added to backplane with SC108 and KIORC.  The CF board is Karlab's 10e which has the added 100ohm/100pF filter on CF read line that operates reliably with many different brands of CF disks.  See the design modification here on Aug 9, 2021.

CPM software support for the CF card is a bit complex; since this is a new I/O device, the existing CF images for either 68B50 or SIO2 won't work, so it needs to be built up from scratch.  There are several steps involved in getting new CP/M installed in a new CF disk:
1.  Format the new CF disk
2.  Transfer new BIOS/BDOS/CCP in the system track of the CF disk
3.  Install a file transferring program in the new CF disk
4.  Transfer CP/M distribution files to the new CF disk

The process is like a wedding, something old, new, burrowed, and blue... It can be done either with Grant Seale's ROM software or Steve Cousin's SCMonitor, or even with my own K80 monitor software, but let's stick with the Grant Seale's original and the best known approach using his ROM monitor that was patched with KIORC addresses.
Step 1, Format is done with Grant's FORM64.HEX as described in his site. i.e., load FORM64.HEX with his ROM monitor and type G5000, and it is done.
Step 2, CPM BIOS for KIO can be borrowed from Ladislau's GitHub.  It is the file "KIO_PutSys_CF64_CPM_DA00H.hex".  It has more TPA space than the original RC2014 CPM such that CCP starts from $DA00.  Just follow the instruction and load the hex file with Grant's ROM monitor and type "G8000" to install new CP/M for KIO in CF's system tracks
Step 3 is transferring DOWNLOAD.COM into the new CF, but I really really don't like DOWNLOAD.COM.  It is (here comes the "something blue" part of the wedding analogy) SLOW, lots of hoops to jump through, so on...  Fortunately there is XMODEM.HEX from foxhollow.ca that can transfer XMODEM.COM instead of DOWNLOAD.COM, but there is a catch:  the new CPM BIOS of step 2 does not implement the file relocation routine in location $FFE8, so GFFE8 command just hangs.  That problem can be fixed with a new file relocation routine:

  ld hl,4100h    ;source
  ld de,100h    ;destination
  ld bc,8f00h    ;copy 36K data
  ldir
  jp 0f000h    ;jump to BIOS boot routine.


To make a long story short, just append this two lines to XMODEM.HEX:
:10FFE000FFFFFFFFFFFFFFFF2100411100010100A4
:10FFF0008FEDB0C300F0FFFFFFFFFFFFFFFFFFFF2C

load the patched XMODEM.HEX then type "GFFE8" which copies XMODEM image from $4100 to $100 and starts CP/M.  At CP/M prompt type "save 17 xmodem.com".  Voila, we have xmodem.com installed in the new CF disk!
Step 4 is using XMODEM to transfer files, but XMODEM does not have batch file transferring capability so each file need to be done individually.  This is where arj.exe and unarj.com come to rescue for Windows users; arj.exe compresses multiple files into one file, XMODEM it across, then unajr.com decompresses back to multiple files.

This all may sound complicated, but with a TeraTerm script file the whole process of format CF disk, putsys CP/M, install XMODEM, and transfer CP/M distribution files can be done in about a minute.  Watch this video of CP/M file creation on a new CF disk.

Step 1 (format CF disk) at 00:07 mark
Step 2 (putsys CPM) at 00:16 mark
Step 3 (XMODEM.COM created) at 00:23 mark
Step 4a (xmodem transfer of unarj.com and cpm22.arj completed) at 00:42
Step 4b (extraction of CPM 2.2 distribution files completed) at 01:05

The video is playing back at normal speed but Z80 clock was 20MHz.  It takes 1 minute and 40 seconds to run the same script with 7.37MHz clock.
  Bill
install_CPM_on_new_CF.mp4
DSC_71151202.jpg

Bill Shen

unread,
Dec 4, 2022, 7:46:46 AM12/4/22
to RC2014-Z80
Next setup is KIORC with SC114 and CF board.  SC114 is a simple Z80 single-board computer with 3 RC2014 expansion slots.  SC114 native console I/O is an economical bit-bang transmitter and receiver implemented mostly in software.  Better and faster I/O boards can be added via the RC2014 expansion slot and this is where KIORC comes in.  With the addition of a compact flash board, SC114+KIORC+CF becomes a fully functional CP/M computer.  Interestingly SC114+KIORC+CF is software compatible with SC108+KIORC+CF.  The software mentioned in previous SC108 post such as Grant Searle's patched monitor, BASIC, and patched SCMonitor all run in SC114 as they were.  The TeraTerm script file for installation of CP/M ran exactly the same on SC114 as it did on SC108.  SC114 even overclocked like SC108; it topped out at 20MHz, same as SC108.  So setting up hardware on SC114 is simple; just plug in KIORC and Karlab's 10e CF board then run the SC108 software suite.  Take a picture and I'm done.

The highlight of researching about SC114, however, is going through Steve Cousin's excellent SC114 pages detailing the various configurations and associated software.  While Grant Searle's original software package, patched for KIORC, will work, it is worth the time reading over the SC114 documentation to gain much better understanding on the process of bringing up CP/M on various hardware platforms.

I was disappointed that SC114 couldn't overclock past 20MHz.  It should be capable of 29.5MHz supporting 38.4K bps bit-bang serial port.  There are 3 spare flip flops in existing design I believe can be bodged to support higher clock but that's another topic for another day.

  Bill

DSC_71161203.jpg

Bill Shen

unread,
Dec 6, 2022, 12:02:39 PM12/6/22
to RC2014-Z80
I was asked about a KIO board design without using CPLD since CPLD is hard to find nowadays.  KIO on RC2014 bus is quite simple; it is mostly direct connections of data, addresses, control from RC2014 bus to KIO with a 74LS138 decoding the base I/O address, so it is a 2-chip solution.  In fact I prototyped one just to make sure everything worked as I've expected.  The schematic is attached.  There are relatively few required connections for it to work with RC2014 but I would not recommend prototyping this design for the beginners because 84-pin PLCC can be tricky to wire up correctly.

I bought my KIO several years ago from UTSource but I see there are KIO on eBay for reasonable price such as this.  I don't know the seller, but have placed an order for 10.  If they work, this can be an economical source for Killer I/O for RC2014.
  Bill
DSC_71211205.jpg
DSC_71221205.jpg
protoKIORC_SCM.pdf

Bill Shen

unread,
Dec 20, 2022, 11:57:40 PM12/20/22
to RC2014-Z80
Received 10 KIO from the ebay seller in 2 weeks.  I'm not happy with how the parts are packaged.  They are wrapped with plastic wrap and sandwiched between 2 white foam.  These are NOT anti-static shipping materials.  The parts are from different date codes and appeared to be used parts, which is what I expected.  Different date code is actually good because these are likely original parts.

I tested all 10 on my K80 hardware which ran RomWBW overclocked to 22MHz.  Console is channel A of KIO and I monitor the current consumption and XMODEM a 40K file with hardware handshake.  All 10 parts passed with similar current consumption.  These are rated 12.5MHz but ran OK at 22 MHz, so I believe they are functioning used parts but not correctly handled.  Functioning used parts of unknown handling history is all we can expect from secondary markets like eBay or AliExpress.  Caveat Emptor.
  Bill
DSC_71561220.jpg
DSC_71541220.jpg

Greg Holdren

unread,
Dec 21, 2022, 1:13:37 AM12/21/22
to RC2014-Z80
Bill,

Thanks for reporting back on this. I thought about ordering a batch of these after you mentioned it. The parts looks a little beat cosmetically but good to hear they function ok. I will see if the seller will use proper ESD protection.

Greg

Mark T

unread,
Dec 21, 2022, 10:39:25 AM12/21/22
to RC2014-Z80
If you have to prompt them to use ESD protected packaging then its already too late.

Utsource also use white foam, not sure if its ESD safe or not but I couldn’t seem to create a static charge on it by rubbing on my hair. Other than the white foam their packaging seems OK.

Greg Holdren

unread,
Dec 21, 2022, 12:56:20 PM12/21/22
to RC2014-Z80
Maybe.... Maybe not. It's like driving around without seat belts. :) When will it happen? Yeah... don't think ESD is a priority or not understood at all.

Richard Deane

unread,
Dec 21, 2022, 2:40:44 PM12/21/22
to rc201...@googlegroups.com
So far, all my aliexpress orders of 74', cpu or cpld/fpga which often ship in clingfilm have been  ok

--
You received this message because you are subscribed to the Google Groups "RC2014-Z80" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rc2014-z80+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rc2014-z80/6da02c67-7554-4551-a59f-df85bf7444a8n%40googlegroups.com.

Nicolae Muntean

unread,
Apr 11, 2024, 4:42:41 AM4/11/24
to RC2014-Z80
HELLO, 

Thank you admin for accepting . I have terminal several scxx plates and I want to thank everyone for the work.
I compiled ROMWBW for AY Ed.brindley v 6.1 in MSX format. Everything works perfectly THANK YOU AGAIN
kiorc_sc xxx.jpg
kiorc.jpg
Reply all
Reply to author
Forward
0 new messages