KC Compact Computer
Contents
Background
The KC compact is a clone of the Amstrad CPC and was developed by a East German company called RFT.
The computer was designed in 1989 and made to celebrate 40 years of the DDR/GDR (Deutsches Democratic Republik/German Democratic Republic). A year later the Berlin wall came down and East and West Germany were joined together and the DDR/GDR came to an end. Production of the computer halted, and it was only available for a short time and is rare.
I read about the KC compact in the Amscene section of Amstrad Action magazine, a Future Publishing Ltd publication. From that point I was hooked and I eventually wanted to own one.
During this time I found Andreas Krueger, webmaster of the Robotron-Net website, who owned one of these computers. Andreas was very helpful and provided photocopies of a manual and the schematics, a dump of the roms, ran some tests for me and more. I want to send him a big thankyou for all the help he gave.
In the last few months (May 2001) I contacted Thomas Tratz who owns a KC Compact. Thomas Tratz runs a great website for QuickBASIC. He has given me many of the original manuals, original software, and I bought a real KC Compact from his cousin! A big thankyou to Thomas and his cousin!
The case of the KC compact is the same as the Robotron BIC A5105, but has different hardware inside. The KC Compact I have does not have a information sticker on the underside, but information for the A5105!
Many of the IC's inside are Russian and clones of other IC's. (The U880 is a clone of the Zilog Z80, and the U82536 is a clone of the Zilog Z8536).
I know of only a few people who have a real KC Compact (Andreas Kruger, Thomas Tratz, Frank Salmon of Oldbits computer collection and myself), if there are others please contact me and I will make a list of KC Compact owners, and you will be members of an exclusive club! :)
This document will describe the hardware and software differences (that are known) between this system and the Amstrad CPC.
Alternative power supply
With the help of Darren Jarvis I now have a new power supply for my KC Compact. He gave me a power pack from a PC laptop, and with a special lead, this works perfectly on the KC Compact.
PC laptop power pack details:
LISHIN INTERNATIONAL ENTERPRISE CORP. AC ADAPTOR.
MODEL: LSE9802A1960
INPUT: 100-240V A.C. 50/60Hz 1.5A
OUTPUT: 19V D.C. 3.16A. 60W MAX
The power pack has a 3.5mm power plug at the end.
I made a lead which has a 3.5mm power socket and a telefunktion socket.
External power supply
The official external power modulator provides +20V,-20V DC with 500mA (believed to be un-smoothed), from a source of ~220V at 50Hz.
The extenal power modulator is connected to the computer's internal power modulator, which generates a smoothed 12V and 5V outputs and these provide the power for the IC's.
The internal power supply is very tolerant and the computer will run with input voltages as low as 6V, but the colours in the palette are weak. If the voltage is increased, the colours become strong, and around 18V-20V, they are all correct. If a low input voltage is used, it is likely that the 12V power output on the expansion connector will not be correct.
The connector is believed to be a Telefunken Line socket (Maplins catalogue reference: FT99H). If you can't find this connector then you can make a suitable connector using a power lead and a sharp craft knife.
Software differences
The base system has 32k of
- Locomotive BASIC v1.1 rom (identical to BASIC rom in English CPC6128) (16k)
- A modified operating system rom from an English CPC6128 (16k)
- Differences are:
- Different start-up message - Computer names (Schneider, Awa, Solavox etc) removed. - Initialisation code for the Z8536 CIO (see details below) - Test program transfer (see details below)
I believe most software will run, but I have not been able to test this, but programs that use the following may be broken:
- Programs that rely on exact Interrupt mechanism of the CPC6128
- Programs that call direct into the operating system rom (these may work, because the changes to the operating system rom are minor)
- Programs that rely on a unofficial hardware feature (I do not know of all hardware details, so I cannot say the level of compatibility)
Hardware differences
- The colour palette is not cleared to black on reset
- The Amstrad unofficial mode (bit 1=bit 0=1 of Gate Array mode register) does not exist, black is output.
This section describes the known hardware differences. This information is not definitive. I do not know all differences,
The KC compact uses a U880 CPU which is a Russian clone of the Z80. Are there any differences compared to a real Z80?
Video
I think the KC compact has a HD6845S CRTC. This is a type 0 and is the most compatible for demos.
The Z8536 *could* be used to re-program the resolution. (see Z8536 description below)
Colour-ROM
The KC compact has a colour-rom. Each byte in the ROM defines the R,G and B of an output colour.
Bit Function 7 not used 6 not used 5 Green 4 3 Red 2 1 Blue 0
The hardware colour index (defined by the I/O write: A15="0", A14="1", D7="0", D6="1" D3-D0 define hardware colour index), is used as a look-up into the ROM.
Each colour-element (R, G or B) is defined using 2 bits and has the potential to define a total palette of 64 colours. The colour-rom only uses 3 of the 4 possible settings for each colour-element, and it is unknown if two of the settings give the same result intensity.
Element Bit 1 Element Bit 0 Intensity 0 0 Zero 0 1 Half? (this setting is equivalent to CPC half intensity) 1 0 Half? 1 1 Full
The colour ROM can be downloaded from the KC-Klub homepage.
External connectors
Cassette socket
The Cassette socket has different connection assignments compared to the CPC, so you can't use a CPC cassette lead directly with the KC Compact.
I made a second lead which converted between KC Compact assignments and CPC assignments, which was connected between KC Compact and the CPC cassette lead.
I have been successfully loaded some CPC software.
Expansion socket
The KC compact has a real connector compared to the P.C.B. edge connector of an English CPC6128. The connector appears to be a PC Card connector. This connector is not the same as the one on a German CPC6128.
The expansion connector has more pins; 58 compared to 50 on an English CPC6128.
I am in the process of making an adaptor so that I can test CPC hardware on the KC Compact.
Parallel
On the KC compact the parallel port is connected to Port A of the Z8536 CIO.
It is a general purpose I/O port. All 8-bits can be used for input or output. The input/output of each bit can be programmed. With standard setup, bit 7 is assigned to /STROBE, and bits 0-6 are assigned to Printer DATA, making a 7-bit printer port.
The Amstrad CPC has a single-direction, 7-bit port.
The KC compact parallel port is more powerful and flexible compared to the Amstrad CPC parallel port!
Keyboard
The keyboard matrix of the KC compact supports all the keys of the CPC, but the following keys are not on the keyboard: F5, F6,F7,F8,F9 8255 PIO Port B Input 7 Cassette data read (identical to CPC) 6 Centronics/Printer Busy (identical to CPC) 5 /EXP (identical to CPC) 4 1 (+5v) 3 1 (+5v) 2 0 (0v) 1 /TEST 0 VSYNC (identical to CPC) Z8536 CIO
The Z8536 CIO chip is a counter and I/O chip. In the KC compact system it is used to generate interrupts, access to the parallel printer port, and possibly video control.
When b12 of the I/O address is "0", the Z8536 is selected.
Bit b9 and b8 of the I/O address select the registers of the Z8536: b9 b8 Register 0 0 Port B data register 0 1 Port C data register 1 0 control registers 1 1 Port A data register
(note: b8 is passed through an inverter and this describes the order of the registers in the table compared to the order of the registers in the z8536 datasheet)
To avoid conflict with other peripherals the Z8536 should be access using: Port address Register &ECxx Port B data register &EDxx Port C data register &EExx control registers &EFxx Port A data register
In the KC Compact:
* Port A is setup as I/O and is connected to the parallel printer port * Port B is setup as timer and is connected to the video hardware (?) * Port C is setup as timer and is connected to the Interrupt hardware
On start-up, the KC compact programs the z8536 to the following state:
* Port A: I/O mode: all bits are set to output, and bit 7 is inverted when writing. (bit 7 is /strobe signal to printer) * Port B: Counter mode (port B is split into two counters, both are setup the same): continuous count, restarts when count is over, uses external trigger, uses external input to update count, pulse output (when count is over) * Port C: Counter mode: same configuration as port B.
Port C is used to generate interrupts. The counter input is HSYNC (the counter counts counter-input transitions; low-high and high-low). The trigger input is VSYV (this signal is derived from VSYNC).
What this means:
* The Z8536 Port C counter is updated when HSYNC changes state * The Z8536 Port C counter is reset when VSYV changes state
With the default settings, the Z8536 will count 26 HSYNC transitions (52 lines of the display covered in this time) and generate a interrupt. At VSYNC the counter is reset so that the interrupts are synchronised.
I do not know the exact function of the counter's of Port B. I have looked at the schematics, and it appears to control the video hardware. Maybe the KC compact has a programmable pixel clock, if it does, then the base resolution can be changed.
CPC Interrupts:
* synchronised to 2 HSYNCs after VSYNC * interrupts cannot be generated closer than 32 lines * counter inside Gate Array counts up to 52 lines. * interrupt can be cleared by writing to bit 4 of Mode/ROM register in Gate Array (counter is also reset at this time)
KC compact interrupts:
* interrupt can be cleared by writing to bit 4 of Mode/ROM register at 0x07fxx (counter is *not* reset at this time) * interrupt system fully programmable: can count HSYNCS, or count internal Z8536 clocks!
Therefore, the KC compact interrupt system is more powerful than the CPC! TEST feature When the KC compact is reset, the /TEST signal on the expansion port is checked.
If it is high (1), the operating system will startup and BASIC will be entered. If it is low (0), the KC compact will enter a data transfer sequence using DATA2, DATA1, /STROBE and DATA7 on the expansion connector.
Data transfer:
The data transfer is controlled by another computer, the KC compact is the "slave".
Using DATA2, DATA1, /STROBE and DATA7, a program of 256 bytes in size can be transfered into KC compact memory at &a880. When all bytes have been transfered, this program will be executed.
KCC Side: Synchronisation stage (Data transfer begin) /STROBE must read as "1"!! wait for DATA1 to change from "1"to "0". Synchronisation Acknowledge stage write 0x0f: DATA2="1",DATA7="0". Data transfer stage (repeat for 256 bytes) Data byte transfer repeat 8 times (once for each data bit)
* write 0x0ff: DATA2="1",DATA7="1", and wait for /STROBE to read as "1" * read inputs: DATA1=data bit
Data byte acknowledge stage write: 0x0f0: DATA2="0", DATA7="1", and wait for /STROBE to read as "1"
* /STROBE and DATA1 are inputs * DATA2 and DATA7 are outputs
Connecting a KC compact to a CPC+ monitor
These connections are known to work!
What you need:
* SCART plug * 8-pin DIN socket
Lead connections:
* Connect the 8-pin DIN socket to the 8-pin DIN plug from the monitor * Connect the SCART plug to the SCART socket on the back of the KC Compact
Signal connections: pin number on SCART plug pin number on CPC+ monitor socket 19 (Composite Video Output) 1 (Composite Sync) 17 (Video Ground) 8 (GND) 15 (Analogue Red) 4 (Red) 11 (Analogue Green) 2 (Green) 7 (Analogue Blue) 5 (Blue)