HARDWAREMONTAGES ★ TEMPERATURE-ANALOGUE INTERFACE ★

Amstrad Synthesiser Interface (Practical Electronics)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 presenta en su versión original ★ 
 ★ Dieser Text wird in seiner Originalfassung präsentiert ★ 

THE Amstrad CPC464 computer is a highly versatile machine which is well suited to many applications, including those associated with user add-ons. The interface which is described in this article, together with the correct software, enables the CPC464 to be utilized as a sequencer for a synthesiser which has the standard five volt gate/ trigger pulse input and one volt per octave control voltage input. The note is programmable over more than five octaves (including all semitones), and the gate time, plus note duration are also programmable.

With its genuine 64K of RAM a large number of notes can be accommodated. In fact the program enables up to one thousand notes to be entered, and with a slight modification it could probably be made to take sequences several times longer than this. The program includes editing facilities, plus the ability to save sequences on tape and reload them when required.

SYSTEM OPERATION

Driving the gate or trigger input of most synthesisers is perfectly straightforward since all thatjs needed is a signal at standard TTL levels. A single bit digital output is therefore all that is required to drive this input. Driving the control voltage input is also fairly straightforward for a synthesiser which has standard one volt per octave (logarithmic) input.

With this type of Synthesiser the control voltage from the keyboard is provided by a potential divider which has a series of equal value resistors. It thus provides a series of output voltages with an equal step size from one note to the next. It is quite easy to simulate this with a computer, and all that is required is a normal (linear) digital to analogue converter. With this type of converter, if writing '1' to the circuit gave an output voltage of (say) 10 millivolts, then '2' would give 20 millivolts, 3' would give 30 millivolts, and so on. The keyboard of a synthesiser gives increments of about 83 millivolts, and it is just a matter of scaling the output of the digital to analogue converter to precisely match this.

Note that some older synthesisers have a linear control voltage characteristic which, paradoxically, has a non-equal increment from one note to the next, but $ linear relationship between the control voltage and the output frequency. Instruments of this type cannot be used with the interface featured in this article, and can not easily be interfaced to a computer.

The block diagram of Fig. 1 shows the general arrangement used in this interface. An address decoder is used to activate a single bit data latch when data is written to a suitable address, and this latch provides the gate or trigger pulse signal. This output can be placed high or low, as desired, under program control. The address decoder also activates a six bit data latch which is used to drive the digital to analogue converter. The converter is in fact an ordinary eight bit type, but in this application only six bits are normally used as this is sufficient to give a range of 63 notes, which is about the limit for most synthesisers. The two least significant inputs of the converter are simply tied to the negative supply rail.


Fig. 1. Block diagram of the Amstrad Sequencer

The converter has an output that increments in units of nominalfy 10 millivolts, but as the two least significant bits are not used here this is boosted to 40 millivolts. This is not sufficient to drive the control voltage input of a synthesiser, and an amplifier is used to boost the output voltage by a factor of about two times.

A gain control enables the output voltage increment to be trimmed to exactly the correct figure. An offset null control enables any d.c. offsets in the system to be trimmed out so that good pitch accuracy is obtained at the low frequency end of the range.

The circuit is powered from the five volts output of the CPC464, and this is the only supply output which the machine provides. This is inadequate to drive the amplifier stage which must provide a maximum output voltage of just over five volts. This problem fs overcome by rectifying and smoothing the output of an oscillator to produce a supply potential of about ten volts for the amplifier stage.

CIRCUIT OPERATION

The full circuit diagram of the interface appears in Fig. 2. The unit connects to the floppy disc port of the computer which is really a general purpose port which makes available the full address, data, and control buses of the computer, as well as a number of other useful lines.

Address decoding is provided by IC2 which is a triple 3-input NOR gate, but in this circuit one of the gates is left unused, and the three inputs of one of the other gates are connected together so that this gate acts as a simple inverter. IC2a decodes the IORQ (input/output request), WR (write), and A10 lines, giving a high output when all three of these lines are low. IC2b inverts this signal to give a negative latching pulse to IC1 and IC3.

This method of address decoding may seem a little strange by conventional Z80 standards, with just one of the address lines being decoded with the relevant control bus lines, and one of the eight most significant address lines at that. However, the CPC464 does not have the conventional form of Z80 input/output mapping where the eight least significant lines of the address bus are decoded to give up to 256 addresses, and the eight most significant lines are left unused. Instead, input/output circuits are activated by taking the appropriate one of the eight most significant address lines low, while the eight least significant address lines are available for use if an input output device requires several addresses. This is similar although not identical to the system used in the Sinclair Spectrum computer.

