User Port Speed Measuring|The Amstrad User)Hardware Montages
 ★ Ce texte vous est présenté dans sa version originale ★ 
 ★ This text is presented to you in its original version ★ 
 ★ Este texto se le presenta en su versión original ★ 
 ★ Dieser Text wird in seiner ursprünglichen Fassung Ihnen präsentiert ★ 

Are you sick of the kids arguing over how many laps their slot cars have done or would you like to record how long the Fridge door is open on a hot day?

So you would like to put your Amstrad computer to work either counting or measuring time, but you have read an article on interfacing and have been put off by things like, address decoding, buffers, AND gates, NAND gates etc.

If you look carefully on the back of the computer the port you plug the joystick into is labelled USER PORT. Provided what ever you want to measure can operate a mechanical switch, you can connect it to this port. The easiest way to set this up is to use a damaged joystick. The wire that goes to all the switches is the common (pin 8). If you an; going to use more than 5 switches you will have to install diodes as used in the Amstrad joysticks. Where a wire from pins 1 to 7 is split to go to 2 switches 2 diodes have to be installed (see diagram) with the colour band on the diode pointing towards the common wire, the other side of the 2nd switch is connected to common 2 (pin 9).

WARNING Any switches and wires connected to the User Port MUST be insulated from any other electrical current no matter how small! Also, unplug the cord from the computer before soldering etc. on the wires and switches.

Some types of switches that could be used are:


Reed switches are two strips of metal, usually encased in a glass tube, that when a strong magnetic field acts on them either touch (normally open) or separate (normally closed). For example a reed switch could be installed in a slot car track, and a magnet installed in the car (if the motor magnet is not strong enough). The problem with reed switches is that they open and close several times as the magnet passes over them, and for counting it may be necessary to cause a delay of several seconds before reading that switch again.


Micros switches have a switch in a plastic body with a metal lever on one side that operates the switch, and usually only need a small movement to throw the switch.


Relays use a electric current in a coil to open or close a set of contacts. If what you want to measure is clectrical in basis you can connect that to the coil of a suitable relay and connect the User Port to the relay's contacts. But make sure that the coil is insulated from the contacts because in some automobile relays the coil earths through the contacts.


These are a small glass bulb with two wires entering the bulb, which contains several drops of Mercury. When the bulb is tilted so that the mercury touches both wires the switch is conducting. Following is a small program that has been used with reed switches on a H.O. Model Railway to check the scale speed of the trains. It uses the @ key to enter the timing mode, the Up pin of the Joy stick to start timing and the down pin to stop/display speed.

When the program asks for scale, enter the large number (e.g. If the scale is 1:32, enter 32). If you want to time something in normal Km/Hr. enter 1. When a REM is removed in line 560 it will display Miles/Hour.


★ YEAR: 1986
★ AUTHOR: Lindsay Allen

CPCrulez[Content Management System] v8.75-desktop/c
Page créée en 035 millisecondes et consultée 635 fois

L'Amstrad CPC est une machine 8 bits à base d'un Z80 à 4MHz. Le premier de la gamme fut le CPC 464 en 1984, équipé d'un lecteur de cassettes intégré il se plaçait en concurrent  du Commodore C64 beaucoup plus compliqué à utiliser et plus cher. Ce fut un réel succès et sorti cette même années le CPC 664 équipé d'un lecteur de disquettes trois pouces intégré. Sa vie fut de courte durée puisqu'en 1985 il fut remplacé par le CPC 6128 qui était plus compact, plus soigné et surtout qui avait 128Ko de RAM au lieu de 64Ko.