# My Amstrad CPC 464, first tests and some pictures. PSU and a simple monochrome video cable.

I have recently bought this nice Amstrad CPC 464 computer. So, I was able to update my article on 8 bit BASIC interpreters benchmarks.

It has the powerful Locomotive BASIC 1.0 built-in.

I didn’t know if the computer was working or not. Furthermore, this is the first Amstrad computer I own, and it came with no accessories. So, I had to search for some information dealing with both power supply requirements and video connector pinout.

On this model, only +5V DC @ 2 AMP are required. I had a spare +5V power supply apart, so it was downhill. The only problem was to find the correct polarity.

I decided to open the computer, so that I could determine where the ground was on the PSU connector. Of course, I was also curious to have a look at the internals. After all, this is my very first Amstrad.

Opening the unit is quite straight. There are a few screws on the bottom of the case. No joints are present, so no concerns about breaking them.

So, I turned upside down the computer, I took away the screws, then I put the unit back to its original position.

When lifting up the top part of the case (featuring the keyboard and the cassette unit), extreme care must be taken, as the keyboard and the cassette unit are connected to the board, which is secured to the bottom part of the case. The connectors of the keyboard can be easily pulled off. The connector of the cassette unit is a bit tough, but it will come off easily as well. No great concerns about connectors orientation: the cassette unit connector is keyed. Still, attention must be taken.

The board shows a clean design, with few ICs. Let’s have a look at the main ICs. On the top, left hand corner we have the AY-3-8912, the sound generator.

Then, keeping going to the right, we have the 8255 PPI: it’s a generic I/O chip (the same used on MSX machines). Then, we have the Zilog Z80 CPU @ 4.0 MHz.

Starting again from the left, but looking at the next row to the bottom, we have the ROM chip, containing the BASIC interpreter and OS, and the CRTC 6845 video chip.

On the top right hand corner, you can see a big heat sink. It is installed over the ULA chip (this is the first version, which should be called 40007). This machine, featuring an ULA with a big heat sink and BASIC 1.0, should be an early model.

On the picture, below the ULA you can see eight chips. These are the 4264 RAMs. Like on early Commodore 64 boards, there is one RAM chip for each RAM bit.

Remaining chips seem to be standard glue logic chips.

Video and power connectors can be found on the rear of the computer. On the board, they are not far from the ULA chip:

The video connector is a 6 pins DIN type (the same as the Commodore serial port connector). The power connector is a standard round male connector.

The video connector offers RGB video signal. A luminance signal is also provided. I once built a very simple monochrome cable for the Commodore 128 VDC output. I used the luminance signal to obtain a monochrome picture. I tried the same approach with the Amstrad CPC 464. The result is the following cable. Please note that picture may be not perfectly stable, but I think it is good enough for simple experiments. I was just in a hurry so I decided to build the simplest cable that I could.

However, it is possible to use an Amstrad CPC 464 with a TV color. But, the cable required is much more complex than the one I have built.

This cable just sends the monochrome video signal to the composite input of your TV set.

This cable is working fine with my TV set, still it comes without any warranty of any kind. Build and use it at your own risk.

As you can see, luminance is connected to the tip of the composite male connector, while the ground is connected to the sleeve (the outer “ring”) of that connector.

Please note that a 6 pin DIN male connector is required. This is the same as those used on Commodore serial cables (used to connect disk drives, printers, etc.).

An RCA male connector is also needed. This plugs to the composite input of your TV set.

Audio on the CPC is provided by a speaker near the cassette recorder. Furthermore, there is also a connector providing audio output.

Talking about the power supply, you need a simple +5V 2 A PSU. I used a 2,5 A PSU to be on the safe side. Most PSU come with different connectors, you will find the right connector for the CPC with ease. By any means make sure you get a strong connection. Loose electrical connection is definetely to avoid.

Pay attention to the polarity! On the CPC male connector, the outer ring is the GND, while the tip is +5V. So, on the PSU female connector, the outer ring must be the GND, and the inner ring must be +5V.

Check the polarity with a multimeter before using the PSU!

Since the GND is on pin 5 of the video connector, I could locate the GND on the power connector easily. I got 0 resistance between pin 5 of video connector and the outer ring of power connector.