Address line A10 is available for use with external addons, and it is therefore this line going low that is used to activate the sequencer interface. Of course, with only one address line being decoded there are numerous addresses that can be used to operate the interface, but in practice it is advisable to only use &F800 as with the only exception of A10 this leaves all the address lines high and will not produce spurious operations of internal circuits of the computer.

IC3 is a dual D-type flip-flop, but only one section is utilized here; it is used as a data latch with the latching pulse from the decoder circuit applied to the "clock pulse" input. The gate/trigger pulse is obtained from the Q output of the flip/flop. *

The digital to analogue converter, IC1, is a Ferranti ZN428E. This is a conventional type having an integral 2-55V precision voltage source, eight electronic switches, and an R-2R resistor network. The voltage reference requires discrete load resistor R1 and decoupling capacitor C1 The output from this stage is coupled to the input of an operational amplifier (IC4) which is used as a non-inverting amplifier. R3 and VR2 form the negative feedback network which set the closed loop voltage gain of the circuit, and VR2 is adjusted to give the correct level of voltage gain. VR1 is the offset null control for IC4.


Fig. 2. Complete circuit diagram of the Amstrad Sequencer

COMPONENTS...

Resistors
R1 390
R2,R4 1 k (2 off)
R3.R5 10k 52 off)
All fixed resistors are 0-25W 5% carbon

Potentiometers
VR1 10k 0-1W horizontal preset
VR2 22k 0-1W horizontal preset

Capacitors
C1 1µ 63V radial elect
C2 2µ2 63V radial elect
C3-C6, C9 100µ 10V radial elect (5 off)
C7 4n7 carbonate
C8 100n ceramic

Semiconductors
D1-D4 1N4148 (4 off)
IC1 ZN428E Constructor s Note
IC2 74LS27 A complete listing of the
IC3 74LS74 sequencer program is
IC4 CA3140E available for £1 inc. P&P
IC5 NE555 from our editorial offices.

Miscellaneous
SK1, SK2 standard jack sockets (2 off)
Printed circuit board PE 505-01
Case 133 x 102 x 38mm
2x25 wav 0-1 inch pitch edge connector
16 pin d.i.l. i.c. holder
14 pin d.i.l. i.c. holders (2 off)
8 pin d.i.l. i.c. holders (2 off)
Ribbon cable, wire, connecting leads, etc.

IC4 is a CA3140E, a device which has a Class A output stage that enables output voltages right down to the 0V rail to be produced. This obviates the need for a negative supply rail. IC5 is a 555 timer device which operates in the standard as table mode. This is the oscillator which is used to provide the boosted positive supply for IC4. Its output is rectified and smoothed by D3, D4, and C6, and also by D1, D2, and C3. The resultant positive outputs are effectively connected in series together with the 5V supply so as to give a voltage tripling action. However, in practice losses through the diodes and the output stage of IC5 result in a loaded supply potential of only about 10V or so, but this is still more than adequate to permit IC4 to provide a peak output voltage of about five to six volts.

CONSTRUCTION

A suitable printed circuit design for this project iS provided in Fig. 3. IC4 has a MOS input stage and an integrated circuit holder should be used for this component. As 1C 1 is not one of the cheapest of devices it is also advisable to use a socket for this component. Be careful to fit this device the right way round—it has the opposite orientation to the other integrated circuits. Fit Veropins at the points where the board will be connected to SK1 and SK2. Do not overlook the two link wires.

The board is connected to the floppy disc port of the computer by way of a piece of 13 way ribbon cable about 0-5 to 1 metre long and terminated in a 2 by 25 way 0-1 inch pitch female edge connector. A connector having a suitable polarising key is unlikely to be available, and care to fit the connector the right way round must be taken. It is advisable to clearly mark the top and bottom edges of the connector as such, or with a little ingenuity it might be possible to add a polarising key to the connector. Fig. 4 gives connection details for the edge connector.

An aluminium box having approximate outside dimensions of 133 by 102 by 38mm is used as the housing for the prototype, but any case of about this size should be satisfactory. SK1 and SK2 are standard jack sockets which match the connectors used on the vast majority of synthesisers, and they are mounted on the front panel.

