Pr . up-to-date electronics for lab and leisure 63164 july | august 1980 ISSN 0308-308 X U.K. competition details inside ! 1 contents elektor july /august 1980 UK 3 1 2 ,3 4 5 6 7 8 9 10 11 12 13 14 15 ’16 17 18 19 20 21 22 23 24 25 26 ? 7 v 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 infrared transmitter 56 trigger with presettable thresholds infrared receiver 57 sample and hold for synthesisers frequency conversion using the 58 pebble game XR 2240 59 simple L/C meter 2 amp voltage regulator data section - pages 7-45 . . . 7-56 sensibell 60 an odd divider stereo dynamic preamplifier 61 sound effects generator 4.4 MHz crystal filter 62 energy monitor converter ^3 private telephone exchange simple opamp tester ^64 1C tremolo automatic cycle lighting 65 electronic magnifying glass voltage controlled duty-cycle 66 acoustic ohmmeter exposure meter and development 67 armless bandit timer 68 the STAMP — Super Tiny AMPlifier. cassette interface adaption 69 missile attack V-FET amplifier 70 voltage controlled harmonic AFC via the tuning diode generator alternative amplifier for the n aerial 71 knock switch wind-o-meter 72 selective CW filter cheap light meter 73 RAM tester garden path lighting 74 low-pass filter legato gate interface for Formant 75 cheap seconds hybrid cascode 76 hexadecimal keyboard car stabiliser 77 small pP switching supply digital sinewave generator 78 variable pulse width generator synchronous FSK 79 post indicator PWM battery charger 80 simple symmetrical supply test transmitter for receiver 81 RMS to DC converter alignment 82 running lights water detector 83 voltage drop detector intelligent nicad charger 84 RS 232-interface more scope for the elekterminal 85 loudspeaker fuse loudspeaker fuse 86 stabilised 10 . . . 350 volt power current saving home trainer supply plus or minus unity gain 87 super-regenerative receiver wet alert 87-180 MHz sawtooth synchronous to mains 88 crystal controlled sinewave enigma generator phase meter 89 hexadecimal display decoder universal warning alarm 90 universal display EXOR edge detector 91 a better piano skin resistance biofeedback 92 variable power supply 0-50 V/0-2 A RS232 line indicator 93 FSK PLL demodulator simple analogue voltmeter 94 audio frequency meter simple 555 tester 95 deglitching remote control state variable filter 96 two more piano octaves semiconductor barometer 97 PROM programmer electronic fuse 98 shop window lighting — 12 V from +5 V 99 how does this strike you? temperature transmitter 100 continuity checker remote control dimmer 101 digital heart beat monitor nicad charger 102 moving-coil preamp high-frequency optocoupler 103 cheap source of energy security rear light 104 automatic range switch improved anti-theft device 105 solid state tachometer variable HF oscillator 106 book page reminder precision VCO market - page UK 16 ulp amp eontents ©amnteifl cBamnh CKM d EDITOR: W. van der Horst UK EDITORIAL STAFF T. Day P. Williams TECHNICAL EDITORIAL STAFF J. Barendrecht G.H.K. Dam P. Holmes E. Krem pel sauer G. Nachbar A. Nachtmann K. S.M. Walraven Technical Queries Please note that, because of editorial staff holidays, the Monday afternoon technical queries service will be suspended from July 14th until August 25th. Written queries will be dealt with in this period. We apologise for any inconvenience this may cause. elektor july/august 1980 7-01 about printed circuit boards "Way back in the early sixties, enthusiastic hobbyists everywhere discovered several easy ways to make neat 'home-brew' printed circuit boards. One popular method was to use 'instant lettering' or 'dry transfer' sheets — manufacturers like Letraset, Alfac and Letterpress supplied sheets with all sorts of useful symbols, lines and discs. To make a p.c. board, you rubbed the desired track pattern down onto copper-laminate board and then tipped the whole lot into a ferric chloride etching bath and let it stew for 1 5 or 20 minutes. After that, all that remained was to drill the holes and repair any hair-line cracks in the copper tracks. Coming back to the present, and confining ourselves to circuits published in Elektor, we find three basic categories: for some circuits a p.c. board is available through the EPS service; for others, a board design is published but not included in the EPS list; finally, there are circuits for which no p.c. board layout is given. We often receive queries and requests concerning one or more of these groups, and now's the time for some answers! To take the last category first: there are two main requests — Q: 'Can you publish more layouts?' A: Sorry, our p.c. board designers already have a full work-load. Q: 'Your boards are beautifully designed. Could you explain how you do it?' A: Yes, we intend to publish an article in the not-too-distant future. Concerning the other two categories, where we have got a design, there are several comments and requests: 'Your boards are beautifully made, to professional standards, but they are sometimes rather expensive. Could you reduce the quality and bring the price down?' 'Could you include a sheet of negatives in the magazine, so that I can make my own boards photo- graphically?' 'Could you supply all published p.c. boards through the EPS service?' Well. First, as to reducing the price: there are two or three main factors that influence this (size, single- or double-sided, plated-through holes, very narrow tracks or track spacing). These are determined by the type of project, more than anything else. Omitting both white and black screens, solder mask and even not drilling the holes will hardly influence the price — it saves pennies, not pounds. Even so, it is still under consideration. What alternatives are there? Including negatives in the magazine turns out to be quite expensive — it would mean increasing the cover price for everyone, whereas only a minority of readers would benefit. That doesn't seem fair. Supplying the negatives at a nominal cost, as an extension of the EPS service, seems possible. However, we would like to try something else first: dry transfer sheets with complete board designs! Shades of the sixties! The quality of these 'instant lettering' sheets has improved greatly over the years, to the point where it seems possible to use them for etching p.c. boards even when very narrow tracks are required. By way of experiment, our sub- scribers in the UK should find one of these sheets included in this issue. It contains five different p.c. board layouts, of varying complexity. They can be used either as etch mask (rub one down on a piece of board and etch in ferric chloride) or as photo- graphic 'film' (rubbed down on a piece of transparent material). What we would like to know is: do you experience any problems? Have you any further suggestions? If all goes well, we intend to start supplying this type of sheet later this year. As a price indication, one sheet (10x8 in., containing several boards and/or front panel layouts) should cost approximately £ 1 .30. Interested? Let us know! can you can a project? Empty cans are a common sight in the western world — even in 'wild and lonely beauty spots'. This means that there is an enormous amount of raw material litterally lying around for the taking. The question is: what can you do with it? This question prompted us to organise a competition: 'Construct a circuit in a can' Specifically, we're thinking of Coca- Cola cans, but other similar cans are also permitted of course, provided they're the same shape and size. Five litre motor oil cans will be disqualified! In some cases, more than one can may be used — for electronic binoculars, say. All entries will be judged on the basis of the following points: • Novelty and ingenuity • Practicability (a photo of the prototype will be welcomed!) Closing date for entries is August 15th. The winning designs will be published in November and/or December. What prizes can you win? Surprises! However, we will give a hint: we are not only thinking of electronic equipment, as in previous compe- titions. On the contrary, we have several other prizes in mind that are more in keeping with the whimsical spirit of this competition! The decision of the judges is final and it is regretted that no correspon- dence regarding entries can be entered into. Readers who require their entries returned are requested to enclose a stamped, self-addressed envelope. Send your ideas to: Canned Circuits, Elektor Publishers Ltd., Elektor House, 1 0 Longport, Canterbury, Kent, CT1 1PE. 702 elektor july/august 1980 This is a very simple circuit and is really intended for hobbyists who like experimenting with infrared or with VFETs, or even both, for that's what this is all about. The circuit diagram shows an infra- red transmitter in its simplest, most elementary form. Its simplicity is achieved with the aid of a VFET. Since FETs unlike other bipolar transistors, reveal a neat linear input to output voltage ratio, it is enough to feed a low frequency signal to the gate and to include an infrared LED in the drain lead. The intensity of the infrared light produced by the LED will then vary according to that of the LF voltage put across it and there you have it — a transmitter. In order to increase the infrared LED's lifespan, a transistor has been added to achieve current limitation, thereby reducing the FET's maximum drain current to about 60 mA. If the current were to rise, the voltage across R2 would 2 A transmitter needs a receiver. A receiver will be described here to act as a counterpart to the infrared transmitter. Again, simplicity itself with the aid of a VFET. The infrared light which falls on the infrared photo diode (here a BPW34 type, but any other will also do) will cause the voltage across R1 to vary. This will of course affect the VFET's gate and the drain current, therefore, will fluctuate according to the modulation of the infrared light received. The modulation can be heard with a set of headphones. Such simplicity of course has its disadvantages. For instance, mains light bulbs which happen to be 'on' in the vicinity will be heard as a humming noise. In quiet sur- roundings, however, fair reception is possible within a range of a few 3 Frequency conversion can be carried out very easily with the aid of this 1C. For instance, when using American clock ICs there may be a requirement infrared transmitter 5....10V become so high that T2 starts to conduct and the gate of the FET is then short circuited to ground. The low frequency modulation signal which is supplied needs to have a value of around 250 mV e ff if the transmitter is to achieve full output. Potentiometer PI is preset with the input short circuited, so that a volt- age of 0.3 volts (drain current 30 mA) is measured across R2 It doesn't matter what type of VFET or what type of infrared LED is used. This is why various types are given in the schematic. In the event of insuf- ficient 'transmission power’ several infrared LEDs may be connected in series, as required. (ITT applications) H infrared receiver metres, which can be extended by using lenses and other optical aids. With a few infrared LEDs and a photodiode this transmitter/receiver combination can be built very easily. It really works and is ideal for experiments. One other thing ... for it to function properly, PI will have to be preset so that when the photodiode is com- pletely shielded from light, exactly half the supply voltage will be measured on the FET's drain. (ITT applications) M frequency conversion using the XR 2240 to convert a signal with a frequency of 50 Hz into a signal with a fre- quency of 60 Hz. The formula for determining the output frequency of the XR 2240 is: m f ° = NTT * fin where etektor july/august 1980 703 R f o = the output frequency m = the ratio of the input fre- quency to the time base frequency. This ratio is deter- mined by the position of the potentiometer and is a whole number between 1 and 10. N = a whole number between 1 and 255 which may be selec- ted by connecting one or more of pins 1 ... 8. fj n = the input frequency When m = 6 and N = 4 the output frequency will be 60 Hz for an input frequency of 50 Hz. Similarly, when m = 5 and N = 5 the output fre- quency will be 50 Hz for an input frequency of 60 Hz. The XR2240 contains a control flip-flop FF, a time base generator TB and an eight bit binary counter. The period T of the signal produced by the time base generator is deter- mined by the RC product of the components connected to pin 13. Signals are then available at the outputs on pins 1 ... 8 with periods of T, 2T, 4T, 8T, 16T, 32T, 64T and 128T respectively. If, for example, the outputs T and 4T (pins 1 and 3) are connected to the 3k3 pull up resistor (R4), the generated signal will have a period of T + 4T = 5T. This provides the 'N' factor given in the formula. A positive going input signal at pin 12 will trigger the time base generator and reset the binary counter. The counter will then operate until the next positive going input pulse occurs. In the circuit shown the required output frequency is 60 Hz for an input frequency of 50 Hz. Therefore, the frequency of the time base generator needs to be preset to the sixth harmonic of 50 Hz which is 300 Hz (m = 6). This is accomplished with the aid of the potentiometer. With the output from pin 3 (4T) connected, the result is N = 4. The circuit will operate satisfactorily with a supply voltage of between 4 and 15 volts. With a supply voltage of 9 volts the current consumption is approximately 8 mA. The synchron- isation (input) signal needs to be a square wave with a minimum amplitude of 3 V. The maximum fre- quency of the time base generator is quoted as being 100 kHz (C2 = 6n8, R = PI + R2 = 1 k). K 2 amp voltage regulator There have been many power supply circuits featuring integrated voltage regulators published in Elektor (and other magazines) in the past. The 78xx series of voltage regulators immediately spring to mind. Why the need for another one? The 1C described here is capable of de- livering a full 2 amp output whereas older ones were only capable of supplying about 1 to 1 Vi amps; furthermore, although some had a current limit facility it was not variable. This, along with the fact that the L 200 has never before found its way into the pages of Elektor, has prompted us to describe it here. Manufactured by SGS-ATES, the L 200 is a 5-pin device and can provide a regulated supply of between 3 and 25 volts at a maximum current of 2 A with correct heatsinking. The 1C also has built-in thermal protection which makes it virtually indestructible. In the circuit shown, the two poten- tiometers PI and P2 control the current limit and output voltage respectively. Capacitors Cl and C2 are included for noise and ripple rejection. The output voltage can be calculated from the formula: V out = 2.85 (1 + |?) While the maximum current available can be calculated from: 0.45 'out " “jTj - This means that PI will have a very low value (0,22 £2 for 2 A output!). In most applications it will be easier to use a fixed resistor of a suitable value. The maximum allowable input volt- age is 32 volts. M / 7-04 elektor july/august 1980 sensibell Remember the old-fashioned copper bell-on-a-chain? In many ways it had considerable advantages over its modern electronic counterparts, advantages which were probably not appreciated at the time. It happened to provide a lot of useful information about the visitor. The way in which he rang — loud, soft, long, short, repeatedly, persistently, etc. said a great deal about him. All this of course is lost with the splendid elec- tronic versions of today. There are two ways of salvaging the old type of doorbell. First, you can hunt around until you find one in a second-hand shop. After all, they use very little electricity. Second, the electronic way, which is to build a 'Sensibell'. The important component involved is a piezo element, from an ultrasonic transducer. When a voltage is connec- ted to it it becomes distorted, when distorted it produces a voltage. If we use the element as a bellpush, two voltage peaks are obtained — one when it is pressed and one when released. The height of the voltage peaks corresponds to the pressing force. The interval between both peaks depends on how long the button is pressed. A simple solution is to construct a ding-dong-bell where the volume of, and duration between 'ding' and 'dong' is determined by the caller. The circuit diagram shows how this is done. The signal originating from the piezo crystal is amplified by A1. Because of the high impedance of piezo elements A1 is best mounted in the doorbell push button. The low impedance output of the amplifier as well as the supply voltage connec- tions can then be connected to the rest of the circuit by a four-core cable. The output of A1 is inverted by A2 so that positive pulses are available both at the beginning and the end of the bell signal. Via T1 and T2 these signals are used to shape the envelopes which modulate the ampli- tude of two oscillators. The two oscillators produce the 'ding' and 'dong' and are constructed around a single 4011 1C. Their pitch can be preset with PI and P2 respectively. A simple output amplifier (T3/T4) completes the circuit. One word of advice — it is best to power the LF amplifier separately — from the rectified bell transformer voltage, for example. The double 15 V supply then only has to pro- vide a few mA. If after installing the device, the bell sounds like a 'dong- ding' instead of a 'ding-dong', this can be remedied by exchanging the piezo element connections. In any case, the piezo element needs to be removed from its original case with the greatest of care before the con- necting wires can be soldered to it. The element can be protected against outside influences with a coat of epoxy resin or double compound glue. W. van Dreumel M elektor july /august 1980 7-05 6 stereo dynamic preamplifier A few years have gone by since the first 'integrated' stereo dynamic pre- amplifier was published in Elektor. It was designed around one of the first dual low-noise opamps, the 739. Meanwhile, the 1C repertoire of many manufacturers has grown to such an extent that there is now plenty of choice of opamps suitable for this purpose. This includes several with excellent characteristics leaving the seven year old 739 on the shelf. It is therefore high time * to discuss a new 1C dynamic pre- amplifier. The one selected is the LM 387 from National. It is an easily obtainable, 8 pin device con- taining two very low-noise opamps. The circuit diagram shows how simple it is to use it to build a high quality dynamic preamplifier. The input impedance has the standard value of 47 k, and is almost exclusively determined by the value of R1. R1 (metal film) may be altered for cartridges requiring a different terminal impedance, to * achieve a straight reproduction characteristic, within the range 22 k ... 100 k. The same is true of the terminal capacitance of the cartridge. The average was estimated to be 100 p for C5 whereas some cartridges (Ortofon included) require a somewhat larger capacitance. By connecting capacitors in parallel and in series (C3/C4 and C6/C7 respectively), the official R1AA time constants are achieved in the fre- quency compensating network. If . components with high tolerance are used, the ideal RIAA curve is ap- proached to within 1 dB. Parts list (everything 2x, except for IC1, R7,C8 and C10I Resistors: R1 = 47 k (metal film) R2.R6 = 100 k R3 ■ 1 k R4= 10 k R5 = 1 M R7 = 1 fi Capacitors: Cl « 1 p/6 V tantalum C2 - 10 p/6 V tantalum C3= 2n7 C4 = 470 p C5 = 100 p C6.C7 = 1n5 C8,C9 = lOOn Cl 0 = 0,47 p/35 V tantalum Semiconductors: IC1 = LM387 Gain is set at 100 (40 dB). The output voltage is sufficient for most pre/control amplifiers. The input impedance of the following control amplifier needs to be at least 100 kfl. If the impedance is considerably lower, which will hardly ever be the case, C9 will have to be raised in value to avoid losing any of the bass notes. The maximum signal/noise ratio depends on the quality of components used, but with an input voltage of 10 mV it will be somewhat better than 80 dB. If we double everything shown in the diagram with the exception of the decoupling components (C8, CIO, R7) a stereo dynamic pre- amplifier can be constructed. Because of the small size of the 1C and the few components required, a highly compact printed circuit board can be made, for which room can be found in the majority of pre/control amplifiers. 7 06 elektor july/august 1980 ~f 4.4 MHz crystal filter L4 ■ 150 »iH L8-120*H When building a communication receiver one of the main problems encountered is how to obtain the high selectivity required. If an inter- channel spacing of 9 to 10 kHz (used for AM broadcasting) is maintained, an excellent filter is needed. One advantage of this type of filter is that fairly cheap crystals can be used. These are called PAL crystals and, because they are used in every (PAL) colour TV set, they can often be bought at a very reasonable price. Their only possible disadvantage is that the receiver design includes a rather outlandish crystal frequency of 4.433 618 MHz, as far as the IF is concerned. Often, however, this forms an excellent IF. The circuit diagram shows that it 8 is a 'ladder filter' with a total of 5 crystals. Generally speaking, this configuration will produce a low-pass filter, in other words, with asym- metrical pass characteristics. The photo here shows that, on the contrary, the by-pass obtained is converter highly symmetrical due to a few design tricks. The 6 dB bandwidth is 5.2 kHz and the —60 dB points are at 12.4 kHz. Out of all the coils included in the design, only LI needs to be wound by hand. It consists of 15 turns of 0.4 mm copper enamelled wire double wound on an AMIDON T50-2 ring core. Time saved by not ’’ having to make L2 . . . L9 which can be bought ready-made, can be used to carefully build the filter. This is always worth while where H F circuits are concerned. In this particular case, for instance, it is highly important to separate the various filter sections by means of metal partitions. It is also wise to connect all the cases of the crystals to earth. M The 4047 low power astable/mono- stable multivibrator constitutes an excellent heart for a simple converter which can provide a 245 V AC output from a 12 V DC Input. For this application, of course, the 1C is connected in the astable mode. The symmetrical squarewave signals available at the Q and Q outputs are amplified by a pair of darlington transistors (T 1 and T2) and then fed to the secondary winding of a low voltage transformer (2 x 10 V 60 VA). The 245 V AC output is then avail- able from the primary winding of the transformer. The frequency of the output voltage can be varied between 50 and 400 Hz by adjusting the preset potentiometer PI . M. Cafaxe H elektor july/august 1980 7-07 9 I simple opamp tester sia 4 This circuit is similar in principle to, and can be mounted in the same box as, the 555 tester described elsewhere in this issue. The opamp to be tested is connected as a simple square-wave oscillator. When pushbutton SI is closed, the non-inverting input of the opamp is held at a reference voltage derived from the output voltage and the potential divider R2/R3. The current through R1 is used to charge capacitor Cl until the voltage level on the inverting input reaches that of the reference voltage. Since the opamp acts as a comparator, its output level will change state thereby producing a reference voltage of opposite polarity. The charge current for Cl will then flow in the opposite direction until the new reference voltage is reached and the whole cycle will be repeated. When the output is high, transistor T1 will conduct and LED D1 will be on. Conversely, when the output is low T2 will conduct and LED D2 will be on. The transistors are included so that other opamps with the same pin-out as, but less current 80611 output than, the 741 can be tested. The circuit requires a positive and negative power supply and will operate satisfactorily from two 9 volt batteries. M * automatic cycle lighting This simple circuit (figure 1) ensures a great improvement in road safety for nocturnal cyclists. The light remains on when the cyclist stops at traffic lights - a battery supplies the current. During the trip with lights switched on (supplied by the bicycle dynamo) the battery, a parallel connection of four nicads, is charged across D1 and R1 and the relay is operated. When the bicycle stops, the relay drops out and it now connects the bulb to the battery. The one thing to remember of course, is to switch off the lights at the end of the ride, but even this can be elec- tronicised. Figure 2 gives a suitably extended version of the circuit. Forgetting the lights need now no longer be a problem with this luxury version, which switches the lights off automatically after about 3 minutes. The circuit is of course a little more elaborate than the standard model. The battery is charged in the same way during the ride with the lights switched on. When the bicycle is halted at a traffic light the voltage is no longer supplied by the dynamo. The trigger input of IC1 (pin 2) then receives a negative pulse and the relay is energised. Now the lights are supplied by the battery (through the relay contacts) until the voltage at pin 6 has reached the level of the internal reference voltage. Then the relay drops out again and the lights and the entire circuit are cut off from the battery. The time is preset by R2 and C2 to approximately 3 minutes. That is more time than a red light takes, believe it or not. If this luxury version is used on bicycles with a hub dynamo and a switch in the headlamp, it may be useful to mount a switch between the dynamo and the input to the circuit. Not that it draws much power, but the relay clicking in and out could be a nuisance! K 7 08 elektor july/august 1980 voltage controlled duty-cycle Ub The principle behind this circuit is the fact that the average voltage of a squarewave is proportional to its duty-cycle. The circuit consists quite simply of an integrator (A1) and a Schmitt-trigger (A2), together for- ming a squarewave oscillator. If the output of the Schmitt-trigger is low the output of A1 will gradually decrease until the lower threshold of A2 is reached. The output of A2 will then go high (just less than the supply voltage) causing the integrator out- put to rise until the upper threshold is reached and the Schmitt-trigger output goes low again. By altering the voltage level on the inverting input of A1 the integrator's characteristics can be altered. As the trigger thresholds of A2 are fixed, the result is a change in duty-cycle. The average voltage of the squarewave output will always be equal to the input voltage, but the frequency will remain constant. In this way the duty-cycle can be varied between 0% and 100%. The control voltage may be anywhere between 0 V and 1 .5 V less than the supply voltage. When the LM 324 is used, the supply voltage may be anywhere between 3 V and 30 V. If other types of opamp are used, the control range may become limited. H exposure meter and development timer A great deal has been published about exposure meters and develop- ment timers in electronic magazines and Elektor is no exception. How- ever, it is very rare to find an article covering both devices at the same time. For this reason a combination design is presented here. As usual an LDFI (light-dependent resistor) has been included in the bridge circuit of the exposure meter. The amount of light falling on the LDR determines the degree of imbalance in the bridge network. During measurement, relay Rel is activated via S2e and the enlarger is turned on. Balance is then restored manually by adjusting potentiometer PI. The final value of PI will correspond to the exposure time required. Indication that the bridge is in balance is given by two LEDs (D7 and D8). Of course, this could also be indicated on a centre-zero meter but this could be difficult to read in the dark and would probably be more expensive than two LEDs. The circuit is in balance when both LEDs are extinguished. Once the above procedure has been carried out switch S2 is changed to its other position. The circuit will now operate as a development timer. The value of PI, together with C3, now determines the pulse duration of the monostable multivibrator IC2. The timer is started when push- button S3 is pressed. The output then goes high activating the relay and lighting the enlarger lamp. LEDs D5 and D6 are optional and are used to illuminate the panel of the case in which the circuit is mounted. If a single pole double-throw relay is used then it is possible to switch the elektor july/august 1980 709 exposure lights off when switching on the enlarger lamp. The role of potentiometer P2 has not yet been discussed. It enables the characteristics of the bridge amplifier to be altered to suit different kinds of paper, and should be provided with a suitable scale. The usefulness of the circuit will depend on how well it is calibrated. Readers who wish to carry out spot measurements can simply mount the LDR into a cardboard tube. This is then placed inside a metal film can and covered by a piece of perspex which has been slightly sanded with emery paper. For details see figure 2. When measuring the exposure time the perspex can be removed and a larger piece placed directly under the enlarger lamp. No details of the 13 For an ordinary cassette tape to be used as long term memory with the Elektor BASIC microcomputer a special cassette interface will have to be used. An example of this was published in the May 1980 issue of Elektor. The difference between the special and the ordinary kinds of cassette-interface aren't so great that the latter type can not be adapted. The small addition required is described here and involves no modification to the existing system. Most interfaces operate on the FSK method according to the Kansas City Standard. With the aid of a device which makes the BASIC micro- computer stop for a certain period of time at the end of each line, virtually any cassette-interface can be used. When the microcomputer is being programmed, a prompt automatically appears at the beginning of each line. This is generated by the com- puter in response to the CR (carriage return) at the end of every line. There is plenty of time for generating these prompts when a program is being entered by hand via the key- board, but not when it is being entered from a tape that was re- corded with a 'LIST' instruction (FSK modulator connected to flag 0). In the latter case, the prompt will be generated while information is being entered. The result is that errors occur in the data that is stored in memory. The circuit shown here works simply yet effectively. At the end of every line the processor is stopped for a period of time (during recording) so that an 'empty' space is recorded on the tape. This period is long enough negative will be visible when the enlarger is switched on. The perspex is, of course, removed during ex- posure. The circuit is calibrated by making test strips. Potentiometer P2 is given a linear scale division numbered 1 ... 20. With S2 in the 'time' position, PI is adjusted until a set of whole numbers is obtained which correspond to the length of time the lamp is on. This will form the scale for PI. Once this has been done a test strip is made using the old method. The same exposure time is then selected with PI. Test strips are made with P2 in various positions until the best results are obtained. The positions of PI and P2 are then written on the test strips to provide the correct coding for all types of paper. D.S. Barrett u cassette interface adaption to give the computer time to generate a prompt during playback without causing data loss. The existing cassette interface (for instance, as described in Elektor's January issue 1978) is connected to the serial input and output of the BASIC computer in the normal fashion. Points B0 . . . B6 of the circuit shown here are connected to the correspondingly marked lines of the Elekterminal (Elektor December 1978) — of course, with- out disconnecting them — and the output of the circuit is connected to pin 5c (NHOLD) of the BASIC computer. When a program is to be recorded on cassette, SI of the extension will be closed. Then the BASIC 'LIST' instruction is entered (without carriage return) . The cassette recorder is switched to record and is started. The return key is then pressed and the data is output from the computer. When the circuit detects the hex code '0D' (carriage return) at the end of each row the output of IC2 goes low and triggers the monoflop IC3. This causes the SC/MP to stop. The duration of the monoflop has been selected to allow for a long enough space to be recorded but not so long as to cause unnecessary delay. H.Schaller. M 7-10 elektor july/august 1980 V-FET amplifier Two years ago (Summer Circuits 1978) we published a design for an amplifier that used V-FETs in the power output stage. This design was based on an application note from Silconix. Since then we have updated the design and provided a printed circuit board for it so we felt it was worthy of inclusion here. The circuit differs from the original version in that the junction of C5/C7/R14/D9 is now connected to the output rail instead of to ground. This improves the amplifier's per- formance considerably. Furthermore, diodes D1, D3, D6 and D7 are shown with different symbols. These are Norton diodes (constant current) as opposed to zener diodes (constant voltage). Both halves of the output stage (shown as connections Sa, Ga, Da and Sb,Gb, Db on the circuit diagram and printed circuit board) are made up from four V-FETs connected in parallel instead of the original three. This provides better load distribution for the output stage. Diodes D8 and D9 are included to protect the output stages from any excessive high voltage transients which may occur. Care must be taken when mounting the eight output FETs. They can all be mounted (with mica washers) on the same large heatsink which should have a thermal resistance of less than 2°C/W. Alternatively, they can be split into two groups of four and mounted on two separate heatsinks. The gate resistors R15 . . . R17, R20 . . . R22, R28 and R29 are not elektor july/august 1 980 7-11 Parts list Resistors: R1,R6,R15,R16,R17.R20, R21,R22,R28,R29 = 1 k R2 = 1 M R3,R7,R8,R23 = 22 k R4.R5.R24 = 220 12 R9.R10.R19 = 10k R1 1.R12 = 390 12 R13.R18 = 2k7 R14 = 12k R24 = 220 12 R25 = 4127 '/, W R26 - 22 12 % W R27 = 330 12 PI = preset pot 220 k (250 k) P2 = preset pot 220 12 (250 12) Capacitors: Cl = 220 p C2 = 10 p/35 V C3 = 100 m/10 V C4 = 4p7 C5,C9,C1 1.C12 = lOOn C6 = 10 p C7 = 22 m/63 V C8,C10= 100 m/63 V C13.C14 = 10.000 m/50 ... 63 V Semiconductors: IC1 = LM 3045, CA 3045 T1,T2,T6 = 2N2222 T3.T4 = MPSU56 (Motorola) T5 = MPSU03 (Motorola) T7 = 2N4402 T8,T9,T1 0.T1 1 ,T1 2, R 1 3.T 1 4, T1 5 = VN89AF, 2N6658 (Siliconix) D1 = CR200 (Siliconix) D2.D4.D5 = 1N4148 D3.D6.D7 = CR390 . . . CR470 (Siliconix), 1N5312 (Motorola) D8,D9 = 9V1 400 mW 8 - 100 V/5 A bridge rectifier Miscellaneous: LI = 20 turns Cu (0 = 0.8 ... 1 mm) on R25 FI = 2A slow blow Trl = 2 x 25 V/5 A (supply: stereo version) SI - double pole mains switch mounted on the board, but should be mounted as close as possible to the gate leads of the FETs. The inductor, LI, consists of approxi- mately 20 turns of enamelled copper wire (0.8 ... 1 mm dia.) wound around R25. Although not strictly necessary, this combination improves the capacitive load characteristics of the amplifier. When setting up the amplifier, PI and P2 should be set to maximum resistance and a milliameter con- nected in the positive supply lead. When power is applied, the current consumption should be about 40 mA. P2 is then adjusted until the quiescent current is between 200 and 350 mA. Finally, PI should be adjusted to give minimum distortion at an output power of 10 W into 8 ohms with a 1 kHz sinewave input. However, if the necessary test equipment is not available to carry out this adjustment PI may simply be set to its mid-position or adjusted by ear. The amplifier is capable of producing 40 watts into 8 ohms with a harmonic distortion of less than 0.04%. When taken to the extreme, some 60 watts may be obtained before clipping occurs. This is, of course, determined by the quality of the power supply. M 7-12 elektor july/august 1980 AFC via the tuning diode Some receivers have Varicap tuning, but no AFC. If this facility is desired, it seems a pity to have to add yet another Varicap. The principle of the circuit described here is that the voltage on the Varicap tuning diodes in a receiver is automatically affected by the AFC voltage. This is achieved by connecting the common pin of an integrated fixed voltage regulator with the AFC control voltage, instead of to ground. This not only causes the total output voltage to rise, but also enables it to be con- trolled. The AFC voltage from the demodu- lator is buffered with the aid of an opamp, after which it is fed to the voltage regulator. Part of the quiesc- ent current of the regulator flows through R3, and at the same time this resistor provides a defined terminating impedance for the opamp. The AFC voltage from most demodulators isroughly 4.5 V (within ± 0.5 V) and the quiescent current of the voltage regulator is approximately 3 mA. In order to control the output voltage over a large enough range and allow the circuit to behave in a stable manner, the opamp will have to sink 2/3 of the quiescent current. From * >M text this R3 may be calculated as follows: _ 4.5 (volt) = 1 (mA) = 4500 n Therefore, 4k7 was chosen here. To avoid oscillation the opamp is compensated by C3 and the voltage regulator is decoupled with C5. The LM 308 type was chosen as a buffer ( 1C 1 ) because of its low input current (only 3 nA) and its very low drift. The circuit's current consumption is approximately 300 pA. The AFC voltage is fed to the input by means of a low-pass filter (R1 and C2) which causes any interfering signals to be thoroughly suppressed. It also ensures quiet, stable AFC control. To switch off the AFC the input voltage of the circuit is preset to the average value of the AFC voltage. S. Hering M alternative amplifier for the n aerial i -| V »OQOQ oj The fl aerial described in the June edition of Elektor consists of two parts. One of these is a coil which must have a low impedance and which ensures high quality reception in spite of its small size — provided a good amplifier is used. This of course constitutes the second half of the fi aerial. There is no doubt about its being an excellent amplifier. The signal-to-noise-ratio is very good and it won't be easy to find another amplifier in the 20 MHz to 30 MHz frequency range with similar charac- teristics. elektor july/august 1 980 7-13 There is however, one disadvantage to the original circuit which was designed around the BFT66. The input impedance is not really low enough. As it is around 50 ft it causes sensitivity to drop by 6 dB per octave at lower frequencies. Further- more, ferrite beads are used which are not always easy to get hold of. All the more reason for discussing a new type of amplifier without ferrite beads and with a really low input i impedance. Figure 1 shows the circuit diagram of the new amplifier. The input impe- dance depends on the transistors j 2 used, but will certainly be lower than 1 ft. The bandwidth is about 5.5 octaves higher than the original and the frequency range extends down to 100 kHz. The ft aerial's favourable characteristics stand out in the tropical and navigational bands as well as on the long and medium waves. Of course, a compromise had to be made in order to obtain these results. The signal/noise ratio is now much worse than when a BFT66 transistor is used. A low input impedance may be achieved by coupling the emitter of T2 to the base of T1. The quiescent current through both transistors is determined by R1 and R2, where the latter naturally determines the quiescent current through T2. The amplifier can be connected to the same supply as that using the BFT66. Furthermore, it must be mounted in a metal case and the printed circuit board must be con- nected to earth at one point only. Figure 2 shows the equivalent circuit of the aerial together with a variable tuning capacitor and the input impedance of the amplifier. The tuning capacitor can be used to bring the entire circuit into resonance. The receiver must however, be provided with an input attenuator to avoid the risk of overdrive. The aerial may of course, only be tuned at relatively low frequencies. An aluminium type aerial which is 3.9 cms wide and has a diameter of 2 meters will reach a maximum frequency of 22 MHz. It can also be tuned to frequencies between 20 and 30 MHz, provided the tuning capacitor is connected in parallel to the loop. R. R. Venekamp M This device utilises the fact that an air current has a cooling effect on an object which is warmer than its surroundings. The object cooled in this case is a transistor (T2) which is connected as a diode. To make it warmer than its surroundings it has been thermally coupled to a tran- ' sistor (T1) which has a current flowing through it continuously. The wind's speed is measured by com- paring the voltage across the cooling diode with that across a reference diode (T3). These two voltages are fed to the non-inverting and inverting inputs respectively of an opamp. This amplifier, which is preset for a gain of 1000, passes a current through the heating transistor via resistor R1. When the wind cools the diode, the forward voltage across that diode rises (2mV/°C) causing the voltage at the non-inverting input of the opamp to increase. As a result, the output voltage of the opamp rises to provide more base drive current for T1 thereby generating more heat in this tran- sistor. The opamp thus tries to compensate for the temperature drop, which leads to an increase in TVs collector current. A high sensitivity is obtained by making the temperature of T2 about 5 degrees higher than its sur- roundings. This is achieved by presetting the meter to give an offset of about 5 mA when there is no wind blowing. Resistor R1 is selected so that the current through T1 is not excessive. In the circuit, T1 is shown as a BC639, but a BC547 type may also be used: the maximum collector current must then be limited to 100 mA. If the circuit tends to oscillate, the gain of IC1 should be reduced — by increasing the value of R5. The photograph shows the con- struction of the wind detector. The two transistors are coupled by glueing their flat sides together with a heat conducting adhesive. H 7-14 elektor july /august 1980 8 cheap light meter r When developing photographs a light meter can be a useful gadget. Of course, the more luxurious the better, but as the diagram here shows, a simple circuit can also be very effective. The circuit is con- structed around a photodiode. In a camera the diode generates enough voltage to control a meter directly. Often, however, there is not enough light under the enlarger. That is why a transistor has been added. Unfortu- nately, this also puts an end to the original design's simplicity, for now a battery will also be necessary. One solution is to connect the light meter to an ordinary multimeter switched to the resistance range. This is indicated inside the dotted line. Remember that the positive test lead of most meters is the negative pole for the resistance range! Operation is as follows. The test diode is connected between the collector and base of the transistor. The more light that falls on the diode, the more the latter will con- duct, thus providing the transistor 80513 with more base drive current. The collector current then increases (almost) linearly and this is indicated on the meter's dial. A. Vis M 101 I / i garden path lighting Plant a new bulb in your garden! This circuit will lead you up the garden path at night in safety. It enables the path to be illuminated whenever required, and it consumes very little energy. The lamp is switched on by reed switches, mounted in the front door and in the garden gate. Ey using a 24 V lorry bulb, electrical installation remains simple and safe while ensuring suf- ficient light. The circuit is powered from the secondary of a 24 ... 30 V/5 A trans- former. Where long leads through the garden are a necessity the higher rating is preferable due to the voltage drop caused by the resistance of the leads. The 50 Hz signal from the trans- former is fed to the base of T2 which converts it into a squarewave. This is then gated by N2 to provide the clock signal for the counter IC2, for as long as Q14 remains low. As soon as Q14 goes high the clock signal is blocked. Transistors T3 . . . T5 form a zero-crossing detector which is also controlled by the 50 Hz signal. Each time the transformer voltage crosses zero the collector of T5 is pulled low for lOOps. This pulse arrives at the base of T1 via the buffer N1. This transistor is used to control the triac which in turn switches the lamp on at every zero-crossing. The light will, of course, appear to be on continu- ously for as long as Q14 remains low. The path will be illuminated for elektor july/august 1980 7-15 nearly three minutes — long enough for someone to walk up the average path and open the front door. The circuit is activated when the reset input of the counter is taken high. For this to happen, both inputs of N4 must be low. One of the inputs to N4 is controlled by an opamp whose output is determined by the amount of light falling on an LDR (light-dependent resistor). A certain amount of hysteresis has been incorporated in this part of the cir- cuit. As long as there is sufficient daylight the output of IC1 will be high. The reset input of the counter will remain low thereby inhibiting the system. As darkness draws in the output of IC1 will go low (the actual level can be preset by means of PI) enabling one of the inputs to N4. The other input to N4 is taken low when one of the two reed switches (SI or S2) opens and closes, when the garden gate or front door is opened and closed. This fulfils the condition that both inputs of N4 must be low and the inhibit is removed from the counter enabling operation (and illumination). Thin twin-lead cable can be used for the reed switches, but thicker wire (about 2.5 mm 2 ) is required for the lamp. Current consumption is ap- proximately 100... 150 pA when the lamp is not on. B.E. Kerley H legato gate interface /-K-y for FORMANT This circuit is an expanded version of the interface receiver for the Elektor Formant music synthesiser. Its purpose is to allow for legato playing. By 'Legato' (contrary to 'staccato') we mean that the notes will run into each other smoothly without a break. That is to say, each key is pressed before the previous one has been released. As there must always be a key pressed no gate pulses will be produced and the envelope curves cannot be released. This disadvantage is especially noticeable with AD (attack-decay) envelope curves. This circuit differentiates the voltage transients from the KOV (keyboard output voltage) to provide a 2 ms signal which triggers the gate pulse. Although this method is only reliable when the portamento is switched off, musically it is of great significance. The input circuit around IC1 and IC4 corresponds to the present Interface Receiver. The buffer IC3 is followed by a differentiator and a switched amplification stage. With a gain of about 100 IC5 ensures an excellent pulse amplitude, when playing half tone intervals. To maintain a negative pulse when moving down the scale as well as up the scale, IC6 inverts the pulse from the output of IC5. Both outputs are connected to an OR gate consisting of diodes D5 and D6. The following transistor stages enable these 'legato' gate pulses to be shaped and coupled to the original gate circuit. As can be seen, the 'normal' gate pulses are available from the Gate I output and the 2 ms 'legato' gate pulses from the Gate II output. When the latter is used the ADSR generators are also released during legato playing. If the new interface receiver is provided with a changeover switch, a choice can be made between either of the gate pulses, (normal or legato), according to the way the instrument is to be played. M. Bertuch H 7-16 elektor july/august 1980 hybrid cascode It is general knowledge that cascoding two or more transistors creates a new transistor with better characteristics than the individual ones (see figure 1). These include a very slight retroaction from point C ('collector') to point B ('base') and a higher collector impedance, thus a much better approach to current source operation at point C. In the all transistor version of figure 1, the base of T2 will have to be fed a certain voltage with respect to the emitter of T1 - 0.6 volts (D 1 in figure 1) at least. If T2 is replaced by an N channel FET, the DC bias of the cascode will be a lot easier to preset — see figure 2. As far as slope is concerned (i.e. the ratio between collector current and base voltage) both versions are equally good. M ’ Q e car stabiliser Together with the 'ordinary' three pin regulator IC's a few different types for special use are becoming available. The LM 2930 from National was primarily intended for use in the car, but it also has other applications. The 1C has a few quite useful characteristics, such as the fact that the difference between input and output voltage need only be 0.6 V. Changing the input voltage's polarity is no longer a disaster and short voltage peaks of up to 40volts cause no damage. Other character- istics include voltage limitation and thermal protection and although useful, are less spectacular. Since the output voltage is 5 volts (there is also an 8 volt version) and the maximum current is 200 mA, this regulator will be ideal for use with instruments (speedometers, " computers) rather than in audio. The circuit is extremely simple. Both capacitors have to be mounted close to the 1C in order to prevent oscil- lation. In most applications the 1C must be mouqted on a heatsink; this can be connected to ground. The maximum input voltage is 26 V. M digital sinewave generator More and more information is being generated by digital means, because of the good frequency and ampli- tude stability obtained. This particu- lar circuit generates a sinewave, but if R1 . . . R8 were to assume other values, different waveforms would also be possible. After the supply voltage has been applied, the R9/C1 network ensures a short reset pulse: all outputs become logic zero. Since output 8 is also 'O', the inverted level ('1') is offered at input D. With the aid of an external oscillator (not drawn) pulses are fed to the clock inputs. At every positive slope the information in the shift register IC1 moves one place further along. Thus, after the first clock pulse Q1 will be '1' and after the eighth Q8 will also be 'V. As soon as Q8 becomes logic 1 however, the information at input D will change to logic 0. Then zero's will be entered until Q8 also changes to 'O'. The entire operation is then repeated. By choosing suitable values for R1 . . . R8 the output voltage is con- verted into a sinewave. The output frequency is one six- teenth of the clock frequency. The CMOS 1C can process up to 7 MHz so that the maximum output frequency is about 0.5 MHz. Gate N1 may be of any type provided that the signal is inverted. The two photo's show the waveform elektor july /august 1980 7-17 zerocrossing sync and the frequency spectrum respect- ively. The most important harmonics, the third and the fifth, are almost 50 dB below the output level. Although the fifteenth and seven- teenth harmonics are much larger, they can be nullified by a simple RC filter because they are further away from the main frequency. A circuit using a 555 timer as an oscillator may be used for the clock pulses — see the synchronous FSK modulator described below. The sync output provides a squarewave, with the same frequency and phase as the sinewave, which can be used, for instance, to trigger an oscillo- scope. H synchronous FSK A disadvantage of a number of popular FSK (Frequency Shift Keying) modulators is that the changeover between the 1200 anb 2400 Hz frequencies often occurs at unpredictable times. A much better and neater solution would be to switch frequencies when the signal is at zero. If this is done then there is no phase shift in the FSK signal. Generally speaking, this is only possible when there is a definite relationship between the data and the FSK modulator. If there isn't then the circuit given here should be of some help. The actual FSK signal is obtained by means of the digital sinewave gener- ator described previously (see above). At every zero-crossing the sinewave generator produces sync pulses which are used to clock FF2. The data level present at the 'D' input of this flip- flop determines which of the two output frequencies are selected. When a '1' is present at the input, the output frequency will be 38.4 kHz, and when a '0' is present the output frequency will be 19.2 kHz. This output signal is then divided by 16 by the digital sinewave generator to produce the correct FSK frequencies. The oscillator for the circuit is formed by the well known 555, albeit a CMOS version (that’s why it has the slightly different 7555 type 5V number). This IC's characteristics are practically the same as those of the 'ordinary' 555 with the added advantages of a much higher input impedance, less current consumption and its almost total 'spike' suppression during output level switching. If the circuit is not used in com- bination with the digital sinewave generator, the sync input must be connected to the Q of FF1. H 7-18 elektor july/august 1980 PWM battery charger This circuit is designed to charge 6 V/3.5 Ah batteries similar to those often used in flash equipment. Of course, there are all kinds of methods to charge lead-acid batteries but what is special about this version is the fact that the charge current is continually corrected according to the state of the battery. Figure 1 shows the block diagram of the PWM battery charger (PWM stands for Pulse Width Modulation). A1 is a squarewave oscillator which generates a frequency of around 2 kHz. A2 is a monostable multi- vibrator which is triggered by the negative-going pulses from A1. The pulse width from A2 depends on the control voltage which is derived from the differential amplifier A3. The latter constantly monitors the battery voltage. The output of A3 varies according to the difference in voltage between the preset reference level and the tested battery level. When both are equal the output voltage of A3 will be such that the duty-cycle of A2 will be 10%. This is enough to maintain trickle charge for the battery. The output of A2 controls the electronic switch ESI, so that current is fed to the battery by way of R1. The duty-cycle of the output signal is automatically varied be- tween 10% and 90%, depending on the state of the battery. Figure 2 shows the complete circuit diagram of the PWM battery charger. The squarewave oscillator is formed by IC2 (a 555) together with the associated components. The fre- quency is preset at 2.27 kHz but this value is not critical. A2 is also constructed around a 555 and is configured as a monostable multi- vibrator. This is triggered by the negative-going pulses of IC2 differentiated by C5 and R8. Pin 5 of the 555 is used as a modulation input and is connected to the output of the differential amplifier which consists of a 741 1C. It is this signal which controls the duty cycle of IC3. The reference voltage on the non-inverting input of IC1 is preset by means of potentiometer PI . The inverting input of IC1, on the other hand, is connected to the battery via a 100 k resistor. As long as the voltage across the battery is lower than the reference voltage, the voltage at the IC's output will be fairly high — when the difference in voltage at the inputs is reduced however, the voltage at the output will also drop and so will the duty- cycle. The easiest way to calibrate the system is by using a discharged battery (about 2 V per cell) and a fully charged battery (about 2.4 V per cell). The discharged battery is first connected to the output of the circuit. The maximum presettable voltage is then fed to pin 3 of IC1 by means of PI. Now a resistor for R12 may be selected to obtain the correct charge current (in the case of a 6 V/3.5 Ah battery this will be 400 mA; in general about one tenth of the capacity). The value of R12 will be somewhere between 2.5 and 5 ohms. Finally, the (completely) charged battery may be connected up. The charge current is now adjusted to a - tenth of the value previously obtained. If an ammeter having the correct test range is not available, the current may be calculated by measuring the voltage across R12 and using Ohm's Law. If a transformer with only one 9 V/1 A winding is used, then a 3140 opamp will have to be used for IC1 and D2, D3, and C2 may be omitted. Pin 4 of this opamp is connected to zero volts. D1 then needs to be replaced by a bridge rectifier (full wave rectifi- ' cation). M.S. Dhingra elektor july/august 1980 7-19 test transmitter for receiver alignment i No doubt there are quite a few readers who would like to have a simple test transmitter at their disposal in order to be able to correctly tune his/her receiver, without, of course, having to pay the earth for it. The test transmitter described here seems likely to be a reasonable solution at a reasonable price. Its advantages include: — a wide frequency output, divided into 12 ranges; — a constant output amplitude over the full range; — low distortion; — simple frequency switch; — 50 output impedance. The block diagram is given in figure 1. As shown, the device consists of two parts, that is to say, a differen- tial amplifier/oscillator with a tuned LC circuit, which generates the high frequency signal, and an amplitude modulator with a built-in 1000 Hz generator. The circuit diagram for the test transmitter is shown in figure 2. The differential amplifier/ oscillator is formed by transistors 7-20 elektor july/august 1980 Parts list for figures 2 and 4 Resistors: R1, RIO - 47 ft R2.R3.R20 = 4k7 R4 = 22 k R5.R13 = 100 ft R6 = 5k6 R7 = 2k2 R8 = 1 M R9 = 2M2 R11 = 10k R 1 2 = 33 ft R14 = 560ft R15 « 56 ft R16.R17 = 82k R18.R19 = 150 k R21 = 820 ft R53 = 1 k PI = 100 k lin. Capacitors: Cl - 100 p variable C2,C3 - 10 n ceramic C4 = 10 m/3 V C5.C8 = 22 n ceramic C6 = 1 n ceramic C7 = 15 p ceramic C9 - 22 p ceramic CIO = 4,7 m/10 V tantalum C11 = 1 m/10 V C12= 100 n C13 = 390 n C14 = 330 n C15 . . . C18 = 47 n C19 = 470 m/25 V C20 = 10 m/16 V tantalum Semiconductors: T1,T2,T3 = BF494 T4 = BF256 C T5 = 3N211 T6.T7 = BC547A, B IC1 = 741 IC2 = 78L12 D1,D2,D4,D5 = 1N4148 D3 = LED (redl D5 . . . D9 = 1N4001 Coils: LI = 68 mH L2 * 33 mH L3 = 10 mH L4 = 3,3 mH L5 = 1,2 mH L6 = 470 mH L7 = 150 mH L8 = 56 mH L9 = 18 mH L10 = 6,8 mH L1 1 « 2,2 mH L12 = 0,68 mH L13 = 68 mH Miscellaneous: Trl = transformer secondary 12 V/50mA Z1 * fuse 100 mA, slow 51 = 12 position switch 52 = single pole switch with intermediary position 53 - double pole on/off switch T1 and T2. This type of oscillator guarantees operation with little dis- tortion as the LC circuit is controlled by square waves. Furthermore, it is the only type of oscillator which affords the possibility of using a single 'range' switch. The frequency range extends from 50 kHz to 30 MHz. It is divided into 12 smaller ranges, for which coils LI ... LI 2 can each be selected by switch SI. After a particular frequency range has been chosen, the oscillator is finely tuned to the desired frequency by means of the variable capacitor Cl . Current passing through the differential amplifier is maintained at a constant level by current source T3. The current source is varied, however, (via R6 and PI) by the output of IC1, with the result that oscillator T1/T2 is amplitude modu- lated with a modulation depth which can be preset by means of PI . Modulation takes place either by means of an external signal or by means of a 1000 Hz signal generated inside the device. IC1 serves two purposes. In the first place, IC1 and transistor T7 form an oscillator, the frequency of which is determined by the loop consisting of Cl 3 and L13. During external modulation (with S2 in the other position), however, IC1 is used as a normal amplifier, whereas transistor T7 no longer operates. For an unmodulated carrier wave to be available as well, switch S2 needs to have an inter- mediate position. LED D3 in T6'$ base potential divider ensures a constant base drive, so that the current through T6 is maintained at a constant level. This causes the FET (T5) to operate in such a way that the output impedance of the test transmitter approaches the required 50 value. Figure 3 shows the circuit of an HF attenuator which is necessary to reduce the test transmitter's output to a level at which receiver inputs can operate. When built as indicated the attenuator can be switched in 1 dB steps within a frequency range of 0 ... 100 MHz and it remains just within 2dB. Capacitors C21, C22 and C23 in the 20 dB pads serve to compensate for the parasitic capacitances of the switches. (from: Ham Radio, Oct. 1978.P.51) Specifications: Frequency range: approximately 50 kHz ... 30 MHz. Output impedance: 50 n. Output level across 50 ft: 250 mVpp < U out < 300 mV pp Internal modulation: 0 . . . 30%, f = 1 kHz External Modulation: 100 Hz . . . 10,000 Hz. 0 ... 30% at an input voltage of 1 VrmS maximum. Table Switch position Frequency range Parts list for figure 3 (not included on p.c. board!): 4 dB pad: R35.R37 = 15 S2 R36.R38 = 47 Si 1 47- 97,8 kHz 1 dBpad: R39 « 100 n 2 80,3 - 145 kHz R22.R24 = 3,3 Si 10 dB-pad: 3 140,8 - 253 kHz R23.R25 = 22 Q R40.R41 =27 SI 4 237 - 428 kHz R26 - 680 Si R42 = 2,2 Si 5 412- 770 kHz R27 = 1k2 SI R43 • 33 Si 6 654 - 1210kHz 2 dB-pad: 20 dB-pads: 7 1,16 - 2,03 MHz R28,R29= 5,6 n R40,R45,R47,R48,R50. 8 2,00 - 3.48 MHz R30 = 220 Si R51 = 39 n 9 3,31 - 6,15 MHz 3 dB-pad: R46.R49.R52 = 10 Si 10 5,46 - 10,3 MHz R31.R32 = 8,2 Si C21 f C22,C23 = 27 p ceramic 11 9,63- 18,3 MHz R33 = 390 Si S4 . . . S1 1 = double pole 12 17,7 - 34,4 MHz R34 = 220 Si switches 7 22 elektor july /august 1980 27 The level of water in a water tank can be measured in various ways, some of which can of course be more complicated than others. The circuit published here lights a LED when- ever the level of water drops below the electrodes. With a high water level, the FET hardly conducts or not at all, because the gate is then connected to earth and there is no voltage difference between gate and source. When the water level drops, the gate/source connection is inter- rupted. The gate is then at a positive potential by means of the 820 k resistor, thereby causing the FET to conduct. The LED will now light. If the reverse operation is needed, that water detector 12V VN66AF VN46AF is the LED lights when the electrodes are short circuited by the water, just connect the 'earthy' electrode in the circuit to the positive and wire R2 between gate and source. ITT Applications H intelligent NICAD charger Like all things, NICAD chargers are subject to human error, that is, the batteries can be placed in the holder in two ways, correctly and incor- rectly. This charger will refuse to operate unless the cells are fitted correctly. The charger consists of a current source (T2) to maintain the output current at about 50 mA. The zener diode D2 and LED hold the base drive of T2 at a constant level and thus also the voltage across R3. The current through R3 is therefore also constant, providing the correct conditions for charging NICADs at the collector of T2. The protection circuit includes T1, D1 and R1. The terminal voltage of +15 v an incorrectly fitted NICAD will turn off T1 preventing the charger from operating. An indication of this will be given by the LED — it will not light. When the battery is fitted correctly T1 will turn on and the charger will function normally. Although the charger is capable of charging up to four penlight cells, it will not detect a single cell being the wrong way round if two or three others are connected correctly at the same time. A small transformer, bridge rectifier and electrolytic ca- pacitor are all that is required for a power supply. The circuit works well providing the NICADs are not com- pletely discharged. H more scope for the elekterminal Sometimes it can be very useful to connect the elekterminal (Elektor November and December 1978 issues) to an oscilloscope instead of to a TV. This of course, takes some doing, but if the circuit described here is used there should be no problems. The principle is very simple. If the oscilloscope has a Z input (which is usually the case, although the con- nection will probably be at the rear), the beam's intensity may be regu- lated by an external voltage. Thus, a video signal can be directly fed to the Z input of an oscilloscope. If care is taken that the beam moves from left to right at the correct moment and obtains the right vertical deflection, a 'TV picture" will appear on the screen. At the end of each row a horizontal synchronis- ation pulse is required. In the case of the elekterminal this is available at pin 4 of IC18 (N13). This output also contains the synchronisation pulses which make the beam fly- back at the end of each raster. This combined signal is fed to the sync input of the circuit shown here. Each frame pulse triggers the ramp gener- ator (IC1) via N2. The output voltage of IC1 will fall from 12 V to 0 V within 20 ms. This will be connected to the Y input of the oscilloscope. The line pulses, which indicate that a new line must be written, are delayed by means of R7, D1 and C6, after which they are shaped by N3. Every 64 ps therefore, a pulse will be produced at the output of N3 which is fed to the external trigger input of the oscilloscope. This causes the oscilloscope's time base (which should be preset to about elektor july /august 1980 7-23 5 V 12 V 80545 6/is per division) to start at every horizontal sync pulse and to write a line. Since the voltage at the Y input constantly falls during a raster period (20 ms) the lines (312 altogether) are written one below the other. While these lines are being written, the beam's intensity is being varied. This is done by the picture informa- tion which is derived from pin 7 or pin 9 of IC12 and passed via a buffer to the oscilloscope's Z input. Not all Z inputs have the same sensitivity which is why any voltage up to a maximum of 30 V may be connected to the point marked Uz. This is then switched by the open collector output of N4. Depending on the type of oscillo- scope, the voltage connected to Uz may have to be increased or de- creased to obtain optimum intensity. The video signal can be inverted, or not, as required, by placing the wire link in the appropriate position. M loudspeaker fuse The loudspeaker protection circuit described elsewhere in this issue can be used to protect multipath loud- speaker systems effectively from users with destructive tendencies. It can be done even more simply by using an old-fashioned glass fuse in series with the loudspeaker wiring. The melting value (in A) of the fuse is based on a compromise between a high value for the bass speaker, a less high value for the medium range and a low value for the treble speaker. To place the fuse in series with the loudspeaker wiring (figure 1) as it stands would cause considerable problems. This is because a fuse has a relatively high series resistance. It is not too good for the muting factor of the amplifier or for the bass reproduction quality for that matter. 1 But there is more to it. When a current passes through the fuse it gets hot causing non-linear thermal behaviour — and the quality of the bass will show a negative temperature coefficient. Something can be done about this. Include the fuse in the negative feedback loop (figure 2), in other words, tap off the negative feedback voltage from a point behind the fuse. The fuse is by-passed by means of resistor R3 which is small compared to R2 (slight influence on the DC set- up of the amplifier), but large compared to the 4 f2 or 8 fi load impedance. A value of 220 ft (1 W) for R3 is fine. M 7-24 elektor july /august 1980 31 current saving home trainer UTF IC4 IC2 IC3 IC1 ( j) (j) (j) (») N1 . . . N4 = IC2 * 4001 N5 . . . N8 = IC3 = 401 1 N9.N10- IC4-4012 Many sport-loving Elektor readers welcomed the idea of an exercise timer or 'home trainer' (Elektor November 1979 p. 20). However, having to continually keep an eye on the watch during all the various exercises seemed to them a bit of a bind. And it had yet another disadvantage — as it was constructed with TTL IC's it required quite a lot of current. Doing exercises outside demands enough energy without having to drag a heavy and clumsy battery package around. In any case, adapting the current requirements to those imposed by cross country running proved to be quite simple. The first step to be taken towards saving current consisted in changing over to CMOS components. A single 1C combining oscillator and timer (IC1), together with C2, R2, R3 and PI which determine the frequency is sufficient to provide the clock signals required by the rest of the circuit. To save costs and space - CMOS monoflops cost more than their TTL counterparts - both monoflops in the circuit were replaced by NAND gates N9 and N10. These, together with two gated multivibrators consisting of N1...N4, C3, R4, C4 and R5, generate the tones marking the beginning and the end of each interval. The circuit is calibrated by means of the trimmer potentiometer PI, the duration of the time interval is shown in the pulse diagram (figure 2). As explained in the original article, the idea is to exercise for one minute until the first tone sounds (A); relax for half a minute until the second tone (B); then exercise again, and so on. When the circuit is switched on IC1 is reset by the pulse from the differentiator R1, Cl. As shown in the diagram, the first exercise minute is slightly too short (one half period of Q6, about 3.75 seconds). This should be no problem however. When the prototype was constructed the optional interval display was left out and the circuit was mounted together with a 9 V battery in a very small case. Current consumption is about 20 mA with an LED display and only about 4 mA without, so the battery has a long lifespan and may accompany many a jogging session. B. Kohler elektor july/august 1980 7-25 plus or minus unity gain U b =10...15V This unity gain amplifier is capable of producing an inverted or a non- inverted output signal, as required, depending on the voltage level present at the control input (A). The circuit works in a very simple manner. If the control input voltage is 0 V, the non-inverting input of the opamp (pin 3) will be connected to earth by way of the conducting FET. The opamp is now connected as an inverting amplifier causing the inverting input to constitute a virtual earth point (the opamp maintains the voltage level at pin 2 equal to that at pin 3, in this instance, ground). With the given values for R1 and R2 the gain will be —1 . If the control input (A) is connected to — Ub the FET will turn off and will form a high impedance load for the rest of the circuit. Now the out- put of the opamp will not be inverted but the gain will remain the same. The input level must remain within 2 volts of the supply voltage extremes, (thus, Vb + 2 V This circuit can be used for accurate phase measurements up to 1 MHz. If all due care is taken during construc- tion, an accuracy of within 0.1° can be achieved for frequencies up to 100 kHz. Not bad! The two input signals, A and B, are fed to an RS flipflop consisting of NAND gates N1 . . . N4. As illus- trated in figure 2, this flipflop produces output pulses with a width that is directly proportional to the phase difference between the two input signals. Or, to be more precise, for any frequency the mark -space ratio (duty-cycle) is proportional to phase angle. A1, T1 and associated components are a current source; diodes D1 and D2 ensure that this current only flows to the integrator (A2) when the output from the RS flipflop is 'high'. This means that the integrator output will reflect the average value of the flipflop — its duty-cycle. The output from the integrator is smoothed (and inverted) by A3. The phase difference between the two input signals determines the output voltage from A3. For instance, a phase angle of 180° will result in 1 .8 V at the output. Once the unit is calibrated, that is. P2 is used to set the voltage at the D1/R6 junction. This voltage should be +0.6 V when the output of N3 is 'high' (R5 shorted) and —0.6 V when the output of N3 is 'low' (R3 shorted). With the output of N3 still low, P3 and P4 are adjusted so that the outputs of A2 and A3 are both 0 V — the latter being the more important. Finally, the output of N3 is again made 'high' (short R5) and PI is adjusted so that the output from A3 is exactly 3.6 V. For obvious reasons, the power supply voltages must be accurate. and adequately stabilised. The input signals must be squarewaves with a very short rise time ('steep edges'). For general purpose use, very good high-frequency amplifiers followed by schmitt-triggers will be required at each input, to convert any signal into the necessary 'squared up' version. It should also be noted, in this case, that the hysteresis of the schmitt-triggers must be symmetrical with respect to 0 V, to avoid errors. N. Nazoa-Ruiz M 7 28 elektor july /august 1980 universal warning alarm A device to attract one's attention when a certain condition is not being fulfilled would have a wide range of applications. The circuit presented here is versatile enough to provide an alarm for any application whether requiring immediate attention, or just reminding one that a certain function is not being properly accomplished. The simplicity of the main circuit is immediately apparent (figure 1), consisting of only two CMOS squarewave oscillators and an output buffer. The circuit operates as follows: N1 and N2 form one of the CMOS oscillators. This oscillator is used to pulse a second oscillator (N5 and N6), which is set at an audio frequency. The mark space ratio of the first oscillator can be varied by means of PI and P2. It can then be seen that PI determines the length of time that the second oscillator is enabled. Conversely, P2 determines the time that the second oscillator is disabled. The frequency of the second oscillator can be varied by means of P3 over the range of 40 Hz . . . 15 kHz. The output of the circuit will be a pulsed tone of the frequency deter- mined by P3, the 'on' time deter- mined by PI, and the 'off' time determined by P2. The circuit can be enabled in two wavs: 1 ) A logic 0 on the A input 2) A logic 1 on the B input (provided N4 is omitted!) Thus the circuit can be triggered by either logic state. The output of N6 is fed to two inverters; N7 and N8. These feed a low pass filter formed by R7 and C3. These reduce high frequency harmonics and give the output a more pleasing sound. Potentiometer P4 is used as a volume control, and therefore the output is taken from the wiper. If the circuit is to be used on its own, then the output can be fed directly to the positive side of C6 and to the output driver formed around T1 (figure 2). If more than one of these circuits is to be connected together, then all the 'out' terminals of the alarm circuits can be commoned and fed to the non-inverting input of IC3 (741) (figure 3). The 741 forms a summer/amplifier circuit. Its output can then be fed to the output driver. A number of simple circuits for sensors are shown in figure 4. If the output of the light sensing circuit is 80522 -5 elektor july/august 1980 7-29 connected to input B, then this forms a dawn alarm (great for the winter, one wouldn't have to get up before 9 AMU Note that when using input B, R4 and N4 should be omitted. The temperature sensor, if connected to point B, forms a high temperature alarm. The liquid sensor, if again connected to point B, sounds the alarm when a conductive liquid covers the probes. If the three sensor circuits are connected to the A input then the following circuits result: a dark alarm, a low temperature alarm and a no liquid alarm respectively. The last two show how to connect the alarm to switched circuits. If used in a car for example, and the circuit is wired as in 5a, with the switch in the positive supply lead, then input B should be used. If circuit 5b is used however then the A input should be used. In a car, the alarm could indicate low oil, low petrol, seat belt not being worn etc. The applications are limited only by the imagination of the constructor. B. Leeming K EXOR edge detector This very simple edge detector can find its way into many applications. It relies on the propagation delay of the EXOR gates to provide an output pulse for every incoming edge, both positive and negative going. The incoming waveform is fed directly to one input of N4, the last of the four gates in the circuit diagram. This input signal is also fed through the other three gates N1 . . . N3 in series and this 'processed' signal becomes the other input to N4. In the case of the 7486 quad EXOR gate, the propagation delay (that is the time it takes for a signal to travel 'through' the gate) is in the order of 15 ns. It therefore follows that the 'processed' signal will be delayed by 3 x 15 ns = 45 ns. Since the output of an EXOR gate is low when both inputs are equal, N4 will give a negative pulse out for the duration of the propagation delay time of gates N1 . . . N3. It will be obvious that this circuit will also be quite useful as a frequency doubler. M _njui_ 80561 • 1 skin resistance biofeedback This device makes a special form of biofeedback possible in a very simple way. It is based on the principle that the more the body is relaxed the higher the skin resistance. With the aid of two 'electrodes’ in the form of metal rings around two fingers, the skin resistance is used to control the frequency of an oscillator. This is constructed around a unijunction transistor (Ta). The tone produced can be heard through a pair of headphones and will become lower the more one relaxes and the resistance between the electrodes increases. As a reference, an identical oscillator is constructed around T2, the frequency of which can be set to produce a tone, corresponding to an optimally relaxed state. If (high impedance) stereo head- phones are used the output of the reference oscillator is connected to one earpiece and the skin resistance sensitive oscillator is connected to the other, the idea being to match the frequency of both tones as closely as possible merely by relaxing. Cool it man! S. Kaul M 7 30 elektor july/august 1980 RS 232 line indicator There are now a large number of peripheral devices such as VDUs, TTYs, printers etc. available to the amateur to add to his/her personal computer system. When things fail to operate correctly one of the first checks to be carried out is to make sure that the correct voltage levels are present on the RS232 line inter- connections. As many personal computer operators will testify, this is not a particularly easy task when the only test instrument available is a multimeter. Inserting probes into live sockets while looking up the relevant literature for correct connection and simultaneously pressing buttons can be very frustrating — especially when power supply lines are shorted out accidentally! It would be desirable, therefore, to have a device that will check whether or not the signals are present and at the correct levels. The accompanying circuit is just such a device and can be built into the computer to provide a constant monitor of the RS232 line. The circuit is very simple and consists mainly of two comparators and two pulse stretchers. Resistors R5 . . . R7 form a potential divider chain to set the voltages on the non-inverting input of IC1 and the inverting input of IC2 to 2.4 and 0.8 volts respect- ively. The RS232 input signal is attenuated by resistors R1 . . . R4 and passed to the inverting input of IC1 and the non-inverting input of IC2. If the circuit is to be used with systems operating on TTL levels only then resistors R3 and R4 can be omitted. The output of IC1 will go high when there is a voltage level greater than 2.4 volts present at the input. Similarly, the output of IC2 will go high when the input level is less than 0.8 volts. The outputs from the two compara- tors are fed to a pair of retriggerable monostable multivibrators contained in IC3 (the pulse stretchers). These provide a pulse with a fixed duration to turn on transistors T1 and T2 and light the respective LEDs. These pulse stretchers are included so that no matter how short the input pulse is it will still be seen by the human eye. The pulse duration is deter- 5 v(+ mined by the values of R8/C1 and R9/C2. If the input signal is relatively long then the associated bypass diode takes over to ensure that the LED is lit for the length of the input pulse. In the circuit diagram, the upper LED (D5) indicates the presence of a positive pulse while the lower one (D6) indicates the presence of a negative pulse. Capacitor C3 is included to ensure correct power supply decoupling for IC3. H 41 There are many occasions when an analogue voltmeter is superior to a digital voltmeter. In certain circum- stances, the swing of a needle across a scale reveals more about the response of, and trends within, a circuit than a number of digital spot measurements. The main trouble with multi- function meters, such as the trusty 'Avo 8', is that they have a low input impedance that presents such a large load on the circuit being measured as to make the readings totally simple analogue meaningless in some applications. It was decided, therefore, to see how the latest semiconductor devices could be used to provide the Avo 8 with a very high input impedance and a full scale range of 25 mV. Any text book will show that the classic way of achieving this is to employ an operational amplifier set to a suitable gain with a couple of resistors, and a further resistor to limit the current into the meter to prevent damage in the event of an excessively large input being applied. voltmeter All circuits of this type incorporate a 'set zero' potentiometer to enable off-set voltage produced by all normal op-amps to be trimmed out. In this design, it was decided to employ one of the new Intersil CA2 (commutating auto-zero) operational amplifiers to eliminate most of the disadvantages of the classic circuit. Each CAZ amplifier consists, in fact, of two amplifiers which are arranged so that when one amplifier is processing a signal, the other is maintained in an auto-zero mode. elektor july/august 1980 7-31 The result of this is a long term off- set voltage drift of 0,2 /nV per year and a low input bias current of only 300 pA. The final circuit, as shown above, provides a choice of four full scale ranges: 250 mV, 2.5 V, 25 V and 250 V. The diodes D1, D2 and 03 protect both the CAZ amplifier and the meter from damage in the event of overload. The circuit will work at power supply voltages between 5 V and 9 V. Obviously, it is sensible to com- promise in circuits of this type between high input impedance and the possibility of stray pick-up. For example, the CAZ amp used would be quite capable of providing a 1 mV full scale range and an input impe- dance of 100 MJ2. Such an instrument would be capable of indicating the difference in length between the two test leads! For practical reasons, however, the input impedance has been limited to 10MJ2 and the full scale deflection to 250 mV which is more than adequate for most applications. For the best performance only highest quality components should be used and, while the circuit is fairly robust, exposure to overload conditions should be limited. Technical design note from Rapid Recall Ltd. H simple 555 tester The versatile 555 timer 1C has the habit of turning up in wide variety of circuits. As it is such a useful little device it has become very popular over recent years. Although the 555 is generally very reliable, there are occasions when malfunction does occur. The circuit shown here will provide a simple and effective method of testing suspect devices. The timer to be tested, I Cl , is con- nected as an astable (free-running) multivibrator. When the 'push to test' button (SI) is closed capacitor Cl will start to charge up via resistors R1 and R2. As soon as the voltage level on this capacitor reaches the trigger point of the timer the internal flip-flop is activated and pin 7 is taken low to discharge Cl. The flip- flop is reset when the voltage on Cl reaches the threshold level of the 1C. This takes pin 7 high and the charge cycle starts once more. The output of the timer (pin 3) is connected to a pair of light-emitting diodes. When the output is high LED D2 will be on and D1 will be off. Conversely, when the output is low D1 will be on and D2 will be off. The LEDs will flash on and off alter- nately — provided, of course, that the 1C under test is a good one. For readers who may have other applications for the circuit and who wish to alter the frequency, the rate at which the LEDs flash is deter- mined by the values of R1, R2 and Cl. The frequency of oscillation can be calculated from the formula 1.44 f “ ( R 1 +2R2) x Cl If, as in this case, the value of R2 is much greater than the value of R1, the frequency can be approximated from the following: For the values shown in the circuit diagram the frequency works out to be around 0.5 Hz. The tester can be made very compact by soldering all the components directly to the 1C test socket, which is first mounted through a hole in the upper surface of the box or container to be used. Alternatively, the components can be mounted on a small piece of Vero-board or similar. Current consumption is minimal and the unit can be powered from a single 9 V battery. K Many multi-band receivers and cheap communications receivers have a bandwidth compatible with the popular broadcasting stations which is too wide for amateur radio purposes. Narrow band receivers or — even better — receivers with an adjustable bandwidth are usually only found in more expensive systems. In order to be able to listen to amateur radio transmissions (SSB and CW) without too much inter- ference, on a broad band receiver, this ingenious audio band filter may provide a solution. It is a state variable filter, that is one in which both the centre frequency and the bandwidth can be varied. If the filter is placed before the existing AF amplifier, it will be possible to attenuate any interference signals by tuning the filter as accurately as possible to the frequency of the received audio signal. It is of course no comparison to a 'real' narrow band receiver, but the result is usually very satisfactory. The input filter consisting of Cl, C2, R1 and R2 is adequate to reduce the range of the available audio spectrum. The 6dB points of this filter network are at 500 Hz and 3400 Hz. Opamp A1 acts as a buffer between the input filter and the state variable filter proper. The latter is constructed around the remaining opamps A2 . . . A4. The Q of the filter and thus the bandwidth can be adjusted by means of PI (control range: 1 50 mA or Tr = 1 x 12 V/14 V/> 50 mA Many electrical appliances in the home have become so automated that it is no longer necessary to switch them on and off manually. Unfortunately, this also means that you have no idea how many units of power (KWh) they are consuming. To find out how long the central heating system has been reducing the level of oil in the tank (black gold nowadays) or for how long the compressor of the fridge has been running, an 'operational hours' counter would be ideal. The simple energy meter described here totals the individual operation times up to twelve hours. The actual 'meter' is a car clock which runs on 6 or 12 volts. Which of the circuits is used (figures 1 and 2) depends on the operating voltage of the clock. The complete circuit is connected in parallel to the device to be monitored and will only work when the device is operating. As the maximum operating time of the clock is 12 hours it should be 'read' regularly and the reading logged. The clock can then be reset. The majority of car clocks have an internal switch that is closed when the clock is at rest. Since this will present a virtual short circuit across capacitor Cl it will prevent it from charging up when the circuit is switched on. It is for this reason that the thyristor has been included. Once the clock has been given a suitably sized 'kick' the internal switch will open and close with the mechanical movement to keep it ticking. Capacitor Cl is charged via resistor R1. After about 10 seconds the volt- age across Cl will be 6 or 12 volts (depending on which circuit is used). The zener diode will then conduct and trigger the thyristor to supply the car clock with the required current. Virtually any 200 V/2 A thyristor can be used. K. Fietta M 7 60 elektor july/august 1980 private telephone exchange There are many old telephones around which still look and work fine and which are often put up for sale at a reasonable price. However mundane the use of a telephone is nowadays, secondhand telephones are always fun to have. They are even better of course, if they can be used as a house 'phone. The circuit given here shows an exchange for up to nine telephones. They all have a single figure number. However, only one connection between two 'phones can be made at any one time. When the receiver is picked up, a continuous tone will be heard. After dialling the number of another phone it is heard to ring. The 'bell' inside the phone is operated when its number is dialled from another 'phone. 1 © II © © © 2 elektor july /august 1980 7-61 The circuit consists of two sections. One acts as an exchange (figure 2), whereas the other is required by each phone (figure 3). Use has been made of CMOS ICs so that the current consumption will be minimal. The power supply is included in the central section. Two of the four phone connections are used. The connections are usually marked 'a', 'b', 'EB' and on the telephone's plug or inside the phone near the terminal strip. Points a and b are of interest to us. Figure 1 shows how they are connected in various situations. Figure la illustrates what happens when the receiver is still on the hook. By means of the internal switch the bell is connected to leads a and b via a capacitor. When an alternating voltage is present, the phone will ring. Direct voltages have no effect. In figure 1b the receiver has been picked up without the dial being touched and the handset is connected to points a and b. Figure 1c shows that during dialling (once the receiver has been picked up of course), points a and b are short circuited while the dial is turned clockwise. When it is allowed to run back, the situations shown in figure 1c and Id take place alter- nately. In the latter case the switch is opened for 62 ms (Id) and closed for 38 ms (1c). The number of pulses which are obtained corresponds to the number dialled. The circuit given in figure 3 is built once per phone. First it detects whether the receiver is off the hook or not. This is done with the Schmitt-trigger consisting of gates N1 and N3. The input voltage is fed to them by way of a low-pass filter (R1/C1) to remove any interference. The receiver will be detected as 'off' when the voltage across Cl is lower than 6 V. Only when the voltage rises above 8 V will the receiver be 'on'. If the receiver of one of the extensions is off the hook, line ZA will be high. The flipflop (IC2) detects whether the receiver was lifted to answer the phone or to dial a number. As long as the receiver is 'down', the flipflop is set. When the ZA line becomes high, because the caller picks up the receiver, the signal is delayed by R4/C4 and passed to the clock inputs of all the flipflops. The flipflop of the extension with the receiver 'off' is the only one to be reset. Then it is possible for N5 to detect dial pulses. At the same time the Schmitt-trigger (N1/N3) is inhibited via N2 (otherwise it would be clocked by the dial pulses). At the phone which is called point a is connected to the ringing tone voltage by way of the relay contacts (UK) once the dial pulses have 3 finished. All receivers that are off the hook are then connected to the central 'speech' current source (ZV) by means of a diode. The last NAND gate (N4) pulls the VG line low as soon as a second receiver is picked up. The central part of figure 2 only accepts pulses lasting longer than 25 ms as dialling pulses. The distinc- tion is made with the aid of the monoflop (IC4) and the AND gate (N4). Real dialling pulses are counted by IC2. Outputs Q1 . . . Q9 are connected to N6 of the extension circuits. The end of the dialling pulse flow is detected by a second mono- flop when no more pulses have reached this half of IC4 for at least 120 ms. The D type flipflop follow- ing it detects two conditions, 'dial logic is activated' (Q =12 V) and 'dialling complete' (Q = 0V). It is set when all receivers are 'down' (ZA = 0 V), or when a number is dialled which does not belong to one of the extensions. By way of N1, the second D type flipflop is set (Q = 0 V) long enough to reset the counter IC2, and to take up the output position again. The ringing tone control voltage (Kl) is generated by an oscillator consisting of two NAND gates (N5/N6). This starts up when the flipflop switches to dialling complete, and stops when a receiver is lifted (VG becomes 0 V). The frequency of the dialling tone generator (a NOR and a NAND gate, N9 and N8), can be altered to suit personal taste by changing the values of C8 and R11. The oscillator only works if at least one of the receivers has been lifted and if either the flipflop is on 'dial logic is activated', or if a ringing tone control voltage is available. The dialling tone is mixed with the speaker current produced by T1 and appears at ZV. The short circuit current at ZV must be preset with the aid of PI to between 10-20 mA. A simple 12 V stabiliser may be used for the power supply. The most important aspect of the transformer is that it must produce a voltage higher than 14 V at the maximum amount of speaker current to be produced. Otherwise a disturbing buzz will be heard. The ringing tone voltage is derived from the secondary transformer voltage by means of a large capacitor. CIO should not be an electrolytic (an MKFI type capacitor is preferable). This circuit is intended for personal use only and must not be connected to existing G.P.O. lines. G. Wieser H 7-62 elektor july/august 1980 1C tremolo 15 V Many of the familiar tremolo effect circuits (periodic amplitude modu- lation) suffer from three main disadvantages. Both distortion and modulation deviation frequently occur and the modulation fre- quency range is sometimes limited. The following circuit allows for a modulation depth of 0% . . . 100% and is relatively distortion free. It is a stereo version, that is it has two channels, and it can simulate the Lesley effect (rotating loudspeakers). Basically, the circuit is quite simple. The TCA730, IC2, is an electronic balance and volume control with built in frequency compensation. Balance and amplitude are normally adjusted with linear potentiometers. If these are replaced by a varying signal source, a periodic modulation of the input signal takes place. The varying signal is derived from the XR 2206 waveform generator, IC1. Although this 1C is capable of producing sinusoidal, square and sawtooth waveforms, for the pur- posesof this circuit only the sinewave signal is of interest. The modulation frequency can be varied with potentiometer PI as required from 1 Hz to 25 Hz. The squarewave output of the XR 2206 is used to drive a PNP transistor, T1 , so that an LED can provide an optical indication of the modulation fre- quency. The internal frequency compensation of the TCA 730 (pins 1 ... 7) remains unused. The sinewave amplitude level can be adjusted by P2, thus con- trolling modulation depth. The degree of balance can be adjusted with P3 (to produce the Lesley effect). Little needs to be said about the power supply. The 7815 voltage regulator solves all the problems. It is not advisable to use an unstabil- ised supply as the modulation in the circuit would cause current fluctuations on the supply line. This will then cause deterioration of the modulating sinewave. The supply transformer should have a secondary winding of 15 ... 18 volts at about 120 mA. The voltage regulator requires a heatsink in the form of an aluminium plate of about 10 cm 2 . T. Stohr H electronic magnifying glass Rectification is usually a question of removing the negative half-cycle (during positive rectification) or the positive half-cycle (during negative rectification) of the alternating volt- age. The reference for the resultant voltage then becomes 0 V. However, the reference level can be any other positive or negative voltage as required. This is done by removing everything above or below the reference level. An example of this is the circuit in figure 1. It is a precision rectifier which allows all of the input signal, Uj, through un- changed provided it is above the reference voltage Ur (figure 2a). Negative rectification is also possible (figure 2b). All that is required is to change the polarity of diodes D1 and D2. The reference voltage can be elektor july /august 1980 7-63 1 . Ui OOHF C3"*"100n I b o S o-r -12.. -15 V preset by potentiometer PI. The circuit works accurately enough for frequencies up to 20 kHz. What can you do with it? You can make an electronic magnifying glass. Supposing a relatively small portion of the alternating signal is to be examined in detail on an oscilloscope. Increasing the gain of the oscilloscope may produce the required enlarged area, but — apart from unpredictable overdrive — the DC shift range could A1.A2.A3 = IC1 =3/4 TL 084/3x LF 356 be insufficient to obtain a clear view of the signal in as much detail as needed. Why not then just feed that part of the signal in which we are interested to the oscilloscope. In order to examine the amplitude stability of an oscillator, a positive rectifier is used with a reference voltage preset to a level just below the peak level of the signal. To look at negative extremes a negative rectifier is required. To 'magnify' an area somewhere between the two extremes a positive and a negative rectifier are connected in series. The value of PI may be anything between 1 k and 1 M. It is important that the reference voltage be suf- ficiently accurate and stable. If necessary, a multi-turn potentio- meter can be used for PI . ** 66 acoustic ohmmeter 1 80590 - 1 There are many instances where it is necessary to test electrical con- nections, for instance, cable networks, the wiring of connectors, and the various interconnections on a printed circuit board. These tests can be carried out with an ohmmeter, but it is often impossible to keep an eye on everything at once, for while watching the meter dial you have to make sure that the test probes do not short anything out. One solution is to construct a simple test circuit which produces a sound when the connections are shorted and which remains silent when the test probes are an open circuit. This permits numerous possibilities. The simplest version which uses a small transformer and a bell is shown in figure 1. The problem with this circuit is that large amounts of current can be produced which could prove too much for the circuit being tested. By replacing the bell with a small loudspeaker and suitable series resistor the current flow can be limited to below 1 mA. This is shown in the circuit diagram of figure 2. The transformer secondary voltage is full-wave rectified by diodes D1 . . . D4 to provide a 100 Hz signal for the loudspeaker. When the base of T1 is connected to R1 (testing for a short circuit) the two transistors will amplify the signal to produce the required tone. 7-64 elektor july/august 1980 armless bandit For most of us, giving money away is very easy, all that is required is a car! For many others the odds need to be a little shorter. They use a 'one armed bandit', or 'fruit machine', or 'three in a row', or 'jackpot'. Call it what you will they all do the same job — part you from your money. A number of rolling drums induce a hypnotic trance in the victim reducing his number of movements to two, inserting coins with the left hand and pulling a lever with the right with only one known surefire cure — atmospheric pockets! Yes, we know that they pay out because the person before you proved it (and so will the one following you). With this circuit it is possible to work out the sequence all day long without touching a single coin. We have even taken out the all too familiar ache in the right arm. It operates with a total of 27 LEDs in three rows of nine. It might be advisable to mount the rows above each other and number the LEDs in each row 1 ... 9. Touching the sensor plate cause the LEDs in the three rows to 'run'. Then, on releasing the touch plate, one random LED in each row will remain N48, N49 = IC16 = 4002 N50 . . . N52 * IC17 = 4011 elektor july /august 1980 7-65 lit. If these happen to be three LEDs with the same number, a buzz announces that you have won. Although the circuit diagram looks a little complicated, its operation is quite simple. If the touch contacts, SI , are bridged, transistors T 1 . . . T3 start the three oscillators constructed around N1 . . . N9 which provide the three decimal counters (IC1, IC2 and IC3) with clock signals. The outputs 0 ... 9 of these counters will then go high one after the other. Although the drawing has been simplified, each output (except for output 9 which is used as a reset) is connected to a buffer/series resistor/ LED combination such as N10/R8/D1 etc. Thus we have three rows of LEDs which run continuously until the touch contacts are released. When this is released, the oscillators continue for a certain period of time determined by the RC networks connected to each transistor collector before stopping. One output from each of the counters will remain high and (any) one LED from each row will light. If the three LEDs happen to have the same number, the comparator circuit built around N37 . . . N49 will detect this and turn on transistor T4. The oscillator constructed around N51, N52 will than start up and, via T5, will cause the loudspeaker to 'buzz'. B. Jouet H the STAMP Super Tiny AMPlifier It has nothing to do with the mail, but it is small enough to go through it. This circuit is a versatile, miniature amplifier and loudspeaker combi- nation that can be used in the tightest of electronic corners. The Super Tiny AMPlifier uses only one 1C, a loud- speaker and eight other components. It measures two square inches and has an output of 200 mW or more. As if this is not versatile enough, the gain can also be preset (or switched). Frequently, small projects require an external amplifier of equally small proportions. Finding a suitably sized circuit can present some difficulty. This problem can now be 'STAMPed' out. Here is the circuit, Elektor can supply the printed circuit board - all you have to do is 'stick a STAMP on it'! The circuit is so simple that it hardly needs any explanation. It is based on the LM386, IC1. This is produced in a variety of specifications and table 1 lists the major differences, output power and supply voltage being the most significant factors. The gain of the amplifier is set by the components between pins 1 and 8 of the 1C. With both R1 and C2 included (in series) the gain is set at 50. Excluding these two components sets the gain at 20. For the maximum gain of 200, C2 is included and R1 is replaced by a wire link. The loudspeaker is the limiting factor of the output power if size is the major consideration. The printed circuit board was designed so that, after cutting the hole out of the centre, the board can be mounted over the magnet of the speaker. This of course, means that only the smallest of speakers would be suitable limiting the power output to 200 mW. However, there is no reason why a larger loudspeaker can not be used and the STAMP stuck (with double-sided tape) on or near it. Table 1 should be referred to in this case. We will be using STAMPs more often in future projects. For handy, low power, compact applications, put a STAMP on it. Technical data of the LM 386 Operating supply voltage LM 386 N 4 ... 12 V LM386N4 5 ... 18 V Quiescent current (Ug = 6 V) typ. 4 mA Absolute maximum input voltage ± 0 .4 V Input resistance typ. 50 k Output power (THD = 10%) LM386N-1 U B = 6 V 325 mW LM386N-2 U B = 7.5V R L = 8ST 500 mW LM 386N-3 U B = 9 V 700 mW LM386N-4 U B = 16 V R L = 32 fi 1 W Absolute maximum package dissipation (at 25°C) LM 386 660 mW LM386A 1 .25 W Parts list R1 = 1 k2 (see text) R2 = 10 n PI = 10-k -preset potentiometer Cl = 100 n C2.C5 = 10 m/25 V Tantalum (see text) C3 = 47 n C4 - 220 m/16 V LS = loudspeaker 8 H/0.2 . . 1 W Although 'apocalypse' doesn't sound like very much fun, this game cer- tainly is. It is a game which combines speed, reaction, skill and fun all into one package. It is simple and in- expensive to construct and uses just five CMOS ICs which help to keep the power consumption down. This, together With an automatic LED shutdown, means that if the game is made portable the batteries should last for a relatively long period of time. The unit has two 'touch plates' which control the game. When the 'START' plate is touched the output of N1 will go high to trigger the monostable multivibrator formed around N2 and N9. The output of the MMV will then go high for about 5 ... 10 seconds (determined by the values of Cl and R2) thereby reset- ting the two counters IC4 and IC5 and lighting the 'WATCH IT' LED D5 via N12. The 'STOP' plate will also be enabled via N4 and the flipflop formed by N7 and N8. At this time the output of N7 will 2 80623 -2 be low thereby enabling the two counters. The counters are clocked (when the reset line goes low and the 'WATCH IT' LED goes out) by the oscillator formed around N10 and Nil. Preset potentiometer PI determines the frequency of oscillation and, therefore, the speed of the game. As each counter output goes high the associated LED will turn on. The Q 0 output of the first counter is fed to the clock input of the second so that as soon as the first counter reaches its limit it returns to 'zero' and clocks the second counter. If no action is taken the Q 9 output of IC5 will eventually go high and trigger a second monostable formed around N3 and N6. The output of this monostable will then go high for about 5 ... 10 seconds and, via N14, light the 'PITY' LED D18. The Q 9 output also takes the clock enable line of the two counters high via D3 thereby inhibiting the count. When the output of the second MMV goes low all the LEDs will go out and the circuit will be ready for another attempt. The count is also stopped via D2 and the flipflop N7/N8 when the 'STOP' button is hit. The LEDs will then indicate the state of the count — or elektor july /august 1980 7-67 the number of people killed in the attack. If, on the other hand, the 'STOP' button is pressed while the output of the first monostable (N2/N9) is still high both inputs of N5 will be high and the 'TOO EARLY' LED, D24, will come on. Playing missile attack After power has been applied the 'START' plate is touched. Immedi- ately the 'WATCH IT' LED comes on to indicate that the enemy are about to launch their attack. After a certain amount of time the 'WATCH IT' LED will go out and LEDs at the outputs of IC4 and IC5 will start to count at an incredible speed. The object of the game is to hit the 'STOP' button as soon as possible. When hit, the 'STOP' button launches your anti-attack missile. If you react fast enough only a few millions will die but if you are too slow the world will be destroyed. The number of casualties is indicated on the LED display. The outputs of IC4 give the 'hundreds of thousands' while the outputs of IC5 indicate the 'millions'. If your reaction was too slow the 'PITY' LED will light and the end of the world will be entirely your fault. If you are too hasty the 'TOO EARLY' LED will light. This is also unfortunate as you only have one missile which is powerful enough to defend you against the attack. Good luck. K. Siol H voltage controlled harmonic generator A voltage controlled harmonic gener- ator is a particularly useful device for music synthesisers as another means to achieve sound synthesis. The circuit presented here was designed to be used with the Elektor Formant music synthesiser, but the idea can be used in many other applications, such as generating harmonics for a guitar etc. Following the true Formant trad ition, the circuit utilises a mixer with three inputs having a nominal input sensitivity of 2 V p-p. Once the input level is correct the output signal from IC1 is clipped by Rq and D1. The clipping level can be controlled by a voltage fed into the modulation input ECV, from a low frequency oscillator (LFO) for instance. The clipped and unclipped signals are then subtracted by the differential amplifier IC3. The result depends on the level of unclipped signal which is preset by P2. Figure 2 shows 2 • ./V\ 8 521 - 2 examples of the resultant output signal with large (2a) and small (2b) levels of unclipped triangular wave input present. The waveforms at various points in the circuit are given in figure 3. From top to bottom they are: A : input signal B : clipped signal C : attenuated input signal D : difference signal (B-C) = output signal If the threshold levels of the triangular input signal are symmetri- cal, the harmonic generator will produce a frequency doubling effect. A pulse width modulated squarewave input can be amplitude modulated by controlling the clipping levels with a suitable ECV signal. When used with a guitar the unit will then produce an effect similar to phasing. M. Bertuch M 80521 - 3 7-68 elektor july /august 1980 knock switch And now for something different . . . Over the years, all kinds of wired and wonderful switches have found their way into the pages of this magazine: touch activated switches, clap switches, temperature sensitive switches, and so on. But never one like this: it switches when you knock it! (Don't bother to write in that you already have several mechanical switches that also require a good clout now and then. We have the same problem). No real blow is needed for this one, however: a light tap is more then enough. The 'knock sensor' is a common-or-garden choke coil, or a plate with the choke mounted on it. Don't knock this idea before you think it over - we can think of any number of possible applications. For example: since modern pop music is going more and more electronic every day, this switch may prove ideal for use with an electronic drum synthesiser. It can be operated with a drumstick! So how does it work? The core of a choke is made of ferro-magnetic material. This type of material contains a large number of small zones where all magnetic dipoles point the same way (so-called Weiss zones). The energy required to rearrange these zones is very small indeed — a gentle tap will do the trick. This, in turn, causes a tiny voltage to be induced in the coil; with some amplification and pulse shaping this provides a good control signal for an electronic switch. To illustrate the principle, we knocked up a test circuit. The block diagram is given in figure 1. The knock sensor, a 68 mH choke, is used as part of a resonant circuit that is tuned to a fairly low frequency (about 3 kHz). A higher frequency could also be used, but 3 kHz has the advantage that the following amplifier (A) can be a very simple low- frequency type. The boosted signal is squared up in a schmitt-trigger, and used to trigger a monostable multi- vibrator (MMV1). The output from 80667 - 2 elektor july /august 1980 7-69 the latter drives a second monoflop (MMV2) and two flipflops connected in series. All this extra luxury at the output side greatly enhances the range of effects that can be obtained when demonstrating a circuit— and that was the whole object of the exercise. What happens is that FF1 is clocked each time the sensor is tapped; FF2 is clocked on every other knock; MMV2 provides a stretched output pulse after each tap, and is also used to reset FF1 . The actual circuit is given in figure 2. The sensor circuit proper is quite simple - all the muddle to the right of the dotted line is the 'demonstration' circuitry. As mentioned above, the sensor coil is a 72 68 mH choke coil, LI. Its output is amplified by T1, T2 and IC1. IC2 is the schmitt-trigger; PI the sensi- tivity control. The two MMVs are contained in IC3, and the two flipflops correspond to IC4. The one-shot time of MMV2 can be set by means of P2. The flipflops and MMV2 each drive a buffer stage which controls a relay and an LED. That's what they call an 'audio-visual display', when they want to confuse you with long words. Assuming, of course, that you use relays which pull in with a loud and satisfying 'click'. Ideal for demonstration purposes. Ask anyone who ever rigged an AB test for loudspeakers. A few more practical remarks. The selective CW filter actual value of the choke is not really critical. However, it's a good idea to make sure that it's not one of those high-class jobs where the core is mounted in shock-absorbing material (foam rubber, in practical terms). That sort of thing does nothing to improve sensitivity. We would not like to have bruised knuckles on our conscience. Furthermore, it should be noted that the switch is also sensitive to strong magnetic fields. Power transformers, electric motors, and so on. Apart from that, this switch has everything going for it: it's reliable, sensitive, and different. Come to think of it, that's what editorial staff try to be. But we don't like to be knocked. M Certain requirements must be met when designing CW filters (CW = carrier wave — basically, u nmodulated morse telegraphy). The response curve must be sufficiently narrow to permit as little QRM as possible, but must be wide enough to overcome receiver drift. It must also be phase linear within the bandwidth. Readily available filters usually have a bandwidth in the order of 500 Hz (6 dB points) and give approximately 60 dB attenuation at around 1 to 2 kHz. In many instances CW signals are insufficiently filtered, so that ringing can often occur in the receiver. A filter with a very high Q allows for maximum selectivity, but is, of course, totally unsuitable for this application. The filter must also be easily reproducable, without any trimming if possible, and the cost must be kept to a minimum. The circuit shown here fulfils all these requirements and has a com- paratively low centre frequency thereby reducing any effect that component tolerances would have at higher frequencies. It was decided to incorporate LC filters in the design as they are superior in operation to RC networks. The coils used need not be of any special quality, virtually any 100 mH choke coils will suffice. Differences in the signal amplitude of normal receiver filters can be considerable as they are usually more than one CW station 'wide' and the automatic gain control (AGC) may cause the filter to 'pump'. For this reason a limiting circuit (D1 and D2) is included at the input of the filter and a further logarithmic limiter (D3 and D4) is included at the output stage. The audio image signal still needs to be eliminated and this is only possible after the IF signal has had special treatment. This circuit is virtually indispensable when it comes to displaying CW signals with the aid of a micro- processor and a TV. The filter then only needs a simple interface circuit. The photo clearly shows the fre- quency characteristics of the filter circuit. The horizontal scale is 200 Hz per division for both curves. The centre frequency of the filter is around 600 Hz. The narrow curve has a vertical scale of 1 dB per division while the broader curve has a scale of 10 dB per division. M 7-70 elektor july /august 1980 RAM tester 5 V One of the most popular memory ICs at present is the 2102 — a 1 k random access memory. In spite of its popu- larity, a simple tester for this type of 1C is virtually unknown. The circuit described here does the job easily — and cheaply. The operation is quite straight- forward, as illustrated in the flow chart given in figure 1. First a 0 is written into all memory locations, after which the 1C is switched into the 'read' mode to check whether there is indeed a 0 at each address. If a logic 1 is found anywhere, a red LED lights to indicate that the 1C is defective. Assuming that no fault is found, however, the next step is to write a 1 into all memory locations. Once again the memory is scanned, this time to check whether all addresses give a logic 1 ; a 0 anywhere in the memory causes the red LED to light. Seven ICs are used in the circuit (not counting the 2102), as shown in figure 2. Starting at the lower right, a schmitt-trigger inverter (N12) is used as a simple oscillator. It drives three BCD counters (IC5 . . . IC7), con- nected in cascade. This produces a 12-bit binary output, the first 10 bits of which are used to address the 1024 memory locations in the 2102. The last two ('most significant') bits are fed to the A and B inputs of a 74155. This 1C contains two '2-to-4 decoders' (only one of which is used) : each of the four possible combi- nations of input data at pins 3 and 13 cause one of the outputs (pins 9 ... 12) to go 'low'. These outputs are used to control the 2102 and the test logic. Assuming that initially all 12 outputs from the counter chain are low, pins 3 and 13 of IC4 are also low. This causes pin 9 of IC4 to switch to logic 0 — pulling the data input of the 2102 low and (via N1 and N9) switching it to the 'write' mode. During the first 1024 counts, all memory locations in the RAM are therefore set to 0. At the next count, pin 13 of IC4 is pulled 'high' so that pin 10 goes 'low'. The 2102 is switched to 'read', and its output (pin 12) should remain zero for another 1024 counts. If this is the case, well and good: the outputs of N2 and N3 will both remain at T and the green LED will be lit. How- ever, if a logic 1 appears at pin 12 of the 2102 this will cause N3, N4 and N1 1 to switch — setting the flipflop (N5/N6) and lighting the red LED. During the third count period, pin 1 1 of IC4 will be low. This causes 'ones' to be stored at all memory locations. Finally, the 1C is once again switched to read and the output is checked (via N10 and N2) to make sure that it remains at logic '1' during the complete count. After the fourth count series, the complete cycle begins from scratch. The complete test sequence takes very little time (milliseconds!). Basically, therefore, to test an 1C you plug it in — switch on the power — operate the reset button (SI). If the green LED lights, and stays on after you release SI, the 2102 is a good one. T. Obermair M elektor july/august 1980 7 71 low-pass filter Notch characteristics: - 6 dB : 2.8 kHz — 40 dB : 6.5 kHz -60 dB : 8 kHz ripple : 1 dB 8kHz 65kHz Most communication receiver de- signers assume that 'anything above 3 kHz can be cut out' and sometimes a series of four RC filters in a row are given in the receiver. It is obvious that frequency characteristics drop- ping by 12 dB or more at frequencies between 2.5 and 3 kHz are far from ideal. The real object of the exercise is to remove the broadband noise without affecting the frequency characteristics within the range re- quired. In other words, it is better to remain at 1 dB with as sharp a cutoff as possible after 2.5 or 3 kHz. The configuration described here already fulfils this function with only one section. The circuit contains AM, medium-fi: C2 = 6n8 C3.C4 = 10 n R L = 10k C5 = 33 n Notch characteristics: — 6 dB: 6 kHz -54 dB: 9 kHz ripple: 1 dB nothing but a single 1C and a few other components. Although it ap- pears to be decoupled through C5, this is in fact not the case, because the input circuit is part of the star formed by C3, C4 and C5 (bootstrap principle). TOKO manufacture coils with a presettable core and when these are used the notch can be tuned to the desired position. M cheap seconds Those of you who study advertise- ments will have noticed that minia- ture crystals for watches are much cheaper nowadays. These crystals are almost invariably tuned to 32.768 kHz, and for a good reason — it is quite easy to derive a 1 Hz signal from this frequency, since it a simple power of two (2 IS ) . Add to this knowledge the fact that the 1C type 4060 contains a 14-bit divider stage and oscillator section, and you can put two and two together . . . The watch crystal is eminently suitable as frequency- determining element for the oscil- lator. If the maximum division ratio of the divider stage is used <2 14 ) , the result is a 2 Hz output. Getting close . . .To bring this down to the mother of all timing intervals one-pulse-per-second, a single flipflop must be added; half of a 4013, say. The output from this flipflop is a 1 Hz signal, swinging between 0 V and positive supply. Life would be beautiful, if it weren't for component tolerances. Crystals need trimming — which is where C2 comes in. For absolute accuracy, a frequency meter is required. Connected to pin 9 of 1C 1 , it should read 32.768 kHz. H 7-72 elektor july /august 1980 hexadecimal keyboard sv ©- T IC2 Z T ICS z d) IC3 Z ~d) IC4 This circuit consists of an encoder which scans each key of the keyboard independently and then converts the data into a four bit binary number. The scan frequency is determined by an internal oscillator and a single external capacitor. Contact bounce is eliminated by a time delay of 22 ms. When a key is depressed, the DA output of IC1 goes high after this delay (DA = data available). The AND output goes low again when the key is released. The DA output clocks IC2 (via N2) causing the data at the inputs of IC3 to be transferred to its outputs. As soon as the second key is depressed, IC2 is again clocked and its outputs change state so that IC4 now holds the corresponding key data. At the sametime, the 'FULL' LED will light. The keyboard information appears at the outputs of IC1 150 ms after the DA pulse. For this reason the clock pulse for IC2 is delayed. This is accomplished by utilising the input capacitance of the NAND gate, N2, and a resistor, R1 . When the LED lights to indicate 'FULL', switch SI is depressed. The D4 output of IC1 will then go high generating a STROBE pulse at the output of N1. This is also the reset signal for IC2. The delayed clock pulse therefore has no effect. As soon as SI is released. IC2 is cleared and waits for the next clock pulse. Both positive and negative going strobe signals are available for various control applications. F. Burmester H small jjP switching supply Switching power supplies have a number of advantages over the more conventional types. Less heat dissi- pation and a greater efficiency lead to a smaller physical size for a given power requirement — and that is the emphasis in this particular article. The 5 V switching power supply described here is able to supply up to a maximum of 1 amp. It uses the National Semiconductor LM 3524 pulse width modulator. This device oscillates at 20 kHz, just above the audible limit, and controls the 5 V supply by varying the switched 'on' time duration of the series pass transistor T2. For this transistor, a somewhat faster device should be used but, since cost rises with speed, it is not over significant for our purposes. The same is also true of diode D1. The current through both Parts list Resistors: R1 . . . R3.R10 = 4k7 Semiconductors: R4 = 6k8 D1 = fast 2 A diode (turn-off t R5 = 33 k < 300 ns) R6 = 0.15n T1 - BC 161 R7,R8 = 470 SI T2= BD 132 R9 = 100 n IC1 = 3524 Capacitors: IC2 = 78L12 IC3 = 79L05 C1,C2 = 2200 p/25 V B = bridge rectifier B40C2200 C3,C1 1,C12 = 10 m/25 V C4,C7 = lOOn Miscellaneous: C5,C6 = 10 n Trl = mains transformer C8 = 470 m/25 V 2x15 V/0.4 A C9.C10 = 330 n LI = 500 mH (see text) elektor july/august 1980 7-73 aossi T2 and D1 is never greater than 2 amps during normal operation. The coil for LI can easily be wound on a pot core with an air gap which is suitable for the frequency range applied (20 kHz). An 11mm long, 18mm0 N22 type from Siemens was used. The number of turns can be calculated from the following formula: n = vST When A|_ has a value of 250, 45 turns are required of a wire thickness that completely fills the core. For example, n = The 5 V stabiliser is protected against short circuits with the aid of the 0.1 5 fl resistor R6. This value can be made up if necessary using two 0.33 £2 resistors in parallel. In the event of a short circuit occurring, T2 will become much hotter than normal and it is therefore advisable to provide this transistor with a heat sink (although normally it would not need it). The +12 V and — 5 V stabilisers are conventional and intended as auxiliary supplies for the popular 2708 EPROM. M 500 x 10' 61 250 x 10 -9 7-74 elektor july/august 1980 variable pulse width generator This simple little circuit will find a great many uses where pulse width is critical. Opamp A1 is connected as a squarewave generator whose fre- quency can be adjusted by poten- tiometer P2. Let us assume that the output of the opamp goes high when the system is first switched on. Part of that output voltage is fed to the non-inverting input via the voltage divider R4, P2, R3. As long as Cl is not yet sufficiently charged, the voltage at the inverting input will be lower than that at the non-inverting input and the output will rema*in high. The moment that the capacitor is charged to such an extent that the voltage at the inverting input becomes greater than that at the non-inverting input, the output of the opamp will swing low. Capacitor Cl then starts to discharge until the voltage at the inverting input becomes lower than that at the other input, whereupon the opamp output will swing high once more. The mark-space ratio (duty-cycle) may be varied with potentiometer PI without affecting the frequency. This is done by making sure that the charge time is different (either greater or smaller) than the discharge time. Capacitor Cl is charged via part of PI, diode D2 and resistor R2, whereas it is discharged via resistor R1, diode D1 and the other part of PI. The sum of these two time constants will remain the same (as will the frequency) when PI is used to alter the mark-space ratio. M post indicator Has the postman been yet or isn't there any mail today? This question is asked daily by millions of people. As a rule, the answer is to go to the letterbox to have a look. The farther you have to go to find out and the emptier the letterbox, the greater your disappointment. The post indicator shows on four seven-segment displays whether it is worth the walk or not. Initially, the flipflop formed by N1 and N2 is reset and transistor T2 conducts causing the word 'NONE' to appear on the display. When the light beam to the LDR is interrupted (when a letter falls through the letterbox) T3 will conduct briefly and trigger the flipflop. As a result, T2 will turn off and T1 will turn on. The display will then show the word 'POST'. The circuit will remain in this state until the reset switch SI is pressed whereupon it will revert to its initial state. For reliable operation it is advisable to mount the lamp and the LDR as close possible to the actual aperture of the letterbox. Further to requests by frenzied members of the staff we are now designing a 'bill detector' which will automatically eject unwanted mail. 80510 H W. Korell elektor july /august 1980 7-75 80 Normally, a centre-tapped trans- former and a bridge rectifier is used to construct a symmetrical power supply. This seems such a natural solution, that people forget it can be done in a much simpler way. The accompanying circuit diagram shows the simpler version. A disadvantage is the single-sided rectification which makes it necessary to use a larger smoothing capacitor to prevent mains hum. With the values shown, a maximum of 10 mA can be supplied at a ripple voltage of about 0.2 V p . p . By using 81 One 1C and a single capacitor are the only components required for this circuit which will accurately measure the rms value of a given voltage. It enables a DC meter to be provided with AC ranges very simply. Figure 1 shows the circuit which has 'nothing to it' as far as construction is concerned. The 1C (AD 536) is designed specifically to carry out a complete calculation and determine the rms value of the input signal. On the one hand, the value of capacitor Cav determines the measurement accuracy at lower fre- quencies and on the other, the settling time that the circuit requires to achieve the indicated accuracy. Figure two gives an indication of how the value of Cav ' s chosen. If, for instance, the value of Cav is 4 /uF , it follows that the error at 10 Hz is 0.1% and at 3 Hz it is 1%. The settling time can be read from the right hand vertical axis of figure 2. For 4 pF the time will be 0.4 seconds. The choice of capacitor therefore depends on the require- simple symmetrical supply 16 V 1N4001 max. 10 mA the formula below, values for other currents and ripple voltages can be calculated. _ 20 • I Uripple q - (Uripple in volts (peak-to-peak), derived current I in mA and C in pF) M RMS to DC converter Specifications measurement accuracy (with Uj n = 7 V e ff ) Frequency range — for indicated accuracy — t 3 dB bandwidth Maximum input voltage Uj n Output voltage U out — ± 15 V supply — ± 5 V supply Supply voltage ± U s Input impedance AD 536J AD 536K ± 5 mV t 0,5% ± 2 mV ± 0,29 20 kHz 100 kHz 50 Vp. p 10 V 2 V ±3...± 18V 16.7 kn ments to be met: a short settling time, a small measurement error at a low frequency or a compromise. Figure 3 shows the minimum input voltage as a function of frequency at various measurement errors. The higher the rms value of the input voltage, the lower the error. The circuit is not only suitable for measuring AC signals, but it can also determine the rms value of a DC signal with an AC component. If only AC signals are to be measured, a capacitor should be connected in series with the input (now the circuit starts to become really complicated). It is also advisable to decouple the supply leads as close to the 1C as possible with 100 nF ceramic capacitors (see what we mean!). Analog Devices application note. M 7-76 elektor july /august 1980 running lights The running light circuit described here is by no means the first (or the last) to be published by Elektor, but it is one of the more interesting. The circuit has no less than eight channels, each of which can be independently programmed. The maximum power output per channel is determined by the specifications of the triacs used. As the lamps are switched on at the mains zero-crossing point, no inter- ference is generated, thereby elimin- ating the need for noise filters. Figure 1 shows the block diagram of the unit. Any eight bit code can be preset at the inputs of two shift registers by switches SI . . . S8. A corresponding LED will light when a switch is closed to give an indication of the state of the switch and there- fore the eight bit code. This preset data is then entered into the shift registers by S9. The shift registers are bi-directional and the position of S10 determines whether the data is shifted left, right or remains static. Data is shifted each time the registers receive a clock pulse. The clock generator is fairly versatile in that not only can the frequency of oscillation be varied, but also 'groups' of pulses can be obtained. This is done by turning one oscillator on and off by a second that has a much lower frequency. The result of this is 1 that the data appears to be shifted haphazardly. The outputs of the shift registers are connected to latches which will only operate at the mains zero-crossing point. A zero-crossing detector is included in the circuit to control the enable inputs of the latches. Each channel output has a monitor LED connected to it. The complete circuit diagram is 80560 1 shown in figure 2. Clock pulses are provided by the oscillator con- structed around N2. The position of S1 1 determines whether N2 is free- running (position 1) or whether it is controlled by the low frequency oscillator N1. The frequencies of the two oscillators can be adjusted by means of P2 and PI respectively. Four NAND gates (N3 . . . N6) are used for the zero-crossing detector. elektor july /august 1980 7-77 A CMOS 1C is used in this part of the circuit as the input voltage will almost certainly be outside TTL limits and the IC's inputs are protected by internal clamping diodes. Capacitors C3 and C4 ensure that a 25 /is pulse is produced at the output of N5 each time the input signal crosses zero. This pulse is used to control the enable inputs of the latches (IC3 and IC4) via N6 and Til. Data from the shift register outputs (IC1 and IC2) will then be transferred through the latches to the bases of transistors T1 . . . T8. When a latch output is high the corre- sponding transistor conducts, the LED lights and the triac is triggered. As mentioned previously, the power rating of the lamp(s) connected to each channel depends on the triac used. With the type shown in the circuit diagram a maximum of 8 A can be switched, but it is always advisable to work within large safety limits. However, about 1000 W per channel should be no problem provided the triacs are mounted on adequate heatsinks. Obviously, great care must be taken during construction and operation of the unit. It is directly connected to the mains! Each channel, therefore, should be provided with an earthed output socket and the entire unit should be mounted in a strong plastic box. Operation is quite straightforward. The desired pattern is selected by means of switches SI . . . S8. With S10 in the middle position (static display), the dqta can be entered into the shift register by pressing S9. The position of S10 can then be altered to give a running display (left or right as required). When S1 1 is closed the lamps will appear to 'hop' rather than flow smoothly. Potentiometers PI and P2 vary the speed of the resultant display. M voltage drop detector This circuit will generate an output pulse whenever the input voltage drops by more than 0.6 volt. Oper- ation of the circuit is very simple. As long as the input voltage remains constant or increases, the voltages at points A and B will be equal to the input voltage minus 0.6 V (due to the voltage drop across D1 and D2). In this condition transistor T1 will be turned off. If the input voltage drops, the voltage at point B will drop accordingly. The voltage at point A, however, will remain un- changed because Cl will be charged. When the difference in voltage between points A and B becomes greater than 0.6 V (in other words, the input voltage will have dropped by 0.6 V), T1 turns on causing Cl to discharge through R1 — generating an output pulse. M RS 232-interface Connecting peripheral equipment to computers is all very well provided the signal levels are compatible. This is not always the case and often some form of interface, to convert the signals from one level to another, has to be added. Certain require- ments have to be met as the output signals of most peripheral equipment conform to the RS 232 /V 24 standard. The interface shown in the circuit diagram is intended for use with the Junior Computer (PA7 and PB0 refer to the series input and output of the JC), but it can also be used with any other computer. The signals are converted to TTL from the RS232 level by transistor T1 and from TTL to RS232 by N1 and IC2. The latter are converted to a level of 24 Vp.p. 7-78 elektor july/august 1980 loudspeaker fuse Loudspeakers, like rules, are designed to be broken. Perhaps not entirely true but they do suffer an enormous amount of punishment especially at Rock concerts and festivals. Even if the rated power indicated on the loudspeaker cabinet is not exceeded, high frequency systems may die of heat, because DIN standard measure- ments do not correspond with the hearing habits of Rock fans. High sound levels, part and parcel of any form of Pop, can easily cause speakers to come to a bad end during continuous duty on 'full power'. It is also fairly obvious that high volt- age levels across the amplifier output will cause low frequency speakers to expire with an unwanted smoke effect. Often the fuses available inside the amplifier aren't activated until the post mortem. This article describes a novel circuit which will disconnect the loudspeaker systems before volt- age levels reach the stage where damage to the speakers could occur. The circuit will protect cabinets of up to 150W with an impedance of 8 Q and it is incorporated into the cabinet itself without a separate power supply being necessary. Figure 1 shows the complete circuit diagram of the loudspeaker fuse. The output signal from the amplifier reaches the loudspeakers via the relay contacts. In the event of overload or high DC voltage levels the relay disconnects the loudspeakers from the amplifier. The DC voltage is detected by two similar but comp- lementary circuits. The 'positive' level detector (T3 . . . T6) receives its supply via D19, R27 and C7 by rectifying and filtering the amplifier output signal. The 'negative' level detector (T8 . . .Til) is similarly supplied via D30, R29 and C8. The amplifier output signal is also fed via a simple integrator (R28/C9) to the inputs of both level detectors. If there is a significant DC level at the output of the amplifier either D20 or D21 will conduct depending on the polarity of the DC. The positive level detector is controlled by D20 and the negative one by D21. The sensi- tivity of these level detectors is approximately 6-7 volts. Once the DC level rises above this value one of the detectors will operate the relay. Which one is, of course, again dependent on the polarity of the offending DC level. The third part of the circuit consists of an overload detector which is shown on the left-hand side of the drawing. The multi-purpose circuit before the input of T1 enables the unit to be used in speaker systems with or without cross-over networks. Four channels are provided making the unit completely versatile, but it will be obvious that in some loud- speaker systems only one or two inputs may be needed. These inputs are in fact connected directly to the loudspeakers, that is after any cross- over filter(s) that may be present. After being rectified by D1 . . . D4 and filtered by Cl . . . C4, the signal is amplified by T1 and T2 to provide a DC control signal for the positive level detector. Some hysteresis is provided by T7 so that the amplifier will have to be turned down before the relay will drop out. Given the power rating of each individual loudspeaker (usually marked on it somewhere) the maximum AC input voltage can be calculated from the formula: U e ff = P • R where P is the power rating and R is the impedance. From this figure a percentage is taken for each input as follows: 3 . . . 6% for high frequency speakers (input R1) 10 . . . 25% for mid-range speakers (input R2) 50% for low mid-range speakers (in- put R3) elektor july/august 1980 7-79 100% for bass speakers (input R4) Once calculated, the AC voltage can be applied to the relevant input with the aid of a suitable multi-tapped transformer. The corresponding preset potentiometer is then adjusted until the relay operates. The two power transistors, T6 and Til, can be mounted on the same heatsink provided they are insulated from each other. Mechanical vi- brations are to be avoided and there- fore some form of isolation, foam rubber for instance, should be used when installing the circuit board. Furthermore, capacitors C7 and C8, the relay and resistor R41 must be fitted firmly to the board. The trimming potentiometers PI . . . P4 can be 'locked' with a drop of nail varnish once the unit has been calibrated. Resistor R41 was originally included as a load resistor for the output transformer of valve amplifiers when the speakers are disconnected. If transistor amplifiers are to be used the value can be reduced to 150 SI. F. Hirsch M stabilised 10...350 volt power supply 013 80594 There are probably many of our readers who possess high voltage valve power supplies which could do with some renovation and modernis- ation. With the wide choice of high voltage transistors available nowa- days it becomes a relatively simple matter to update such supplies. The BU 111 was used here, but the BU 126 or BUY 76 can also be used satisfactorily. Usually, the transformers used in this sort of supply have a number of high voltage tappings. In addition, there is nearly always a low voltage winding available. In this particular case a 300 V tapping was used for the high voltage side and a 9 V winding served to supply the stabilis- ation circuit. The latter is very simple and needs no explanation. About 420 V AC is produced once the 300 V tapping has been rectified (D1 . . . D4). This is a rather incon- veniently high value, which is why two 350 V electrolytic capacitors are connected in series for smoothing purposes. Two parallel resistors (R1, R2) ensure that the voltage drop across each capacitor is equal. Resistor R5 reduces the dissipation of T1 and together with a second RC network (R3, R4, C3, C4) provides the collector of T1 with smoothed input voltage of about 350 V. Transistors T2 and T3 may be ordinary TUN's, since they do not have to deal with high voltages and currents. Diode D7 protects the base of T3 against excessive negative voltage peaks. Four different current thresholds may be preset with only two 6 pole pushbutton switches: 1 mA (nothing closed), 5 mA (S2 closed), 15 mA (S2 and S3 closed) and 50 mA (only S3 closed). At full load a voltage of 2.8 V is developed across resistors R8 . . . R 1 1 . This is fed to the base of the regulator transistor T3 via D9...D12, so that this transistor turns off when the current exceeds the preset threshold value. The same voltage is also used to monitor the current with the aid of a 1 mA moving coil meter. Switch S4 enables the meter to be switched for voltage measurement. Current is limited when it exceeds the preset threshold value by about 10%. The output voltage can be adjusted with PI to between about 10... 350 V. Fine adjustment for calibration purposes is possible with preset potentiometer P2. The supply is sufficiently protected against lengthy short circuits. W. Seifried 14 7-80 elektor july /august 1980 super-regenerative receiver 87-180 MHz The simplest receiver to posess both high sensitivity and selectivity is (still) the super-regenerative receiver. It can receive both AM and FM signals and would be a highly attract- ive type of receiver, were it not for its 'stubborn' character. Many people associate this type of receiver with constructional problems and their tendency to scream and whistle! A good design, however, need suffer none of these disadvantages. As the circuit diagram shows, it will re- quire a few more components than usual, but should repay the extra work. The result is a receiver with a number of excellent charac- teristics: both AM and FM reception, an 87-180 MHz range (in other words, an FM taxi and aviation band), a 0,4 //V sensitivity for 10 dB signal/noise ratio (AM) and a bandwidth of approximately 100 kHz. If the circuit design illustrated in figure 2 is used, the construc- tional problems mentioned earlier will also be avoided — yet another advantage. What a super-reg really is, is a fed- back amplifier which is continually on the verge of oscillating (or at least most of the time), a condition which leads to the highest possible sensitivity. It could also be called an oscillator which is switched on and off between 20,000 and 30,000 times per second by means of a relatively slowly rising sawtooth voltage. During the rising slope of the sawtooth (which is most of the time) it's an amplifier stage on the verge of oscillating and only * BF 900 elektor july /august 1980 7-81 Parts list: Capacitors: Semiconductors: C1.C21 = lOOp T1 = BF 324 Resistors: C2,C3,C6,C13 = 1 n T2 = BF 900 R1 = 15 k C4 = 3 . . . 20 p (e.g: Jackson Bros T3.T4 = BC 549C R2,R14 = 33k Cl 604) T5 = BC 547 R3.R6 = 22 k C5 = 220 p D1 = AA119 R4 = 470 n C7,C1 1 ,C20 « 10 n IC1 = LM 386 R5.R13 = 10 k C8 ■ 180 p R7.R15 * 100 k C9 = 220 p/10 V Miscellaneous: R8 = 220 n CIO = 33 n LI = tuning coil (see text) R9 = 150 SI Cl 2 = 3n3 PI » potentiometer 10 k log. R10= 470k C14 = 220 n SI = single pole switch R1 1 = 1 k Cl 5, Cl 7 = 47 n R1 2 = 3k3 C16 = 4p7/10 V R16 = 3M3 C18 = 220 p/6 V R1 7 = 4k7 C19= 100 p/10 V Ri8 = ion during the (short) peaks of the sawtooth does it really oscillate. When the slope falls, however, oscillation stops immediately. The frequency at which the oscillator is switched on and off is called the quench frequency and should of course be above the audible thres- hold. Let us consider the circuit diagram (figure 1). The input amplifier with the BF 324 (T1) serves a double purpose: on the one hand it ensures preamplification of the serial signal and on the other it acts as a buffer between the oscillator and the aerial The applications of simple designs are not always restricted to those of a single circuit. A combination of two (or more) circuits can offer new perspectives. For instance, combining a crystal controlled frequency synthesiser and a digital spot sinewave generator produces a very stable sinewave generator. This 'hybrid' uses switches to select the output frequency in 1 Hz steps. Figure 1 shows the crystal controlled frequency synthesiser section. It is a slightly modified version of the circuit published in the Summer Circuits 1979 issue of Elektor. The heart of the circuit is formed by a phase locked loop (PLL). A very stable frequency is fed to one input of the PLL (IC7) and its output is passed through a variable divider chain before being fed to the other PLL input. The PLL will try to equalise both input frequencies and adjust its output frequency accord- ingly. Therefore, when the division ratio is set to the figure N, the output frequency will be N times greater than the input frequency. As the input frequency is derived from a to prevent the receiver from oper- ating as a transmitter at the same time. The MOSFET T2 and transis- tor T3 together provide the actual super-regeneration. T2 is connected as a self-oscillating mixer. Diode D1 limits the amplitude of the oscillator signal. The sawtooth generator ('quenching waveform') is construc- ted with the aid of gate 2 of T2 and transistor T3. The negative slope on the collector of T3 also reaches gate 1 of the MOSFET by way of C5 and R6. Although the quench frequency is above the audible threshold (between crystal source, the output frequency will be very accurate. The frequency of the crystal oscil- lator (3.2768 MHz) is'' divided by a factor of 2 1S (IC5 and half of IC6) to provide the PLL with an input frequency of 100 Hz. The frequency divider for the PLL is formed by IC8 . . . IC1 1 and the desired division ratio (N), and hence the output frequency, is set up on switches S3 . . . S6. For optimum operation, the value of the capacitor connected between pins 6 and 7 of the PLL will have to be varied with frequency. This is accomplished with the aid of electronic switches ES2 and ES3. The remaining half of IC6 divides the PLL output frequency by two, while IC12 and IC13 form a divide-by-100 counter. This means that two signals are available at the output — one with a frequency fifty times greater than the other. The circuit of the spot sinewave generator is shown in figure 2 and is an extended version of one published in the Summer Circuits 1978 issue of Elektor. It can be directly connected 20 and 30 kHz), its amplitude is such that^the output signal must be thoroughly filtered (R11 . . . R 1 4/ CIO . . . Cl 3). With T4 and T5 the signal is then amplified to a level sufficient to drive the LM 386, a simple and cheap LF amplifier 1C. The only coil in the receiver (LI) can easily be wound. This requires 7 turns of 1 mm Cu wire on an Amidon core (T50-12) with taps on one and on two turns from earth. There should be no further difficulty as far as construction is concerned. M to the circuit of figure 1. Basically, the circuit consists of a 25 bit shift register and a resistor network. The fundamental frequency, f 0 (output of N5 in figure 1), is fed to the data input of the first shift register (IC14). The higher frequency (output of N6 in figure 1) is fed to the clock input of each shift register. The signals at the outputs of IC14...IC17 are symmetrical squarewaves with a frequency of f G . The voltages derived from two successive Q outputs are shifted in phase for the duration of one clock period. All 25 output signals are added by means of the resistor network consisting of R10 . . . R54, so that a 50-step sinewave signal is generated across Cl 2. The circuit around IC18 is an amplifier which acts as an output buffer. The amplitude of the output signal can be varied between 50 mVp. p and 5 Vp.p by means of PI. The fre- quency can be varied in 1 Hz steps between 1000 Hz and 9999 Hz. The sinewave is symmetrical around a reference voltage (U re f) and any offset can be removed by P2. The crystal controlled sinewave generator elektor july/august 1980 7-83 hexadecimal display decoder Decoders for converting a four bit binary code into a hexadecimal display are often few and far be- tween. With the aid of the PROM programmer featured elsewhere in this issue it is possible to solve the problem by programming a PROM to function as a hexadecimal display decoder. There is exactly enough memory space in the 82S23 PROM, which is a 32 x 8 bit device, for such a de- coder program. The eight outputs of the PROM control the seven segments of the display and the decimal point. When a logic '1' is present at the 'blank' input the display will be turned off. The display in the circuit diagram is a MAN 461 OA type. Other com- mon anode types are of course also suitable, but pin connections may be different. Before the PROM can fulfill its task it will have to be programmed. A suitable program is given in the table. If the data to be entered is inverted then, of course, common cathode displays can be used. In principle, the 74S188 (also a 32 x 8 bit PROM) is equally suitable. The only problem is that it cannot be programmed with the programmer in this issue. The same connections, and the program, can however, still be used . . . address DP binary E D C B A 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 1 1 0 0 10 0 0 0 10 1 0 0 110 0 0 111 0 10 0 0 0 10 0 1 0 10 10 0 10 11 0 110 0 0 110 1 0 1110 0 1111 1 0 0 0 0 1 0 0 0 1 DP Y8 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 10 11 0 0 0 0 0 10 0 f g Y 1 1 1 1 0 0 0 0 0 1 1 0 0 0 0 0 0 1 1 0 0 0 0 0 0 1 1111 data a b c d e Y7 Y6 Y5 Y4 Y3 Y2 0 0 0 0 0 0 10 0 11 0 0 1 0 0 1 0 0 0 0 1 1 10 0 110 0 10 0 10 0 1 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 110 0 0 0 110 0 1 0 0 0 0 0 110 0 1 0 0 0 display n U I I 3 3 3 5 6 "7 / a a a b r z_ d E F n u. i i. 10 0 10 10 0 11 10 10 0 10 10 1 10 110 10 111 110 0 0 110 0 1 110 10 110 11 1110 0 1110 1 11110 11111 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 1 0 10 0 1 10 0 0 10 0 10 0 0 1 0 0 0 0 0 0 1111 0 0 0 0 0 0 0 0 0 0 10 1 1 0 0 0 1 1 0 0 10 0 1 1 0 0 0 1 0 0 111 0 0 1 0 0 0 0 0 0 0 a. 3 3 s. a. 1 I. a. 3. a. b. r d. E. "® 7-84 elektor july /august 1980 universal display The LED display described here can be used in a variety of applications ranging from tachometers to audio modulation meters. It consists of two rows of twelve LEDs and is controlled by means of three logic signals and one analogue signal. The three logic signals determine which row of LEDs is enable and whether a thermometer type scale or a spot scale (a single LED illuminated) is used. The analogue input signal is continually compared to a number of reference voltages derived from the supply. When the input signal level is higher than a particular reference voltage the corresponding opamp output will go high. One of the LEDs connected to the opamp will then light provided T14 or T15 is conducting. It is important to ensure that these two transistors do not conduct at the same time as then excessive current would be drawn from the opamps. If, for instance, the input voltage is higher than the reference level at pin 9 of K6, the outputs of K1 . . . K6 will be high and the rest (K7 . . . K12) will be low. With input B high and input C low, T14 will be conducting and LEDs D7 . . . D12 will light. When the inputs to B and C are the other way round, of course, LEDs D7' . . . D1 2' will be on. If transistor T13 is conducting (input D low), however, transistors T7 ... Til will be turned on and LEDs D8 . . . D12 (or D8' . . . D12') will be short circuited and only D7 ( D7') will light — spot measurement. By rapidly changing from one row of LEDs to the other, and by simultane- ously switching between two analogue input signals, it will appear as if both rows of LEDs are lit at the same time. This could give an indication of the audio signal level in stereo equipment. A suitable control circuit appeared in the 1978 Summer Circuits issue of Elektor (see page 7-51, figure 4). H. Burke elektor july/august 1980 7-85 a better piano i Quite a lot of magazine space has already been dedicated to the Elektor piano. By now, we have the impression that most constK tors are satisfied with the 'sound'. However, there is always room for improvement — and we recently found a new trick. Only a handful of components are needed — two or three pounds worth — and no drastic surgery, so there's no harm in trying it! The basic idea is quite straightfor- ward — in fact, it was mentioned in the article 'Extending the Elektor piano' (December '78, p. 12-51). The output from the master oscillator board is a symmetrical squarewave. This means that it contains the fundamental and all odd harmonics. However, a 'real' piano produces even harmonics as well, which gives a different sound. In the article referred to above, this problem was solved by converting the squarewave output into a 'stepped sawtooth'. However, there is another way of achieving the same result. The output from the master oscillator can be converted into an asymmetric square- tve, using quite inexpensive ICs. Making a squarewave asymmetric means altering its duty -cycle; this can be done in any number of ways. The principle described here is to add further squarewave signals at twice and four times the frequency. 'Add' isn't quite accurate: the signals are all applied to different inputs of a NAND gate. The signal at the output of the NAND gate will still have the same frequency as the 'fundamental' input, and the same level ... digital ICs are decidedly fixed in their ways, they only pro- duce signals that swing between 0 V and positive supply. However, the duty-cycle of this signal is now changed to 12.5%. There's asymmet- ric. The higher frequencies required for this transformation are available at the cost of a few wires: they correspond to the same note, one and two octaves up. Obviously, this goes wrong at the highest octaves: for octave 2, a 25% duty-cycle can be achieved by 'adding' the highest octave; the highest octave (octave 1) is left unaltered. Not to worry: those harmonics are virtually inaudible. Figure 1 illustrates how to modify octave 2, and figure 2 shows the arrangement for octave 3 — this principle is also valid for all lower octaves. Three three-input NAND gates are contained in one 1C type 4023, and four of these ICs are used for each octave. The basic principle should be clear: in a given octave, each note is NANDed with the same note, one and two octaves higher; the output from this NAND gate is used as the signal for that note in the lowest of the three octaves. 2 u 2 U, 8051 1 - 2 M 7 86 elektor july /august 1980 variable power supply 0-50 V/0-2A Because of its internal reference source, the LM 10 is eminently suitable for use in power supplies. By using two ICs both the current and the voltage can be made variable. An added feature is short circuit protection. The output voltage is increased linearly by potentiometer PI, and the current (also linearly) by P3. The preset P2 is used to set the peak output current, up to a maximum of 2 A. The maximum output voltage can also be preset by a resistor connected in parallel with Rla. This method ensures better stability and less noise. The output voltage is stabilised in the following manner. The inverting input of IC1 is connected to the output via R4 with the other input to the junction of PI /R2. The opamp will attempt to prevent any voltage difference by controlling T1. This will either increase or decrease the current through R6 which will consequently vary the voltage to the darlington output stage. The voltage level at the junction of P1/R2 is generated as follows. Pin 1 of the LM 10 is the reference output. No voltage difference should occur between the two inputs of the opamp, in other words, junction R1/R2 is connected to the same potential as the negative connection (pin 4) of IC1 . The reference voltage across R1 will be 200 mV at a current of approximately 100 /uA which will also flow through PI . This means that the potential drop across PI will be equal to 10“ 4 (100 juA) times its resistance. Otherwise, there will be a difference in voltage at the input of the opamp, so that it will adjust this until the output voltage has reached the exact value. Current is stabilised by comparing part of the reference voltage (at the wiper of P3) with the voltage dropped across R11 (through which elektor july/august 1980 7-87 Parts List: Resistors: Rla = 2k2 Rib = empirically established (see text) R2 = 10 k R3.R7 = 3k3 R4 = 390 fi R5 = 47 k R6 = 3k3/1 W R8= 180 n R9.R10 = 0,47 n/3W R 1 1 =0,075 0/2 W (2x0,15 0 in parallel or resistance wire) R1 2 = 470 0/5 W PI = 500 k lin. P2 = 4k7 preset P3= 10 k lin. Capacitors: Cl = 1 n C2= 10 n C3 = 22 n C4 = 47 m/63 V C5 = 4700 m/80 V (see text) Semiconductors: T1 ,T2 = BC 161 T3,T4 = BC 141 T5 = BD 241 T6,T7 = 2N3055 D1 ,D2 = 1N4148 D3,D4= 1N4001 IC1 ,IC2 = LM 10C Miscellaneous: Tr = 42 V (36 V)/3 A transformer B = B80C2200 ( 200 V/8 A bridge rectifier) the output current passes). Since the LM 10 is not very fast, conventional current protection has been added with the aid of T3. This limits the current at a fixed threshold value. To a certain extent, the minimum output voltage will depend on the load. This is because the (small) supply current of the two opamps passes through the output. It is therefore always advisable to connect a fixed resistor across the output of the supply. With a fixed resistance of 470 n (5 W) a minimum output voltage of 0.4 V was measured in the prototype. The maximum output voltage can be determined with Rib, as mentioned above, and should be no more than 50 V. In many cases however it is better to accept a lower value to work on and use a transformer of 36 V. The 4700 p electrolytic capaci- tor may then be the common 63 V type. Transistors T5,T6 and T7 will have to be mounted on a fairly large heat sink. Figure 2 shows the printed circuit board layout for the supply. National application note M FSK PLL demodulator cs FSK (Frequency Shift Keying) signals can be demodulated in a simple manner with the aid of a PLL (Phase Locked Loop). Frequency shift keying is used regularly for data transmission, where a carrier wave is switched between two predetermined frequencies. The frequency shift is obtained by controlling a VCO with the binary data signal, so that the two frequencies are determined by the '0' and '1' logic states. When a signal is present at the input of IC1 the VCO is locked in synchronisation with the input fre- quency. This involves an equal change in voltage at the output of the 1C (pin 7). The loop filter capacitance (C6) is smaller than usual to eliminate spikes from the output pulse. At the same time, a ladder network of three RC sections is used to filter out the remains of the carrier wave from the output signal. The free-running fre- quency of the VCO can be preset with potentiometer PI between about 1900 and 6200 Hz. The character- istics of the circuit (low pass filter R5 . . . R8, C7 . . . C9) make it suitable for speeds of up to 714 Baud. H 7-88 elektor july /august 1980 audio frequency meter 10 V N1 . . . N4 - IC1 - 4093 B If your interest is primarily with audio, a commercial frequency meter, although very nice, is not strictly necessary since most of its range will be redundant. The simple circuit described here is used to con- vert an ordinary lOkfl/volt moving coil volt meter into an audio fre- quency meter. The input signal is first amplified by transistor T1 (with a gain of about 40) and then passed through a Schmitt trigger formed by N4. This converts the signal to a square wave and the negative edge of this is used to trigger a monostable multivibrator (N 1 and N2). Its output is then inverted by N3 and fed to the multimeter which should be switched to the 2 volts (fsd) range. The three ranges of the frequency meter are selected by SI. They are 200 Hz, 2 kHz and 20 kHz and are calibrated (with the aid of a fre- quency generator) by the three potentiometers P2, P3 and P4. The circuit can be set to maximum sensitivity by PI. This potentiometer varies the DC bias through T1 and therefore the voltage to the input of N4. When this voltage is exactly centred between the two trigger threshold levels the sensitivity is then at a maximum. SI a = fi n max ■ 200 Hz ^ 1 V/100 Hz SI b = fj n max - 2 kHz - 1 V/1 kHz SI c = fi n max = 20 kHz - 1 V/10 kHz 20 Hz < fjn < 20 kHz Uj n min-100mV The input is able to withstand up to 50 volts peak to peak. For low input voltages, less than 14 volts peak to peak, the impedance is about 25 k£2. At greater input voltages, D1 starts to conduct and the input impedance drops to about 5 kJ2. The accuracy of the frequency measurement will be determined by the meter used since the accuracy of the circuit itself is better than 2%. H deglitching remote control Interference pulses in remote control receivers are a nuisance. Worse, when the control is for model planes they can be fatal ... A quite effective interference rejection circuit can be built, using only two monostable multivibrators. Figure 1 illustrates the basic principle, as a block diagram; figure 2 gives a complete circuit for one common commercial system. The circuit is included in the receiver, between the pulse shaper and the demultiplexer. In a normal system, interference at a level of only 10 . . . 30% of your own signal strength is enough to drive the servo's completely haywire. The 'interference susceptibility' of a given receiver depends, by and large, on its response speed. The faster it reacts, the more it tends to go wild. In general, the end of the 'burst' elektor july/august 1980 7 89 I ' ® V\AA^f\AAAi~iV\A/ , M II 'll ii - [IT1 _ T ; MMV 1 mm M M V 2 from the transmitter is the most 3 sensitive period. As illustrated in figure 3, interference spikes after the transmitter shuts down tend to extend the output from a pulse shaper — like MMV1 in figure 1. However, MMV2 in figure 1 is not 'retriggerable': it gives a brief pulse, after which it has a considerable 'down time'. This second one-shot is triggered at each positive edge from the first MMV, so that it 'reconstructs' the original control signal — ignoring any interference spikes that occur after the trans- mitter closes down! If the inter- ference is prolonged, MMV1 remains triggered; it doesn't produce any further pulses for MMV2, so that no further output pulses are produced. The servo's remain in their original position. Not that that is necessarily ideal, but it is better than having them run wild! The pulse length of MMV1 should be approximately twice that of a normal transmitter pulse. The pulse length of the second MMV is less critical: anywhere between 0.2 and 0.5 milliseconds should do. The circuit given in figure 2 is a typical example of the principle. However, component values will vary from one system to another. Until manufacturer's standardise, we can't 80565 3 give one final 'recipe'! The principle is valid, however, for all similar remote control systems that use AM modulation. A. Stampfl M two more piano octaves Readers who have built the five octave version of the Elektor piano can extend its frequency range by the addition of two more octaves with the simple circuit shown here. In the circuit diagram of the master tone generator (Elektor41 page 9-10) it will be seen that, when the fre- quency of the master oscillator ( 1C 1 3) is divided by two, the fre- quency of each note is also divided by two. This causes the range of the keyboard to be shifted downwards by one octave. This disadvantage is turned into an advantage in the circuit described here. The physical modifications to the piano are very straightforward. The tone 'positions' of the keying circuit boards, relative to the master tone generator, have to be moved 'up' one octave. That is, the connections on the tone generator board for octave 1 are removed and rewired to the position of octave 8. This is continued with all the keying circuit boards until octave 5 occupies the position of octave 4 on the master tone generator board. The expansion circuit should now be connected in place of the wire link between IC13 and IC16 on the master tone gener- ator board. The clock output (pin 6 of IC16) is the link point furthest from the edge of the board and is connected to the input of the expansion circuit. («)(“)<«) u,Q p IU 1 1 U 4 IUJ ’ 00 " <|) (p €p D1 ... D4 = BA102 This modification, when completed, will enable the keyboard to be switched up or down an octave thereby achieving an effective range of seven octaves. The expansion circuit contains only three ICs. For the divide by two networks, a 4013 is used. The other two ICs (401 1 's) contain the gates for the control logic. Switches SI and S2 are ordinary single pole types as shown in the circuit diagram. It should be noted that the piano keyboard will be 'normal' (as prior to modification) whenever both switches are closed or open together. When switch SI only is closed, the keyboard will be higher by one octave and with only S2 closed it will be lower by one octave. Some readers may prefer to incorporate the two switches into one. D. Butler 7-90 elektor july /august 1980 PROM programmer Programmable Read Only Memories are finding their way into more and more electronic construction projects. Unfortunately, programming equip- ment (and services) tend to be rather expensive as far as the amateur constructor is concerned. It is also possible that the stringent program- ming requirements of most PROMs can act as a deterrent to the would-be programmer designer. For these reasons we have decided to include here a circuit which can be used to program one of the smaller and more common types of PROM. The device in question is the 82S23 which is organised as a 32 x 8 bit memory. (The 82S123 can also be programmed — this has tri-state outputs whereas the 82S23 has open- collector outputs). The signals generated by the programmer conform to the manufacturer's specifications. These are shown in figure 1. The V cc signal is the supply voltage for the PROM and CE is the signal which has to be applied to the 'chip enable' input. The V a signal is the actual program- ming voltage. Its rise time has to be somewhere between 10 and 50 ps. The chip has to be programmed 'bit by bit' which does of course take a certain amount of time. In order to establish the chronological sequence of events, the horizontal axis in elektor july/august 1980 7-91 figure 1 has been divided into ten equal parts of 100 ns each. Figure 2 shows the block diagram of the programmer. The circuit is controlled by a clock generator that operates at a frequency of 100 kHz. Each period of the clock signal will last 1 00 ps. The output from the clock generator is fed into a divide- by-ten counter. Each of the counter outputs will go high in turn for the duration of one clock period. The counter is reset when output '0' goes high. Initially the counter is started manually with the aid of a pushbut- ton. After one clock pulse, output '0' will go low and the 'automatic' start/stop circuit will be enabled. The counter will then operate until the '0' output goes high again regardless of the pushbutton's position. The other outputs from the counter set and reset the three flip-flops at various times in the cycle. These flip-flops are used to control the programming Parts List: Resistors: R1 = 18 n R2.R4 . . R11,R18,R19,R20, R25,R26,R27,R30= 10 k R3 - 390 St R12 . . . R16.R24 = 5k6 R17 > 270 n/1 W R21 * 1 M R22 = 560 k R23 = 4k7 R28.R29 = 1 k PI = 2k5 preset potentiometer P2 = 25 k preset potentiometer Capacitors: Cl = 1000 m/40 V C2,C3,C4 = 100 n C5 = 8n2 C6.C9 = 10 n C7 = 1 n C8 = 1 m/25 V CIO = 47 n Semiconductors: IC1 = 4043 B IC2 = 4093 B IC3 = 4017 B IC4 = 7815 IC5 = 7805 IC6 = 82S23 B - B40C1000 D1,D2,D3.D5,D7 - DUS D4 = LED D6 ■ 10 V/400 mW zener diode T1 - BC 160 - 16 T2.T4.T5 = TUN T3 - BD 139 T6 = TUP Miscellaneous: 51 = three-way switch 52 = 8 position switch 53 . . . S7 = pushbutton (digitast) Tr = transformer with a secondary winding of 18 V/0.25 A 7-92 elektor july/august 1980 signals shown in figure 1 . The address containing the particular bit to be programmed is set up on the address select switches. The actual bit is then programmed via the 8-way selection switch and SI. When SI is in the other position to that drawn the memory contents can be 'read' by means of the LED which will light when the selected PROM bit is a '1 '. The complete circuit diagram of the PROM programmer is shown in figure 3. The PROM to be pro- grammed is IC6, the clock generator is constructed around N4 and IC3 is the counter. The network R21, R22 and C8 makes sure that the counter is reset upon initial switch-on. Transistor T1 provides a constant current for the programming pulse and is controlled by FF2. The output of the current source is switched by means of T2 and FF3. The program- ming voltage, V a , thus generated has a rise time which is determined by the values of R26, R27 and C5. With the values shown it will be around 20 ps. Transistor T4 is also con- trolled by FF2 to provide the voltage for the PROM. The chip enable input is controlled via FF4 and T5. The printed circuit board and component layout for the PROM programmer is shown in figure 4. If a frequency meter is available then resistors R28 . . . R30, T6, D7 and CIO (shown inside the dotted area of figure 3) can be omitted. These components have been included so that the operating frequency can be set accurately with a multi-meter. With this part of the circuit included, calibration becomes very simple. The connection marked 'A - B' between the current source and T2 is disconnected and capacitor C8 is temporarily short-circuited. With a multi-meter connected to output C, potentiometer P2 can be adjusted until a reading of 5 V is obtained. A moving coil meter should be used (not a DVM) as it is the average value that is to be measured. (Readers who have a frequency meter at their disposal can, of course, adjust P2 until the frequency of the signal at the output of N4 is 10 kHz). The meter is then switched to the current range and a 180 0/0. 5 W resistor connected in series with it. Poten- tiometer PI is then adjusted to give a reading of 50 mA between the collector of T1 and ground. During programming the current will be 65 mA (again, the average value is measured). As the circuit is now set up, the short across C8 can be removed and the link between A - B can be replaced. Operating the programmer should not cause any problems, but care should be taken when inserting the PROM. This should be done with the supply voltage off and with SI in position 'a' ('control'). The address can be selected with S3 . . . S7 and the bit to be programmed with S2. With SI in position 'b', S8 can be pressed briefly to commence programming. Only 'ones' are programmed as the PROM is supplied with a 'nought' in each memory location. Finally, the LED can be used to check the memory contents after programming. It will light when the selected bit output is a '1 '. M shop window lighting i An expensive item in any shop- keeper's budget is the cost of illumi- nating the window display. One method of reducing costs is to keep the number of lights down to a minimum. Unfortunately, this could well discourage nocturnal window shoppers. Some time ago an important retailer specialising in domestic appliances came up with an economical alterna- tive. The shop window lighting was installed in such away that the passer by was able to switch it on himself. After a certain period of time the lights would then go out automati- cally. This system appears to be an interesting prospect, but installation is by no means cheap. The outside switch would have to be vandal proof and water proof at least and this is expensive to start with. Hardly cutting costs! The circuit described here is also operated by the window shopper, but without using an external switch. A proximity sensor fitted inside the window controls the lighting via a triac. The drawing in figure 1 shows a temperature compensated Wien bridge oscillator. This produces a 30 kHz sinewave output with a peak-to-peak amplitude of 4 V, presettable by potentiometer PI . The window sensor is connected to the non-inverting input of the oscillator. IC1. The sensor plate Js mounted on the inside of the window and therefore represents a capacitance with a dielectric consisting of glass and air. Capacitance loss depends on a number of factors. Humidity and temperature, in other words a change in weather, would vary the influence that the sensor plate has on the oscillator. These slow changes are compensated for in the circuit. The output signal of the 80515 1 ♦ (0 Wien bridge oscillator is rectified and clipped by D1 and C3, with the result that the voltage at the gate of the FET (T 1 ) depends on any slow changes in the sensor plate capacitance. This varies the drain/ source impedance of the FET which will therefore maintain a constant output amplitude. Consequently, the oscillator is not affected by slow changes in temperature and humidity. The control loop, however, only reacts to slow changes. When a hand elektor july/august 1980 7-93 is placed close to the sensor plate, the rapid changes caused will not be compensated for immediately and the oscillator will switch off. A voltage is present at the collector of T2 (point 'X' in the circuit) whenever the oscillator is running, but will drop to 0 V when the oscillator switches off. This voltage level controls the monostable multivibrator con- structed around N1 and N2 in figure 2. When this input of N1 goes low, the output of N2 will also go low (for a period of time determined by the values of C6, R12 and P3) to turn on transistor T3. This will light the LED in the opto-coupler which will in turn trigger the thyristor. This can only occur at the mains zero- crossing point for at any other time transistor T4 will be on and the gate of the thyristor will be grounded. The result of this is that the triac will only be switched on at the mains zero-crossing point thereby keeping interference to a minimum. A flashing LED controlled by the 2 Hz oscillator (N3) is mounted close to the sensor plate which will, hopefully, draw the window shopper's attention to it. Switch SI is used as a reset and when pressed briefly will discharge capacitor C5 and DIO will start to flash. If now a hand is held near the sensor plate the lights will switch on for a period of time determined by the setting of P3. It is not necessary for the system to be operative all night long. P2 sets the time period (a few hours) after which the output of N4 goes low and the MMV is inhibited rendering the system inactive. The layout of the printed circuit T T 0 rMlS oU 1 ®L IN 6 ° A 6 6 6 6 6 Parts List Resistors: R1 ,R2,R5,R19 = 47 k R3 = 100 k R4 = 39 k R6.R11 » 1 M R7,R8,R13,R16 = 10k R9.R21 = 1 k Rio = ioo n R 1 2 = 56 k R14.R24 = 270 n R15 = 560 k R1 7 = 27 k R18 = 1M5 R20 = 1 k/1 W R22 = 100 J7/1 W R23 = 150H PI = 25 k preset potentiometer P2 = 10 M preset potentiometer P3 = 1 M preset potentiometer Capacitors: C1,C2 = lOOp C3 = 47 p/10 V C4 = 2p2/10 V tantalum C5 = 2200 p/10 V C6 = 470 p/IOV C7 = I m/10 V C8.C1 5 - 10 n C9 = 10 p/25 V CIO - lOp/IOV Cl 1 = 470 p/40 V Cl 2 = 82 n/400 V C13 = 330 n C14 = 100 n Semiconductors: T1 = BF 256A T2,T3 = BC 557 A T4 = BC 549C T5 = BC 547A D1 ,D2,D3 = DUS D4 = zener 12 V/400 mW D5 = 6V8/400 mW D6 . . . D9 = 1 N4004 D10= red LED B = B40C500 (40 V/500 mA bridge) Tri = triac 5 A-type (e.g. TIC 226D) IC1 = 3140 IC2 = 4093 B IC3 = MCS2400 SI = S.P.S.T. switch F = 3.1 5 A fuse, slow blow Tr = transformer, 12 V/100 mA Suitable cases are available from Veroor West Hyde Developments. boards for the unit are shown in figures 3 and 4. It is advisable that the connections between the two are made with screened cable, with the screen connected to earth. Now a word about setting up. Once assembly of the small printed circuit board has been completed, and fitted in a suitable box, PI is set to minimum resistance (turned to the left). A multimeter switched to the 10 volt range is then connected between point 'X' and earth. PI is then adjusted to that the meter reading drops to zero very briefly whenever a hand is held against the window pane near the sensor plate. The copper square on the board in figure 3 must be mounted against the inside of the shop window for best results. K elektor july/august 1980 7-95 how does this strike you? 'Energy crisis' is becoming something of a catch phrase nowadays, for one reason or another. Whether this is due to a shortage in fossil fuel or simply because the power 'isn't on', is another matter. While one of our designers was poring over a history of electronics, by candlelight, with knees knocking from the cold, he was suddenly struck by a brilliant flash of inspi- ration. Tap an unused natural source! The basic idea is shown in the accompanying diagram. The neon lamp (a one killervolt type) limits the voltage across R1 and R2 to 1000 V. These resistors are connected in a voltage divider configuration, providing 15 V at the centre tap; this voltage is rectified and stabilised by D1,R3 and D2. The battery (10 Nicads in series) is charged through D3. Readers are advised that some components may suffer from instability. The circuit was originally intended as a back-up for the solar cells in very remote applications — repeater stations in the Himalayas, orbiting spacecraft and the like. However, it can also be used as a battery charger, under one condition: for safety reasons, the lightning conductor must be mounted indoors. lOO The question often arises — is it a high resistance or is there an open circuit somewhere? The purpose of this tester is to check whether or not there is a conductive path with a resistance of less than 5 MJ2 between two points. A higher resistance than this is indicated as an open circuit. The results are indicated by two LEDs. As the circuit diagram shows, the drain of FET T1 is directly con- nected to the positive supply line (consisting of two 1 .5 volt cells) and the source is connected to the negative rail via resistors R2 and R3. The circuit untder test is connected between the gate and the negative rail. Since the FET only conducts with a gate voltage (as opposed to current), no distinction is made between large and small resistance values (provided these are lower than 5 Mfi). When open circuit, the voltage on the gate is +3 V with respect to Based on an idea by B. Franklin M continuity checker SI ground and T1 will conduct thereby causing the voltage at the source to just about reach the supply voltage. This in turn provides transistor T2 with a base drive current and it starts to conduct, with the result that LED D1 will light. If the re- sistance is lower than approximately 5 MJ2, the gate voltage will drop, so that the FET will behave like a large resistance and the voltage at the source will also drop. Transistor T2 will then turn off and, of course, so will D1.AsfarasT3 is concerned, the voltage on its base will also drop causing it to conduct and thereby lighting LED D2. The value of R1 determines the resistance range which can be tested. With the value given here the highest resistance which can be tested is approximately 5 Mfi. M.S. Dhingra M 7 96 elektor july/august 1980 digital heart beat monitor 12 V Recently we published a circuit for a digital heart beat monitor that was sent in to us by Mr. P. Leah. We have since improved on it in places, brought it up to date and designed a printed circuit board for it. The AND gate N6 and the three NOR gates N7 . . . N9 of the original circuit have been replaced by one NAND gate and a separate (4528) 1C. In addition, the circuit around IC8 has been modified to such an extent that a preset pulse is now generated at every zero crossing (pin 15 con- nected to pin 14). In addition to this, the circuit of the sensor amplifier has been completely revised. The first section is now self-adjusting within a large intensity range and the second opamp is connected as a schmitt-trigger with self-adjusting threshold levels. The display now uses the more modern 7760 type of seven segment indicators from Litronix and HP. Finally, a loud- speaker has been added so that the heart beat can be rendered audible. The indication is now accurate to within 2 beats over a range of 40 ... 180 beats per minute. The self-adjusting characteristics of the preamplifiers enable various types of photodiodes to be used. For good, reliable results the sensor will have to be light proof and rigid in construction. In principle, the circuit is sensitive enough to produce good results when a sensor is attached to the ear lobe, but a sensor for a finger tip will produce much more reliable results. Due to possible fluctuations in signal amplitude, the circuit may count one heart beat as two separate beats. In order to detect such errors a small loudspeaker that is controlled by a monostable multivibrator (N7, N8) has been added. It will 'squeak' at IC11 regular intervals to indicate that the sensor is correctly positioned. The circuit is mounted on two printed circuit boards. The display section is mounted on a separate board so that it can be used as part of other circuits if required. Digital heart beat monitor Elektor July /August 1979 Resistors: R1.R3 = 4k7 R2- 1 k R4.R6.R8 » 100 k R5 = 1k2 R7 - 1M2 R9.R1 0 « 15 k R11 = 560 k R12 » 8ft2. % W R13 = 8k2 R14 = 330 k R1 5 . . . R21 - ion R22 = 220 k R23 = 22 k R24.R26 = 47 k R25 - 47 n PI = 1 k preset P2 •= 100 n preset Semiconductors: T1 . . . T3 = BC 141 T4 » BC 51 7 T5 - BC 559C IC1.IC2 = 741 IC3 . . . IC6 = 4518 IC7 = 4520 IC8 - 40103 IC9 = 74C928 IC10 = 4528 IC11 - 4011 IC12 = 4081 IC1 3 = 7805 D1 = BPW 34/41 Capacitors: Cl ■ 220 p C2 * 47 /i/10 V C3 = 33 n C4 = 150 n C5.C8 = 47 ji/1 6 V C6 = 1 p/16 V C7 - 10 m/1 6 V C9.C10.C13.C1 4 = 100 n C11 = 680 n Cl 2 ■ 1 0 n Cl 5 » 10 m/ 35 V tantalum Miscellaneous: Lai = lamp 12V.1 W DPI . . . DP3 = HP 7760 LS = miniature loudspeaker 8 ... 150 n SI - SPST 7 98 elektor july /august 1980 moving-coil preamp Everyone knows that there are only two ways to connect moving-coil phono cartridges: either through a transformer or a pre-preamp that uses lots and lots of transistors. It is rather surprising, therefore, to find a design using only three transistors! This circuit, by E.H. Nordholt and R.M. van Vierzen, appears in the April 1980 issue of the Journal of the Audio Engineering Society. The original article is extremely interesting, but also rather lengthy, so we will restrict ourselves to the conclusions. In the first place, it is shown that in a design of this type the internal base resistance of the transistor is highly important for the noise performance. The value of r^ for some current types is given in Table 1. It is apparent that the BFW16A is by far the best, so it is used in the final circuit. The circuit itself looks fairly straightforward. The bias current for the first stage is set by a current source, T3, making for high loop gain and good supply rejection. The frequency response is rolled off above about 50 kHz, by including C2. The current through the output stage, T2, is set to 10 mA, so that output levels up to 200 mV can be handled with very little distortion. As is apparent from Table 2, the amplifier gives excellent performance. The noise output is also illustrated in figure 2. The complete unit can be mounted Table 1. Type rb/|«l Manufacturer TIP 30A 13 Texas Instruments BFY 90 21 Philips BFW 92 16 Philips BF 181 12 Philips BFW 16 A 4 Philips between the moving-coil cartridge and the input of a normal dynamic preamplifier, as shown in figure 3. Note that the two signal return lines from the cartridge should only be earthed at the preamp input, as shown — not inside the record player! Table 2. 80616 2 Frequency response 20 Hz-50 kHz + 0/-2.5 dB Voltage gain (1 kHz) 34 dB Input impedance > 1 kit Output impedance < 100 SI Maximum input voltage 4000 pV Harmonic distortion (1000 Hz. maximum input): 2nd harmonic distortion 0.014% 3rd harmonic distortion 0.01% total harmonic 0.017% IM distortion (maximum input, 200 Hz and 7 kHz, 4:1) 0.05% Signal-to-noise ratio (10 cm/s, 20 Hz to 16 kHz, unweighted, R s = 2.5 n, with BFW 16A) 68.8 dB 50 x preamp RIAA preamp. i 1 i 1 elektor july/august 1980 7 99 cheap source of energy Because of the ever diminishing world energy sources it is imperative that we investigate any form of alternative power. As we all know, resistors produce noise and noise is a form of energy. Why not harness this energy? In order to do this the noise voltage will have to be rectified and smoothed, as shown in the circuit diagram. The effective output voltage is determined by the equation U 0 =V4-k-B-T-R where T is the absolute temperature (degrees Kelvin), B is the frequency bandwidth of the noise produced, and R is the resistance value. It will be apparent that the higher the resistance value and the greater the ambient temperature, the more volt- 60607 age will be produced. The forward voltage of the diode should be as low as possible. Germanium diodes are therefore preferable, but better results can be obtained by using Stannum (Sn) diodes (especially in situations where the diode can be kept sufficiently cool). This is where temperature comes into effect. Since we are removing energy from the resistor, its temperature will tend to drop. Inventive readers may be able to use this phenomenon to cool the diode. It is important to choose the right type of resistor. Only old, preferably damaged resistors which produce a lot of noise should be used. Modern noise-free types are definitely not suitable. The output voltage of the prototype energy source was found to be approximately 1 mV with a resist- ance value of 0.6 Gfi (Gigel-Ohm). In order to reach higher voltages several sources can be connected in series. If higher currents are required then, of course, they should be con- nected in parallel. M » automatic range switch It is often convenient to utilise an automatic range switch (autoranger) when measuring with digital meters. Unlike the forgetful human, an autoranger ensures that the range is altered before any damage can be done to the actual meter. It detects whether the measured parameter (be it voltage, current, resistance etc.) is 'out of limits' and increases or decreases the range accordingly. The automatic range switch shown here operates on exactly the same principle. A maximum of ten decades can be switched with it. The logic signals to control the circuit are derived from the conditions 'over- flow' and 'first figure = zero'. In the case of the Universal Digital Meter (Elektor, January 1979) these will be the BCD codes 1011 and 0000 respectively and are determined the moment the first digit is multiplexed to the display. For this reason the 800 elektor july/august 1980 2 ESI ... ES3 = 36 IC7 = 4066 •The total resistance of R16 and ES3 when closed should be 800 SI. In practice, a value of 780 SI for R16 (680 SI + 100 n) should be quite close. 96 Hz multiplex signal which con- trols the first digit (the MSD) is used as a 'strobe' signal. If the condition 'first figure = zero' occurs, a 96 Hz pulse train appears at the output of N1. If the 'overflow' condition occurs, the pulse train will appear at the output of N2. These pulses are filtered by the RC networks R1/C1 and R2/C2 to ensure a clean signal. When one of these two conditions takes place, the monostable multi- vibrator, IC2, is triggered by the trailing edge of the first pulse in the train. The duration of the single 'interval' pulse thus generated by IC2 can be adjusted with the aid of potentiometer PI. During this inter- val gates N3 and N4 are inhibited. For the time being therefore, only the first pulse will reach the up/down counter IC4. Only when the duration of the pulse train lasts longer than the interval will IC4 receive a second pulse. The BCD output from IC4 is con- verted into decimal by IC5. The limits of IC4's counting range are preset by suitably connecting the inputs to N3 and N4. Figure 2 shows a suitable input attenuator for the circuit, whereas figure 3 shows how to connect the various parts to the Elektor Universal Digital Meter. J. Borgman 3 solid state tachometer Only a handful of components are needed to produce this tachometer which is useful both in the car arid on machine tools that require a speed indication. The visual indication is by means of a row of LED's in a vertical or horizontal column (or even a 270° arc). The number of LED's lit at any one time correspond to the measured rotational speed at that time. IC1 is a frequency to voltage converter. If used in a car, its input can be connected (via R1) to the contact breaker terminal of the coil (commonly marked 'CB'h The output of IC1 is fed to the inputs of both IC2 and IC3. These two IC's are cascaded, that is the ten LEDs controlled by each 1C form a single line. In this case, the LEDs from IC3 will form the first ten in the line. The cascading link is between pin 6 of IC3 and pin 4 of IC2. An input voltage of about 1 .2 V will succeed in lighting all the LEDs from IC3, above this level will be elektor july/august 1980 UK 15 106 book page reminder taken over by IC2. The relationship between the input frequency and the number of LEDs lit can be adjusted by potentiometer PI . This will of course depend on the maximum number of revs re- quired. For a four stroke four cylinder car engine, the maximum is normally in the region of 6000 RPM. Much above this is tempting provi- dence. In this case the twentieth LED should light at around this figure. If a bell transformer, with a second- ary voltage of 3 ... 5 volts, is tem- porarily connected to the input, the LED indication will be equal to 1500 RPM therefore the LEDs up to and including D5 will light. It is a simple matter to adjust PI to ensure this is so. A spot indicator (or a single LED lit as opposed to a row) is also possible with a few minor modifications. For this pin 9 of IC3 must be connected to pin 1 of IC2 (and not with +1 2 V). Similarly, pin 9 and 11 of IC2 are linked together (and not with +12 V). A 22 kft resistor is then wired across D9 of IC3. The brightness of the LEDs can be adjusted by altering the values of R6 and R7. It may be useful to use different coloured LEDs for the varying degrees of warning signified by the length of the LED row. M How many times have the lights gone out when you are halfway through the best part of your 'whodunnit'? Or perhaps your spouse can no longer sleep with the reading light on? How do you mark your page without bending , it when your cuddlesome canine friend has chewed your favourite imitation leather bookmark? These questions together with the fact that nobody likes to deface their books (do they?) were the motivation for designing this very simple and easy to operate book page reminder. When not being 'programmed' the majority of the circuit is switched off and the only parts that draw current are three decoder/driver ICs (IC2 . . . IC4). As these are CMOS ICs the actual current consumption will be very small. Operation of pushbutton switch SI causes the numerical page information to be displayed on the three seven-segment LEDs. The oscillator formed by N1 . . . N3 is also supplied with power via SI, but although it starts up the decoders are not clocked as their clock inhibit lines are still held low. If, however, one of the push- buttons S2 . . . S4 are also depressed, the associated decoder/driver will start to count and its new value will be indicated on the relevant display. The power drivers contained in IC5 . . . IC7 are included because the decoder/drivers are not capable of directly supplying sufficient current for the LEDs. For avid readers who enjoy reading large volumes an extra facility has been added. The carry-out signal from IC2 is divided by two by means of a 'D' type flip-flop and then fed to the decimal point of the leftmost display via a pair of inverting buffers (N4 and N5). This means that the decimal point will light up every second decimal cycle to indicate page number Ixxx. The desired page number is programmed by first holding SI closed and then operating each of the other three buttons in turn until the correct number is shown on the display. SI is then released and the page number will be stored until such time as it is updated. A previously stored number can be recalled simply by pressing SI . If any of the switches I s, IIIJSIJI p SI Editorial note. For those readers who are less inclined to wield a soldering iron, we have an alternative solution: cut out this circuit and use it as a bookmark! Flush mounted proximity switch Hamlin Electronics has introduced j ne flush-mounted axially operated proximi switch designed for use with intruder alarr or in counting, batching and warning mechc isms. Known as the Type RP113, the re€ switch device is easily fitted into a he drilled in the door frame, with the operati magnet similarly fitted to the door. The switch measures 28 mm in length x 7.1 mm in diameter, and is supplied with n pairs of leads; one pair can be looped ba into the circuit. Four reed-switch optic are available: low-cost Form A (normal open); standard Form A; high-power Form and standard Form C (single-pole/doub throw). Heat sink for dual in line packages This new product solves the problem of protecting delicate components when wave or reflow soldering. Beryllium copper spring construction fits 0.3, 0.4 and even 0.6" packages. For really large DIL packages two or more heat sink clips may be used in including DIPs, while interconnections a easily made using standard 22AWG (0.64 mn solid wire. Circuit Mount prototype boards are availab in a range of sizes from small modul designed to hold a single 1C up to 1020 poii panel-mounted boards complete with bindif posts. All separate modules are interlockii and also feature screw holes for permanei mounting. OK Machine & Tool (UK) Ltd , Dutton Lane, Eastleigh, Hants S05 4AA, Telephone: 0703 610944 Prototype boards OK Machine & Tool (UK) Ltd have intro- duced a new series of 'Circuit Mount' boards for electronic projects and prototypes. All boards feature solderless insertion type sockets on 0. lin centres and each row has five common points. Larger boards also feature 40-point bus lines, while a separate bus strip module is also available. Furthermore, all boards can accept standard component leads tandem. The heat sink clip prevents over heating when hand soldering and is ventilated for maximum air flow. Precision made in Switzerland, it holds securely in all positions — it will not come off in handling. Heat Sink costs £ 1 .75 + VAT. Hamlin Electronics Europe Ltd., Diss, Norfolk IP22 3AY Telephone: Diss 10379) 4411/2/3. (15651 ly t affect page found when (1563 M) Tool range Ltd., Upton Road, Reading RG3 45 A Telephone: 10734) 29446 UK 20 elektor july/august 1980 advertiser™ E1.FKT0R BOOK SERVICE 300 circuits SO, digibook 300 CIRCUITS "FOR THE HOME CONSTRUCTOR" This book of more than 250 pages contains clear descriptions of 300 projects ranging from the basic to the sophisticated PRICE £1.95 + 50p postage & packing (UK only) OVERSEAS SURFACE MAIL £2.65 BOOK 75 PRICE £3.00 + 50p postage & packing (UK only) OVERSEAS SURFACE MAIL £3.70 A selection of some of the most interesting and popular construction projects that were originally published in Elektor issues 1 to 8. 30 projects are contained in this book, plus a 'DATA' section which includes a chart of pin connections and performance for common- anode LED displays, valuable information on MOS and TTL-ICs, opamps, transistors and our tup-tun- dug-dus code system for trans- istors and diodes. With over 100 pages, the wide variety of projects in this book stimulates the professional designer to up-date his know- ledge and even the beginning amateur should be able to build most of the projects. SC/MPuter m PRICE £3.20 + 50p postage & packing (UK) OVERSEAS SURFACE MAIL £3.90 Microprocessors are becoming an important part of electronics. One good way to acquire a working knowledge is to build your own system from scratch - and then use it! With this in mind, Elektor designed a simple system based on the National SC/MP chip. The system may be extended to meet various requirements. All possibilities will be discussed in the SC/MPuter books. This first book in the series gives all the necessary information for building and operating the basic system. DIGIBOOK Provides a simple step-by-step introduction to the basic theory and application of digital electronics. Written in Elektor's typical style, there is no need to memorise dry, abstract formulae - instead you will find clear explanations of the fundamentals of digital circuitry, backed up by experiments designed to reinforce this newly acquired knowledge. For this reason DIGIBOOK is accompanied by an experimenter's PCB which will facilitate practical circuit construction. PRICE £4.50 + 50p postage & packing (UK) OVERSEAS SURFACE MAIL £5.20 WHEN ORDERING PLEASE USE THE ELEKTOR READERS ORDER CARD IN THIS ISSUE