After making the video cable and adapting the PSU, I wanted to turn on the main board to see if it was functional. I had the top part of the computer (containing the keyboard and the cassette recorder) unplugged.

The main board ICs were getting no power. That seemed strange to me, as the power supply connector was on the board. But I suddenly realized that the ON/OFF switch was on the top part of the computer that I removed. At first, I thought it was used for the cassette recorder and keyboard only.

After I had connected the top part of the computer to the main board, I was eventually able to see the boot screen. I was very happy to see that this nice Amstrad was perfectly working!

Still, I had some problems with the keyboard. Some keys had a tendency to get stuck. Gently lifting them up with a little screwdriver and/or a key extractor, pressing them down and then lifting them up again a few times allowed me to fix these little issues. DO NOT use the extractor to take out keys from such a keyboard! There are some plastic joints on the keys which must be carefully loosened from the inside of the keyboard.

Extreme care must be taken to use such a tool, so that no scratch to the keys is done. Now, the keyboard works fine. There was no need to take it apart.

At this point, I took the chance of making some BASIC experiments with this machine. First of all, I tried some BASIC bechmarks on it so that I could update this article.

As you can see from the results of the bechmarks, Locomotive BASIC is very fast. Still, by using the editor and listing programs, I noticed that characters are printed to the screen in a not too fast way.

I also wondered how this BASIC would behave with garbage collection critical programs. I typed in this short program, known to cause problems with the Commodore 64 BASIC and others, if not modified properly:

 5 rem not working program
10 dim a$(4600) 20 for t = 1 to 4600 30 a$(t) = "#" + str\$(t)
40 print t : next

This program causes slow garbage collection on Locomotive BASIC 1.0 as well. I didn’t bother into measuring the time required to complete the program, but it produces very long pauses like on CBM BASIC 2.0.

Still, I think the program can be adapted and fixed in a way similar to what I did on the Commodore 64.

Using WinAPE CPC emulator, I tried this program with Locomotive BASIC 1.1. It offers a really fast garbage collection routine, but the program is not completed successfully anyway. At a certain point, a “String space full” error” is issued.

Still, the program runs pretty fast up to that point, so I think garbage collection is of no concern with Locomotive BASIC 1.1. And please note that this program is actually a “nasty” program, a piece of code created just to show garbage collection and string handling possible issues on BASIC interpreters.

As an additional note, this program also seems to show problems on MSX 1 BASIC as well (causing an ?OUT OF STRING SPACE error). The same thing happens with Simiv BASIC on an Olivetti Prodest PC 128. Instead, the Commodore BASIC 4.0 machines, the Commodore TED computers and the Commodore 128 can run this program completely with no issues.

The Sinclair Spectrum can run this program with no problems as well, simply because it makes use of static strings. On Commodore machines with BASIC 3.5, 4.0 and 7,0 this program runs OK too because Commodore fixed the slow garbage collection issue by using back pointers on strings. This way, the garbage collection is really fast. So, you have the advantage of using dynamic strings combined with no meaningful delays during programs execution. Back pointers do take additional memory, but this is definetely not a problem on 8 bit machines providing 60K and 121K free BASIC RAM memory (like the Commodore Plus 4 and the Commodore 128).

On Locomotive BASIC 1.0, strings can be no longer than 255 characters, like on Commodore BASIC.

On the CPC 464, the video chip CRTC 8245, combined with the ULA, can provide three graphical modes, with 20 columns, 40 columns and 80 columns text. Bitmap graphics is also supported on all of these modes, and can be easily accessed by using custom BASIC commands. Official maximum resolution is 640 x 200 dots (in 80 columns mode). A palette of 27 colors is available.

The ability to show 4 different colours on adjacent pixels even with a resolution of 320 x 200 dots is a great feature, compared to what other 8 bit systems could do. However, those 4 colours are common for the whole screen. Still, more colors can be shown by using rastersplits. With the lower resolution (160 x 200) 16 colors are available.

The Amstrad CPC is a really nice 8 bit machine. I hope I will have enough time in the future to build a color video cable and to try some programs and games on it.