The printed circuit board is mounted on any convenient area of the base panel of the case using 6BA or M3 fixings. If the case is a metal type it is obviously essential to use spacers to prevent the connections on the underside of the board from being short circuited through the case, and even if a non-metal case is used it is still advantageous to use spacers. This avoids any distortion of the board and possible damage when the mounting nuts are tightened.

Some means of taking the ribbon cable through the case must be found, and it may be possible to simply take it through the small gap between the top and base sections of the case. If this is not possible a suitable slit must be cut or filed in the rear panel of the case. To complete the unit the connections from the printed circuit board to SK1 and SK2 are added.


Fig. 3. P.c.b. design and component layout of the Amstrad Sequencer


Fig. 4. Connection details of the Amstrad Edge Connector

ADJUSTMENT AND USE

Start with VR1 and VR2 at a roughly central setting. Connect the unit to the computer prior to switching on. The computer should display the usual ready message etc.— switch off at once and recheck the wiring if it does not. As a quick check of the unit the command:—

OUT &F800,0

should set the gate/trigger output high and the control voltage output at virtually zero. The command:—

OUT &F800,127

should set the gate/trigger output low, and the control voltage output at something in the region of 5V.

In order to set VR1 and VR2 at the correct settings, first set the control voltage output to give the lowest note using the command:—

OUT &F800,1

When using the interface remember that a value of '1' gives the lowest note, and the a value of '0' is not used as a note value. Connect SK1 andSK2 to the appropriate inputs of the synthesiser using standard jack leads. With most synthesisers it is necessary to have one or more of the controls in the right position before the external inputs will function properly, and the manual should give details of the correct control settings if you are in any doubt about this point.

By adjusting VR1 it should be possible to vary the note from the synthesiser slightly. Adjust VR1 to obtain the same note that is produced by the lowest key of the keyboard. Using the command:—

OUT &F800,25

should give a note two octaves higher than the lowest note of the keyboard, and VR2 fs adjusted tp give precisely the correct note. It is advisable to repeat this procedure a few times until exactly the right note is obtained with both note values. The unit should then track perfectly at intermediate notes, and even if the keyboard only provides the usual two or two and a half octave range, most synthesisers are capable of producing the full five octave range using an external control voltage.

The suggested sequencer program enables note pitches, gate durations, and total note durations to be programmed, and it has other features such as automatic looping or playing a sequence just once. Gate and total note duration values are in 300ths of a second incidentally. As the program is menu driven and is largely self explanatory in use no further description is .really needed here. For those who wish to design their own software the basic sequence is for the note value to be written to address &F800 using an OUT instruction, and this automatically sets the gate/trigger output high.

To terminate the gate/trigger pcilse a value of 64 plus the note value is written to address &F800 using an OUT in-struction. The next note value is then written to &F800 after the appropriate time has elapsed. BASIC is normally fast enough for an application of this type, especially one of the faster versions such as the Locomotive BASIC used in the CPC464. However, if machine code is used to control the interface remember that output instructions which u'se the B register to provide the upper eight bits of the address bus must be used, since the CPC464 uses sixteen bit and not eight bit input/output addresses.

PRACTICAL ELECTRONICS

★ AMSTRAD CPC ★ DOWNLOAD ★

File:
» Temperature-Analogue  Interface    (Practical  Electronics)    LISTINGDATE: 2022-02-25
DL: 213
TYPE: PDF
SiZE: 59Ko
NOTE: 2 pages/PDFlib v1.6

★ AMSTRAD CPC ★ A voir aussi sur CPCrulez , les sujets suivants pourront vous intéresser...

Lien(s):
» Hardware » Informatique pratique - Pilotons un servomoteur (Science&Vie)
» Hardware » AC32L: Interface 32 sorties pour CPC (Radio Plans n°497)
» Hardware » Interface Mémoire : RS XMX Card
» Hardware » Montage Drive - CPC 6128 Plus - Changer 3 Pouces Interne Par un 3 Pouces 5
» Hardware » Montage Drive - Lecteur 5 Pouces 1 4 Pour CPC (Micro-Mag)
» Hardware » Integration HxC avec Adaptateur Dualshock - CPC
Je participe au site:
» Vous avez des infos personnel, des fichiers que nous ne possédons pas concernent ce programme ?
» Vous avez remarqué une erreur dans ce texte ?
» Aidez-nous à améliorer cette page : en nous contactant via le forum ou par email.

CPCrulez[Content Management System] v8.7-desktop/c
Page créée en 293 millisecondes et consultée 960 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.