9 770268 45 FEBRUARY 2004 £3.70 THE ELECTRONICS & COMPUTER MAGAZINE www,elektor-e!edromcs.to.uk iButton Access Control System complex logic for your own 1 2-to-230 V Power Inverter Electronlf+Val Heart Digital Alarm Clock DIY RF Inductors *s 1 Ep ,yim Touch-Controlled Switch The leaders in PIC development EASE OF USE ♦ ♦ ♦ ♦ All you need to get started with PIC Industry standard/quaiity board Open the box and get coding Available with C compiler or_ use our PicScript to write programs using simpie commands... NO ASSEMBLER, NO COMPILER, JUST WRITE AND RUN AUTOMATION SCRIPTABIUTY PicDev Board with PicScript £99.00 (plus p+p) This is a complete development suite for the novice or non programmer, It is shipped with: . PicDev Board . PicShell and PicScript software . Breakout board . Cables PicDev Board with C Compiler £1 65.00 (plus P + P) This is a complete development suite for the more advanced programmer. It is shipped with: • PicDev Board . PicSheii and PicScript software . C compiler . Breakout board . Cables Example scripts 1CD1 Sim Lf IdJc r Enccsfer RiJLa P ffiinp ty'fn HT\ 6-i-K Mf'CSSl ffajii Board The Vohjme 2003 CD-ROM is automatically sen! fa you when published {February 2004) If you lake out an annual subscription to ELECTOR ELEC- TRONICS you may choose between two types of sub- scription. PICK YOUi © m SmSSCISPTOM TYPE AND RECEIVE THIS SURVIVAL KIT This survival kit consists of a collapsible compass with various functions , a lightweight but robust torchlight (batteries included) and a 9-piece stainless steel pair of pliers with 14 functions. Elekfor Electronics SubscnpHon-PLUS priced at £45.50 (UK). You receive 1 1 issues (includes July/August double issue) plus a copy of the Volume 2003 CD-ROM. This CD-ROM contains the complete Volume 2003 of Efektor Electronics, including diagrams / PCB layouts and an extensive search function. The normal price is £16.25 (plus PSP). However on choosing Subscription Plus the Volume 2003 CD-ROM is included in the price, and you do not pay postage. Your saving: £10.00! Efektor Electronics annual subscription priced at £39.50 (UK). You receive 11 issues (includes July/August double issue). A standard annual subscription costs £39.50 in the United Kingdom; ECONOMY MAIL: £51.30 in the rest of the world: PRIORITY AIRMAIL: £52.30 in Europe and Eire, £64.00 in the Middle East, Africa, Southwest Asia, Central & South America. £66.00 in Australia, Far East & Pacific Territories; AIRFREIGHT: US$88.00 in USA & Canada only, '- Subscription-PLUS prices may be found on the reverse of the Subscrmtion Order -orm, ana on our website. THE ELECTRONS S COMPUTER MAGAZINE On'y a:;' cable if the new subscriber did not sub- scribe to Elektor Electronics in the east 12 months. Offer subject to availabitiy THE ELECTRONICS & COMPUTER MAGAZINE jC. \ r _-asr 3 Z?. Hbnsry 10=4 L5S" - - - ■ -T-c^r.r-; a^d srec r ■ E ■: " 7 " E - 77 V V V . 7 iisr - : I Be c : 1 “jncri-Dgr <’= c ItCCKUklKl Wwrar lcw Htj.vi'g : r ',3"CT 'fSjiJUft'JTK' Erri-; ic'- v a! ' "! = w shsr : f ---i * 5 v-v - !■ ~v E :_ 1 > vit-tiEvy ' ■_■ ■ w . — ■ L.E.™ i .L-.r - ■ .voi-r 3 ; “r— if 7 ' ■■■:•■ * ' : : E E _ v tre - -- ■ --2 5 . :. -■!■ - -- - 2 ~ ::.: 1 z*-mz --.z-'i'z . ■ :r -e cd u -, 7 - f — . I " I “i't; 1 " 7 i Z. 1 II z Z I iTI«Ts 5 ;DOr« 5 J *:Z .C."!_E il = < Caaba™.* n. aaies* =1 Head Oke frrjii : ■J'i'f: :■••: \z 1 £ l.V:?T D“ F t:.ir www.elektor-electronics.co.uk Hands-On CPLDs In the past Complex Programmable Logic Devices (CPLDs) have been something of a dosed book to most semi-professional electronics enthusiasts but this hands-on series should go some way to help dispel that myth. -ire,-, cs : . : . : " Set. ce Hz _ ' : - Z :“-i Z a~z r >— Z zz~ t- : wi: " ' i ■ ■ , ■. 33=ptacse: {^44){0)1 580 20C&57. (+44)^5} 1 53^2006* 6 Br-iLi . £0 ut ■ v. : M — i i _ f r i ” i~f " , 7 1 : " zr. Z :i -citm Hc2d Offite Eegrrer : h.v. BQ 0e< 75 NI-6 L^AE Sesi (4-3 1) 46 43B9444, fee (4*3 1) 46 -amifil E: •■■i i - Ett=_ _cro:n : E.E E':.l~ : CoCiT^ftl f>DL‘ie TtesiaiiSdesatiedntw n^z^eare’'.: dbrneifeL photc ^t^c i' 6 . p i 'faj d?tlgt boar? M an i~ :-= .JlhS in the sdtcect3 ret oyer thsi r^o ™ ptdJjfehesJ in Eec5f 6n\ewcftf5earscsira(3fp£3ai«el«(lii5fio(pc^ L&e to arsv.'Ef ai cor55cc«ferjCE. ?nz At rt tr^ie tc rnccrc '~ ro . r oj^ we sod request fcf*radw 2 fcns to, or adSfefBS ifer* — i: : - zzr-.z. Z . : : ■ 7 sTde 17 1 : mi Ei^;|3^e rE^r^xes. ptease use our BT{Sfeiinr fam tasr) viftch s 2.'aT5G»e ;r ■ : , , ..v ^ ^ v fezd&s Set, :r ■'■4 m riTc =Ljr; . , -_- fer tre proves dssaised r r j r-^i 7 i_ 7 cr. fi - 1 c ;-, T*f,sd 77 r I E * C 2 1 GT jr s.. c a£g&= £r..*r - 1 — ■ £ ffluSf Q O ori PC fl ^ GAL^f^lvi? i ^^3ndE?BOHs-^odi&|iafeta' tuiorg 74 Sneak Preview 74 Index of Advertisers H37: > j a -I- i'm 1 - : ■: -£ Z- *wi •’ ^ ‘ j ( I ntfv -Ji J ’ l *] jcd *| £ Crt j “ ■: Cl f -| DrDA( lata Log ger low cosfo^under £60 Built in sensSrs^for light, temperature and sound (level and waveforms) Light level Temperature External sensors: Humidity Temperature 02 in Air Reed Switch Use DrDAQ to capture fast signals Outputs for control experiments Supplied with both PicoScope (oscilloscope) and PicoLog (data logging) software For more information on DrDAQ, please visit: www.picotech.com/drdaq85 PC Oscillosco ■- Ave-srs Virfyaf /nstrum enf Scope and spectrum analyser functions A fraction of the cost. of bench top scope Save multiple setups for ease of use Save, print and e-mail your traces FREE technical support for life FREE software and upgrades Automated measurements For more information on our scopes, please www.picotech.com/0cope1 53 Tel: 01480 396395 Fax: 01480 396296 E>gnail: sales@picotech.com 1 ft s • to design complex electronic systems nan(«ile l&r E 1 1 C mi taro Hcrai»ntr>Ue» Howe ode fe a programming system for PICmkfo mkracontroHers based on flowcharts. Rowcods Includes mac i os to facilitate the to ntscl of complex devices tike 7 'Segtneot and LCD displays. Floret otfe eUows complete ranrices to design control systems without ge Hi ng bogged down In the programming involved. -■“-t IBCeHIft * Requires no programming experience * Full on screen simulation * Produces PiCmlcro hex code for a range of 8, i8p 28, and 40 pin devices ■ FuSt suite of demonstration tutorials * Allows complex PICmicro designs to he produced in minutes for full sperifi cation see: www.matrixmultimedia.co.uk |fff or contact 115 for a Full colour brochure LUUI email: sales^matriitmulti med fa. to.uk matrix email: s^Us#matrIxrnulti mg dfa.to.uk tel: 0870 700 1331 fax: 0 S 70 700 163 a multimedia Allows you to program PICmicros and test your programs Designed for education, hobbyists and industry Supports low cost Flash programmable PICmicro devices Fully featured displays including 2 line LCD and quad 7-segment LEO Programs most 8, 18, 28, 40 pin devices - including those with ADC capabilities Free download software provides seamless send and verify function 3 CO ROM courses in t, assembly code, and flowchart programming are available fur full specification see; i} j fi H^rj | lifi j-rj . frl" 1 1 1 1 TiTtl u-Ji “J Evr ! 1 ! » lull* ul nit 1 I jiHij g l 1 m r __ t H . f “l 0 t ■ _ C | ..ft-/ or contact us for a full colour brochure £ m a i [: 5 = ic- s matrijunullJaiedia.ca.Lfk matrix lei: 0870 700 183* fax: 0870 700 1831 multimedia - X-*- Extensive l/Oi~ Serial, rDA, SPI, l 2 C, Analogue, rimers/Counters, RTC, etc • Large Memory Capacity: Flash, SRAM, DRAM. •Supports:- lNSI ‘C’ compiler, assem ker all Windows32 base [ Source Level Debug.%^ am Driver Support with ai Time Multitasking OS vyith a free run time licence. ■ fee Unlimited email support. www. a m. uk, com see our web site for full details CAMBRIDGE MICROPROCESSOR SYSTEMS LTD Unit 17-18 Zone 'D' Chelmsford Rd. ]nd. Est Great Dun mow, Essex CM 6 1XG Telephone: 01371 875644 email: sales@cms.uk.com Forest Electronics - PIC and AVR ANSI C Compiler Products FED's ANSI C Compiler for PIC or AVR processors * Fully integrated editor with syntax highlighting, multiple pages etc. * Full project support - include and manage multiple source files, simulator, assembler files and notes 'Comments within one project * Fully integrated simulator and waveform analyser step from C line to C line, or examine code in assembler form. View device pins using a logic analyser application, * Simulator supports LCD modules, keypad, buttons. LED’s, displays, analogue inputs, serial and asynchronous data. * Designed to ANSI C standards * PIC - Supports 18xxx. 16xxx, 12xxx series 14 and 16 bit core processors * AVR - Supports standard and MEGA core processors * Generates MPLAB/AVR Studio projects and source files and completely standard hex output files. Prices from £45.00 - VAVw.fored.co.uk for full details. Wll-C t AVIDICY Drag and Drop rapid application development using ANSI C for PIC and AVR » Rapid Application Development for the PIC or AVR microcontroller using the C language (VVIZ- C for the PIC, AVIDICY for the AVR) ■ Drag and drop your software component selections on to your design * Included components support timers, serial interfaces, I2C, LCD. 7 Seg displays, keypads, switches, port controls, many bus Interfaces including 1 1C and Dallas iBution, AVR P3C Hardware, and more. * Connect software components to MCU pins by point & click * Parameters set from drop down list boxes, check boxes, or text entry * Links your code automatically into library events (e.g. Button Pressed. Byte Received etc.) • Automatically generates your base application including full initialisation, interrupt handling and main program loop • The complete C Compiler and AVR Simulator programs are integrated into AVIDICY - total editing / compilation . assembly / simulation support in one program • Also includes the Element Editor to enable you to create your own components with ease. • Demonstration available from our web site Prices from £50.00 - full details from www. fored.co.uk Forest Electronic Developments 12 Buldowne Walk. Sway LYMINGTON, Hampshire, $041 6DU. 01590-681511 (Voice/Fax} Email - VISA "into@fored.co.uk" Full details from - www.fored.co.uk SOFTWAI Volume MSW |iC - |IP PERIPHERALS & NETWORKS The second Toolbox CD-ROM again contains o vast collection of carefully selected software fools for the electronics enthusiast. In your profession or hobby, how often did you experience that your project failed to reach the target in time because essential information was missing? Toolbox 2 offers new inroads to obtain information you just can't do without. This new CD-ROM contains software tools fop and information about, microcontrollers. However, just being aware of the existence of a microcontroller is often not sufficient — available data often needs to be extended with facts and figures about the right memory devices and com- munication channels. Thors why this CD-ROM gives specific attention to technical documentation [specifications, application notes, standards) about protocols (DiSEqC — Digital Satellite Equipment Control), field buses (including LON and HART), as well as modern information carriers [Smart Media, CompactFlash, SD card, etc.) which find increasing use. The hardware side of things is not forgotten either — Toolbox 2 contains data on connec- tors, cables and adapters (audio/video, GSM, memory, networks, parallel, serial, key- board/ mouse). The CD-ROM also contains a large number of useful Internet addresses. Order raw itsfng the Order Form m iTie Reeders Services section m this issue Elekfor Efetfronks (Publishing) • RO, Box 190 • Tunbridge Wells IN 5 MY * England. Telephone +44 (0) 1580 200 657 ■ fax +44 (0) 1580 200 616 -tUSCTU LtUlUXSt THE FLECTHCNK5 t CO.M.-UTli MAGAlJNi. l-; : .... Kgi See also www. elektor - electronics.co.uk L. m [ip] & Elektor Electronics 2 2004 CDEkklor Cn each CD ycLi wfl find a i ar;: as pj: ishad in the svant year. , rireto dag rams and PC8 ayc^is, an j an extensive sea'ch pre-gram. Tra 1997 grd 1998 CD-ROMs also indude a woridng demo of Bedrofrics Webber: i to rr-p ii?e r s- rriiilafen of seeded Ete&cr projects. CO Elridtr 1596: Price £25 35 (USS 44,85} CO EldkEor 1597: Price £25.35 (USS 44.85} CO Micr 1993: Pride £16.25 ( LES-S 28.751 CO Mm 1999: Price £16.25 (USS 28.75) CO Elektor 2000: Price £1 6 .25 (USS 28.75) CD Mm 2001: Price £16,25 (USS 28,75) CD EUtor 2002: Price £16.25 ^USS Z3 J5) jiP-fC hordw£-r« l software 97-93 A" the itentorg entries c? ire Jute tozirst 1 927 rr crcorKsssoraimset^n: mere than ICC riestos RRP £14.95 (USS 26.45) PC Software 98*99 VTinning extras from toe Jute August 1923 PC senwars compel lion, Vera than 70 prize-?, nring programs i, COS and Windows). RRP £12.05 (USS 21 .25) E-Rootef 1, 2 £ 3 VoL 1: 22 Etetiar E ectrenics prefects co\'eiir ? g msnjpnscessors, contoste .vith taxi, circuit c Igrams and PCS layouts - a e:e:te: r - : temiaL RRP £21.15 ( USS 37.40) ' /oL 2; 19 to: fop recess or-hased o: nst me ii on : i : a:: s corn:: toe v/th text drci'd diagrams and FCB sybifis etectonte formal. RRP £21.15 (USS 37.40) /oL 3: 24 pP .presets in: text PCB layouts and schematics in separate ffes ter editing with EAGLE 3.5 CAD software. Selected presets supp a: .\to IT;':'.: -iGrtrc a a source coda L es. RRP £21.15 (USS 37.40) Tba Audio Cafccftaa CD-ROM A unique CD-ROM ter the true aixfio lover, containing no f6v.gr than 75 aud o designs from E is 'dor Etedrctocs rr-agasre year vriums 1595 ihrouch 1999. RRP £12.06 (USS21J25 Ekkt:r K ddtoii fr^udes all important r.pes cMC. such as HCMQS TTL CMOS, Bnear iCs. and many more. DetaSed manufacturers' :aia ato app zsrion dm its. M_ trite search roiiit nss RRP £21 .15 (USS 37.40) [CD — Diktat's Competent Dclchore Fcurtosratove databanks covering over 5 277 !Cs, aver 22,500 bipolar transistors, over 4,900 FETs, just under 25 JM tf cries, over i .600 opteootoers, thyrislws and triecs. Bus 9 calculator! toots for zener c ade series resistors, vc7a:s regu ators, voriace ci nders, AM 7s, renter are ndicte? values. RRP £12.95 (USS2290) Elekfor Ekcfrcndcs Digild GroJt Elircry (1-2-3) Oil vdsse 1 Contains over 300 eric _ is complete with c era" and tax!. Zee m a to print modjle. Fas: search tec to Errc-r- toterant index search system, Many printed-circuit coarc layouts, RRP £12.05 (US$21.25) On 2 A second ate acton of c-.er 305 crcteis comp a: a ; r (fag ram and text RRP El 2.05 (US$2125) On vfee 3 A tori ssteetrin :: ever SCO z r ctos rr : aia -v to diagism and text RRP £12.05 (USS 21.25) The Ekklcr D:fG$heei Collection, OnYohos 1: Oriririte ato unabridged datasheets, more tear SCO ICs (74xx and 4 Ox series), voltage regulators, inear ICs, raises an setts. RRP £1205 (USS 2125) Oil Vokn* 2: Datasheet of mare than 1C 77 iterate ccrr points: krafligh-power transistors, MOSFETs, thyristors, lilacs, .afac:a r 3. zener d cries. LED c e: avs. etc. RRP £12.05 [USS 21-25) 0a Vohwi 3: tester sate :to :::_ s- - : s'i -air 77:’ ser as. F1C. STS" A/E. COR 6SHC05'frB '1 and SX. Also the DSP21 03 series. RRP £12.05 USS 21.25 On Vdrai 4: Bams j : eats of fjeqjsntiy used mem ■: ry chips an 3 modules. RRP £12.05 iUSS 21:25) m EmrTM/fumtit Difiitfffr Cofuafow On Y&W 5: Mare than 4CC- aatesheefs ccvsri n g m >; ■ : : : ~ r: m tom 4 :a 32 be. in 8-p n to 744 encases. RRP £12.05 (US$21.25) ■ Ci'i: c: • : h ii i : :--C : •: rz 1 Tac- n::-r : : _ : / : i fiii l Shcrews 2900*2003 This series contains hundfeds of freeware arte shareware pregrams retetsc c: eisetror'es. In te rest ha as .ncriza arid csrrponefits, last and measuramsnt, ce. step men- tea's, stmufation, GAD and RF systems. Appficatioos vary from schematic capture indudffig c^tal and anatogue sa’nutetiorjrF^tiipto PCB dalriri complete w/.S cateuiafter toe is and nticroo>ntmler development teo^ Depemfing on their oripis hie programs mn ureter Wtedows, DOS a nd f or Linux. Ear CD-R CM ;ex cepi ,'c . rr.a 2CC0) : cited 3 a FD> fte v, te s ctear cier, a.v-: ; :'::'ari:n:rieCu- mi RRP £12.05 i US$21 25) pervetume Tc:a:x 1 c ii 2 On these CD-RO!,te yaj to: cc acted infoima! (datasheets and appfcata notes) and loots (software) considered to is pe r ate: a w ri a^ w : r- _ : .v r ^'crcca lire tors. RRP £12,05 (USS21. 25) per volume Order now using the Order Form In the Readers Services section In this issue sgll HI i ■ 1: Efekfor Electronics (Publishing) b P.O, Box 190 • Tunbridge Weils IN 5 7WY • England. Telephone +44 (0) 1580 200 657 • Fax +44 (0) 1580 200 616 THE ELECTRONICS £ COMPUTER MAGAZINE See also www Addresses YAvw.xilinx.com wv av.c ooEptd.com JTxilinx www-altGra.com 30 on IC1 to reinforce the input sig- nal via R15. This has the effect of shifting the voltage threshold at which the buffer can switch back (hysteresis) and so masking the effects of noise on the input. vA'AvJatticesemLcom Resistors R14 and R15 control the hystere- sis of a Schmitt trigger input. This is quite important because any noise on the ignition input signal would cause the tachometer to give a false reading. El 5 provides the feed- back from the output side of the input buffer. When the buffer changes state a small pro- portion of its output is fed back out from pin Free Downloads Excel spreadsheet. file number: 030052-1 Lzip PCB layout in PDF format File number: 03005,5- 1 .zip www.e I ekto r-el earo ni csxcuj k/d 1/ d 1 , htm, select month of publication. The PCB and future developments A double- sided PCB has been pro- duced specifically for this tachome- ter project. The PCB and component placement diagram is shown in Fig- ure 3. Component mounting should be fairly straightforward but take care not to allow any solder debris to enter underneath the PLCC socket where it could short between PCB tracks. Correct orientation of the IC is important so ensure that the clipped comer of the package outline corresponds to the corner of the socket and silk-screen printed IC outline on the PCB, Ensure correct polarity of the LEDs, capacitors and diodes when they are fitted to the board. When any circuit uses a line of discrete LEDs the finished project always looks a bit amateurish if the LEDs are not uniformly in-line* A Resistors: Rr-R8.Rr6-R20.R23 - lOkO R9,R22 = I00Q RIO = 3kQ9 RJ I - Ik m Rf2.RI3.RI5 = 4kQ7 RI4 = IkQ R2! - lOOkil R24.-R55 = 270U Capacitors: 0,02 = IQ//F 16V radial C2 = IQOjLiF 1 6V radial C3-C6,C8,CI I = IGOnF C7 = 22pF !6V radial C9 - 220pF 16V radial CIO = 820nF 03,04 = 33pF Semiconductors: D i ,D2,D3 = 1N4001 D2 = zener diode 3V9, 500 mW D4...DI9 — LED, green, 3 mm ICI = EPM71 28SLC84-I5 IC2 - 7805CP T! = BC547A Miscellaneous: Kf = 4-way 5IL pinheader K2 = ! O-way pinheader LI — GBpH choke 51 — 6-way DIP switch X I = 4.9 1 52MHz quartz crystal PCB. available from The PCBShop Disk, order code 030052-1 I or Free Download good tip here is to firstly solder just a single leg of each LED in place. The board can now be flipped over and all the LEDs carefully bent or re- soldered into exactly the right posi- tion before the second leg of the LEDs are soldered. The layout is not too cramped so there is no reason why this PCB could not also be used as a develop- ment platform to prototype other CPLD designs. Those of you how- ever who are looking for the flexibil- ity of a true evaluation board should not be disappointed by our EVA- board that we shall be featuring in a forthcoming ar ticle in Elektor Elec- tronics . 1.030052- It In the second pan: of this article we will take a closer look at the CPLD internals and device programming * 16 Elektor Eledronics 2 2004 Compact GPRS/ GSM Modem k. i k EWPROm JfTS Alpha Micro Components ( www. al ph amic ro.net) has launched a brand new 'AMC18Q2GSXLA dual band GPRS1/GSM2 embedded radio modem module. Developed using RIM ' s superior radio modem, the module is ideally suited for transmitting data to and from wireless mobile elec* tronic devices such as point-of- sale terminals and metering equipment. Measuring just 90mm x 56mm, this highly com- pact modem module supports both the existing GSM radio stan- dard and the new GPRS 'always on p radio connection. Unlike a GSM con- nection, which is billed on a co st-per- second basis, GPRS is charged on the basis of cost- per-byte transferred. Once a GPRS connection has been established with the service provider's host, the module may remain online at no cost to the user, ready to receive or transmit data. By running TCP/IP and PPP on board, the AMG1802GSXLA radio module may be interrogated simply as an Internet address from any web browser. Features include voice support and front end sensitivity 108 dBm typical. PPR IR TCP, PAR and CHAP protocols are supported over the GPRS net- work in addition to modem emulation up to V32 over GSM. The module runs from a single BVolt supply and drives a 5 volt serial interface with baud rate selectable up to 115,200 bps. The radio SIM module may be sited either on the user’s motherboard or on the AMC18Q2GSXLA module itself. Control of the modem is via a standard AT command-driven serial interface with extended register settings for the GPRS option. In this way, the AMC13G2GSXLA maybe seen as a simple dial-up analogue modem to any existing user application. Variants of this module incor- porating GPS (Global Position- ing System) capabilities and 12 volt power source are cur- rently under development for asset management and vehicle tracking systems. Alpha Micro, Springfield House, Cranes Road, Sherborne St- John, Basin gstoke, Hampshire HGZ4 9U, United Kingdom, TeL + 44(0)1256 S51770, fax: + 44 (0)1256 351 771. Wi eb : wwv . r . a 1 p f i a j p. 1 r ro.net (047012- t) New Catalogue of Antennas Alpha Micro’s Special Products Division is pleased to present a new and extensive range of antennas for home, mobile, fixed, hand portable and GPRS us e { www. alph am i cro . net ) . Featuring a wide range of top quality antennas, including single and dual band, 2.4 GHz, DECT and Bluetooth, Alpha Micro provides antennas to suit any requirements from a large catalogue of worldwide manufacturers and suppliers. Responding to the increasing demand for mobile and global positioning systems. Alpha Micro is offering an unrivalled selection of GPS and GSM antennas. Included in the range is an ingenious ’covert tax disc antenna’ that can be discreetly installed behind a vehicle's displayed tax disc and is GSM and GPS enabled, allowing the vehicle to take advantage of both communi- cation and location services. Other offerings include the magnetic mount GPS antenna — a discreet externally mounted device with 3 V or 5 V DC voltage, SMA plug and 5 m RG174, Stylish shark- fin’ GPS and GSM antennas are also available. Lightweight base stations are offered such as the KITE — an ideal local base station with end fed half wave, a base-load whip and 3dB gain. Hie antenna has a VHF and UHF frequency range and comes with a five- metre cable. Hand portable antennas fea- tured include the M4UHF85 — a flexible, overmoulded portable antenna with built-in strain relief, 8-b-mm long M4 thread, helical wound and UHF tuned frequency. Mobile antennas ideal for installation on vehicles include the CAB- MAG 6mm, a mounted, high strength antenna with a rub- ber overmould and four rare earth magnets. For high vehi- cles, the low profile antenna LOWPROUHF is on offer, pro- viding top quality reception without the inconvenience of adding extra height. Alpha Micro is also pleased to offer an acclaimed selection of wireless antennas, including unobtrusive panel antennas for Bluetooth and IEEE602.il, inter- nal and external rubber anten- nas, Of. INI and Yagi antennas. Alpha Micro, Springfield House, Cranes Road, Sherborne St. John, i - — - i Basingstoke, Hampshire RG24 9LJ, United Kingdom, Tel: + 44 (0)1256 851770, fax: + 44(0)1256 851771, Web: www.alphamicro.net (047012-3) 2 2004 Elektor Electronics 17 GENERALINTFRFS Digital Alarm Clock Based on a PIC micro Design by M. Conde de Almeida maconde@terra.com.br Although digital alarm clocks have been around for years, most of today’s off the shelf products suffer from serious design limitations. For example, many don’t keep track of weekdays and can only store one alarm time. High time for a home-brew design that does a better job. Off the shelf alarm clocks present a serious limitation if, for instance, you and your partner have different wake-up times or if you have to give or take medication at regular intervals. This limitation gets more serious if you want alarms to go off only on specific days of the week or only during work days. The time set- ting process on most clocks is also subject to improvement. In the majority of cases you adjust time by incrementing minutes and hours. If your clock Is at, say, G6:15h and the correct time is 20:58h you need to keep a key pressed for quite some time and release it well before the desired hour/minute, switching to ‘slow' setting. If not, you’re past the desired time and have to start all over again. This article proposes a solution for these design we akn esses by dis- cussing a low-cost circuit based on the popular PIC 16F84A microcon- troller from Microchip. Our digital alarm clock keeps track of weekdays and has eight alarms that can be individually set to go off every day only on working days or, if you want, on a specific day of the week. The time setting process allows the adjustment of each digit of the clock separately by means of Up and Down ( Hr and -) keys. It also incorpo- rates some other interesting features. Like all good digital alarm clocks our project has a battery that keeps the clock ticking in the event of an AC power failure. In battery-pow- ered mode the display is turned off to reduce energy consumption. How- ever, if you want to check the time you may still enable the display by pressing a 'display on 1 button. In battery mode the alarms will con- tinue to operate normally. When an alarm goes off the display will be turned on to show the current time. The eight different alarm times are kept in the PIC’s EEPROM. So, you won’t have to adjust any of the alarms again even if the battery fails. A snooze’ key will temporarily turn an alarm off. Tire alarm will be trig- gered again after a minute until it is definitely turned off. A master Alarm On/Off key will enable/disable all the alarms, independent of their individ- ually set states. A bright LED dis- play makes it easy to check the time from a distance or in the dark. The 4-MHz crystal oscillator guar- antees a pretty accurate iimebase for the clock (error = 0.000427%). 18 Elektor Electronics 2 2004 GENERALIKfTFRR Figure E . Circuit diagram of the PEC-based Digital A arm Clock. The hardware Figure 1 shows the complete circuit diagram of the clock. All intelligence (and a lot of logic) is vested in the PIC16F84 MCU in position IC5. Using RA0-RA4 and RB5-RB7 as input port Lines, and REG-RB4 as out- put port lines, a fair amount of exe- cutable code run from the on-chip memory is able to take total control of the circuit, requiring just a 5-V supply voltage and a clock signal generated with the aid of an external 4-MHz quartz crystal, XL Components RIO and Oil guar- antee that the microcontroller is reset at power-on. Switches S1-S5 are connected to the microcontroller's PORTA pins {all configured as inputs). Resistors R3- R7 guarantee a High logic level at the PORTA pins when the switches are open. When closed, these keys will force a LOW state on the PORTA pin they are connected to, triggering the execution of specific clock con- trol routines. PORTS. 6 and PORTS. 7 are also configured as inputs. R8 and R9 guarantee a High logic level at these inputs when the associated switch S6 or S7 is open. 37, when closed, will activate the s Snooze’ function- Similarly, S6 will temporarily activate the display. This function is only available when the clock is operat- ing in the battery mode. Resistors R1 1 and R12 form a volt- age divider fed by the main 12 VDC source. They guarantee a High logic level at PORTS. 5 when the main sup- ply voltage is available. In this situa- tion the display will be permanently on. If for some reason the main power is not available (AC power failure) there will be a Low logic level at PORTE. 5 and the entire display will be turned off by the Software- Looking at the output devices controlled by the PIC, the alarm buzzer Bzl is driven via PORTE .2 while PORTS. 3 controls LED1 and LED2. the Hour/Minute separator in the readout. Four common -cathode 7-segment displays, LD1-LD4 constitute the clock readout. These displays are driven by four 74HCT164 shift registers (IC1-IC4) connected in series. R2 only serves to guarantee a High level to the enable pins of the shift registers. PORTE. i drives the CLOCK pin (8) of the shift registers while PORTB.O drives the DATA line of the first shift; register in the chain (IC1. pin 1). The microcontroller program will clock 32-bit strings into the shift registers whenever a display update is necessary. PORTB.4 con- trols the RESET pin of the shift registers. This port line will be held Low when the display is to be turned off. The regular 12 VDC power may be sup- plied by a standard AC or DC adapter Diodes D3 and D4 will guarantee exclusive operation of either the 9 V battery or the 12 TOC power 2 2004 Elektor Electronics 19 GHSlHQU-INn-RFST ■C source. They will also guarantee that R1 1 and R12 are only powered by the 12 VDC source. The 5 V supply voltage for the logic cir- cuitry is provided by a 780 5 regulator (ICS). Capacitors C3, C4 t Co and C6-C9 help to keep the supply voltage as clean as possible. Current consumption or the clock in nor- mal use {i.e., powered by the mains adapter) is of the order of 75 mA. The current from the 9-V backup battery amounts to about 5 mA. Control software The entire clock program was written in the PIC Assembly Language using the MPLAB Integrated Development Environment {v. 5.70.40) supplied free of charge by Microchip, The source code and Hex hies containing the program ready to be flashed into the PIC microcontroller can be obtained free of charge from the Publisher's website, see 'the Free Downloads' inset. The file number is 030096-11. For those without access to a PIC programmer, the microcontroller Is also available ready- programmed under number 030096-41. The flowchart in Figure 2 summarizes the operation of the program. After an initialisa- tion routine where I/O pins, Interrupt regis- ter, Timer O/Prescaler operation are config- ured and alarms information is read from the EEPROMs into the PIC data memory the pro- gram enters a loop In which control keys are read and, based on their status, a specific branch is taken. Alarm Adjust Routine Time i Rou Adjust ,„e | Briefly Weef Display - t Day " | 030053 - 13 Figure 2 * Row chart of the program run by the PIC. For example, if the Alarm Adjust key is pressed and held down longer than about 3 seconds, the program will execute the Alarm Adjust Rou- tine and, once finished, return to the main loop. 20 Elektor Electronics 2 2004 COMPONENTS LIST Resistors' Rl, RI I ,R!4-R45 = IkQ R2...RI0.RI3 = I OkH RI2 = 2km Capacitors: Cf,C2 = 22pF C3,C4,C6-CI0 = lOOnF C5 = 1000 /jF 16V radial Cl I = 10 16V radial Semiconductors: DI,D2 = LED, 3mm, red, low- current D3 = IN4001 D4 = IN4I48 T! = BCS47 ICI-IC4 = 74HCTI64 ICS = PIC 1 6F84-04/p, programmed, order code 030096-41 IC6 = 7805 Miscellaneous: K l = 2- way PCB terminal block, lead pitch 5mm S I = on off switch S2-S7 — miniature PCB mount pushbutton, type DTS65N LDI-LD4 = LTS430 IE (Lite-On) BZ! = 5 VDC buzzer (active) XI = 4MHz quartz crystal BTI = 9V battery with and clip-on lead PCB, available from The PCBShop Disk, PtC source and hex (object) code files, order code 030096- I l or Free Download If the Time Adjust key is held depressed for less than ah out 3 sec- onds, the display will show the cur- rent weekday. If the key remains pressed longer than about 3 sec- onds, the program will execute the Time Adjust routine and, once time and weekday are adjusted, return to the main loop. When no key is pressed the pro- gram keeps updating the display, checking the current time against the alarm entries in memory and triggering the beeper if a matching times are found. Although it has not indicated by flowchart, the display updating process is affected by the status of GENERALIMTFRRT QQOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO oooooooo oooooooooooooooooooooooo uumroois u mrmr GOh). The microcontroller is configured so that the TTMER_0 overflow will take place every 2,048 ms. This is accomplished by setting the prescaler to divide the HMERO clock by eight. Whenever called, the interrupt handling routine, will increment a 16-bit counter This counter has a maximum count of 29.297 (7271 h). This means that every minute {29,297 x 2.048 ms = 60,000.256 ms or very close to one minute) it will overflow. The overflow of the 16 -bit counter incre- ments the minute- counter (modulo-10) which, after overflowing, increments the tens-of-min- utes counter (modulo-6) which increments the hour-counter and sure it will finally incre- ment the tens-of-hours counter. As shown above, the clock's minute is slightly longer than it should be. This error, amounting to O.OQQ427?3 T will cause a time difference of less than two minutes per year which is pretty low compared to what is achieved by most the off-the-shelf clocks . 21 2 2004 Elektor Electronics Construction The artwork of the PCB designed for the clock is shown in Figure 3. The PCB has to he cut in two to separate the main board from the display board. Start by soldering the wire links onto the main board. Then follow the five IC sockets and all low-profile components. The rest of the construction should be mostly plain sailing as only regular components are used. As always, take care with the polarity of elec- trolytic components like capacitors, diodes and (yes!) the displays. The display board is secured to the main board at an angle of 90 degrees. The interconnections between the boards are made using angled SIL pin- headers or 40 short pieces of stiff, bare wire. The pushbutton actuator rods will protrude a little above the display tops to make them accessible from the outside once the PCB assembly has been mounted behind the front panel. A red bezel may be used as a finishing touch to enhance the appearance of the clock. Using a multimeter, make sure that there's no short circuits between the +5 V supply rail and ground When inserting the integrated circuits always check the correct 'pin V position. Finally avoid ESD damage to your circuit by keeping yourself grounded by means of wrist straps. Clock operation The Time adjustment is shown pictorially in Figure 4. Other drawings are available but not printed here for lack of space. They include: -clock display; - keys and their functions; -alarm on /off key operation; - buzzer control procedure; n n . n n UU'UU Cuf£r.iTF-& Third digit adjusted Press T S dj PfS-SS i acj n u ^ First dig Ft selected Use -rf— Id adjust ii necessary i ] $ First digit adjusted n u Fourth digit Usa -if- to adjust rt necessary I I Fourth digit adjusted PressTadj PfessTadj in. iu° Second digit selected Use 4,-- lo adjust if necessary LTso 4/- to adjust it necessary i I i* Seccr.d digit adjusted Press T ^ to end Adjust Procsss Press T a dj I "I I 9 n u Third digit selected Uss */- to adjust if necessary HI+HH Display Hashes 'HHHH'lo indicate process t-nrf i “I S I o o Clcck returns to normal operation with new lime sal GSMW-ta Figure 4. Time adjustment procedure. - operation in battery mode (mains power failure); - alarm adjustment, The pictures are supplied in the form of a (zipped) pdf document — see this month's Free Downloads, num- ber 030096-12. :: :o- ■: Free Downloads PIC source and hex (object) code. File number: 030096*1 hzip Clock operation pictograms. File number: 030096-12 PCB layout in PDF format. Fife number: 030096- Lzip YAVw.elektor- ejecEronicsxo.uk'dl/dkhtm . select month of publication. 22 Elektor Electronics 2 2004 Visit our website www.d istel.co.uk THE ORIGINAL SURPLUS WONDERLAND! THIS MONTH'S SELECTION FROM OUR VAST EVER CHANGING STOCKS Surplus always wanted for cash! ] GIANT 10” 7 SEGMENT DISPLA YS I IC’s -TRANSISTORS - DIODES A bux £Affri\3se enefcfies ls to ti-feg to jou tossa ■3 AS 7 zte-'i ; new pris! The ICr’’ character etes gSss soteptcrto; rast =o:i]r z£ bng diterecs ere sracies a hcei cf aDcics- fens fodudrig, &COTB boards. cSgftei docks, cocrr tefs s event timers etc. As As Lrzte etc a dmpto EBctciTiodDa^ca- a nest cf ccn-pL^s indudtog IBf.t PC's In CGA, EGA VGA & SVGA modes BBC, COMWOOQRE fnau Qna Urmm 1 1LL . ARCHIMEDES ?.rd APPLE. Msry feahies: E&hed s)d a-v.Tito sr>ii LCiV RADlATTON VPR spohfcadoa FtJy guaranteed. In EXCELLENT Or issd conenon TiK & Swrtvel Base £4.75 VGAcshlaforlBMPClnciJded, r\*+U, - Order as uniy ti^y(E) cg 73 Exti-mal csh-Vss tor other tj-pes of computers j.nLlahe - CALL Generic LOW COST SVGA Monitors We choose the make , which includes Compaq, Mftsubushh IBM. etc. Supplied ready to run with aft cafes. Standard RTB 50 day guarantee. 14 n 15" ir £59.00 £69.00 £79.00 order TD&4 o^dsrTG21 order TJ66 Supplied in good used condition. Shipping cede (D) ni‘ v tested i guars.it'eed i pass; b e m-Ttcr scr-rsn L;-nrs. L-i t 'ack piastic case rc 24 7 V AC malrfa cc. A=:ed. to attrac- r HT x Hior x 1334“ D. Only £79.00 d 3Vr’ COMPAQ 31 37C6-S21 fISMJSgb ULT7SCSI3 SW FUJI FK-3C9-2G 20mb P^PA^ Ur RFE 3fSr CON H ER CP3024 20 mb IDE ffr (or equlv.) R=E " ' IDE 3t COSHER CP3044 40 mb IDE E/F (orequ^v.) RP= I QUANTUM 40S PrttdrrY«42mb SCSI IT. Ne^ RFE 5%“ MIN15CRJBE 3425 20mb MFM Ur for e£piv,> RFE 5'-' SEAGATE ST-234R 30 mb RLL S/F Refute 534“ CDC 94205-51 40?nb HH MFM !TF RFE Lo .5 :□ 1 5YJ HP 37543 ESQ Ms SCSI RFE tested 5' / HP C3Q10 2 Ghyte SCSI differtntiat RFE tests : &' NEC 0224 6 65 L'b SMD i nte f Ta C fe - New S' FUJITSU U2322K 160Mb S’.O br RFE test&d S' F U J IT S U \m 52 K2 G b S M 0 IT RrE tested Many other floppy i H dirves, IDE. SCSI. ESDI tfe from stock, see ivehsi'ts for full stock list Shipping on all drives is code (C) Now £199.00 £59.95 £59.95 £69.99 £43.00 £43.95 £63.95 £69.95 £99.00 £195.00 £93.00 £195.00 £345.00 INDUSTRIAL COMPUTERS Ttey shoebox sized ted: i e - 1 V hz 366 PC system rt as5 „r rd after (mm) 266 w X SB h X 272 d. RX^dcated control &ppi- cations funning DOS. Linux or even VVtedours E Steel case con- tains ©5 to 265 V AC 50 i 60 bz 7Q V« stt P$U. a 3 skit ISA passive backE-'ena and a Rocky 31 S (PCI 04) standard, ante board com- zJ.a r ¥,-'21 S MByte NON VC^ATLE a A 3 5t*ts T:e>.Cp C~.'d' RAM DISK. System comprises; Rocky 316 (PCI 04) S3C ISA card with 40MHz AU 3363X C?U r 72 p-'rs S:MM sfcivoi 16 l.'byle SIMM. A7, J I B OS : battery backed up real time dock. 2x9 pm D 16650 serial perte. EPP/ ECP printer pad. mini DIN ke^-bosnl con- nected floppy pert, ICE port for hard c'm as ld to 52S MByte eapsdty. watchdog line r and PC- ft 04 bus socket The 6 MByte - : = itete m zdk on a chip 1 has iis own BIOS, and can b ekfcked, formatted & booted . Si^pGed BRAND NEW fidty tested and gugr- sTitesd. For fy* data see feature j :e~ c-n weds te. Order as QG36 ' OO’s of 3 pp l tcatioos inc: nnlu TQQ Hfi -- n rewa I . rout ere. rabetf cs etc ^ n I y L a y . U U 0 TEST EQUIPMENT & SPECIAL INTEREST ITEMS ‘SKSSSJ?! ^ JSS. 1 " ^ p iT SUBUSHJ FA344 5 ETK L ’ fuel spec SVGA nxmltofs FARNtLL (T60V t>C @ 50 Amps, bench PcziNef Sucwtees FARRELL AP3080 0-30V DC © SO Amps, bench Suppy K1NGSHILL CZ403/1 O50V @ DC 200 Amps - NEW IkW to 400 kW . 400Hz3phasopc^rewrces ♦exetcck IBM S23Q iyos 1, Tc'^enrlng base urz driver Wayne Kerr RA2O0 Aud'ajfroquency respc"is ans ,se r INFQDEC 1U, 24 port, RJ45 netMxk pstehpanets. ^Th33 SCO’tt 16570 12 Fed. ELFqmet huo - RJ45 cbfinaetzrs =LDE- T 3C051 15571 24 Perl Eteemct huD - RJ45 connectevs 3COM 16700 0 Part Ethernet hijp - RJ^5 cac/tecte3 \T.\ IBM 53F5501 Token Ring lCS 20 port 'aba rrcb^'ai I3M MAU c'<&h r. datre vtic "> z a " a- 5 225- 23- ZC r - \ AIM 501 Low cBsteritert OscSafor 9Hz ;o 33CKhz, IEEE 170 At LG ON 33SQ.1 160o-lS80 MHz hybrid power combteers Trend DSA 274 Data Anatyser vttth G703^M) G4 Vo Marconi 631 0 Prcsqrsjrjr ab5e 2 to 22 GHzaiittp generator Marconi 2022C 1 OKHz-IGHz RF si^tel generator me ra rrir IC-KHz-1 HP1650B Lo^c Analyser HP3781A Pattern gererst:; & HP37B2A Errcr Ds’ector HP 6621 A Oval PnogrsftmabJeGPlB PSU 0-7 V 160 wette HP6264 Rack ntc^r. vcriab-teO-20V @ 20A rr.atsred PSU HP 541 2 1 A DC to 22 GHz four charnel tost sat HP3130A cpt 020 2X ', ( Hz pj’se ccrjcrstof, GPIB etc HP - : ;■ --G. r.’gn spec-e'evm dcze'S HP DRAFTMAS7ER 1 B hich s:=eod plotter EG+G Brook deal 950350 Prtresfon In arrp Kafthiey 530 CV capadtesrV v^ctags ansVser Recal ICR40 cu£ 40 channel vofles reewder system PiR-k-srs 45KVA 3 ph On Une UPS - New batteries Emerson AP130 2-CKVA rndUEtrial sfec.UPS Mann Taliy MT645 H ch sks<: Trte pn-.ter Intel SBC 4S6H33S£Muf:bus 4S6 system. B?.'b Ram £245 £935 £1550 £3950 £P0A £760 £2500 £49 £69 £59 £39 £POA £45 £550 £250 £PQA £4500 £1550 £3750 £POA £1800 £475 £POA £7900 £550 £750 £1£QQ £POA £3750 £4500 £1433 £2200 £945 Trio 0-18 vdc Zr.sar, xetsmd 30 amp bench PSU. Hew £550 Fujitsu .M 304 1 R 600 L = M hie h speed b^nd prin tar £1950 Fu J 3 ts u M 304 1 D 600 LPM prcite r vrte ra t'wc r* it&rfece £1250 Stemsos K4400 64 Kb to 14C M a demux a naf/a-ar £2950 Perkin Elmer 23S B infrared spcctnjfbctcmets^ £500 Perkin Elmar 597 [o^red spac &ophofcxnete £350 0 VG Electronics 1035 TELETEXT Decod Tig L'a’gT ’.'ate - £3250 Li g ht Band 60 output high spec £u rack mount Video VDA^s £495 SekunlcSD 150H IB c^gital Hybrid chert recorder £1995 BSK 2633 Mltzpptxifse pre amp E300 T ayl or Hch s on Ts Jysurf amp “Tar 7 recorder £750 A DC SS20O Carbon dioxide gas detedor/mon&x £1450 BBC AM20 3 PP?.f Mater (Ernest TiiTter) + drive elacfrcnucs £75 All HITSU 9 6 54 A Optical DC-Z5G. b ^vefofm men z-z-r £5650 AH R ITS U M L93A opficai meter £93 0 AH R ETSU F ibre c-ptic charsctenstk: test set £ P DA R&S FTDZ ETuai sand uni £650 R&S S BUF*E 1 Vtekm modutatqr £ 77 5 WILTROH £53 0B 1 Z4 / 2CG Hz RF -L.v-zt p g aneretc J £ 5750 TEK 2445 150 MHz 4 traps Q&b. aaccpe £1250 TEK 2455 300 Mhz 300 MHz oscilloscope reck mount £1955 TEK TDS3S0 4::>,'.-z d g-j nea a + disk drive, FFT ete £2900 TEK TDS524A £0_Mr.zd'gds‘ realms + cate^r display etc £5100 H P353 5A Opt £j / 2£Hz to 4 Q M hz s-KC£rjm anahser £39 50 PHILIPS PW1730 10 ©OKVXRAYtsrierslisr & accessories epoa VARLACS ' Largs range from stock - call Of aeo our wahsrte CLAUDE LYOHS 12A 24GV sinde phase ante, vert rac 5 £325 C LAU D E L YO HS 1C0A 24 C, r 4 1 5V 3 phase a trim, voh rags £29 00 w 19" RACK CABINETS Europe's Largest Stocks of quaE% rack cabinets, enclosures and accessories. Over 1000 Racks from stock This month’s special 33 / 42 / 47 U- High Quality All steel Rack Cabinets 1 * to m Eurocrafi Enclosures Lid to L‘:a highest pos- sible sp&c T rack teat^nes ell steel construction wrii ramcp’/at 5 side, fra-': and back doers. Freni and hack dears a:e hinged for ezsy access and aE TckB.b;e 'rt'Lh Tr.'e secure S levdr barrel locks.. t r.e fre-nt doer is constructed of dcucte vc r h a designer style 1 smekee ' z 'rart sand to sna'c’e status iect catcra to zz sssn through the panel, yet remain unobtrusive. Irtema-ly lbs rack features fuity sicltad re'n- : :-rcsc vert csJ fcdio mambers to taka the heavi- est cf 19" rack equipment The irwo movable vertical futing struts (extras ava ab'e) ere pra puficftod for standard 'cage nUbrt A mains dis* tjibirtkxi panel intemaSy mocnled to the bodom rv a/ F pravxtes 5 x I EC 3 pan Euro sockets and 1 x 13 s.rrp 3 pui switched utility socket Qvaral v^ntte- bon b provided by fu-;/ 1 : ^ r =~£Z :a tx and double farmed fop mdCpn win fcp a.*d sice louvres, TTe Erp p=r= ms.r cs removed for fitting cf integral fans to the slz p'ate sic. Clher features "s'cde. r ned csstefs and ftodr tsv&'s^. prapumched ciiliy pars! at lower rear tor eebto / connector access ate Soppfied in excellent, sfighlly used condition with keys. Colour Royal blue, some grey r. b 3 : t Lj - :e i_:: - ^r, ::"z r :. :- r p,/s:T"S VIDEO MONITORS PHILIPS HCS35 izsr.ie siyfe as eLrai^ive^' sr/.ac co-bur moo-tor wfth both RGB and standard composite 15.625 Khz video inputs T a SCART socket srd separate prsr.o lacks. Integra’ cJd.to power amp and speaker tor all audio visual uses. Wfl eor/vect cited to Amiga and Atari BEG computers, toeel to* efl video monitoring / security aa^ ca:a-s wth direct connection to most colour cam eras. FTgh qua'ity ViHh many totetL’teS euzh as ffc-nt conceded Hap corTtitos J VCR correction button etc. Good used condition - hi v tested - guaranteed COO flfl Dfcne mto ns: W14‘ x Ri2YT x \$’A r D. u n 1 V w 5^11 U (DJ PHI UPS HGS31 LrtJ2 ompact & 1 cokxtf \id=o monitor w'm stan- dard composite 15.625 Kfiz video input via SCART socket. Ideal tor aS fnontoring / securty sppScaSnrt:-. High quality, ex-equipmenl 33U Order as- BC44 : - r"E: m : Ti'=1625H x 6350 x 6C'3 W. {64* H x 25* D x 2Q-/F W ) Only £245 42 U Order as DT20 External c mgrrstons ram-201 9H x ©350 x BOG W. (79.5" H x 25 1 D x 23YT W ) Only £345 47 U Order as RV36 dim8hS;OTS| mrn=2235H x 635D x 633 Y. i'SB T H x 25 r D x 23 ] .£ '.V Only £410 Call for shipping quotation (indoEtoted A specs' bir/ng po-A-sr ’ A quality product tea- turing a to '. cased COLOUR CCD caT=ra at a give away price ! Unit features fJ autotaht sensmg tor use in tow light i high light applications. A 10 mm fixed focus- ■dde angle lens g'.-es excellent focus and resolution from c-ose up to long range, i re composite video output w conned to a_rry composts monitor dr 7\ (via BCART socket} ar-d most video £F ** recorders, Unii runs from 12V DC &c f Qy tdaal tor security ^ portable applica- tions wtere marts pester not avaiab-'e. Overall dinefisbns @6 mm wide x 1 17 deep x 43 high. Suppfed BRAND NEW & fo-ly gue-teriesd w’th user cate, 103 s cf applies- ttons mdudtog Security. Home Video, Wte TV. Web Cards ete, ete Order ss LK33 ONLY £79.00 or 2 for £149.00 »e SOFTWARE SPECIALS NT4 Workstation, complete with service pack 3 and licence - OEM packaged. ONLY £89.00 $ ESCARTA 55 - CDRQM, Not the latest - but at this price ! £7.95 DOS 5.0 c~ 3 V'i T t s-ks with cc-rrctss books dw QBasic . £14.95 ’.T5ndows for Workgroups 3.1 W Dcs 6.22 on 3.5' c ^ £5 5.0 3 Windows 95 CDROM Only - Flo Licence - £19.95 WordPerfect 6 to* I D3 suppled on 3YT desks wtih manual £24.95 sh : pp:ng charges for solty/are is cc :f 3 SOLID STATE LASERS VtstoJe rad. &70nrn laser diode assembly. Unit nats from 5 V DC st approx 50 rrA Crigrtaily made for conttouous use to Irdusteal bar- ~ ~?z s sea n "re "3 , ” e ! = ssr is mounted to a refnc,: i- -: sz d a t .t.' r d "■ z Qck. v,T-ich functions asahstsrtk and r*g d DgZzal mM. Dms c t xk are 5Qwx50dx1Sh fT-Yi. intec^: tea L_ ras a crar terrv psrefoiB shutdown, current control, (az-:-- 0 < c -zr-i c,-r.c ; z T“1 L ON / OFF. Many uses tor Experimental opfes, comms & sghtsfxrAB etc. SuppSed Domptote with data sheet Order as TD3 1 OWL Y £24. 9 5 w DC POWER SUPPLIES Virtually every type of power supply you can imagine. Over 10,000 Power SLrpp//es Ex Stock - Calf or see our web site * RELAYS - 200,000 FROM STOCK Save ££££*s by dttcsLng yptr iwximlsy fmm cur Massive Stocks covering types such as Xffitery, Ocfsf, Gradto, HermedcaMy Hr vrfp rf. 3;r: ■te- r :;=. : ., Cc^tecfcr— . Tr-z- Z-: e. '/■: /. 3: .' Stats, Prkited Cireui t kkxmting etc. , CALL cr sec our web site srsfw.disttiLco.uk fz-r rrora .rto ■ V~. *. - •"-- - stock. Smm ££££s • III * # * * ll|| t • ■ » i t f I I ■ Iff * « ■ « * ft * * i mm mm # t i * l I * • « l « * « ■ ■ * * « ft ft ft ft m him ■ * ft ■ ft ■ ii ft ft * ft ft ft • « « * ■ ■ ft ft ft « ft ft • ft rs ALL MAIL TO Ddpt EK. 29 / 35 Osborne Rd Thornton Heath Surrey CR7 3RD, UK Open f/on - Fri 9.00 - 5:30 IS Million Items On Line Now ! Secure Orde ring, Pictures, Information vtosip www.distel.co.uk email = admhi^tSatBLco. uk Secure Ste ALL m ENQUIRIES 0208 653 3333 FAX 0208 653 8888 26 ■ ■■■■> te =ncss ter LK Mstotond. LK cusfcmas add 175% VAT to TOTAL ontor grrxxrt fiteffnm Oder £10. Bona Fife aocxxii arias r^-n=p»=d tom Ln'.szSes ard LocaJ WfiCffe - nvimun axcxjte erte^ £103. Chex^s £ 1 0Q are stXpct Id 7 woterc. zs.z n eerance. CaTtege (BH3350, (C^iq, (D)=£l5CG, (EJ^CIAOU. (F}=CALL, AJay approx 3 fejS for sFfogtog - tester CALL AJ goods sepcisd tooxStencferi CcrdforBcf Sa3w4KxicsihaifevuBri^ou'v«hs^ and . to Sbcto 2 200“ Elektor Electfomcs 23 GENERAL \~-R ^ The ABCs of inductors By B, Kainka Electronics hobbyists often wish to copy a circuit for which suitable coils or fixed inductors are not readily available. However, you can wind just about any type of inductor if you only know how. Or you can take inductors from old equipment and modify or adjust them. All you have to do is determine is how many turns you need. Low-value inductors are primarily used in R F circuits. A general distinction must he made between inductors with mag net is able cores (made from ferrite or iron) and "air-core’ inductors, which are wound on insulating forms or entirely without any sort of coil form. Air-core inductors Let’s first turn our attention to air- core inductors. Figure 1 shows an example of an inductor for a short- wave resonant circuit, which has 20 turns, a diameter of 16 mm and a length of 36 mm. It has an induc- tance of around 3 pH T and with a variable capacitor having a maxi- mum value of 300 pF it has lower fre- quency limit of approximately 5.3 MHz. How can this be calcu- lated? Read on to learn more... (and by the way, there's also a simple util- ity program to make things easier). For a ’long’ inductor with I > D and n turns, a cross-sectional area A in m 2 and a length i in in, the follow- ing relationship generally holds true: L = (p 0 xn 2 x A) + I where [1q is ihe magnetic constant or permeability of free space and has a value of 4ir x ICr 7 henry /metre 1.2466 x 10 c henry/metre. Although this formula is strictly true only for infinitely long inductors, it can be used as a satisfactory approx- imation for inductors with lengths down to 1 = D. For an inductor with a given num- ber of turns, the magnetic coupling between the individual turns increases as the length of the induc- tor decreases, which yields a greater inductance. By reverse token. L 24 Elekto r El ectro n ics 2 2004 I ft ’NERALINfTFRPTT T tr T 030353 - 11 increasing the spacing between the turns of an inductor decreases its inductance, and this is sometimes used to tune inductors. For inductors having a circular cross section, the above formula can be simplified to the following approximate formula, where the diameter D and length i of the coil are given in millimetres: L = n 2 xD 2 + l [nH] Figure I. Structure of an pin core inductor. Figure 2. Structure of an inductor with an E-l core. figure 3, A inouctor in a resonant circuit Figure 4. A absonant circuit with a loss resistor. This formula includes the approxi- mation Tr 2 - 10, which introduces a small error (approximately 1.3 %). Extreme accuracy should anyhow not be expected, since the induc- tance depends in part on the shape of the coil, particularly the ratio of its length and diameter, as well as the thickness of the wire and even its surroundings. Consequently, for many purposes it is adequate to be able to calculate the inductance of an air-core inductor within a 10 per- cent tolerance margin. Inductors with cores RF inductor forms with threaded fer- rite cores are often used in practice. The core increases the inductance, typically by a factor of four or even more. The inductor can be tuned by adjusting how far the threaded core is screwed into the inductor. Ferrite cores are made for specific frequency ranges, within which they exhibit small energy losses. Significantly higher inductances can be obtained using closed cores with or without air gaps. Although an air gap reduces the inductance, it allows a higher magnetisation levels to be used, since it prevents the core from becoming magnetically satu- rated even at high currents. The types of cores commonly used are toroidal (ring) cores, E-I transformer cores (Figure 2) and closed pot cores. With such cores, the inductance strongly depends on the material used and the geometry of the core, as well as the number of turns. This means that it is nor possible to give a general formula for calculating the inductance, as with air-core induc- tors, Instead, manufacturers state an A L value in nH/n 2 for each core, such that L = Aixn z [nHJ For example, an Amidon T37-2 ring core has an A~ l value of 40 nH/n 2 . If you wind a cod of 10 turns on such a core, you will obtain an inductance of L = 4000 nH = 4 pH. Ring-core inductors, like air-core inductors, are suitable for building RF resonant circuits. Besides the A L value, the design frequency range of the core is also important. Amidon Type xxx-2 cores (with red marking) are suit- able for frequencies up to 30 MHz, The calcu- lation program, which is described in more detail below, can be used to quickly deter- mine the inductance of air-core inductors and inductors with known A L values. Resonant circuits Although resonant circuits are the most important application for inductors, resonant frequency and damping are also significant when inductors are used for other purposes. For one thing, it's important to recognise undesired resonances, and for another thing, it r s very easy to determine the value of an unknown inductor by using frequency mea- surements. If an inductor and a capacitor are con- nected together as shown in Figure 3. the result is a resonant circuit. Electrical energy can 'swing back and forth between the inductor and the capacitor, similar to the motion of a pendulum, and such a circuit has a characteristic resonant frequency. After being excited by a short current pulse, a res- onant circuit will oscillate freely at a fre- quency given by the formula f 0 = 1 - [2re x V(LC)] [Hz] Resonant circuits are often used in circuits where several different frequencies are pre- sent and in frequency mixers. This allows currents and voltages to be distinguished according to their frequencies. A parallel res- onant circuit has a complex impedance Z whose peak value occurs at the resonant fre- quency f 0 . At this frequency, f? c = R L , and the currents through the inductor and the capacitor exactly cancel each other since they have a 180- degree phase difference. An ideal parallel resonant circuit with no damp- ing would have infinite impedance at its res- onant frequency. However, energy losses always occur in practice, due to the ohmic resistance of the coil, magnetic losses in the core of the induc- tor and electromagnetic radiation. The reso- nant impedance thus remains finite. This causes the oscillation to be damped. For sim- 2 2004 Eleklar Electronics 25 GENBMLIKTTFRFT pLicity, the losses can be grouped into an equivalent parallel 'loss resistance' R, as shown in Figure 4, For every resonant circuit, it is possible to specify a quality factor, or 'Q factor’, or sim- ply : Q\ which Is inversely proportional to the bandwidth of the circuit. Q is dimensionless and can easily be determined by taking the ratio of the parallel damping resistance R to the inductive impedance = 2 it f L or capacitive impedance R c = l/(2n f C) at the resonant frequency: Q = R f Rj = R / R c Figure 5. Resonance curves with various Q factors. If a resonant circuit is excited by an alternat- ing current I with constant amplitude and variable frequency, for example using an AC generator with a high internal impedance, the voltage across the resonant circuit will be proportional to the magnitude of the complex impedance Z. Tine voltage will reach its max- imum value at the resonant frequency. The amount that the voltage increases at resonance is inversely proportional to the extent to which the oscillations are damped by any sort of energy loss, and thus directly proportional to the Q factor of the resonant circuit. At either side of the resonant fre- quency, points can be found at which the voltage is reduced from its maximum value by a factor of 1A2 = 0.707 (-3 dB), The difference between the frequencies of these two points is defined to be the bandwidth BW of the cir- cuit. The relationship between the bandwidth SR/ and the resonant frequency and Q fac- tor of the circuit is: BW i-2dB) = / Q figure 6. User interface for the inductor calculation program. Figure 5 shows resonance curves for several different Q factors, A cir- cuit with Q = 50 has a greater band- width [BW,) than one with Q = 110 [BW z l You can also see that the peak value at resonance increases as the Q factor increases. This means that the resonant circuit oscillates more strongly at its reso- nant frequency. By contrast, the var- ious circuits show nearly the same behaviour in regions far away from the resonant frequency. In practice, the circuit damping, and with it ihe Q factor, almost always arises from a combination of series and parallel resistances. The series resistance comes from the wire used to form the coil, and at a given frequency it is greater than the DC resistance of the inductor, due to the 'skin effect'. The parallel resis- tance is determined by the matching impedance in the circuit. However, iron cores and ferrite cores also have losses that can be expressed in the form of a parallel resistance. For a given inductance, an inductor with a core requires fewer turns and thus has smaller copper losses, but this comes at the price of core losses. At high frequencies (above approximately 100 MHz), pure air- core inductors wound using thick, silver-plated wire give the best results, while at medium frequencies (around 10 MHz) the best Q factor can be obtained using closed cores, such as ring cores. However, air-core inductors can also be used down to frequencies of approximately 1 MHz* By contrast, inductors and trans- formers for use at low frequencies use almost always require cores. With careful coil construction. Q factors of around 100 can be achieved. However, resonant circuits can also be damped by connected circuitry or an aerial. This damping can be counteracted by using loose coupling to the resonant circuit ha a small auxiliary winding, a coil tap or a suitable capacitor. When a reso- nant circuit is connected directly to an amplifier, the internal impedance of the amplifier must be very high in order to minimise the damping. Inductor calculations using software A small Visual Basic (VB) program called LCFR has been written to make calculations for inductors and resonant circuits. The source and executable code for this program can be obtained free of charge from the Elektor Electronics website. The number is 030398-11, see this month’s Free Downloads. This pro- gram, whose user interface is shown in Figure 6, calculates the induc- tance of air-core inductors and inductors using cores with known A- l values. In addition, it can deter- mine the resonant frequency and inductive impedance fh of the induc- tor at resonance if a capacitance value is entered in addition to the inductance value. The program consists of three parts that independently perform calculations, which for purely practi- cal reasons are merged into a single user interface. Calculations for air- core inductors are made using the 26 Elektor Electronics 2 2G04 upper portion of the window, and magnetic-core calculations are made using the middle portion. At the bot- tom you can see the calculated reso- nant frequency and inductive imped- ance. If a new value is entered in any of the boxes, the results will change immediately. The most recently cal- culated inductance is automatically used for the calculations in the bot- tom section. Tins program is ideal for quickly trying out 1 new parameters. The fact that the inductance is shown to three decimal places should not be taken as an indication of the accu- racy of the result. Instead, it is intended to allow calculations to be made for inductors covering a wide span of inductances, ranging from a few nanohenries (1 nH = 0.001 pH) to many millihenries (1 mH = 1000 pH). If you want to build a resonant circuit for a specific frequency, you can start by entering the capaci- tance, then calculating the induc- tance and finally determining the number of turns for a type given type of core or coil form. However, a less systematic approach often works better. You can simply select a type of inductor and then try several inductance and capacitance values until you find a satisfactory result. For instance, you may wish to deter- mine which standard component values of fixed inductors and capac- itors can be used to build a resonant circuit that will have a particular res- onant frequency in a specific circuit. Here a trial -and- error approach often yields results faster than systematic calculation. Some practical examples Suppose you want to wind a 330-pH inductor for a medium-wave detec- tor radio on a cardboard roll with a diameter of 42 mm. Further suppose that the wire diameter is 0*5 nun, so 100 turns will yield a coil length of 50 mm. Now you can simply try sev- eral different values, which ulti- mately yields a result of approxi- mately 80 turns. For tuning the medium- wave (MW) band starting at 530 kHz, the variable capacitor must have a maximum capacitance of at least 45 pF: For higher frequencies, you will 2 2004 Elektor Eleclromcs GENERAL need fewer turns. An inductor for a VHF FM receiver, for example, will have only five turns, with D = 8 mm and 1 = 10 mm. The calculated inductance is 0.16 pH. With a 20- pF capacitor, this inductor will resonate at 88.9 MHz, which is almost exactly the lower limit of the VHF FM broad- cast band. The above examples use air- core inductors. But how can you use a fer- rite core? Usually, you won't have any exact data for the core. You will thus have to estimate how much it will increase the inductance or reduce the frequency. An inductor for the short-wave band, for example, might have n — 18 turns, D = 8 mm and 1 = 12 mm. For a pure air-core inductor, this gives a calculated inductance of 1.7 pH. But with a 275- pF variable capacitor, this inductor achieves a lower frequency limit of approximately 5 MHz with the core fully threaded in, which corresponds to an inductance of approximately 3.7 pH. The frequency can thus be reduced by a factor of two using a threaded core, and the Inductance can be up to four times as large. A relatively long medium -wave ferrite rod can in turn increase the induc- tance by a factor of approximately ten. Roughly speaking, we can say that an inductor on a ferrite rod only needs to have approximately one third as many turns as a similarly dimensioned air- core inductor hav- ing the same induct ance. The resonant frequency of a reso- nant circuit can change consider- ably when it is built into a circuit. Particularly at relatively high fre- quencies, wiring capacitances have a significant effect. This means that it is often necessary to make adjust- ments after assembly or build tun- ing capability into the circuit by means of a threaded core or trimmer capacitor. For major modifications, it is often helpful to use a few rules of thumb that can be directly derived from the formulas give above and simulated using the LCFR program. For instance, doubling the number of turns quadruples the inductance and cuts the frequency in half if the capacitance remains the same. Tire frequency is thus inversely propor- tional to the number of turns and inversely proportional to square of the capac- itance. This means that twice the frequency can be attained with one fourth of the capac- itance. In order to tune over a frequency range of 1:3 using a variable capacitor, you need a capacitor with a capacity ratio of at least 1:9* Inductors are not necessarily limited to RF circuits. They are also used in interference fil- ters, low-frequency/audio filters and voltage converters. Schematic diagrams often show only the inductance value, without any other data for the inductor. Particularly in blocking- type voltage converters, the saturation cur- rent level and resistance of the inductor are also important factors. It is also certainly possible to use a fixed inductor with the correct inductance but still not obtain the optimum result. Consequently, it is often worthwhile to wind your own inductors, even if only for initial testing. For instance, a 1.5-mH inductor for a voltage con- verter can be wound on a ferrite rod from an old medium- wave radio. If you have a rela- tively small ferrite rod that originally had 100 turns (which can. be easily counted when you unwind the coil), it must have had an induc- tance of 300 pH, since the commonly used variable capacitors have a maximum capaci- tance of approximately 300 pF. You can thus calculate an value of 30 nHy h 2 . From here it's only a small step to the desired result: you will have to wind approximately 220 turns on the rod to obtain 1.5 mH. Damping, Q and bandwidth If you know the value of the damping resis- tance for a resonant circuit, it's easy to calcu- late the circuit's Q factor, and thus its band- width, This following example shows how a specific problem can be solved using the LCFR program. Suppose you want to build an aerial filter for the medium-wave frequency of 1296 kHz (BBC. AM and DEM) using a fixed inductor. A possible solution can be found using the stan- dard values of 100 pH and 150 pF: The pro- gram calculates a resonant frequency of 1299.5 kHz, and the small deviation of 3.5 kHz lies within the allowed tolerance* The pro- gram also indicates an inductive impedance of approximately 800 Q. If the DC resistance of the inductor (1.7 Q) is taken as the series resistance and divided by the inductive impedance, the resulting Q factor Is approximately 500, which is unreal- istically large* In actual fact, you should assume a Q factor of around 50 for small fixed inductors. Tire extra damping arises from the skin effect and core losses. In order to avoid excessive loss of energy 27 GENERAL I NTTFRF^ 030393 - 17 Figure /.A fitter circuit. Figure 8* Exciting free oscillations. figure 9. Damped self-resonant oscillations. figure 1 0. Ftesistive coupling from the aerial, the filter should primarily be damped by the connected circuit. We thus chose a low working value of Q = 10. This also means that there's a reasonable chance that frequency deviations due to component tolerances will lie withip the bandwidth of 130 kHz. A G factor of 10 can be obtained with a parallel resistance of 8 kQ. If the aerial input of the receiver has an impedance of 50 Q, an impedance conversion ratio of 160 is necessary. This corre- sponds to a voltage conversion ratio of \ 160 = 12,6. If you used a induc- tor that you wound yourself, you could achieve this using a suitable tap or coupling coil. For a resonant circuit using a fixed inductor, a capacitive voltage divider can be used. The initial form of the resulting circuit is shown in Figure 7. The actual resonant frequency has now been increased slightly since the capacitance of the reso- nant circuit has been reduced by the two additional capacitors. You could thus suitably modify the values of the capacitors or provide a supple- mentary trimmer. However, it may be better to first try out the circuit. It may well be that the self-capaci- tance of the fixed inductor partially compensates for this error. In fact, this circuit proved to be satisfactory in practice in a DRM receiver with- out subsequent adjustment. Would it be possible to use a T37- 2 ring core with A- L = 4 nH/n 2 to make a DIY inductor? This idea can be quickly simulated and equally quickly rejected, since 158 turns is an unrealistic value for a small ring core. However, an air-core inductor with D — 8 mm, i = 8 mm and 110 turns is conceivable. If you have a suitable threaded core, you can man- age with approximately half as many turns. This also allows the exact fre- quency of the filter to be adjusted using the core. Measurements If you do not have a suitable signal generator or dip meter, the only way to measure the resonant frequency of a resonant circuit Is to use an oscil- loscope, The frequency can be mea- sured by exciting the circuit so it oscillates freely (Figure 3). This requires a steep-edged square -wave signal with a frequency well below the resonant frequency. Many oscilloscopes have a square- wave output for calibration purposes {usually 1 kHz). This should be cou- pled to the resonant circuit as loosely as possible via a small capac- itor. With suitable adjustment of the time base, you will be able to observe free oscillations. Besides the resonant frequency, damping can also be measured in this manner. Figure 9 shows a measurement made using the previously calcu- lated resonant circuit. What is impor- tant is to affect the circuit as little as possible. This means you should use a 10:1 probe with an internal imped- ance of 10 Mil. The figure shows the result of a measurement made with a horizontal deflection factor of I ps/division. The measured fre- quency is slightly greater than 1100 kHz. The G factor can be determined from the number of oscillations required for the amplitude to drop to 0.37 (1/e) of the initial value. Here the Q factor is approximately 10. The frequency and G factor are affected by the measurement set-up. However, they will be affected even more strongly in an actual circuit. A 10-kQ coupling resistor can be used instead of a 10-pF coupling capacitor (Figure 10), In this case, the resulting oscillations will be somewhat weaker, so a more sensi- tive vertical scale must be selected. Using a resistor for coupling gener- ates higher damping. However, the advantage of this approach is that it avoids any shift in the resonant fre- quency due to the coupling capaci- tor, so the frequency can be mea- sured more accurately. In addition, measurements can also be made over a wide frequency range, from around 10 kHz to many megahertz. This simple measurement tech- nique can also be used to measure the values of unknown inductors. If you use a known capacitance value and measure the frequency, you can then determine the inductance. It is often necessary to try several differ- ent capacitors before you obtain readily measurable oscillations. With relatively large inductances, it is necessary to use correspondingly large capacitors. It is also possible to determine the value of an u nkn own capacitor using a known inductance. The A L values of unknown cores can also be determined using this technique. To do this, wind a small test coil on the core and determine the resonant frequency with this coil connected to a known capacitor. From the number of turns and the inductance, you can then determine the approximate A-_ value, { 333338 * 28 Elektor E fee fro ni cs 2 2004 BOOK THIS DATE IN YOUR DIARY NOW FRIDAY MAY 7 AT THE UNIVERSITY OF WARWICK, COVENTRY 1 THE FUTURE OF THE MICROELECTRONICS INDUSTRY IN EUROPE: IS THE CURRENT UPTURN JUST A BLIP OR PART OF LONG TERM TREND ? 7 Watch out for details in the Subsequent issues ofElektor And on our website. FRUSTRATED ! Looking for !Cs TRANSISTORS? A phone call to m could get a result. We offer an extensive range and with a world- wide database at our fingertips, we are able to source even more. We specialise in devices with the follow ins prefix (to name but a few). 2X 2SA 2SB 2SC 2SD 2? 2S) 2SK 3X 3SK 4N 6N 1 7 40 AD ADC AN AM AY BA BC BD BDT BDY BDW RDX RF BFR BF.3 BFT BFX BFY BLY BLX BS BR BRX BRY BS BSS RSY BSW BSX BT BTABTB BRWBU BLK BIT BUY BUW BUX BUY BUZ CA CD CX CXA DAC DC DM DS DIA DIG GL GM HA HCF HD IEF ICL ICM 1RF i KA R1A L LA LB LC LD LF LM M M5M M\ MAB MAX MB MC MDAJ MJE MJF MM MX MP3 MPSA MPSH MPSU MRF XJM XE OM OP PA PAL PIC PN RC 3 S \A SAB SAD SAJ SAS SDA 3G SI 3L SX SO STA SIK STR STRD STEM STRS SY1 T TA T A A TAG IBA TCTCA IDA TDD TEA TIC TIP TJ PL TEA TL TLC IMP TMS TPL U UA UAA UC UDX ULX l~M UFA UPC LTD \ X X YR Z ZN ZTS -f man) 7 Olivers We can also offer equivalents (at customers' risk! We also stock a full range of other electronic components Mail, phone. Fax Credit Card orders and callers welcome r SVWTTOf r VISA 1 Connect . j Cricklewood Electronics Ltd 40-42 Cricklewood Broadwa\ London NW2 3ET Tel: 020 8452 0161 Fax': 020 820S 1441 Special Offers :: ■TEKTRONIX : 2445A > r h Delay. Cursors etc. SuppSed will 2 TetirOffc probes. i mus a# H P. 545TU Dg&srg fisc lOQUEtf _ ZAl 5 CtftSUiS CRL754 set.nl ffBa CsSxsZl LEG ' £95 BFftMJUK HD1 1 1 3 5 BiLU 23 Flirty vth 8jfea>\ tesds & cirryTg l>5£ - £31 VfATHE KERR S424 T: “ -CtBsjt _ 1:1 HACA1 43£G Trut FU5 lq taints. £5* RAEAL mm 35 iM £?3 .... Just In ... HP. wem Egnsl Gemma mim 5Q0KHZ'i12UHz £25* KtJiWODD GSL325 Ekj$ Trace SOUHz „ El 25 Inlet LB8523 Ctedtoscc^w Trass Fiji] SQHiH 0S3N QsSlSCepi ItelTfSCeWHE . t;5 HATlOHAL PAMA5 GNiC YP7715A Affit/Stf . EtZS KEXW0GO VTF /6 MiShtfaNK ittSsSEl £58 XEHWDftD FL14B Yinm £ FEcggrli&fSer £:7 KQIWD0 D FU &A Wun & Outer ltUrtfeed JTSPtewQfl Blri431HtolA^r £75 Ed ' jrc; iy r. . i S23 Farnell DTV 12-14 Oscilloscope Dual Trsi5 12 Mttz TV Coupling flr.ly Farnell LFI Sine/Sq Oscilloscope IDHz * 1 TSKz Only OSCILLOSCOPES MAS CO ?i i I ^-7 C : f ' '-’-.t- Sroi 1 ’ ms. ft Ifea seJ £1M ttssa ____ £■;; MAE COK1251-3 --.r= T A5 Yci't-fiCff. k.Hxa^3Q 3ft - 25M>iz t Cl 95 COULD J38 Sre^q (fee 1GHz - 1QQK1 kz£xjv (Saarfon £75 £125 AV05 IOS n Cf^TI<W C-LS4. w£l] c5c. £ H P. mU Un fei Q1 KZ-I3JC(Z AfiLHi Sfl^ TnSgtf 8*53 J'Tn. rLifflptWse E3N fASKE. 1L A.ttrrsSc LfexJ Utfer Ifensed I ' .E3M fARKEll 0-501 Low ft=q ESgfei ESa hum OfeioT&B TTUS^ag^ P^fee *$£, RULE II::' : " w r l': : ' ' 1 - : : : ■ ... 2$ tfesJ ES5 M.P. 3J1(A Ftn ©s 0E5HZ-5WHZ El 2 5 5 - - r= 'Ez”- ?Jls* Huuihii L=?>i : : : : Lbb ITL OtlpaL H_P_54SJi nTh SVFALnjk: i'c i-"- FLUKE 77 - -n^rf 3 S: : ■ FLUKE 11 Si ^ | PW Eli _:mi '.I wt .’ lit.-l" zr.'-rj::: 1 THUH pEffili'tS Fiartssa t-i'et::' 1 j. 2VH.E ThdFLlS] THJJiOEF PSU Fl2Vv2 HI. - 7-1 ■ " :a itz ZM. :- Racal Datron Iu^pr “ Ti Quaffly 6.5 Digit Bench Muttimot^r -VS a Dr«AVOsF: COOCWRL GVT«7 Ch jMJ tfiEM&ss&s IS -?.-,vss . CHe-i _ SDlAPITtEg Ji 7TEg D L r ’. r : Ed : : Jr. t SQiAHTROM pls __ \\ \ : : Hhih OmjJIi m 5&I4 i£5X-£i-:-vu : r L z~. WA Fjuoem. Haasoo^w r i - 'i Ell HEOS ITS?/; 0-2SA p^iff suffTr Kfisano B“3wto-iaft f ATimi ttea PSU 3W35-ZT 0-HV SF2A Tme» CUD. LEO »S?ilay 1_ El SB farmll <> 2 A sty FARM ELL 00-1 G-3W O-IA EH :■ l.L: :: Ij= it -i ■. d t- : u. - :_t e : : , - £4j UiTTLAl: T UL/LLHlF ■ 50r 1 'I IS9 (knt T cks KCWMj IQS ffWfl £1SM ! - : -■ i ' ■ , : - : ■ ■■ ttflBOWU tHS3tQ Obfld TfKS SGUE& LEEHOT 5iXA Djb _ ^:.i "i* -ir 31 WT1CH Ctei 7rs2 2SUEb 33^ rnps - 5;sz ::c -: :l;l- flin EVL^dilC::- T Jii l^r tMt -u- = : • \ k Ol Oral (nee I DGUKz Dfe . lAi* I :ri:i I'zl ~sr.i 'Iv^ TcaK Qi£/ 5 i: i :-5feB*TiKg?: : ^ C\ iJfTRO-Ct ^£33 Dofl Toes TOC' = •• . - : : : >K>3 Ohu^’ :l: 7tw5 ir : . : ■ :i> ■:-£■£ . Sr US £32 IS 1 1 l-ES S§5 Uls £=7: E&i: £ti3B z£iil 2i£t: idttt' Ili = 2 in:: KSM li 15 £lEt3 Oal Spectrum Analysers £ : £ " E £ 1 -- -r ~ 1 ; 7 5 t'3 j z -l'l- " "-i“ - - : j- 1- .. .. ££112 " 7 : - r 7.-- : -.7..- fiii5 : : £3 El'S ::.:a :■" -:o< -i-y y £73; J ill:: - ’ ■ - rfVif ’ . ■ hj-'fi i| ’J- Z £lf£‘3 :-£.= J.;.' ■ -- ,, £3359 . fllP HP. MMUTFOT R413IB EAIOflimdbcb m £iW;-2?5^[ _ IWlttftf Z352 tEJQKs WHOM Z37Q S3H2 ll£WHt_ H? :1 ■ J.::' HP.UfT Sjitena Ss53 £ SOfe-iIMJKi 1 : I'l- i‘J.: NIC. : F:F£ - - mug ^ ■ 1 ; ViL'iSf R72A rnzfusfiif £ Tim Araifsa— P. zTf-F.- 1 - ".ci V: ..'f HP. 2577A K*ncrt /craSysef &S^2£ltftfrc HP. 533JBL Itomca&ja iasara Og»Cff Dfef) SOtB Cf 5td rcrainfe rfl HP. SwJW PSJ 0-OT f 0-2A h f ->::■;!= : :- h p. psh tag (Mar Bvilisuy HP.6SKZ9 H £rI2£4 ?G. : --:=: O.c.- *-r I " : :-. 7 £ 1 I - fLP^ljfent 34M1A CUV 55dgfc HP. ansi UMU 55 dijfl „ FUt££ £.7 :mr && hSThiLfi : : ;:iV ‘HTHbf -y - -v?r outer foil g rou n cf — > i n n sr foil hot' end — > inner foil ground — > older foil oscilloscope in X-Y rradc: X = generator. Y = pftJD-s Q 3 OS 20 - 12 Figure z. Left: .vrong po arisation; hgbi: correct polarisation. 35 2 2004 Elektor Electronics DNTROi 1 FR Touch oiled Switch With a PIC Design byj. Wickenhauser www.wickenhaeuser.com You don’t need special ICs when a capacitive (or ‘touch’) switch can also be realised with an inexpensive PIC controller. This article shows how it’s done. Over the past few years several manufactur- ers have come up with special integrated cir- cuits for touch control switches. These ICs usually operate on the principle of capacitive change, work perfectly but are hard to obtain as well as relatively expensive. Fortunately a capacitive switch may also be realised using Traditional' means, i.e., a little physics and a microcontroller The human body may act as one plate of a capacitor, with the ocher plate formed by a coin soldered onto a copper plane. The principle is illustrated in Figure 1 . Assuming the coin has a surface area of 3,2 cm 2 and is placed at a distance of 4 mm (using an acrylic plastic disc as a spacer) and a dielectric constant of 8, a theo- retical capacitance of 8 pF is obtained, or 2- 3 pF when the pad is not touched. A second capacitor (C2) is charged via two resistors. In reality the three switches are microcontroller port lines with GP1/GP2 rep- resenting signal ! A and GPO, signal 'B\ The measurement comprises the closing of the two switches for 2 us using signal ‘B\ The 2-gs period allows capacitor Cl to almost fully charge via El, A very small portion of the charge (the amount is negligible) also flows to ground via R2. Next the two switches are opened and Ci is allowed to charge C2. As soon as the voltage on C2 exceeds a certain level {here, about 0,7 V) the measurement is finished. Signal T 1 disap- pears and C 2 is discharged. This marks the return of the measurement cycle to its start state. The number of iterations it takes to fully charge the second capacitor is counted — it’s as simple as that. The simultaneous charging and discharg- mg of C2 may appear a bit of a con- tradiction. However, a small portion of the charge in C2 is also lost, because the switches are open much longer than closed- The smart button Ideally, about 20,000 cycles are required to enable G2 to be charged by the users finger. Consequently a measurement takes about 50 ms. As soon as the software has recognised a 'key press' action on GP3, output GP4 is pulled Low, causing the indi- cator LED to light up. At the same time, the number of cycles for each measurement is output via pin GP5. An oscilloscope or a pulse counter connected to GPh will clearly indi- cate the approach of the finger. As you can see from the circuit diagram in Figure 2, the microcon- troller used is a cheap and easy to obtain type PIC12C508 which has 512 bytes of memory If you happen to have a ‘509 lying around (with 1024 bytes) it can be used also. The R-C oscillator inside the PIC operates at about 4 MHz. The printed circuit board shown n Figure 3 is single -sided. Normally the copper plane on the board is suf- ficient for reliable operation. In cases 36 Elektor Efec Ironies 2 2004 ■ ~ measurement R\ R 2 signal Figure I . Principle of operation. Q f- 01 2 Kl SIG O DIGO O ■+5V > GND o- GID GP3/MCLR GFO EC1 03<4l4 - 11 5 GP4Q1 GP1 PIC12C50X Gp2.Oi.CL GP^T 5 RS GO- R2 10k hi l&Sk R3 w 1 00k T1 C2 EC347C PA 01 J / i \ V f i \ \ > lOOn Rgure 2. Circuit diagram of the Touch-controlled Switch. MEBQCCMBQLLER Free Downloads PIC source code for use with Microchip MPLAB assembler. File number: 0302 14-11 zip PCB layout in PDF format. File number: 030214- 1 .zip www.e le kto r-electron ics . co. uk/dl/dl. htm . select month of publication. COMPONENTS LIST Resistors: RLR6 = lOkil (SMD shape 0805 ; R2,R3,R4 - fOQkQ (SMD shape 0805) R5 - IkD (SMD shape 0805; R7 - 4700 (SMD shape 0805) Capacitors: Cl - 470nF (SMD shape 1206) C2 - IQGnF (SMD shape 0805) Semiconductors: D I = Chip LED, red , SMD shape 0805) Ti - BC847 (50T23 case) 1C I = PICI2C508AO4, SOS, programmed, order code 0302 1 4-4 1 Miscellaneous: Kl = 4- way mini PCS terminal block, lead pitch 2.5mm PAD = sensor area {see text) PCB. order code 030214-1 Disk, PIC source code file, order code 030214-1 I or Free Download where higher sensitivity is required, the surface area may be increased. The circuit is capable of adaptive operation. This means that the trig- ger point is shifted (within limits) to compensate for effects like dirt on the touch pad Only relatively fast capacitive changes are recognised as valid actions. Also, the fact that the measurement is completely done in software can be exploited by mak- ing clever use of the energy re due- — IfTnC. I f^HMH tion features offered by a PIC. Because a measurement takes only 50 ms and it is sufficient to do measurement every 500 ms, the controller could be 'asleep most of the time. The upshot is that the average cur- rent con- sumption of the circuit can be reduced to 0,1-0. 2 niA without problems. The circuit is made relatively immune to constant external RF signals by the software varying the speed of signal 'A' to some extent. {D38Ef4-l‘. r # "\ Figure 3. Copper track layout and component mounti ng plan of the tiny PCB designed for the circuit. 2 2004 Elektor Electronics 37 mMsmcmm switch radio-controlled mains sockets on and off from a PC by K. Heiden The wide availability of low-cost switched mains sockets with radio remote control provides a simple way to control electrical equipment, lights, etc. using a PC. Using radio not only means that we do not need a cable, but also avoids problems with electrical safety as the interface is electrically isolated from the mains supply. As USB interfaces become more widespread on PCs the serial and parallel ports are becoming less and less important. Most computers, however, still offer the legacy" ports which are available for new rigure l . The handheld transmitter (ELV part code rS 10 S8'2) before modification. applications, now that devices such as printers tend to use USB. The par- allel port, for example, is ideally suited for controlling electrical devices remotely. Using a simple switch interface it is possible to turn household appliances on and off under PC control. So as not to add to the cable spaghetti already associated with the PC, the remote control described here uses a modified radio-controlled mains switch. These are available from various outlets including spe- cialist electronics shops as well as D1Y and housewares shops. Gener- ally two or three switched sockets are sold as a set along with a single hand-held remote control (see Fig- ure 1 and Figure 2). In order to control the switches from a PC we will need an interface to connect the parallel port of the PC to the hand-held remote control transmitter. If the facility for manual control must be retained, the best approach is to purchase another transmitter, as the unit connected to the interface will be attached to the parallel port using only a short cable and so it will not be convenient to operate it manually. Interface Circuit The parallel port interface circuit (Figure 3) is essentially divided into two parts: the part that drives the remote control transmitter using optocouplers, and two optional extra switching stages built around IC1 and two relays. This switching cir- cuit allows for the control of two additional devices, located near to the PC, directly from the interface. If this feature is not required, the switching stages can be left out, and signals DO, D1 and D3 (port pins 2, 3 and 5 of the 25- way sub-D plug) left unconnected. Port signals D4 to D7 (pins 6, 7, S and 9 of the 2 5 -way sub-D plug) are connected to the remote control transmitter via a quad optocoupler device (IC2 T type ILG74). Figure 1 also shows the pinout of this device. The circuit diagram only shows the part of the remote control trans- mitter circuit that is connected to the interface circuit, namely the push- buttons and the connections for the power supply. The pushbutton con- nections for the transmitter are brought out on four wires labelled A to D and connected to the output transistors of the optocouplers (see 38 Elektor Electronics 2 2G04 Figure 2. A radio-controlled switched mains socket (EL\ FS 10 system). also Figure 4). When the port pin driving an optocoupler goes high, its output transistor conducts, bridging the corresponding pushbutton con- tacts on the transmitter. The effect is the same as if the button had been pressed (channel 2 on/on. channel 3 on/off and so on). We can arrange for the pin on the parallel port to be taken high using suitable software. The components between the paral- lel port and the optocoupler (the series resistor and the diode) serve to li m it current flow and protect both the input LED of the optocoupler and the output transistors of the parallel port. The interface circuit also includes a power supply for the remote con- trol transmitter. The transmitter bat- teries (two button cells in the type we used) should be removed and connections made to the points marked ‘A and in the circuit dia- gram, A voltage of 3 V for the trans- mitter is derived from the 12 V sup- ply of the interface using D2. H1L C3 and Zener diode D3. The interface circuit itself can be powered from a 12 V mains adaptor connected to K1 or by connecting to the PC’s internal 12 V supply. The optional switching stages connected to port pins DO. D1 and D3 are equipped with one normal relay (with one coil) and one latching relay (with two coils). They are con- trolled by driver IC1 {type ULN2B03). The latching relay (RE1) is con- trolled using port signals DO and D1 and has the feature that its state is preserved when power is switched off. In contrast, RE 2 is an ordinary, non -latching, relay and is controlled using D 3. Its contacts are closed only while current flows in the coil. Switching pulses can be generated using this relay with a duration under software control. Thus it is suitable, for example, for driving an electri- cally-operated door latch from the PC, con- necting the relay contacts in parallel with the button for opening the door. You may be wondering why there are no protection diodes across the relay coils: this is because suitable diodes are already built into the ULN2803, A 25- way male sub-D connector is required to connect the interface circuit to the parallel port. A cable with at least eight con- ductors is required for the connection, with the 25-way sub-D connector at one and suit- able connector at the other. If it is desired to use a spare ordinary printer cable, a 36-way Centronics- style socket will be required. Figure 3, ! he circuit of the para ltd port, interface connects to the handheld transmitter \ia optoco upset's. Tvo relays are also available. 2 2004 EEektor Electronics 39 Figure 4. I he pnnted circuit board (author's design) of the so:derec to it to connect to the interface circuit. handheld Transmitter y/f th ' r es Construction The simplest way to construct the interface circuit is to use matrix stripboard. The com- portents are all widely available and so should be easy to obtain, A suitable latching relay for RE1 is available for example from Conrad Electronics (order code 50 40 60), For RE2 practically any small 12 V relay can be used. As can be seen from the circuit diagram of the parallel port interface and from the pho- tographs. a few connections need to be made to the remote control transmitter using short lengths of insulated wire. The connec- tion points are easy to find: they are simply the contacts of the pushbuttons. The cir- cuitry inside the transmitter can be quite tightly packed, and so solder- ing can be a little fiddly Things are not too difficult with the FS 10 remote control system available from the German company ELV that we used in our prototype: as soon as the enclosure of the transmitter (part code FS 10 S8-2: see Figure 1) is opened up and the caps of the pushbuttons removed, the contact points of the pushbuttons me visible {Figure 4). It is very easy to solder wires to these contacts, connecting the transmitter to the optocouplers (points A to D in the circuit). The figure 5. I he sv< itching interface built into a plastic enclosure. pushbuttons can no longer be used The completed assembly can be protected by a plastic enclosure (Fig- ure 5, which shows a slightly modi- fied version of the interface). The Software The control software is as straight- forward as the interface circuit. All it has to do is set the individual bits of the parallel port high for a period of about one second, and then low again. We do this using a COM file, which is created in advance with the aid of a VB (Visual BASIC) script. First type in the program Mk_C0M,vb$ shown in the text box using any suitable text editor (such as WordPad or Notepad), and save it under this name in any directory on the hard disk. Now nm the program by double-clicking on the filename: this will create the hie SETLPT.COM in the same directory The VB script can now be deleted. The various switching actions can be carried out using the follow- ing commands: SETLPT 1:01 switches the latching relay on. SETLPT 1:02 switches the latching relay off, SETLPT 1:08 switches the non-latch- ing relay (briefly) on. SETLPT 1:10 switche s rem o t ely-c on - trolled mains socket 2 on. SETLPT 1:20 switches remotely-con- trolled mains socket 2 off. SETLPT 1:40 switches remotely-con- trolled mains socket 3 on. SETLPT 1 :8Q switches remotely- con- trolled mains socket 3 off. The space after 'SETLPT' must not be omitted. The digit S 1 T after ‘SETLPT' and the space refer to par- allel port LPTL The characters after the colon are hexadecimal digits which define the value which will be sent to the parallel port: two digits must always be specified. The assembler routine sets the parallel port to the value given after the colon for about 1 s F and then sets it back to zero again so that only a brief positive pulse will appear on the data line. If you have a second parallel port (‘LPT2') on youi com- puter which you wish to use with the interface, then the command 40 Elektor Electronics 2-2004 BEADEBS should read ‘SETLPT 2:XX\ A note for PC experts: the I/O base address used for LPT1 is 0378 hex, that for LPT2 is 0278 hex. You can create a shortcut to the file SETLPT.COM with parameter "1:08’ on the desktop, and call it Open Door', Then, when someone rings the doorbell while you are busy at the computer, just double click on the icon and the door opener will be activated. To prevent the DOS win- dow appearing, right-click on the icon and select 'Properties', Then, under 'Shortcut' select 'Run min- imised’ and Close window on exit'. Conclusion Tiie author has been using the circuit for many months without any prob- lems, mainly in conjunction with an SMS remote control circuit previously published in Elektor Electronics. If you prefer to control the inter- faces using Windows, there are small programs available on the The following file, Mk_COM.vbs\ can be typed in and run to create the assembler file SETLPTCOM’ automatically. Alternatively, the file SETLPT.COM' can be down- loaded directly from the Elektor Electronics website at -v w,e ! ehLQr-eiecLronic5.co ,uk (select this issue). d = "186,120,003,138,030,130,000,128,251,049," d = d & "116,007,128,251,050,117,030,254,206,160," d = d & "132, 000, 044,048, 177,004,210, 224 , 138,038, " d = d & "133, 000, 128,236,048, 008, 224 ,177,001,056," d = d & "200, 116, 009, 208, 225, 117, 248, 184, 001, 076," d = d & "205,033,238,187,000,004,226,254,075,117," "251,184,000,076,238,205,033" t = split (d, Set xso = CreateOb ject ( " Scripting , FileSystemOb j ect" ) Set File = f so, CreateTextFile ( "SETLPT .COM", true) for n = 0 to ubound(t) : File. write chr{t(n)) : next Internet which allow the parallel port signals to be set high or low. Simple parallel port interfaces using Windows software have also been published in the past in Elektor Elec- tronics T and that software can be adapted for the interface presented here. Examples include the 'Universal Paral- lel Input /Output for PCs' on page 20 of the April 2000 issue and ‘Centronics Interface' on page 28 of the April 1996 issue. The book PC Interfaces under Windows 5 is also recom- mended. ■ffjf.-. i Digital Logic Compared December 8003. p, 98. 030317-1 Tee drawing in Figure 2b is incorrect. Toe input should be connected directly to the FET cares The anode or the lower erode should go to ground and die cathode of the upper die des to -rVcc. protecting the inverter input against harmful over- and undeivoltages. HCProg 2003 FAQ This project from our September 2003 issue has been immensely successful and ;he ioiIov;i::a fre- quently asked questions (FAQs) have been gathered from read- ers correspondence regarding this design. Tire answers are provided jointly by the author and our in-house design s taff T I'm having problems wish GOMDLG32-OCX 1 An error report pops up zelling rue OCX is on: c: date. in most cases, this problem may fee solved simply by copying all o ex ' fifes to the Windows System or Wmdows\Systen}32 directory 2. READ on a PIC16F84 fails. Noth- ing happens. 1 get error roc or: TRAXSPnSSIQX FAILED or a READ ’.window opens and nothing happens The op ere lion is coca - £i or r In su cue ssfuf ybu're looking at bad communication between PC and programmer, usu- ally with laptops and notebooks. F. place 1 3 w ith a B C547 . c — : : R 2 0 and fi: a 10k resistor between pin 7 of K2 end die base of T3. A inLure version of the software will coma is communication error signalling and reporting' 3. . h e PI C 1 zF r 74/i ca nn o : he pro- grammed: however no problems are encountered with the stan- dard version (no A suffix . The A versions employ a different algorithm. Support wdl be incorpo- rated in an update. 4. Car you offer supper: lor the PIC16C54, -CSS and -C57? Sony we ran':. These processors have been omitted right from the T: : . :.-e they in::-, exyem s:ve ;ban comparable Flash types A'e may investigate the czssdifwer mmnMmmEjMr: of usmg equivalent types from the !6C55x series with serial me ruin a capafeaiuea . This is qu lie c am - pH eared however 5. Will there be an update for the 1 Sxxx series? T::-.-:- new AIL a:: mm - ::: supper through an update However we need to get samples hist. 6. Erasing a PICJ6F628A and mp io- grammmg it produces an error at a duress 1 . G _ T;j e saw e : v: z h zh e PIC15F73. The problem is unde- investigation. i: may he the same as with :he 16F874A, A 16F73 has only just arrived 7. Where can I buy or download the HEX or BIN hie to program my own PIE in position ICG? As already explained in ar. earker Terre mm Up date ’ l vmmrsr 2003 vie cede cannc: ire me He available because the author receives royalty payments for every copy sold of the ready-: : mi rammed FIG. 5 There's the its: of PIC devises :Ta: can da handled 7 The Oat can be retrieved from the Windows pic gram iisr.f i. v far you: convenience, here's a printed ver- sion!: I2C 508. 12C6G8A, 12C5G9, 12C5G9A 12C.R5C9A 12CE51S. 12CE519, 12G671. 12C672. 12CE673. 12CE674, 12F629, 12F675, 16C505, 16C554, 16C556, 16C55& IT Oul IGCtZ in C 62 A, 1GC62B, 16C620, 16G620A 16C621, 16C621A. 16C622 16C622A 16CE623, 16CE624 t 16CE625, 16F627, 16LF627, 16F627A, 16F628. 16LF828, I6F628A 16C03, 16G63A, 16F630, l6C64 r 16C64A. 16C642, 16CS5, 16C65A, I6C65B. 1GC66. 16C6G2, 16C67, 16F676, 16C71, 16C7IG AT 11 15C7I2. 16C715 16G7I6. 16C72, 16F72. 16C72A, IGC73, 16F73, 16C73A. 16C73B, 16C74, 16F74, 16C74A, 16C76, 16F76 16C77.16F77.. 16CP33. 16FS3 16C84 16GR84. 16F34 16FB4A 1GF87. 16EB8. 16F8I8, I6F819 : 16F370. 16FS71. 16F872. 16FS73, 10F873A. 16F574. 16F874A 16F876. 16F876A 16F877 16F877A. 2 2004 Etektor Electro nics 41 ERALINfTFRFS iAccess an intelligent access control system Design by I. Joostens Surveys show that people are feeling increasingly less safe. Consequently, protecting property and buildings receives more and more attention these days. One of the aspects of such protection is access control. The system described here goes further than most such systems. Besides granting persons selective access to specific areas, iAccess allows you to check who was granted access to which area and when. 42 Elektor Electronics 2 2004 GBgMLlSfMPT Features at a glance - up to 125 keys can be programmed - Independently controls two entrances using two readers - access privileges can be individually configured for each key - protected against scanning - system configuration using an LCD menu or an RS232 link to a PC - outputs can be configured as monostable (door opener) or bistable (relay) - door openers can be powered by AC or DC voltages - optional indicator LEDs - programming port for easy firmware updating - activities can be logged via an RS232 link - backup power supply using a leadracid battery - High reliability ensured by a watchdog timer communications via the RS232 interface and controls the peripheral components. The microcontroller used here has 2 KB of EEPROM, which stores the physical key num- bers (as engraved on the iButtons) and asso- ciated access privileges, as well as the sys- tem configuration parameters. A special progr ammin g interface allows the microcontroller software to be easily updated. As the program uses a fairly large number of interrupts, it was not possible to have the microcontroller maintain the time of day using software. Consequently, a real- time-clock IC is used for this purpose. Nowadays, access control systems are available from quite a few manu- facturers. These are usually either quite elaborate systems designed for thousands of users and offering a large number of features, or very lim- ited models that are more suitable for private use. Most commercially available sys- tems use electronic keys, such as magnetic cards, badges, iButtons, or transponders. There are also models that use PIN codes and/or biometric features. The circuit described in this arti- cle combines the versatility and fea- tures of the large systems with the simplicity and ease of use of the small, stand-alone types. Here iBut- tons axe used as electronic keys. Rel- ative to other key systems, iButtons offer quite a few advantages, such as ready availability, a high level of robustness, and the fact that the user interface (reader) consists of only a simple set of contacts. Fig- ure 1 shows a photo of an i Butt on with its associated read probe. Two entrances are independently monitored. The circuit includes a dri- ver for a door opener as well as a relay output. The latter is suitable for enabling or disabling an alarm sys- tem, among other tilings. An optional link to a computer can be used to configure the system and record events in a log file. Concept and block diagram The overall structure oft he access control system is shown in Figure 2, As can be clearly seen, the key ele- ment is a microcontroller. It looks after reading the iButtons, handles Figure i . A DS9092 i Button with associated read probe. 020 1 63- 12 figure 2. Block diagram of the access control system. 2 2004 Elektor Electronics 43 NTFRFS Figure 3. Schematic diagram of the complete system. 44 Elector Electronics 2 2004 The user interface is formed around an LCD module, four push- buttons (including the reset button) and a miniature buzzer. To reduce the number of I/O pens used, the LCD is driven in 4-bit mode. The iButtons are read using an intentionally simple 1-wire interface. As the length of the 1-wire bus will be relatively short in most cases, and only one 1-wire device will be con- nected to the bus each time, the bus does not have to meet particularly severe requirements. Key readers can be fitted with status indicators using red and green LEDs. The system can drive most types of door openers that are suitable for use with a X2-V supply voltage. A circuit specially developed for this purpose allows the door opener to be driven using an AC or DC voltage as desired. To prevent possible dam- age to the access control system or the door opener in case of improper use or fault conditions, several sup- plementary protective measures have been incorporated. As already mentioned, besides the door opener driver circuit there is also a relay output that can be used for additional switching functions. Finally an expansion connector has been added for users who wish to experiment with the circuit. Power for the entire circuit is provided by a lead- acid storage battery that is continuously recharged by a mains power sup- ply. This provides two significant benefits. First, in case of a power outage the system will continue to operate from the battery for an extended length of time, so access to an area or building remains assured. Besides this, using a stor- age battery allows the mains power supply to be relatively mod- est in size, since the short current pulses needed to operate the door opener are provided by the battery instead of the mains supply Schematic diagram The full schematic diagram of the system is shown in Figure 3. The functional blocks shown in Figure 2 can be recognised here without too much effort. The most important elements are described in more detail below. 2 2004 Elektor Eleciromcs Microcontroller user interface, RS232 interface and programming port Microcontroller IC1, an AT39SB252. is used here in a quite conventional manner. No external program mem- ory is used; all of the firmware Is located in the microcontroller's 8- KB Flash memory. A fully pro- grammed version of the microcon- troller can be purchased from Read- ers Services, but the source code and executable software are also available from the Elektor Electron- ics website or on a pair of diskettes (see the Components List). The microcontroller can be pro- grammed via connector K4 using a standard 1:1 serial cable (not a null- modem cable) and a computer run- ning the Elektor Electronics MicroFlash program. The microcon- troller must be held in the reset state while it is being programmed. This is done using pin 4 of K4 (DTK), with the necessary level adjustment being provided by R9. R12 and D4, in combination with IC10 T a 74HC126 quad tri-state buffer, D urin g pro g r amming , I C 1 0 causes the signals on pins P1.5-P1.7 of the microcontroller (SP1 bus) to be connected to K4. Here IC2 (MAX232) acts as a combined level adapter and RS232 driver. When the DTR line on pin 4 of K4 again goes low, the outputs of IC10 go into a high- impedance state, which isolates the programming interface from the rest of the circuit. In tills state, SI acts as a normal reset button (in combina- tion with Rl, R2 and Cl). The serial port (RS232) is built around an MAX232 in a conventional manner and is available on connec- tor K3. BZ1 is a miniature piezoelec- tric buzzer that can be driven directly from a microcontroller I/O output. Real-time clock The real-time clock is formed by a PCF8573 (IC3) in combination with a watch crystal (X2) and a trimmer capacitor (C22). The IC T which can be completely controlled via an IC interface, accurately maintains the date (day and month) and time of day (hours and minutes). R3 and R4 are included because the microcon- troller P0 port does not have internal pull-up resistors. 1-wire interface The 1-wire interface is connected to micro- controller interrupt pins INTO (P3.2) and INTI {P 3. 3) via several resistors and Zener diodes. When an i But ton is held against a key reader, the associated I/O pin of the microcontroller is briefly pulled to ground. This generates an interrupt, which triggers an interrupt routine drat ultimately reads- the data from the iButton for farther processing by the main program. As the internal pull-up resistors in the microcontroller have fairly high resistances, R5 and R5 are included to provide additional current for the 1-wire bus. According to the 1- wire protocol specification. R5 and RG nor- mally have a value of at least 1.5 k_. but if the distance between the key reader and the access control system is relatively long, bet- ter performance can be obtained by using a somewhat lower value. From experimental tests, a value of 820 O will allow the system to easily handle a distance of more than 100 metres between the access control system and the key reader. R7, RS, D1 and D2 protect the I/O pins against high voltages from electrostatic dis- charge or attempted sabotage. For instance, they enable the microcontroller to survive someone holding a 9-V battery against the contacts of a key reader Buffers, logic and drivers A ULN2803 (IC4) is used as a driver IC for the various indicator LEDs and the output relay. Tills IC contains eight open- collect or drivers, each of which can switch a maximum current of around 500 mA. IC11 and 1C 12 are included because the microcontroller I/O pins cannot supply enough current in the high state to properly drive a ULN2803, and because we prefer to use active -low signals at the microcontroller level (since all I/O pins are high during a reset). These ICs have a dual role. First, they act as buffers between the microcontroller and IC4, and second, they form a logic circuit that also provides the necessary signal inver- sion, This allows the microcontroller software to be simplified, 50- Hz signals are present on pins 6 and 8 oflCll for driving a door opener. Door opener interface The door opener is driven directly by 105 , an L6202. This 1C. which is actually intended to be used as a motor driver, contains a full H- bridge using MQSFET technology. It can han- dle a continuous current of 1.5 A and peak currents up to 5 A at a maximum voltage of 48 V. Both halves of the H bridge are driven by the 50-Hz signals from the microcontroller. Whether the door opener actually receives any current depends on the signal at the 45 GENERAL INTERS Enable input of the IC This signal is set high by the microcontroller after a valid key has been presented. However, this does not hap- pen just like that; there is also protective cir- cuitry In the signal path. The first protective circuit is built around IG6 f which is a 555 wired as a monostable timer with a period of approximately 30 sec- onds. When the signal on pin 2 oflCll goes high, T1 is switched on via R25. This causes the trigger input of ICS (pin 2) to be briefly pulled to ground until C24 has been charged The rising edge on pin 2 of IC11 does not affect the Reset input of ICS, which is active low, so the timeout starts running at this point. If the signal on pin 2 of IC11 returns to the low level during the 30 -second interval, the falling edge on pin 4 of IC6 will reset ICS. The direct effect of this is that the output signal on pin 3 exactly follows the Enable sig- nal as long as it does not stay high longer than 30 seconds; otherwise IC6 will indepen- dently disable the output signal. This prevents the door opener from being enabled for an extended length of time, which would be detri- mental to both the coil of the door opener and die lead- acid battery. A second protective circuit pre- vents ICb hom being overloaded and acts as a sort of current limiter. The current flowing though the door opener and IC5 reaches ground via sense resistor R24. The voltage across R24 is fed via R31/C34 (for noise suppression) to NAND gate IC13a, which is wired as an inverter. As soon as the voltage on pins 1 and 2 of IC13 reaches half the supply voltage level, IC13 will see this as a ‘high 5 logic level and pin 3 will go low. This occurs with a current of approximately 1,14 A (2.5 V © 2.2 Q). This will cause timer IC7 to be trig- gered via pin 2 and start a timeout of around 1 second. Pin 3 of IC7 will go high, and overload indicator D21 will be illuminate d. The Enable signal on pin 2 of 1C 5 will be pulled low via IClSb-d, interrupting the current. After 1 second, 1C 7 will reset itself, and if the overload condition has been corrected the circuit will again be operational. If the overload is still present, IC7 will immediately be retriggered after resetting itself. The net result is a series of short current pulses at a one-second rate, which will not harm 1C 5. Power supply The power supply consists of a charging circuit built around voltage regulator ICS and a small lead-acid storage battery rated at 12 V 1,2 A, To keep the ripple component of bat- © -O o + ^pOQQQQQQ, V^y _ O o FU2 0 R9 Q R1 O RIO O Q4 1 o D3 | o; ECS ’O'O' 0"0"0'0‘0"0 o 9 oo 9 o Cl 4T 1“ £ cs C. £ 0 000 oq 0 oj S ,°q oqj OOOOOOOQQQQQOOQQOQOQ 00000000000000000000 o.P. Q . opo 1C11 0 00 0 Q O Q p O O JC12 OTTU gO Q Q Q Q Q Q C36 1C10 < o][oo 7 'o 0 0 0 0 0 0 r , Q-Q-Q-Q-Q- Q _Q_ CLP. foooooooooooooo ,£32 ,, C24 o-o|]jo ofjoo U? C\ Ci ci; c: O j D24 |[ Q R31 R29 R3G ^ D21 \4 rr o o o C31 K11 r\J iN O «N Ck Ka F4 F3 00 2) 4 1 f* k ft 00 ^gune 4, The circuit is assembled on a double-sided printed circuit board. The LCD is connected to KL 46 Elefctor Electronics 2 2004 GENERALINTFRfV iery charging voltage as small as possible, smoothing capacitor C18 has been generously dimensioned. DIG prevents current from flowing in the reverse direction during a mains outage. Diodes D11-D15 are included to provide temperature compensation. If the temperature increases, the voltage across the diodes will decrease, which will cause the charge voltage on the bat- tery to increase. The charge voltage can be adjusted within certain limits using P2. Components list IC8 = LM7805 TO220 IC9 = L200 Resistors: IC 1 0 = 74HCT 1 26 RLRI7 R20 = IkQ IC 1 1 = 74HCT04 R2 = 47kO IC 1 2 = 74HCT08 R3.R4.R25.R26.R3 ! = lOkQ IC 1 3 = lx 74HC00 R5.R6 = 1 kQ5 R7,R8 = I00O Tl = BC547B R9-RI2 = 27kO Miscellaneous: R13 = 1 kl 25 BZI — DC (active) buzzer. 5 or 6V RI4 = IQS 5W FI “fuse, SOmAT (slow) with PCB R15 = 3k09 mount holder RI6 = 4kQ7 F2 = fuse* 630mAT (slow) with PCB R2 \ , R22 = not used mount holder R23 = ! 0Q F3 = Fuse, 2A5T (slow) with PCB R24 = 2Q2 5W mount holder R27 ^ 1 MQ F4 = fuse, IAT (slow) with PCS R28 = 330kQ mount holder R29 = 220Q Kl = 1 6 -way boxheader R30= lOOkQ K2,K9,KIG =3 -way SIL-header PI — IGkQ preset K3,K4 = 9-way sub-D socket P2 — 5 kH multiturn (vertical (female), PCB mount, angled ptns mounting) K5 = 2-way PCB terminal block, lead pitch 7.5mm Capacitors; K6.K8 — 2-way PCB terminal block. Cl = 2uF2 10V radial lead pitch 5mm C2,C9*C 1 2- K7 — 14-way SIL pinheader Cl 7.C20.C2 1 .C23.C26.C27.C32 .C Kl 1 - 3-way PCB terminal block. 33.C3S.C36 = lOOnF lead pitch 5mm C3.C4 - 22pF REI = V23 057-80 D02-A20I (12-V C5-C3 t C!Q = IOuF S6V radial relay, ! changeover contact) C II = 220uF 25V radial SI -54 = pushbutton, 1 make contact CI8 = 2200 uF 35V radial TRI = mains transformer, 2 x CI9.C31 = 220nF 9V/I2VA (e.g,, Monacor Monarch C22 = 5-40pF type VTRi 2209) C24.C30.C34 = 22nF XI = 1 2M Hz quartz crystal C2S - !00tlF 16V radial X2 = 32,768kHz quartz crystal C28.C29 = !5nF Heatsink for EC9: Fisher type SK 1 29, 38.1 mm high, 6.5 K/W Semiconductors: Sealed lead-add battery I2V/I.2 Ah DI,D2 = 5VI SOOmW LCD module, 2 x 20 characters, D3,D4 — 4V7 500mW HD44780 compatible, e.g., Hitachi D5-D9 = 1 N4007 LM032 or JHDJM202A DI0.DI8.D20.D2i = LED. red. low PCB, order code 020(63-1 (see current Readers Services page) DH-DI5.D24 = IN4I48 Disk set {2 pcs), contains source code DI6 = IN540I Hies and control software, order D 1 7,D 19 = LED, green, low current code 020 1 63- 1 1 or Free D22.D23 = BYW98 IC1 = AT89S8252-I2PC, Download programmed, order code 020 1 63- Also: 41 Any no. of i Buttons type DS1 990A 1C2 - MAX232 Optional: i Button holders type IC3 = PCF8573 P DS9G93A IC4 = 2803 or TD62083AP Reader probe type DS9092 IC5 - L6202 IC6.IC7 = NE555 (optionally -L or -T) Construction, alignment and commissioning The circuit is built on a double- si dec! primed circuit board with plated -through holes, which is illustrated in Figure 4. Despite the complexity of the schematic diagram, assem- bling the board should not present any sig- nificant problems. Use IC sockets for ail ICs and check that the values and polarities of the components are correct before soldering them in place, since it can be difficult to unsolder components from a circuit board with plated-thiough holes. After assembling the board, do not imme- diately fit the ICs in their sockets, and leave the LCD disconnected for the time being. Turn P2 fully to the left and connect K5 to the mains. Using P2. adjust the voltage on K6 (the connector for the lead- acid battery) to exactly 13.8 V Then check the 5-V supply voltage at pins 1 and 2 of Kl and at each of the !C sockets, except for IC4 and IC5 (which receive 13,8 V). Switch off the mains voltage and rotate C22 so the plates of the capacitor are half engaged. Set PI to its mid-range position* Now insert all ICs into their sockets and connect the LCD to Kl using a length of 18- way flat cable. Switch the mains voltage on again. At this stage, it is quite normal for the circuit to not do anything, since the firmware is missing. Using a standard 1:1 serial cable, connect the programming port (K4) to a free serial port on a computer. Unzip the Zip file con- taining the firmware and put all the hies in a folder on the hard disk. Start rhe program MicroFlash.exe, which is located in the folder with the firmware, and select the proper COM port. Click on 'Flash hex' and select hie f iacov35.hex' or equivalent {depending on the version number). The microcontroller will now be programmed. Depending on the speed of your computer, this may take a few minutes. As soon as the programniing is fin- ished, the microcontroller will be reset and the main program will start to execute in Hun mode. Normally, buzzer BZ1 should emit a short beep at this time. Using PI, adjust the contrast of the LCD. If everything has gone well, the following text will now appear on the LCD: 'IACCESS 3.5 Mo 00:00’, ‘Rim... 1 Allow the entire circuit to warm up for IS minutes, and then use P2 to again adjust the voltage on K6 to 13.8 V as precisely as you can* If you have a frequency meter, you can connect it between ground and pin 11 of IC3. You can then adjust C22 so the signal has a period of 7.8125 ms (12S Hz). If you don't have 2 2004 Elektor Electronics 47 GENERAL ► Program neiu key Bp ply key to reader Select key nr JM Key ■$! stored Replace key 5 51? Key DO! stored _U Key exists dOD Edit key ► Bcces rights out! Recess ouH* J? Access ora El on? _ y m i mmm Access on Sun? _ u / Rcooss times out! trnmj.1V 50 to fjflfcOO ^ Access rights cut 2 Access out?? _Y Access on Men? y i ■ ■ Access on Sun? _ y p- Recess times cut2 from_00:0i| to Or 03 ^ Back to r« a inmenu ► Erase Ley Select key nr _001 Erase key 001? Ji Key 601 erase d Key 001 is empty ► Set clock Timejlo 11/01 m.W ► Output i properties Output type Jlono Output delay _05s ► Output 2 properties Output type Jlono Output lie Ley _05s ^ Output current Set _hC current > Return to run mode 'late . Over, ev, of the menu structure. a frequency meter, you can adjust C22 by feel , depending on whether the clock runs fast or slow. Even without any adjustment, the clock is quite accurate. After fitting the circuit board into a suit- able enclosure, you should attach an identifi- cation label as illustrated in Figure 3, As this is a mains -powered device, this is obligatory in connection with electrical safety. Basic settings Provisionally connect four pushbutton switches to the SI— Si positions on the circuit board. These buttons have the following functions: SI = Reset. S2 — Enter, S3 - Down, $4 — Up, Also provisionally connect an iButton probe to pins 1 and 3 of K2, with the centre contact of the probe attached to pin 1 and the ourer contact connected to pin 3. Press and hold the Up button. Briefly press the Reset button and wait approximately two seconds, then release the Up button The sys- tern will enter the configuration mode and display a menu on the LCD. You can now use the Up and Down buttons to page through the various menu options. Do so until the option 'Output I properties' appears, and then press Enter. Then select Output type Mono' (you can use the Up and Down but- tons to select one of two options: ‘ Mono’ or l _ Bl ). Press Enter and select a time, such as Output delay OS s’. Press Up or Down until a time of 5 seconds is set; then press Enter. You will be returned to the main menu. Now select the option Output 2 properties’, and under this option select 'Output type _Bi r as the output type. Pressing Enter will again return you to the main menu. The door opener interface has thus been configured as a monostable interface with a period of 5 seconds, and the relay output has been con- figured as bistable. Select the 'Output current:' option in the main menu and press Enter. Then use Up and Down to select- "Set _AC current' and press Enter. There is little point in setting the time before the board has been fully fitted in its enclosure and the lead- acid battery has been connected. Select 'Program new key' and press Enter. The message Apply key to reader' will appear on the LCD. Hold an iButton against the iButton probe. Once the key has been correctly read, you will hear a short beep, and the physical key number will be shown for 2 seconds on the LCD- After this, ‘Select key nr. GOT will appear. After you press Enter, the key will be stored under number 1. If you wish, you can use Up and Down to select a different key number in 48 the range I -125 before pressing Enter. Key numbers already in use are marked by a # sign (e.g. 065#). Finally, select "Return to runmode 1 in the main menu and press Enter. The system will execute a reset and return to the run mode. Now discon- nect the middle lead of the iButton probe and connect it to pin 2 of K2. After this, each time the iButton that has just been programmed into the system is held against the reader probe, relay RE1 should be actuated. You can also test the door opener interface by again connecting the iButton probe to pins 1 and 3 of K2. Connect a load to K8 that can handle a 12-V AC voltage. If you use a 'heavy' load (> 300 mA), you must connect the lead-acid battery to K6 and allow it to charge if necessary. Each time the iButton is held against the reader probe, power will be applied to the load for 5 seconds. Overview of the menu structure The menu structure is quite simple and intuitive. If you use Table 1 as a reference, you should not have any significant problems. Nevertheless, a few remarks axe in order with regard to keys and access privileges (which are called access rights' in the menus). A particular iButton can only be stored once in the memory. If you try to program the same iButton into the system more than once, an error message will appear. Access privileges are assigned per key at three levels: - Level 1: door opener or relay output For each key and each door opener or relay output, you can specify whether the key is allowed to acti- vate the door opener or the relay. - Level 2: restriction to certain days of the week For each key and each door opener or relay output, you can specify which days of the week the key is allowed to activate the door opener or relay. - Level 3: restriction to certain times An access period can be assigned Elektor Electronics 2 2004 GENERALINTERES - Connection to a computer Besides manual operation using the LCD and push- button s T a computer can also be used to configure all of the system settings. If a large number of keys must be programmed into the system, this method is con- siderably faster and more convenient than the manual method. This is all made possible by die Windows program 'iAccess remote console which is also avail* able on the diskettes listed in the Components List. Using a standard I : I serial cable, connect K3 to a free serial port on the computer and then start the program. The first time you use the program, you must check the settings i9600 baud, BN I j and modify them as necessary. In the iAccess console' menu, select Establish link to remote system'. You now have to enter a pass- word (which you can choose yourself the first time you use the program). Click on Continue, and the message 'Link established' will appear after a few sec- onds. RS232 control active and 'Link established...' will be shown on the LCD. The system is in now in configuration mode. Now you can use various menus to modify all the configura- tion settings of the access control system and program or edit keys. It is also possible to generate a backup and/or reset all of the programmed keys, along with their associated access privi- leges. This function is extremely handy if you wish to update the firmware of a configured system using NicroFlash, since doing so will erase the EE PROM in the microcontroller When you are fin- ished, select 'Disconnect from remote system' under the 'iAccess console' menu, and the system will return to the run mode. Each time a key is read, information is displayed on the bottom line of the LCD, This information consists of the time when the key is read, the key reader number, the key number ( 3-1 25), and the result code (0—4). The meaning of the result code is as fol- lows: 0 = the presented key is accepted, and the associated door opener or relay output is activated. 1 — unknown key 2 = no access privilege for the door opener or relay in question (Level I j 3 = no access privilege for the current day of the week i Level 2) 4 = no access privilege outside of the access interval (Level 3 ) All of this information can be stored in the computer. This only requires 'Enable event logging' to be activated under the 'IAccess console' menu. If desired, the program can be minimised to an icon in the system tray. It is also possible to start the program in minimised mode, with event logging being immediately active, in addition to the information shown on the LCD. several other items are recorded in the log file, such as: - result codes 5 and 6 (warm and co3d resets); — the state of the door opener or relay output i on or off ); — the name of the user (see below); - the physical key number as engraved on the i Button. if desired, several additional items can be recorded for each key, such as the name of the user (key holder), key label date issued, date returned, etc. Summaries of this information can also be printed out if desired. This information is also used in the log file and when the keys are edited in configuration mode. Hake suEe the tafgel system is connected to yaui corripideE. EiVtef Lhs coaiecl paiswo-td and ckck ths “ConliiTiue 1 button. The ptocedure take: about In a seconds. hne’(^, (ho taigel IX display should show the r.essags TIB 232 Con-mi active'^ 1_ink established..' Password _.Er i tor , . 1 ior vc T . i i i r 3r Even t bggng dufcted Available software for iAccess (ref. 020 [ 63-1 I, zip, Free Download) File name Size Ti r row a re version 3_5.zip S3. 1 33 Executable 2_2.zip 1,087.471 Source 2_2.zip 669,005 Content of Firmware version 3_5.zip File name Size I ACC-V35.A5 1 163.172 Description Microcontroller source code, version 3.5 Widows software for recording events and configuring the access con- trol system, version 2.2 Source files for the Windows software (Delphi 5 Mote the source code car. only he recompiled using Delphi 5 Professional (or a higher version; with the DEIS AM database engine installed; see www.eIevatesolt.com. Description Version 3.5 source nie 2 2004 Efektor Electronics 49 GENERALIMTRFV IAGC-V35.LST LACG-V35.0BJ I ACC-'/ 35. HEX Content of Executable 2_2,zip File name Size f Console exe 2.300.416 ioonsole.ini 507 KEYLOC-DAT 7,807 KEYLQGJDX 8.192 EXTRA.DAT 14,735 EXTRA. IDX 28,672 BACKUP DAI 30,166 BACKUP IDX 16.384 1WETCTRL.DAT 1 ,663 n^IETCTRL IDX 8,102 286,299 7.108 19,692 Listing file generated by the assembler Object file Intel Hex Lie ioi programming the microcontroller Description iAccess F. emote Console version 2 2 executable file Configuration parameters and various settings for iConsoIe Database files containing logged event data Database Lies containing user data and additional key information Database Lies for generating and restoring b aekups of the keys dace- base Database for receiving external commands via a computer network reader unit 1 reader probe red LED green LED reader unit 2 Figure 5, The I Button probes and Indicator LEDs (D ! 7-D20) are combined to form two reader units. for each key and each door opener or relay output. The key can activate the door opener or relay output only during this time period. Note that access privileges at a higher level take priority over access privileges at a lower level. For example, if a key does not provide access to door opener 1 based on Level-1 access privileges, access is effectively denied Red LED Green LED Meaning blinking at 0.5 Hz off system waiting for a key off on door opener or relay activated on for 3 s off key refused on off system in configuration mode Table 2. Status LED indications. to the key regardless of what privi- leges may be assigned at Level 2 or Level 3. Building and connecting reader units For practical use, the iButton probes must be fitted into robust reader units that can be installed adjacent to a door or other type of entrance. For the prototype, cast aluminium boxes were used for this purpose. Besides an iButton probe, each box was fitted with red and green status LEDs. The necessary connections me shown in Figure 5. The wiring between the main cir- cuit board and the reader unit can best be made using standard UTF network cable. Make sure that the terminals of the iButton probe are connected using a single twisted pair in the cable, such as blue and blue/ white. For outdoor applications, you should preferably use a DS9092L probe or possibly a DS9092T probe. The DS9092 model is not suitable for outdoor use. since raindrops can cause shorts between the outer con- tact ring and the contact surface in the middle. The iBuitons can be fit- ted into small holders (type DSS093) that are intended to be attached to a key ring and to which a number can be affixed. Finally, Table 2 provides a brief summary of the indications provided by the status LEDs. Additional information about iAc- cess is also available on the author’s website at 1 ttp www it : cj g£ign __ Free Downloads All project software. File number: 020163-1 Lzip PCB layout in PDF format. File number: 020 1 63- 1 ,zip www.g I ektor-el ectronios,co,n k/ dl dl-htm . select month of publication. 50 ElektOf Electronics 2 2004 MV YQJIDFI INFS t Use a mains cable with moulded-on plug. 2. Use 3 strain relief on the mains cable. 3. Affix a label at the outside of the enclosure near the mains entry slating the equipment type } the mains voltage or voltage range . the frequency or fre- quency range , and the current drain or curent drain range. 4. Use an approved double-pole on off switch, which is effectively the ‘discon- nect device'. 5. Push wires through eyelets before soldering them in place. 6. Use insulating sleeves for extra protection. 1. The distance between transformer terminals and core and other parts must be >6 mm. 8. Use the coned type , size and current- carrying capacity of cabfes and wires -see shaded table below. 9. A printed-circuit board like all other parts should be weft secured. AH joints and connections should be well made and soldered neatly so that they are mechanically and ele c l finally sound. Never solder mains-carrying wires directly to the board: use solder tags. The use of crimp- on tags is also good practice. JO. Even when a Class If transformer is used ' it remains the on olf switch whose function it is to isolate a hazardous voltage (Le.. mains input / from the pri- mary circuit in the equipment. The primary-lo-secondary isolation of the transformer does not and can not perform this function. In all mains-Gperated equipment certain important safety requirements must be met. The relevant standard for most sound equipment is Safety of Informa- tion Technology Equipment, including Electrical Business Equipment (Euro- pean Harmonized British Standard BS Ef-t 60950:1 992 1 . Electrical safety under this standard relates to protection from - a hazardous voltage, that is, a volt- aoe greater than 42.4 V oeak or 60 V d.c.; - a hazardous energy level which is defined as a stored energy level of 20 Joules or more or an available continuous power level of 240 VA or more at a potential of 2 V or more: * a single insulation fault which would cause a conductive part to become hazardous: * the source of a hazardous voltage or energy level from primary power; * secondary power t derived from internal circuitry which is supplied and isolated trom any power source, including d.c.) Protection against electric shock is achieved by two classes of equipment. Class I equipment uses basic insu- lation ; its conductive parts, which may become hazardous if this insulation fails, must be connected to the supply protective earth. Class li equipment uses double or reinforced insulation for use where there Is no provision for supply protec- tive earth (rare in electronics - mainly applicable to power tools). The use of a a Class II insulated transformer is preferred, but note that when this is fitted in a Class l equip- ment, this does not, by itself, confer Class IE status on the equipment. Electrically conductive enclosures that are used to isolate and protect a Hazardous supply voltage or energy level from user access must be protec- tively earthed regardless of w nether the mains transformer is Class I or Class II, Always keep the distance between mains-carrying parts and other parts as large as possible, but never less than required. If at ail possible, use an approved mains entry with integrated fuse holder and on off 5 witch. If this is not avail- able. use a strain relief i Figure, note 2) on the mains cable at the point of entry. In this case, the mains fuse should be placed after the double-pole on off switch unless it is a Touch proofs type or similar Close to each and every fuse must be affixed a label stating the fuse rating and type. The separate on off switch (Figure, note 4), which is really a disconnect device*, should be an approved double- pole type (to switch the phase and neu- tral conductors of a single-phase mains supply). In case of a three-phase sup- ply, ail phases and neutral (where used) must be switched simultaneously. A pluggable mains cable may be consid- ered as a disconnect device. In an approved switch, the contact gap in the off position is not smaller than 3 mm. The on off switch must be fitted by as short a cable as possible to the mains entry point. All components in the primary transformer circuit, includ- ing a separate mains fuse and separate mains filtering components, must be placed in the switched section of the primary, circuit. Placing them before the on off switch will leave them at a haz- ardous voltage level when the equip- ment is switched off. if the equipment uses an open-con- struction power supply which is not separately protected by an earthed metal screen or insulated enclosure or otherwise guarded, all the conductive parts of the enclosure must be protec- tively earthed using greemyellow wire (green with a narro w yellow stripe - do not use yellow wire with a green stripe). The earth wire must not be daisy- chained from one part of the enclosure to another. Each conductive part must be protectively earthed by direct and separate wiring to the primary earth point which should be as close as pos- sible to the mains connector or mains cable entry. This ensures that removal of the protective earth from a conduc- tive part does not also remove the pro- tective earth from other conductive parts. Pay particular attention to the metal spindles of switches and potentiome- ters: if touchable, these must be protec- tively earthed. Note, however, trial such components fitted with metal spindles and or levers constructed to the rele- vant British Standard fully meet ail insu- lation requirements. The temperature of touchable parts must not be so high as to cause injury or to create a fire risk. Most risks can be eliminated by the use of correct fuses, a sufficiently firm construction, correct choice and use of insulating materials and adequate coal- ing through neat sinks and by extractor fans. The equipment must be sturdy: repeatedly dropping it on to a hard sur- face from a height of 50 mm must not cause damage. Greater impacts must not loosen the mains transformer, elec- trolytic capacitors and other important components. Do not use dubious or flammable materials that emit poisonous gases. Shorten screws that come too close to other components. Keep mains-carrying parts and wires well away from ventilation holes. so that an intruding screwdriver or inward falling metal object cannot touch such parts. As .soon as you open an equipment, there are many potential dangers. Most of these can be eliminated by discon- necting the equipment from the mains before the unit is opened. Bui, since testing requires that it is plugged in again. It is good practice (and safe? to fit a residual current device (RCDr. rated at not more than 30 mA to the mains system (sometimes it is possible to tit this inside the mains outlet box or multiple socket). T Sometimes called residua! current breaker - ROB - or residual circuit cur- rent breaker -RCCB. These guidelines have been drawn up with great care by the editorial staff of this magazine. However, the publishers do not assume, and hereby disclaim, any liability for any loss or damage, direct or consequential caused by errors or omissions m these guidelines, whether such errors or omissions result from negligence, accident or any other cause. 3-core mains cable to BS650Q 1990 with three stranded conductors in thick PVC shealh Max current 3 A 5 A 13 A conductor size 16 0.2 mm 24 0.2 mm 40 0.2 mm tfom cond area 0.5 mm 2 0.75 mm 2 1.25 mm 2 overall cable dia. 5.6 mm 5.9 mm 7.5 mm Inciil^loH hrin.L'iin ii.-ira Irt E 1 CCC 1 -I 7 ) 11 1 J U 1 U IL.U j i u U n. - u VI IU U L l U 1 " 1 £. Max current 1.4 A 3 A 6 A til ax working voltage 1000 V rms 1000 V rms 1000 V rms PUG sheath thickness 0.3 mm 0.3 mm 0.45 mm conductor size 7/0.2 mm 16. 0.2 mm 24 0.2 mm Norn cond area G.22 mm 2 0.5 mm 2 0.95 mm 2 overall vrire dia 1.2 mm 1.6 mm 2.05 mm 3-llat-pin mains plug to BS 1363A 2 2004 Elektor Electronics 51 ME CooiRditner Xilinx CPLD Development Kit By Paul Goossens Here s a brief article about an attractive development kit from our friends at Xilinx, which is not only rich in contents but also affordable for the hobbyist! The board is supplied ready-built and comes with two CD- ROMs crammed with software. designs but also in hobbyist’s pro- jects sent to us for evaluation and eventual publication in Elektor Elec- tronics . As we see it, this is not only due to the fact that these compo- nents offer far more possibilities than PALs and GALs. but also that nearly all FPGAs and CPLDs are program- mable, the relevant manufacturers put free development software at your disposal and — last but not least — - Elektor Electronics is and remains way ahead of its competi- tors. Admittedly, a disadvantage of these new chips is that they are usu- ally supplied in SLID cases only C Liljii '■ _- r ; srtj r.aqpl !$*>.£> sc ” x \ r if It PALs and GALs never really made it into the world of hobby electronics, despite the fact that these components are instrumental in vast component count reductions, even accepting changes to their contents and so obviating the need to build yet another ver- sion of the circuit. Apparently, in the eyes of many hobbyists these advantages do not justify the cost of a suitable programmer, the associated design software and a pile of data books, CPLDs and FPGAs on the other hand are increasingly found, not only in professional r] L- : Lj . 52 Elektor Electronics 2 2004 DEVELOPMENTS An extensive package The one disadvantage we just men- tioned is of no consequence if you decide to go for the new develop- ment kit from Xilrax* What is called a 'development board" actually com- prises of the following elements: - printed circuit board with a CPLD ready fitted - parallel cable for programming - deve lo pm ent s of t w are ( I S E Web - pack) on CD - resource CD-ROM crammed with information - Programmable Logic Guide - battery holder However, the most remarkable thing about tills kit is not its contents but its price of just 50 US dollars plus shipping, which means that it should be possible to have one deliv- ered to your doorstep in the UK for all out 65 pounds* This price, we feel, really defeats almost any attempt at home construction (just consider the cost and effort that goes into making the board...). Availability is no prob- lem either: simply order your kit directly from the Xilinx Internet shop which also welcomes private cus- tomers, using the link: www.xilinx- com/xlnx/xebiz/nnl i n e- stoie.i sp?sG!obalNa vPick = PURCHASE On this page, click on Development Boards' and then on ‘CoolRunner-II Boards’* This will take you to the page showing the development kit covered by this article* The hardware The printed circuit board conies with a CPLD type XC2C256TG144-7 fitted ex-factory. If desired, a second CPLD may be fitted on the board — this may be an XC2C64 or an XC2C32. An oscillator running at 1 .8432 MHz supplies the clock signal required by the CPLDs, The oscillator module is fitted in an IC socket allowing it to be easily exchanged if a different clock frequency is in order. In your choice of the oscillator module, do hear in mind the pin connections and the supply voltage (3.3 V). The power supply may be a DC adapter (mains eliminator) or a bat- m - _ > 1 p2jap.xch ;: l:v tery. Depending on your choice. JP1 may have to be relocated. If an exter- nal supply greater than 3.3 V is used, the jumper has to be in the 'Int' posi- tion (internal stabilisation)* When two series-connected 1.5 -volt bat- teries are used, JP1 needs to be moved to the + Ext’ (external stabili- sation) position. As shown by the indication, the supply voltage is not stabilised in the sec- ond case. If a too high supply voltage is applied, components may be damaged (as we learned the hard way), so be careful! A 25-way sub-D connector is provided to be able to program CPLDs. This connector is linked to the parallel port on the PC using the ■ms 1 j d f Ml l C. Iff f 1 f , f — J 53 2 2004 Efektor Electronics DEVELOPMENTS cable supplied in the kit. Those of you in pos- session of another Xilinx JTAG interface may conveniently use the dedicated JTAG con- nector on the board. The I/O resources on the board are scanty. One LED and a single pushbutton are con- nected to the CPLD. Sure, that may be suffi- cient for a few initial experiments, but the possibilities are of course limited to say the least. Instead of extra I/O, Xilinx have opted for a prototyping area on the board, which allows peripheral hardware to be added quickly and easily. Furthermore, all relevant signals and supply rails are bonded out to pins on four connectors (you have to mount your own 40-way box header, though). These connections are useful if the footprint of your extension circuit exceeds the space offered by the prototyping area. Software The software that conies with the kit is extremely extensive and distributed across two CD-ROMs. The design software and a number of examples may be found on tire CD- ROM labelled TSE\ The other CD-ROM con- tains a multimedia presentation about the development board, together with some addi- tional technical information. In our case the ISE software suite con- tained version 5.1. Meanwhile, updates have become available on the Xilinx website, and all users of the kit are encouraged to get these free downloads. During installation you are prompted to register ownership of the product, which is possible by Internet, fax or e-mail. V/ithin ISE, designs may be entered in a ' number of ways: Verilog and VHDL are the two languages the software understands. Resides, the software contains its own schematic capture utility that allows a cir- cuit to be drawn in a more conventional way. The state machine editor is a nice bonus fea- ture thrown in by the people at Xilinx. This editor takes the hassle out of designing a state machine. Just draw it, enter the right conditions and hey presto the software gen- erates a valid VHDL file. If you're after bugs or improvements, analysing and/or modify- ing such a state machine is much easier than examining just about any piece of VHDL code. Fortunately ISE also contains a tutorial providing step-by-step guidance on how the software is best used. As usual, it is recom- mended to complete the tutorial to the very end. Doing so will eventually save you a lot of time searching for the desired function. To cap it all, ISE also contains a program that allows a CPLD to be easily progr ammed horn a PC. In this way, the entire pro- gramming cycle is dealt with by a single software package. Finally This development kit Is highly rec- ommended if you are interested in CPLDs, or just want to gain experi- ence in describing circuitry in the Verilog or VHDL language. On their website Xihnx also offers a consider- able number of free examples for use with ISE. The price of the Xilinx CoolRunner-n kit, its availability and ease of ordering are first -rate and we hope other suppliers of development kits will follow suit. Here at the Elekcor Electronics editorial offices we are curious to know what, if any. circuits you have put together using this brilliant development kit, so do let us know if you think you have something worthwhile to show us. Our mailbox, editors(5)elektor-ele ctronic s. co . uk is kept spam -free so has plenty of room for your designs! In closing we wish you lots of fun with your CPLD experiments. XILINX PfOtfuciS and Services .... F : r . . - . = F-— 3 : „ ■■■ : - i I ^ - - - ft .•V iv % I -.T ■> '.M nUto -al ■■ :■ ' v : feign iHrSa j-in; j-ji.-sf.-f's rziliZ j-t; pr*M*fT t>LD. OKiFLi t tf 4 Fic -E='nF d cr*.L-L SR?iffVC3C(&Pr=£*-k - : ; • - ■ »* 9 Bfjfl iea end jceKSliift-. TSi£ II [. CaSVfl^df*a{Al[3d[ari«uf¥?ts3b3Ei . Urrfi -fist fGdF OrLC 1 3fc Sf v - "t : : : t ■ r - 1 ■. ■ . . • s-i : r t ZlCi 7 J-j'tr -B - a r- ir->z Z^iiT ■ -t 3 ~ - > * £' J Oufftmur. !I ' * CiiSii *!t Ctdri: 1 II I Z‘56 irjna Fj*Vtr 2 kX = OO-CKZ- » r : : .>s * ; ; . : “ £ ;qT 7 . - ; _ - • iv-vr - 54 Efektor Electronics 2 20D4 DASYLAB LITE NEwPRODlOS Big or small budget — straightforward or complex application — here’s a version of DASYLab to suit most needs. So now everyone can access legendary usability and make their data acquis i- tion set-up a success the DASYLab way! DASYLab has made setting up PC -based data acquisition sys- tems easier and faster than ever before. And it doesn't take a programmer or prior knowledge of working with this kind of graphical data acquisition software to be able to use DASYLab straight away ■ — It comes with an excellent 'getting started' tutorial and is extremely user-friendly. But if money is tight, and the foil ver- sion of DASYLab Is a little beyond the budget, it's no longer necessary to make do with a more * clunky’ , less usable software alternative. Now with a new lower price, just £425 plus delivery and VAT, DASYLab Lite is the most affordable way to access the acclaimed functionality and ease of use that makes DASY- Lab the first choice for Win- dows-based data acquisition. It takes fust a few minutes to create individual applications with DASYLab and even the most sophisticated acquisition and control tasks can be solved vrith DASYLab quickly and without any program- ming. All that's needed is to connect graphical icons repre- senting the hardware, the sig- nal processing and the chosen display. Users can benefit from real- time display and logging, a pre/post trigger module to make it easy to capture areas of interest in your data. DASY- Lab Lite also supports RS232 inputs and has a wide range of - - ’ - ■* ' . — ^ — ^ T •m -t > : - - Lq Jk. (■ Wz&f - , w ~ m- ■ 1 "S' - rn WwWVimAAA/ 1 mj i I yUWVV\AAAA/VWWW!Ai displays including Chart Recorder, Y/t Chart, Bargraph and Meters. Adept Scientific pic, Amor Way, Letchworth, Herts. SG6 1ZA Tel. (+44 (0)1462 480055, fax (+44) (0)1462 480213 E-mail daq@ adepts ci snce . c o .uk Web: www.adeptscien ce. eo,uk (037 L 67- 1 > Resolution - 8bits Sample Rates - 1,2,5,10,20 Ms/s models £119 ex vat/pp (1 Ms/s model) PC or Laptop portable measuring instruments ... lip Lid. 28 Stephenson Road. Industrial Estate. St. hes. Cambs. PE 27 3WJ Tel: 01480 460028 Fax: 460340 info (5 itp 1 01 .coni www.itp 1 0 1 .com v,n.vw. tiepie.com Handyprobe HP2 - 1 Ch. 7 Oscilloscope y Spectrum Analyzer 7 Voltmeter plus! y Transient Recorder 7 Parallel Port y Windows OS- all Handyscope HS3 - 2 Ch. 7 Oscilloscope y Spectrum Analyzer y Voltmeter plus! 7 Transient Recorder y Arbitrary Waveform Gen. 7 Two hi-z probes 1:1-1:10 SUSB 1.1 or 2.0 7 Windows OS- all Resolution Menu - 12,14, or 16bits Sample Rates - 5, 1 0, 25, 50 Ms/s models £435 ex vat/pp (5 Ms/s model) 2 2004 Elektor Electronics 55 mini proik: i!egt>rtorck Valentine Heart LEDs are red my dear. . . Design by F. Welling Although this month’s Mini Project is not exactly stunning from a technical point of view, there are a number of unusual sides to it, mainly regarding why and how it came to be published in this issue. Read on... Unusual aspect no. 1: This is the first Valen- tine circuit ever to be published in Eiektor, and no. the highstreet flower shops are not to bianie if that is the first you associate with Valent ine ’ s D ay. Valentine’s Day is reportedly the day we * celebrate' the beheading of a priest called Valentinus on 14 February 270. Tire execution orders came from an oppressive emperor called Claudius Goticus (a.k.a. Claudius II). According to some sources, Valentinus was a bishop and the 14 th of February a popular Roman holiday. The legend of Saint Valentine tells us the martyr was executed for illicit marrying of Chris- tian couples, the occasions being marked by Valentinus presenting lots of flowers to the newly weds. The oldest literary evidence for Valentine’s Day being associated with (secret) love may be found in 14 :h century writings, as well as in some of Shake- speare’s sonnets and plays. Un usual aspect no. 2. The designer of this circuit, FI or i an WoUing, was 14 years old when he sent us his article proposal — making him the youngest external author ever to make it to publication of a Mini Project, Unusual aspect no , 3: Originally, this project did not stand a chance of get- ting published in EJektor Electronics. Just like all contributions and other article proposals we receive from hee-lance authors, Florian's papers were 'evaluated for publication value’ during a meeting of editors and design staff. Although the pro- ject met with praise for the meticu- lous way the circuit, the circuit board and the documentation had been designed and presented, and despite the fact that the small heart- shaped LED ornament was "charm- ing’ , the manuscript was rejected for publication because the complete 56 Elektor Electronics 2 2004 Si MINI PROIFCT 1.5 1.7 1.9 2,1 2.3 2.5 Forward Voltage [\ ’ R1 i eon h © BT1 6V D1 D4 07 DIO 02 05 D6 Dll D3 06 D3 DIG gs x/i xs Z* Z D14 gs gs gi Z : E 01 2 D15 gs gs zs E 030009 - 11 Figure l . typical U/t characteristic of a Rgure 2. 1 he circuit: one resistor and ! 5 LEDs, red LED, project was found rather too simple for our demanding readership. How- ever, when writing a letter informing Florian about the rejection of his pro- ject, still encouraging him to send further projects in the future, one of our fellow editors suddenly recog- nised the simple arrangement of LEDs on a board as the perfect cir- cuit for Valentine's Day. Having dis- covered that such a circuit had not been 'done' before in our magazine, and because Blektor editors are always open to novelties, the LED Heart was added to our forward planning schedule. So, here it is, although one more thing should be noted... Unusual aspect no. 4: The Elektor designer assigned with tire technical preparation of Florian’s project {mainly to make it meet our design standards), could not resist doing his bit of post-engineering. Admittedly, there’s not you can change drastically when looking at one resistor and a bunch of paralleled LEDs, but improvements and fine tuning are always possible. The difference between Florian's LED Heart and the Elektorised version boiled down to the components used. Apparently, Florian was encouraged to use SMD LEDs by our two-part article SMDs — Don’t Panic!’ In the January and Feb man/ 2003 issues of Elektor Elec- tronic $, The resulting project, he thought, would make a excellent gift as well present a convincing exercise to win over those readers still hesi- tant about their own skills in han- dling these tiny components. The lat- ter aspect has been crossed out, how- ever, because the Elektorised version of the project employs normal size components, not only with an aim to make the project easier to reproduce for beginners, but also to prevent component sourcing problems. Because all components except the LEDs are soldered at the rear side of ‘High Efficiency 9 LEDs Light Emitting Diodes (LEDs) have been around for a long time — the first LEDs were mass-produced around 1975. The luminosity of red LEDs is specified by the manufacturer at a current of ] 0 mA or 20 mA (depending on type)- These current eaters are hardly used anymore (at least not In Elektor circuits), because red LEDs with a much higher efficiency are now available. These successor types light happily at a current of just 2 mA (similar green LEDs are specified at 4 mA or 5 mAh Because of their improved efficiency, these LEDs are referred to as High Efficiency' types In some professional publications. The classification Low-Cur- rent' is however more commonly found in catalogues, datasheets and articles.. Such LEDs are perfectly suitable for low currents of the order of 1-3 mA and are clearly visible in indoor applications when operated at just under I mA (as in the project described in this article). Besides, who would use the Electronic Valentine Heart in the glare of the February sun? the board, only the LED faces are visible from the front, allowing the front side of the board to be painted or sprayed in whatever way you like. For our own prototype, we happened to have some red paint left... Circuit and component calculations As most of you will know, there are few, if any, applications of LEDs that do not include some form of current limiting resistor. After all, LEDs are simply diodes that light when a forward bias voltage is applied across them. They also ‘exhibit' the typical diode charac- teristic shown in Figure 1, If you apply a slowly rising voltage starting at 0 V to a LED, such that the device conducts (L to anode; - to cathode), you will notice that nothing hap- pens for quite a while — no current appears to flow. However, once the voltage exceeds a critical level, current starts to flow, rising very quickly when the voltage is increased further. This so-called threshold voltage occurs at 0,6 V with normal silicon diodes and at 1.6 V with most LEDs (as in Figure 1). A value of 1.7 V will be noted when testing low-current LDs in this way. Without a current limiting resistor, a small increase of the voltage beyond the threshold voltage would mean imminent destruction of the LED because the forward current rises extremely fast and soon exceeds the 'safe 1 level With a resistor in series with the LED, things look different because according to Ohm’s law, the resistor becomes the main current determining factor. In the circuit of the Electronic Valentine Heart (Figure 2) rive strings of series -connected LEDs are con- nected in parallel. Each string consists of three LEDs. The voltage across each of these strings equals three times the forward con- ducting voltage of a single LED. Assuming a device voltage of 1.7 V we get 2 2004 Elektor Electronics 57 MINI PRO Figure 3. The heart-shaped board (insert LEDs from track side). 3x1.7V - 5.1 V The LEDs are connected to the battery by way of a 180-fl resistor. Although the battery voltage is 6 V nominally (2 x 3 V), we should use the value 5.9 V to account for the load on COMPONENTS LIST Rl = 1 80ft DI-DI5 = LED, red. low-current Si — 3 -way SEL pinheader, angled, with jumper ( alternative: miniature slide switch) Battery holder = SMD button cell holder (e.g., Farneii # 302-9785) Two button cells type CR2032 PCB, available from The PCBShop button cells. If the voltage across the LED strings is 5.1 Y the resistor is accountable for the voltage differ- ence between the two voltages at its terminals. The difference works out at 5.9 V - 5.1 V = 0.8 V. From this value we can calculate the current as 0.8 V / 180 Q = 0.00444 A = 4.44 mA This current is supplied by the bat- tery, flowing through the resistor and the LEDs. Because all LEDs are of the same type and the voltage across each string is also equal, it is safe to assume that the current is equally divided across the five LED strings. Hence, the current through each individual LED equals 4.44 mA / 5 = 0.89 mA Not a lot, you may think, but suffi- cient for a low-current LED to light with reasonable brightness. If the circuit was modified such that aU LEDs are connected in parallel, the current consumption from the bat- tery would be three times as high (assuming the same LED current is maintained). The load on the battery would then become about 13 mA, which is rather heavy on the button cells used. Besides, the difference in brightness between individual LEDs would be far more noticeable than with the series-connected version. If you would like to know more about LEDs and how they can be used in large clusters, you should get a copy of out article LED Arrays’ from the April 2003 issue of Elaktor Electronics. The Internet is also a good source for additional informa- tion on LED calculations, see ‘Web Pointers 1 at the end of this article. SB Printed circuit board and construction. The printed circuit board designed for the project is single-sided. The 3- mm holes in It enables the LED faces to be seen from the front side. For this to work the LEDs have to be inserted from the solder side of the board, their terminals being cut, bent and then soldered to the copper pads on the board. The other three parts in the circuit (battery holder, resistor and a 3 -way SIL p inheader) are soldered in SMD fashion to the track side of the board. The battery holder is actually the only SMD com- ponent. Instead of the soldered bat- tery holder you may, of course, use a separate holder (for example, con- taining two AA cells) and connect it to the board via wires. When soldering the LEDs onto he board, make sure you get their polar- ity right. As indicated in the circuit diagram, the cathode is the shorter of the two wues. This (negative) con- nection is marked by the bar in the diode symbol. Our prototype is switched on by relocating a jumper on the 3- way SIL pinheader. For a more sophisticated approach to on/ off switching, a miniature slide switch is recom- mended. Finally If you have been wondering all the time why the Electronic Valentine Heart does not blink just like most other LED ornaments, brooches and trinkets, well, it happens to be Unusual Aspect no. 5. There’s noth- ing to stop you making the LEDs blink, though, just consider borrow- ing the flip-flop element from our LED Christmas Decoration’ (Decem- ber 2003). Web Pointers ou rwo rid . co m p y serve, com./ h o me p a ges/ B 1 1 [_B o wde n /led ,ti t m hnc: -'/linear L or g/ckts. ; I e d . p hp www. electronics 2000 . co . uk/cal d calded.htm vvvAv.haiTiradiomd1a.com/ HRj-CaiotEDcaic.htm Elektor Electronics 22004 World’s Smallest SMD Chip LEDs Components Bureau, the Cam- bridgeshire-based passive components and specialist capacitor distribution company, has launched a new low cost blue surface mount chip LED from Kingbright in the world's smallest 0402 style package. The new blue chip LED com- plements Kingbright r s 0402 range that includes orange, yellow, green and super-bright red indicators with typical light outputs of 140 mcd at 20 mA. The new GaN LED chip offers the luxury of blue indication in applications at a fraction of the cost of tradi- tional blue SMD devices. Measuring just 1.0 x 0.5 mm and less than 0,5 mm thick, the LEDs feature a water-clear lens with viewing angle of 120 degrees and are ideal for use in a wide range of applications including back- lighting and indication in light- weight. portable instrumentation and telecommunication devices. Besides the new GaN blue ver- sion, Kingbright r s 0402 pack- aged LEDs are available in the full spectrum of colour (430 to 700 nm} and brightness (All— nGaP to InGaW technology). Depending on colour, specifica- tions include power dissipation from 75 to 170 mW, DC forward current of 30 mA peak forward current from 150 to 195 mA r reverse voltage of 5 V and oper- CAN Code Creation Wizard Utilising its GoldFire Develop- ment Suite and Code Creation Wizards, Crossware can create from scratch embedded CAN programs for Motorola’s Cold- Fire MCF5282 microcontroller in just under 1 minute and 34 seconds. It is difficult to explain in words just how easy and quick it is to create a CAN program using our Development Suite,” said Alan Harry, Crossware's founder and CEO. “Conse- quently we decided to record the whole process so that developers can see exactly how ids done. The complete video lasts less than 2 minutes and can be viewed along with the source code that the Wiz- ard generates." Crossware's ColdFire Develop- ment Suite includes a number of Code Creation Wizards to help the programmer write code for the MGF5282 micro- controller. The CAN Code Cre- ation Wizard is particularly useful because setting up the CAN controller registers and message buffers is normally a complicated process. However, using Crossware's CAN Code Creation Wizard the program- mer can bnild a complete func- tional program that will trans- mit and receive CAN mes- sages without any previous experience and with no learn- ing curve. Not a single line of A Chip in the Old Block voltmeter built in. Lascar Elec- tronics has added to its range of low-cost, ultra -minia- ture panel instruments with the introduction of the OEM IB-LED, Now you can buy a potted LED This module is a 314-digit, LED block with all the features of a voltmeter with a 9-nim digit height that combines low cur- rent consumption with a com- pact body design no bigger than a standard LED block. Supplied in an encapsulated, compact DIL package, the OEM IB-LED can be easily inte- grated into applications where space constraints exist and the full functionality of a voltmeter many times its size is required. Features of the OEM IB -LED include selectable decimal points, auto -polarity auto-zero and 200 mV full scale reading with on board calibration. a ting temperature range from -40 to +85 degrees C. The 0402 style LEDs are capable of T , ■with- standing reflow soldering tem- peratures up to 230 degrees C for up to 10 s and 140 to 160 degrees C for up to 120 s. All Kingbright 0402 style chip LEDs are supplied on tape and reel in quantities of 2000 pieces. Components Bureau Ltd., Vision House, 11 Bramley Road, St Ives, Cambridgeshire, PE27 3WS, Tel.: +44(0)1480 386565 Fax: +44 (0)1480 386566. Web: www. co mpo ns n tsbureau L com ( 04701 2 - 5 ) code has to be written. Developers can view a demon- strator video at h ttp; // www. cros sware.com/ca n. An evaluation version of Crossware's ColdFire Develop- ment Suite can also be down- loaded allowing programmers to generate complete CAN pro- grams of their own. Crossware, Old Post House, Silver Street, Litlington, Royston, Herts, SG8 0QE f UK TeL + 44 (0) 1763 853500, fax + 44(0) 1763 853330. Web: www.crossrware.coin The module s low cost makes it an attractive option with prices starting at £15.50 (vol- ume discounts available). Lascar Electronics Lim ited, Module Hose, Whiteparish, Salisbury, Wiltshire SP5 2SJ. TeL (+44) (0)1794 834567, Fhx (+44) (0)1794 884616. Web: wwwJascar e letffcronics.com ( 0 + 7012-2 2 2004 Eiektor Electronics 59 p .nbun/ Ejeetroiiics U.K. Manufacturers & designers of quality Transformers for over 20 years. • IVA-750VA size range, medium quantities • Mains, Audio, Loudspeaker & ferrite types • Specialise in Vaive/Tube mains and output transformers. • Rewind/Replacement of rare/speciai transformers • A standard range of Valve/Tube Amp mains & Output Tx’s (P/P, SE etc) is available through Mike Holme's web site: www.mc-h.demon.co.uk/transformers.htmi (Also, Valve circuits, Parts lists, Chassis & Advice) • Established supplier to Maplin Electronics (www.maplin.co.uk) for over 15 years. Contact David Brooks l.Eng MliE (Proprietor) Phone : 01245 328:174 Fax: (24Hr) 01245 328963 Email: DanburyEfecTX@aot.com 20 Cutters Rd, Saltcoats Ind. Estate, South Woodham Ferrers, Essex. CM3 5XJ (UK) * C compiler supplied * Compatible with most development tools * In-system programmable * Free Atmoi debug si mu Hart or available ■ Peripheral drivers and libraries supplied * Increasing range of expansion modules ■ Full web site support Check out FJexIt at www.ennovi.co.uk enpgvjjtd 0 + 44 ( 0 ) 1 425 47 aa &4 salos^«nnovi.ca.uk Fre-eisian measurement Embedded contra] Intrinsic safety Internet embedded systems USB interface ELEKTOR CD-ROMs Just like previous editions, the crop of 2003 supplies nil ingredients to allow the modern elec- tronics kitchen to cook and serve a wide range of recipes ranging from appetizers and cockiail snacks right up to the main dish, not forgetting salads and desserts, of course. The ingredients are hundreds of programs that can be run on various operating systems, linked direclly or indi- rectly to electronics in general, programming, microcontrollers for sure, but also to rnony allied areas. Besides the usual sections (CAD, Audio, Calculation Tools, Programming, Simulation, etc.) the 2003 edition of ihe Freeware & Shareware CD-ROM contains a collection of 'must-haves' which are not specifically linked to electronics, but valuable when it comes to writing or manipulating programs and files (assembly code, C, Delphi and others). This collection comprises utilities like xnView (for graphics file visualisation), dir print (file, directory and subdirectory listing), Total Commander (previously known as Windows Commander) and other ingenious tidbits covering functions like file renaming. Order now using ihe Order Form in the Readers Services section in this Issue Elektor Electronics (Publishing) » FtO. Box 190 * Tunbridge Wells TN 5 7 WY * England. Telephone +44 ( 0 ) 1580 200 657 » Fax +44 ( 0 ) 15 SO 200 616 — 0 i OiE ELECIfcOKlCS A COMFUTM MAGAZINE See also www.elektor* eledronks.co.uk 60 Etefctor Electronics 2 2004 QUASAR electronics Quasar Electronics Limited PO Box 6935, Bishops Stortford, CM23 4WP Tel: DB70 246 1826 Fax: 0870 460 1045 E-mail: sales@quasarelectronics.com Add £2.00 PaP to all UK orders. 1st Class Recorded - £4. Next day (insured £250) - £7. Europe - £5. Rest of World - £10. We accept all major credit/debit cards. Make cheques.'PO’s payable to Quasar Electronics Limited. Prices include 17.5% VAT. MAIL ORDER ONLY. Call now for our FREE CATALOGUE containing details of over 300 electronic kits, projects and modules. © ©871 CREDIT CARD SALES 71? T1 Motor Drivers/Controllers Here are just a few of our controller and driver modules for AC, DC. unipolar/bipolar stepper motors and servo motors. See website for full details. DC Motor Speed Controller (5A/1G0V) Control the speed of almost any common DC motor rated up to 100V/5A. Pulse width modulation output for maximum motor torque at all speeds. Supply: 5-15VDC, Box sup- plied. Dimensions (mm): SOWxIGOLxGOH. Kit Order Code. 3Q67KT - £12.95 Assembled Order Code: AS3067 - £19,95 NEW! PC / Standalone Unipolar Stepper Motor Driver Drives any 5, 6 or 3-!ead unipolar stepper motor rated up to 6 Amps max. Provides speed and direc- tion control. Operates in stand-alone or PG- controiled mode. Up to six 3179 driver boards can be connected to a single parallel port. Supply: 9V DC. PCB: 80x50mm. Kit Order Code: 3179KT - £9,95 Assembled Order Code: AS3179 - £16,95 PC Controlled Dual Stepper Motor Driver Independently control two unipolar stepper motors (each rated up to 3 Amps max.) using PC parallel port and soft- ware interface provided. Four digital inputs available for monitoring externa! switches and other inputs. Software provides three run modes and wilt half-step, single-step or man- ' ual-step motors. Complete unit neatly housed in an extended D-shell case, Aii components, case, documentation and software are sup- plied (stepper motors are NOT provided). Dimensions (mm): 55Wx70Lx15H. Kit Order Code: 31 13KT - £1 5,95 Assembled Order Code: AS3113 - £24.95 NEW! Bi-Pofar Stepper Motor Driver Drive any bi-polar stepper motor using externally sup- plied 5V levels for stepping and direction control. These usually come from software running on a computer. Supply: 8-30V DC. PCB: 75x85mm. Kit Order Code: 3 1 58KT - £1 2.95 Assembled Order Code: AS3158 - £26.95 Most items are available in kit form (KT suffix) or assembled and ready for use (AS prefix). Controllers & Loggers Here are just a lew of the controller and data acquisition and control units we have. See website for full details. Suitable PSU for all units: Order Code PSU203 £9.95 Rolling Code 4-Channel UHF Remote State -of- the- Art. High security. 4 channels. Momentary or latching relay output. Range up to 40m. Up to 1 5 Tx's can be learnt by one Rx (kit in- cludes one Tx but more avail- able separately), 4 indicator LED 's. Rx: PCB 77x85mm, 12VDC/6mA (standby). Two and Tenchannef versions also available. Kit Order Code: 31 3GKT - £41 ,95 Assembled Order Code: AS3180 - £49,95 Computer Temperature Data Logger 4-channel temperature log- ger for serial port. ; C or *F. Continuously logs up to 4 separate sensors located 20Gm+ from board. Wide range of free software appli- cations for storing/using data. PCB just 38x38mm. Powered by PC, includes one DS1820 sensor and four header cables. Kit Order Code: 3145KT - £22.95 Assembled Order Code: AS3145 - £29.95 Additional DS1820 Sensors - £3,95 each NEW! DTMF Telephone Relay Switcher Call your phone number using a DTMF phone from i > anywhere in the worfd and . f | remotely turn on/off any of the 4 relays as desired. User settable Security Password, Anti- Tamper, Rings to Answer, Auto Hang-up and Lockout. Includes plastic case. 130x110x30mm. Power 12VDC. Kit Order Code: 31 40KT - £39.95 Assembled Order Code: AS314G - £59.95 Serial Isolated I/O Module PC controlled 8-Relay Board, 1 1 5/250 V relay outputs and 4 isolated digital inputs. Useful in a variety of control and sensing applications. Uses PC serial port for programming (using our new Windows interface or batch files). Once programmed unit can operate without PC. Includes plastic case 130x100x30mm, P owe r: 1 2 VDC /500m A . Kit Order Code: 3108KT - £54.95 Assembled Order Code: AS3108 - £64.95 Infrared RC Relay Board individually control 12 on- board relays with included infrared remote control unit. Toggle or momentary. 15m+ range, 112x122mm. Supply: 12VDC/0.5A Kit Order Code: 3142KT - £41,95 Assembled Order Code: AS3142 - £59.95 FIC & ATMEL Programmers We have a wide range of low cost PIC and ATMEL Programmers, Complete range and documentation available from our web site. Programmer Accessories: 40-pin Wide ZIP socket (ZIF4GW) £15,00 1 8V DC Power supply {PSU201 ) £5.95 Leads: Parallel (LEAD108) £4,95 / Serial (LEAD76) £4,95 / USB (LEADUAA) £4.95 NEW! USB 'Al! -Flash' PIC Programmer USB PIC programmer for all 'Flash' devices. No external power supply making it truly portable. Supplied complete with 40-pin wide-slot ZtF socket, box and Windows Software, Kit Order Code: 31 28KT - £49.95 Assembled Order Code: AS3128 - £54.95 Enhanced PICALL’ 1 ISP PIC Programmer Wilt program virtually ALL 8 1 to 40 pin PICs plus a range | of ATMEL AVR, SCENIX sx and EEPROM 24C de~ - ^ vices. Also supports In Sys- tem Programming (ISP) for PIC and ATMEL AVRs, Free software. Blank chip auto detect for super fast bulk programming. Requires a 40 -pin wide ZIF socket (not included). Kit Order Code: 3144KT - £54,95 Assembled Order Code: AS3144 - £59,95 ATMEL 89xxxx Programmer Uses serial port and any jjtfj standard terminal comms .tjs program. 4 LED's display the status. ZIF sockets not included. Supply: 16-18VDC. Kit Order Code: 3123KT - £29.95 Assembled Order Code: AS3123 - £34.95 NEW! USB & Serial Port PEC Programmer USB/Serial connection. Ideal for field use. Header cable for 1CSP, Free Windows software. See website for PICs supported. ZIF jtt SO cket not incl. Supply: 18VDC. Kit Order Code: 3149KT - £29.95 Assembled Order Code: AS3149 - £44.95 No. iKITS. www.quasareiectronics.com Secure Online Ordering Facilities Full Product Listing, Descriptions & Photos Kit Documentation & Software Downloads 22004 Elektor Electronics 61 High performance Windows based PCS Design Capture , a Simulation and Layout software at prices you'd expect r from your local computer store! NEW! in Ecssy-PC 7 Library Databook Step and repeat plotting Swap Connection Mode Dimensioning Copy to Metafile much more Stop press... by customer demand, now with Tsien Boardmaker 2 design import... 73QQ '■fiodiHn ST"- | J -«r |a + ^ *+k;+,-niF.. 5 tSB I r-.'-.-'-.c; . Number One Systems delivers true 32 bit Windows software applications including features that a few short years ago v/ould only have been available in software tools priced in the thousands! Test drive Easy-PC and Easy-Spice for yourself and be prepared to be amazed at the super value... Cali for a brochure, price list and demo CD on +44 (0)1684 773662 or email sales@numberone.com Orm Cud&mc ■ Number One System s ^jSSSSi tlr or download from 1 a I 302 circuits SUMMER CIRCUIT COMPILATION BOOKS De 30x series of Summer Grojil compifcfioo bocks hove been bestsellers for many years. You can use these books not only for building ibe cir- cuits described, but also qs a treasure trove of ideas or circuit adaptations for your own experiment Since the series was started in the early 1980s, many readers have found in these books ihnl new approach, new concept, or new circuit they were looking for flat surprisingly our 3Gx books are now firmly established os collector's items, and carefully preserved by thousands of professionals and hobbyists o round the globe. Circuits and design ideas included for audio, video, music, car, bicycle, home, garden, gomes, radio, software, test and measurement, PC and peripherals, power supplies, computer hardware, and more. 300 Circuits, 301 Grants, 303 Grants and 30b Grants are now out of print. 302 Circuits 354 pages, size 14 x 21 cm soft cover fSBN 0-905705-25-4 RRP £10.35 (US$21.00) 304 Circuits 366 pages, size 17 x 23.5 cm, soft cover ISBN 0 905705-34-3 RRP £13.45 ( USS27.00 ) 305 Circuits 369 pages , size 17 x 23.5 cm, soft cover ISBN 0-905705-36-X RRP £15.55 (US$31.00) 307 Circuits 342 pages , size 17 x 23.5 cm r soft cover ISBN 0-905705-62-9 RRP £18.20 (US$37.00) 308 CIRCUITS size 17 x 23.5 cm, soft cover ISBN 0-905705-66-1 RRP £18.20 (USS 37.00) Order now using the Order Form in the Renders Services section in this issue llekfor Electronics (Publishing) » P.0. Box 190 * Tunbridge Wells TNS 7WY • England, Telephone +*14 (0) 1580 200 657 * Fax +44 (0) 1580 200 616 82 Elektcr Electronics 2 2004 ervicing Your Complete Prototype Needs O Prototypes at a fraction of the cost O l GOfng and setup induced 0 Any contour O Fr4 1.6mm f 35pm Cu iXMt l£ EUBOCABD GSP 7 V O Mus/ry ste/Ti&rtf 0 ft'tijV Up Sefl5S n/ns 0 CA J .f / CAD cosnEutejg + rao/Zf?^ + fMopfa/s + VAT £ 29.89* +$te£ng /afe® ihetj? v^ry_ Asbe - €'-^3 na* : r£K -3S3ffT^/tFIW it~yi-IiT lalJLjCBifllfl ApWiiF i lift nr;*** 0 ©SO®' 3 I Simpy^se/^ yMf fifes orJe# DMM: PC8-P00L COM f «+?(?/ jtf oread Crop^Cb ^s K^aE: ^ = - - Based on the MSC 1210 Development System -.els™ IE? L. In the July/August 2003 issue we started a series of arti- cles based on the Texas Instruments MSC1 210 microcon- troller. Thanks to this contemporary controller and its 24- bits A-D converter, the development system can be pro- grammed for lots of applications and measurement func- tions. Among these is a high-accuracy digital meter wit no less than 5Vi digits and 8 analogue inputs. All you have to do to build the instrument is add an LCD! We can offer the ready-manufactured, populated and calibrated board for just £ 69.00 / $ 1 12,50 {plus P&P) Because the MSC1 21 0 microcontroller comes in an SMD case with 0 + 5-mm (0:02 in.) pin spacing, soldering the device properly with DIY tools is almost impossible. That's why we are offering the development board as a ready- manufactured unit only. Elektor Electronics (Publishing) * P.0. Box 190 ■ Tunbridge Wells IN5 7V/Y * England. Telephone +44 (0) 1580 200 657 • Fox +44 (0) 1580 200 616 IKE EUCTBONSCS £ COHFUTIii MASAliXE See also www.elektor- eledronfcs.to.uk 2 2004 Elektor Electronics 63 ELECTRONICS ONI INF Remote Control for your PC With a home-made infra-red receiver By Harry Baggen With the PC seeing increasing use as a multimedia machine, recording and playing back video and audio, users will soon want to control a number of functions remotely, just as with their TV or hi-fi set. All you need to realise this is a standard infra-red remote control unit, a home- brew receiver circuit and some software. A number of manufacturers in the consumer electronics sector supply remote controls with special receivers — the complete kit allowing a PC to be controlled from a dis- tance. In many cases, the remote control includes a kind of mouse replacement so you can even move the cursor around on the screen. The infra-red (IR) receiver usually consists of a small receiver module for connecting to the PC’s serial port by way of a cable. The supplied software then looks after the processing of received IR signals. In many cases, a remote control set is included with a TV card for the PC, although the features then remain limited to a number of essen- tial TV and radio functions. Fortunately, several alternatives are now available to link a PC to a remote control. Thanks to a number of clever programmers and some really simple hardware it has become possible to use a dead stan- dard remote control transmitter to realise remote control on your PC, The receiver is, of course, home built, which — we are sure — is unlikely to present problems to read- ers of Elektor Electronics. Inciden- tally, if you happen to have an IR remote control lying around, say, from a TV card system, you'll find that tills may often be used without problems in combination with the programs discussed below. On the Internet you’ll find a vari- ety of articles and web pages dis- cussing home construction of an IR receiver. The designs vary in com- plexity from five-component 'inter- faces' right up to microcontroller-dri- ven gadgets. In all cases, however, you'll have to build up a small circuit. When a microcontroller is used, we 64 Elektor Electronics 2 2004 found that in the majority of cases the hex code to program your own MCU is freely available. How to build an IR Receiver by Aiessio Sangalli [1] provides exten- sive explanations and clear pho- tographs, allowing even beginners to assemble their own IR receiver without too much of an effort. Aiessio s design is simple by any standard, consisting of an ER receive module, a voltage regulator and three passive components. Similar designs, also rich in illus- trations and with detailed descrip- tions may be found on the Heat- seekerz website (2). Hie author, Tom de Keninck, sets a standard how an electronic construction can be described on web pages. The pho- tographs Tom shows us, in combina- tion with a step-by-step approach and the assumption that the reader knows virtually nothing all con- tribute to the excellent reproducibil- ity of the circuit. The Infrared PC Remote Control — Info page |3] aims a bit widen Here, we found several receivers dis- cussed — designs with and without microcontrollers. The site also dis- cusses the necessary software and proposes some ready to go solutions. We also found a doxvnload link to the shareware program 'PC Remote Con- trol'. A receiver circuit based on a PIC12C503/509 is discussed at the UIR page [4). The author shows how the circuit may be built from stan- dard components as well as SMDs (surface mount devices). The Universal Remote Control Receiver [5J is a project built around a PIC16F34. According to the description, it is suitable for nearly all commercially available remote controls. Both the microcontroller hex code and the PC layout are available to everyone wishing to build this design. Tire designer also offers the associated software, DRCS (Dalton Remote Control Software), to run on your PC. A similar circuit based on the pre- vious design is called the Universal IR-receiver for serial interface [6] and may be found on the web pages of the electronics faculty at the Uni- versity of Ulin, Germany. Besides hardware (a remote con- trol transmitter and a matching 2 2004 EEektor Electronics ELECTRONICS ONI INF receiver) you’ll also need software to detect and process the serial data, as well as convert it to commands the PC can understand. A universal program that looks after these tasks is called LtRG (Linux Infrared Remote Control) |7j. A Windows ver- sion of the program is available from the WinLIRC homepage [8]. Girder (91 is also a well-known Windows automation tool (share- ware) capable of recognising and employing lots of remote control sig- nalling formats for linking to Win- dows programs and PC hardware. The sheer popularity of this program has resulted in many exotic IR for- mats now being supported thanks to the contributions of active users. If you don’t believe us, just take a look at the list of avail- able plug-ins! IRAssistant ( 10 j, which comes free of charge for private use, also allows mouse movement to be mimicked using the remote control, as well as launch and control pro- grams, run macros, aE from the comfy chair. Finally, we should mention uICE [11] by MediaThxX. This shareware is also rich in fea- tures when it comes to driving hardware and software. The program is marked by an Office-like user interface, offering an on-screen menu and on-screen display looking very much like the ones you see on modern TV sets. '451 1 2 internet Addresses [1] How to build an IR receiver h i t b.U fnx. man aweb.com I Hr d [2] Heatseekerz - remote control: www:fi sotseefce rz. net/ index. phb?pa&e = ortfcfes&jd ^== 4& plenum ~ ! [3] infrared PC Remote Control - info Page: www. ge c cities . com [ Cape Canaveral/Lab/ 1 4 75/rem o tectrL h £ni 1 [4] UIR - Universal Infrared Receiver hupJ/fiv. cc. fee hr/— mozgid UJR/ [5] Dalton Electronics - URCR: www . daf ton-electron ics. com! URCRJURCfl os px [6] Universal IR-receiver, Microelectronics Department. University of U!m: ik.ro. e-techntk. uni-ufm, dei resec rch/urcr.btml [7] URC - Linux Infrared Remote Control: wwwjircor ■_ [8] Wi n LI RC H o m e p age : w • e : [9] Girder: _ . de - [10] I RAs s i s tan t: www tr assistant. com fdotcamlv current/ \ I I ] Medi aTexX S oftware Solutions: .w.- w, media texx. com/ 65 Entern&l www.elektor- eledronk^to.uk £12.95 [USS 22.90) Jtfrtnvm conifvttv lefjufasiiieniS: P«iM*n It misi 133 Mfty: idfr Vfliunvs 8s; lifiiL 3? J.IEJ RAM: Kit m m fise sfece on fejd ftek The program podrage consists of four cfotobanks covering iCs, frara- sistars, diodes and cpkxiouplers. A further nine app h cations cover tbs calculation of, for example, z&m diode series resistors, voftoge regu- lators, voltage dividers and AM Vs. A colour band decoder is included for determining resistor end Induc- tor values. The databanks show the cose draw- ings of nearly all components, os welt as their pinouts end quick design data (if known). Each data- bank also has a search engine for component parameters. The ECD gives you easy access to design dab for * over 5,300 tCs * over 22,500 bipolar transistors * over 4,900 FEU, thyristors end trices * just under 25,000 diodes * over 1 ,800 optocouplsre All databank applications are fully interactive, allowing the user to add, edit and complete component deb. Order how using the Order Form in the Readers Services section, or WRITE TO P,0. So I H-j * Wd ',VYr T?iS 7WT * Es:>-d Tzfc$&rae *44 ui IS SO 300 z57 * Hi +44 (ft] 1SS0 200 616 BOOK THIS DATE IN YOUR DIARY NOW T*il LtiCTIOttiiS k COMfUTU. MAGJLELM FRIDAY MAY 7 AT THE UNIVERSITY OF WARWICK. COVENTRY 1 THE FUTURE OF THE MICROELECTRONICS INDUSTRY IN EUROPE: IS THE CURRENT UPTURN JUST A BLIP OR PART OF LONG TERM TREND ? ’ Watch out for details in the Subsequent issues of Elektor And on our website. BACK Sli-'l STOCK! The ready built GBDSO hoard costs £ 90.00 including the associated PC software and the magazine articles The GBDSO (Gameboy Digital Sampling Oscilloscope), published in Elektor Electronics October and November 2000 is stiiS in great demand. The GBDSO is a plug-in module that turns the popular Nintendo Gameboy Classic, Colour or Advanced into a versatile dual-channel oscilloscope. An optional link to a PC even allows measured oscillograms to be viewed or stored on the PC. The GBDSO comes as a ready-built and tested PCB and may be ordered via our website: wwv/.elektQr-eiectrQnkS'tO'Uk The ready built GBDSO board costs £ 90.00 including the associated PC software and the magazine articles (published in the October and November 2000 issues). Order now on www.elektar-eleclronks.co.uk Ekkior Electronics (Publishing] * P.0. Box 190 ■ Tonbridge Wells TH5 7WY * England. Telephone +44 (0) 1580 200 657 * Fax +44 (0) 1580 200 616 TKi ELlttiOrCjCS £ COMPUTTB MAGAZINE WM | ■ 1 See also www.eEektor- eEecfronics.co.uk in 66 Elektor Electronics 2 2004 Please Note SefTASTir t-’.s - .i*5d @ us a.i'.ii.-E frc-it re-r ^ : .v- pscs of tte PuMsfers' wcbste 3 t mrar eMfrynefecftm^ □tskE&ES are suppfed for the comstasnce of ras5=£s ■Aitfeut Entem^ access. £ U5S EVER OR EE US Em ¥ irri Ufl Lr l* JT O Elector Elecimnfcs Help Disk 96602 1-\ : e V.' n io ivs , %i&. 815 14 43 Elector Electronics Item Tracer 19 85-20 OZ G35503-I1 arnEnts (fejsfea$$ f(Ss< PIC soorce 7T4 cofe 4 -sa 563 030* =->41 PlC 1 BfS4 -04 p zzc* tr. 15 20 26.90 iAccess @020163-11 Disk set, sane cwte and contra! software 7-50 1330 02016341 AT89S8252-12PC, pfogr^nnral 1390 24. £0 Simple 1 2-10-23 OV Power Inverter •@ 020435-1 PCS 8-50 15.G5 Touch-Gonlrailed Switch @ 030214-11 Dss^, PIC source code 490 S.65 03021 4-4 1 p: Cl 2C 5GS AG4 SC3 . pnwrareraad 6-15 10.90 ifUj y£o ¥nfT(#nilf &(/{/*# 64-K6DC552 Flash Board @ 3300424 PCS 9-35 16.35 ■@ 63034 ?-f j Od‘ rt fc pm^l sofTA-ifa. 490 fi-65 030042-21 29F010. pngiHiTDrd 10-00 17.70 03034 > ■ 3 r GAL 1 EVfl0 1 5Df? prog s&vm&i £-10 10 £-3 Cllmale Logger @ 030*376-1 PCS 7-75 13 70 1 - C3 v ‘ ■ S-' 1 z E' rr^Gih £ soiu'i -.v 4-9*3 8 55 FMS Flight Simulator Encoder @ 030066-1 FCB 1IF2Q 15 05 D3006641 87LPC7fi7B?L pro^anvned 17-05 sots LEO Roulette @ 030169-1 FCB 17 90 31.60 © 030163-1 i L . " ‘ i C'V 'J: 7 ard ” : f E5 4-90 3.65 QZ 0 1 S3 -4 i 53 3 2 . 1 1 - 1 2 PC. pnsgaarmsd S-05 14 25 Mufii-evenl Alarm Clock @ 020304-1 1 tesk, C [ source J fee ftes 4 90 3.65 02030441 AIS9C2G514 2rC. pra^anffred &1G 1080 Slepper Motors Uncovered Q2012741 p;ciD=a73-2fSP 19-10 33.30 Mn 327 REREMRER PRR3 soujcs L ofc-jsd k>:e 4 -m 3.65 0203504 1 PfC16F&s-U3P 1315 23 25 Stopper Motors Uncovered (2} W 020127-11 m>. so-.::? co:-e r 5 4-90 £.£5 Universal Clock Generator @ C 2 23 5 5-11 C'-E 4 &c-L r :e code T- 4 >90 5.65 Wireless RS232 Link @ 030204-1 PCS 6-70 15.40 No, 326 NOVEMBER 2003 Rev Counter far FL C Models @ 024111-1 PC a 17-50 31.00 024 1 1 1-1 1 D Ei 5TMC5 std fe: l cede 490 3.65 02411 HI 69C2051 ■ 1 2PC, ptg^nmEd 885 15.65 RunningTexl Display @ 02 C407-1 1 t.i ' . s ounce end r - ■. cc-c e 490 3.65 USB Analogue Converter @ D20374-1 PCS 765 13-50 @ 020374-11 DfeS; hat code and Wnkms software 4-90 3 65 02 0374 -41 Pt€l6C7 65. jjmgfsmrned 53-25 23,45 No, 325 OCTOBER 20Q3 DDS HF Signal Generator @ 020299-1 PC 3. g-nergser li-K) 20 55 @ 020299-2 FCB rwirn-y.^ypiC 12-10 21 45 62 C 293 -4 1 41 95555 15 E-PC. pec-?ST:T^j Minimalist InducliomBaiance Melal Detector 30-55 5-403 @ QZQ26IM PCB 8-95 15.85 JBEADEBSS ES GENERAL =rrts^< rtiii t jZ1‘1Z PZBi . ii '-n-ii.r J ^rt -ir-h- lots, ROMs, EPflOWs. RftJLs. Gris. cr^crtKsrfcOlas sod e-tttee f: r : : -:::i . : tevz - £s 4 r.v f. i 1 : it - :e L'C-sr&i us r i“E Ox-i- fcrr Vi;.::" Tfe c : - "iy le. :e l::‘ :: :■:=.- re:*.: p-- . 1:7 .. i".:- "i" "i-. = i PCS vv* i ■:: i,-iz r ■ 7 : ^ : : ? .T'Zszn zri Fes'E-e Sir,-: a t± ■ : _- : rife i :.i" E r ::e. * EPROM?, GALs, PALs. {EJRiis, LUCtts, PX& aid otter ~ e? £ i‘ e i _ : : ££ := i : ? - -p- - 5 : 1 :::: :■:: i t: 1 . :: :.*■.-== Trt p,:- m :zzr,z~. ± 1 :: : l *3=pr r Piijes 5 ”: iti.Ti 0 £scrfp.t*c£s h=r= ssp&r- s e*fe Eiose In pre-rioas its,**, t.iO.E PAST ISSUES Past issues, i sfeuSd be onSsed from Ssftvre Hi . U;Jt i fitiis Rh -1 Fur. Paihlfjf Roi5. liCEHURST Tfi3 THE. Ir.i'zzi Wip-rHiU: 15EQ2G-GE37. fat 13-0 2i‘5lE. cfn-il wwss 7 riHjs.c'ir pnc: .’1 Prsfi : x :ir .»jri .**:?:■ .„•< -o:.n =■•: C-eci ■•: ‘ 1 ■; •: ::: -zs. =*= 1 - tti< rd Etefc £5*30 (ar rnsfl Europe): E5.10 farm £ r-s$2Jy ito Bs&srasf 3 =•_•£= : ■; : : ; e i -r= Li [Ifr 1 ■: : .7 €" jf Eun?;«fi; a&d £c -: e ■ -i' E : : ' ARTICLES r c ' '?:• ' TOSbi : ' psst L". : f= : : : - : : ■ ^ : r :_r E: .its ... :---•: ~ - , f - -• : :: : : : ; - : jj ; C05 '5 ' _ : r: i : : i_ : ■ -: -: : ; : ' : i : : £ USS Xflfnx PROM Programmer @ 0101&3-11 SfefelUt to crijr/r^nro 4-90 8.65 fiUt O'Cr i ^IriD^rl jLUU iJ ATV Picture Generator @000295-11 Disk, source Aha codeStes 4^3 i0 £5 020295-41 AT90SB515-SPC, pnj^OTTCd 15 20 2660 0202964 2 AT90S 1200-i 2PC . prograiawed 13-90 2460 DTMF Remole Telephone Switch @ 020294-1 FCB 1165 236.:' W 020294-11 Cfe*_ 4-90 B65 020294-41 Pi€l 6 F&4A-2C ?. pm^nsned 14-70 25 CO 1C Display with I2C Bus @ 027660-2 PC 3 7-35 1300 PICPrag 2003 © 010202-1 PCS 94>5 1600 3 010202*11 C s6 VVi&'A3 snfiAirs 490 365 010202-41 F1C 1 ^874-20 R progrartin=d 23 55 41.85 Polyphonic Doorbeil C? : 026354-11 D;.5*l pfB;ect EOnWHS 4-90 565 029354-41 PSC1BF84A-10P pmpamEd 14-45 2555 Precision Measurement Central 030060-91 Brcdy-assssrifed & r £;:es 4-9C £65 020293-41 Pttl 2C5QSA-G4?SM, prograrntred 7-40 13.10 AI90S2313 Programmer ■ - ■ @ 024025-5 PCS 9-05 1660 ' Hard Disk Selector @ 034050-1 PCB 945 16.75 Mini Running Text Display " @ 02036611 Dke« s:-^ceccc5 Be 4-SO 365 Mini Test Chari Generator @ 02C4 33- i 1 Lfe.<_ Fl-C setifca c«fe 4 90 86-5 Programming Toni tor ATtinylS @ 0300345-1 FC-3 7-55 13 3-5 © 030930-1 5 0 e- pre^sd: 490 56-5 Quad Bridge Car Amp @ 034033-1 FC3 S70 15.35 Remote Light Control with Dimmer @ 020337-1 1 DisV.. HEX end source ffies 4-90 3 SS 020337-41 ATS9C2051-1Z. pregfammsd 6-25 11.65 to 399 ItifiE 9RR3 nU* gu Vyflt £U(/J AVRTV Tennis @ 030026-1 ’/=in P83 B7Q 15.43 @ 0SC626-2 Pus^fettco FCB 860 15.25 @ 030026-11 DSsk. A\6 scutrcg COC5 490 565 030026-41 ATS05515 c-mparrm=d 15 20 26 9j Eleclronic Knotted Handkerchief @ D203G3-11 Disk PC snd cwtrtfllsi SO??as:t 490 8.65 020303-4 1 AT9GS23 1 3-1 DPC, pragramte'd 12 SO 22.30 Law-Cost LCD Gonlroller (Z) & 020114-1 PCB 870 15.35 @ 0701 14-11 6 ,> preset S-jTTa *f 5 4-9D 3.55 Night Light Control @ 0201 i 5-1 1 C .ev hex ird sataca code 4-90 3.65 0201 1 64 1 AJB0S23 1 3- 1 lFC. pmgsivrad 12 85 22 75 Universal XA Development Board @ 010103-1 FCB 1320 23.35 @ 0191 03-1 1 Cfe v. GAL cade. EPRO !, p : tax Ses, XADBf 4-90 865 0101 03-2 1 EPStDJi! ECS . 27C256-S0. p'cc isnmed 1SHW 17.70 030103-22 EPF.QV LC9 27C256-93. pravamm^d 10-00 17.70 01 01 03-31 GAL 1 o '.6. pmc-rsmmai 4S0 3 50 2 2004 Efektor Electronics 67 r Ho ] ? i M4 Y POP 1 - — £ uss Countdown Timer © 02B29541 scc-ir* and tet 02G-£'3o- 4 1 AT SCSI 200 : :cc-^t £ t-=c USB Audio Recorder @ 01 201 3- 1 1 Disk E? R OM - c ote 01 201 3-2 1 EPa OM 27CS1 2. pcogramm-c Valve Final Amp (2) •2 OZCO'I -■ AmpT^r : : 3 rd .Cte c'-srit (S> 020071-2 ftfivef stflp'V basn! Mo 320 jJPfl// 2003 4^0 1390 4-90 1250 1510 70-05 8.65 24.66 £65 22 33 26.75 17 75 Hvf v£ w nf Ilf L ju- U Ej J B-Chann&l Disco Lighi Controller @ 010131-1 PCS 13-10 2315 010131-41 67C750 O' 87C71. p/Dararaned 23-03 40.70 Pico PIC © 01 CO-59-1 PCS 13-70 33.10 @ 010059-1 1 d:^_ ma program 490 365 Single-Chip Tone Control @ 02G&544 FCB 1090 19 30 Swtched Outlet Power Bar vrilll RS232 Control © 020233-1 PCS 1080 1910 m 020293-11 Disk. pnVed software 4-90 5 65 Temperature indicator tar the PC © 020353-1 t I?, v ■ s-uu tee disd c GfTipf ] t : 4 f ABO 5.65 02033047 AT 69C2051 . prog 10-25 18.15 No 31 S MARCH 2003 tlUa u- f -J fff.fiflUii 17 V IDA Switch’Morie Power Supply @ 020054 3 PCS 045 1665 Add-on Switch unit tar Ft C Models © 020126-1 PCB 055 15.15 f 020126-11 0- e-. rE» and sourcs f es 4-90 B.65 02012641 PIC16C71 2-041 SO. prcq^-rmzti 15-20 25.90 AVRee Development System @ 02U351-1 FOR 1320 23.35 @ 0003514 1 3 e.'ITI pfUgfdJRS 4 -SO 8.65 Guitar Effects Switchbox © 0201B1-1 PCS 13-15 23.30 Intelligent Fan Timer @ 0201/0-11 DT- pro tCI scftwiii 4-93 6.65 020170-41 VSP433 -1 121. c-mgranmed 1130 2000 SAA3049 Replacement - Q20QS54 PCS 13-05 23.10 © 0202-35-1 1 0.e£ somite i n T ■ co-:t 4-50 fl.CD 020OS541 E"LFC7o4 B f L prec ■ ; t "red 093 17.55 Two-Cotonr Running Light © 010134-1 PCS contiDT^r rasjti e-25 14.60 © 010134-2 PCS. l£D tearc 1065 IS £0 @ 010134-11 D sv. ii'cg:: 3e*iA-£/e 4-S© 6.55 01013441 AT B9C205 1 - S 2 'FC . pcogtsnnied 7-15 12 65 Nn 31 E FFRRi/ARY 2003 wJUt rCtffilfnfii lUl/v 20 40 MHz Logic Analyser @ 020032-1 FCB 15-20 26 £5 m 020032-11 04 i.. prcc-E.ri 490 8 6-3 02003241 ATSOS £■ 5 1 5-SPC. ^TKrzr.T act 1510 Zo.70 Active Loudspeaker System (2j @ 020054-2 PCB 795 14 05 Autoranging Capacitance Meier @ 0201444 FCB 7-35 13.00 @ 020144-11 Dee - saarcs and h- « f t.s 4-90 £.55 02014441 PICt6f S4A-20R pcogtafninEd 15-20 26.S0 Dimmer with 0-10 V Control Input © 01Q1254 CCctAC: PCS 17 m © 010125-2 ttirr*s>=T FCB eoa 15.65 Electronic Hourglass @ 0200364 PCS IB-55 32.85 # 020036-11 C3- pm-gcr SDftvrec 4-90 B.65 020&3S41 F5C16F34-04 ? p/BgraiTmBd 15-20 26 90 RPAnnKw./^s Optimise your PC Soundcard @ 02018441 E*cef s$weatfe!*e^l m, 317 JANUARY 2003= uss 1 :: Aclive Loudspeaker System (1) @ 020QS4-! PC 3 Electronic RFG Dice Roller @ 02D005 1 PCS <® 0200054 1 C-e>l s&jzlz c&3s f e 02COD541 AT 90=4 113-5 PC. Rorfenl Deterrent @ 020110-1 FCB SMS -Controlled Mains Sockets @ 0201 57- 4 PCB Nd 316 DfCFMRFR 2 ft ft? = 690 10-05 4-90 30-80 12-95 12-90 12.20 17.75 E.05 5-4 50 21 30 22. E5 ¥i\Im «1 f U OC-Vi^l/ 70Cfl £lrU4 □Cl PLC © 0101 13-1 PCS. ooTTVcrter bosti 5-40 14 E :- © 010113-2 PC-3. sairLins] boird 1250 2210 © 010 1 13-11 S'ET/ij.rs 5 sossnis axfe 4-90 3.65 0101 1341 AT90S85 1 5-BPC . progrsnmai 21-20 37.55 Pori Line and ADC Extension @ 02100741 07- 3 AS C O s 2 - 51 oraggsms AM 8.65 Programmable Diai-Oul Blocking Device @ 0201 06- 1 PCB 12 26 21.55 @ 020106-11 rEsfr. project sC'tAi"? 4 90 5.55 D2Q1B641 A T S9C £ C 5 1 - J p'cciTTEd 850 71.50 USB Audio Codec wilb S PDIF © 020178-1 PCB 11 10 *960 if 4ft JIJ If 1/ r Eff . JD tfl £C/v£ Audio Level Check tor Line Inpul @ 020189-1 PCS 9-25 ■5.35 EPROM Emulator © 024:66-1 FCB 9K33 7c 50 @ 024066-11 E>V GAl J E G EC Ee3» 4 90 5.65 0242^31 GAL 16V39. prugrarmied 50Q £.55 LEO Torch @ 0120134 r C 5- I'T- rEG EOsTjVdJH 4-90 B.65 Q1 2G 1941 PC 1 2CS72-04 £ p'c.-'a.TT^d IQ-40 IE 40 Stand-Alone EEDTS Pro © 020125-1 PCS 15*35 27 15 Telephone Baby Monitor @ 0120164 PCS 10-00 17.70 © 01201 S- 11 Disk soGice ar-j h=». files 4QQ 6.05 01201641 AT90S1313-10PC, pregramsO 10-40 1640 Vehicle Diagnoses Adapler @ 020133-1 PCB 0-25 1635 JU/T 31A OCTORFR Fflft? * i£ fly* mi 1 # (/u! y&b/j AT90SB535 Programmer © 024051-1 PCB 905 16 05 Digital RF Wattmeter # 020026-1 FCB 1265 22.70 S 020026-1 7 Bge-7. es_":t cc-:A fTe? 4-9U 3 65 02002641 PT 1 cF37 i£C- SP 1900 35.20 Motorcycle Theft Alarm * © CCOlO 1-1 FCB 9-95 17.50 @ 000191-11 D%s>_ source ccce ffes 490 B.65 0601 41 P.C16F3W SO 1990 35.20 09019142 F'i 016754-04 P 14 70 26.05 Sound Pressure Level Meier © 02Q1224 FOB 19 70 34.85 Nn 313 3FPTFMRFR 2 ft ft? ItUw y f y iJtJT i CfTI&C-H & UV£ 20-Metres Band Receiver @ Of 0097-1 FCB 1430 25.30 Capacitor ESR Tesler .© 012022-1 PCB 16T5 2B.60 Continuity Tester @ 0200024 FCB 460 3.10 EEDTS Pro Super Loco Decoder Upgrade 02009441 FTC t&r sype-: Ixo CT--c-:f r 1990 35 25 0200954 S FTC f» fc=ATI S9gTiS3::T 17 25 30.55 Firmware Update lor EPROM Emulator @ 024107-11 ogj. tel T 4-90 8.65 02410741 Alt 205 J -1 2 - EfDO ITiT-E-j 7S5 14.10 High-Speed Controller Board @ okh 02- 1 FCB 11-95 2U5 Parallel JTAG Interface © K-CCCS- FCB 8-75 15 45 ? 1? lift Y'5 ttfti t3T 2 ft ftp flUr yl£ yUil^yUyai £ ULf f 4-!Bit Decimal Display 824072-31 QAL22V1 CO-25LP pec? r t r: 6-93 12.20 Products for older projects (tf available) may be found or our web site http:Hwww.elektof-electronics.co.uk SB Elaktor Electronics 2 2004 : Please send this order farm to ' reverse For conditions) Elektor Electronics (Publishing) P. 0 . Box 190 Tunbridge Wells TN5 7WY ENGLAND Tel.: (+44) [0J158D 200 657 Ffflc(+44) (0)1 580 200 61 6 imerneirvu'i elektor-e lectranics.co.uk antf Csnetk nsi&ffc m*y (fca ae raft obSged Id} use S prices, srad $end the Ottfcf lam trr_ CM Ct&wiy Sound Lab, P.O- Bax 876 , Peterborough, IfH 03 ^ 5 ^- 0876 . Td. ( 603 ) § 24 - 6371 , 924 - 6526 , fsc ( 60 S) 924 - 3457 . BraS: c.E:E-]r, ORDER FORM 2-2004 VAI No GB 454 135 463 - i j i i i Name Address email Post code Tei. Fax Date Please supply ihe following. For FCBs, front panel foils, EPROMs. PALs. GALs, microcontrollers and diskettes, state the part number and description: for books, state the full title: for photocopies of articles* state full name of article and month and year of publication. Please use block capitals. Qty, Order Code Description Price each Total NEW CD-ROM Freeware & Shareware 2003 E 12.05 NEW CD-ROM Toolbox - 2 £ 12.05 308 Circuits £ 18.20 M SCI 210 hoard £69,00 GBDS0 board £ 90.00 Method of payment (see reverse before ricking as appropriate] Note: cheques not made aul in steiling must be increased by the equivalent of £15.00 □ Bank draft □ Cheque (payable to Elektor Electronics Publishing) Ptees 3id street fa I-i ? «sri; r : F :ee i~~, "f~ 5Mjni3 tore supersede those hi jfniri ,_L SS-iS E S Z r Sub-total P&P Total paid ij Giro transfer (our account no, 34 1 52 3801 ) .J Postal money order □ ^IsT Expiry C8te: fi * Reduced price for subscribers. Hty subscription number is: SWITCH oniy: issue number: Signature: i 1 I I I 1 I ] I 4 l I 1 I 1 I 1 I I I ■ J r- i i Please sene this order form to ■ t i Worldwide Subscription Service Ltd. Unit 4, Gibbs Reed Farm Pashley Road Ticehurst, nr. Wadhurst East Sussex i ENGLAND TN5 7HE I I Tel. (+44) <0)1580 200657 ] Fax (+44) (0)1580 200616 ■ Email ww55@wv.5s-demGn.co.uk [ E I SUBSCRIPTION ORDER FORM ■ -i f i I \ Please enter my subscription to Elektor Electronics T type □ Subscription-Plus (incLCD-RQM Volume 2003) or □ standard subscription. Subscription rates and conditions are given on the reverse of this form. Please send me r free of charge the SURVIVAL KIT Title (Dr Mr Mrs/Ms)* Address: Initials: Surname: email: Postcode: ’ crass out v>hai is not explicable Dale: Method of payment (see reverse before ricking as appropriate} Hate: cheques nat made out in steriHip must be increased by the equivalent of £ 15.00 "□Bank draff J Cheque (payable to Elektor Electronics) EJ Giro transfer ~_j Bank transfer Zl Postal money order Q r vlSA X riwl zu~ Signature: SWITCH only: issue number: Expiry date: i i 1 * i l i l E I 111 2 2004 Elektor Electronics 69 r ORDERING INSTRUCTIONS, P&P CHARGES [ 1 • Except in the USA and Canada, all orders, except for subscriptions and past issues (for which see below), must be sent BY POST or FAX to our Tunbridge Veils address using the Order Form overfeat. Please note that we can not deal with person callers, as no stock is carried at the editorial and administrative : office. On-line ordering: http:/ w f w w.efektc r-el ectronics . CQ.uk Readers in the USA and Canada may (but are not obliged to) send orders, except for subscriptions (for which see below): to the USA address given on the order form. Please apply to Old Colony Sound for applicable P&P charges.. Please allow 1 4-6 weeks tor delivery. Orders placed on our Tunbridge Wells office must include P&P charges (Priority or Standard) as follows: I OK: £3.50 i £u rap e : £5,00 (Standard ) o r £7 .00 (P riority) 1 Outside Europe: £8.00 (Standard) or £12.00 (Priority) i E E HOW TO PAY 8 Unless you have an approved credit account with us. all orders must be accompanied by the full payment including postage and packing charges as stated above. Payment may ae made by cheque drawn on a London clearing bank (but see para. 4 below), postal order, VISA, Access. MasterCard or Euro Card (when paying by credit card, the order must go the cardholders address). Do not send cash through the mail. Cheques and postal orders should be crossed and made payable to 'Elektor Electronics (Publishing) 1 . Payment may also be made by direct transfer from a private or business Giro account to our Giro account No. 34 152 3801 by completing and sending to the National Giro Centro, in a National Giro postage paid envelope, a National Giro transfer deposit form. Do not send Giro transfers direct to us, as this will delay your order. : If you live outside the UK. payment may also be made by Bankers 7 sterling draft drawn on a London clearing bank, Eurocheque made out in pounds sterling _ ("with holder's guarantee card number written on the backs, or US or Canadian dollar cheque drawn on a US or Canadian bank. If you pay by Bankers' sterling draft, make clear to the issuing bank that your full name and address MUST be communicated to the London clearing hank. Our bankers are NAT WEST PLG. 1 St James’s Square, Wadhurst. East Sussex TN5 6BH. England. Our account number is 3512 5225. Sorting Code 60*22-1 5. IBAN code : GB40 NWB K6 022 15 3512 5225 \ SIC code : NWB KGB 2L ■ Subscription rates from January 2004 issue Standard Plus ! United Kingdom ........ £39.50 £45.50 Economy Mail Rest of the World (excluding Europe) , . £51.30 £57.30 Priority Airmail | Europe & Eire .....£52 50 £53.50 Middle East, Africa, Southwest Asia, Central & South America .£64,00 .£70.00 Australia, New Zealand. Far East & Pacific Territories £66,00 ...... £72,00 Airfreight USA & Canada only USS38.00 .... .US596.50 I Payment should be made by: * Cheque or bankers' draft in sterling drawn on a London clearing bank (except in the USA and Canada — see below): Eurocheques must have the holder s guarantee card number written on the back. ■ USS cheques drawn on a US or Canadian bank — only by subscribers in the l USA or Canada. * Direct transfer to our bank (NAT WEST PLC. 1 St James's Square. Wadhurst, ! East Sussex TN5 6BH. England). Our account number is 3512 5225, Sorting Code 60-22-15. * Postal order. * Credit card: VISA. ACCESS. Euro MasterCard, JCS Electron or Switch. * Transfer to our Giro Account number 34 152 3801. Giro transfers should be 1 COMPONENTS Components for projects appearing in Eleklor Electronics are usually available j from certain advertisers in this magazine. If difficulties in the supply of components are envisaged, a source will normally be advised in the article. Note, however, that the source (s) given is (are) not exclusive. Delivery Although every effort will be mace to dispatch your order within 2-3 : weeks from receipt of your instructions, we can not guarantee this time scale for all orders. Returns Fault 1 / goods or goods sent in error may be returned for replacement or refund, but not before obtaining our consent. All goods returned should be packed securely in a padded bag or box, enclosing a covering letter stating the dispatch note number. If the goods are returned because of a mistake on our ! pari, we will refund the return postage. Damaged goods Claims for damaged goods must he recei ved at our Tunbricge Wells office within 10 days iUKj: 14 days (Europe) or 21 days (all other j countries). Cancelled orders AH cancelled orders will be subject to a 1G : : handling charge with a minimum charge of £5 GO. Patents Patent protection may exist in respect of circuits, devices, components and so on T described in our books and magazines. Eleklor Electronics tPublishings does not accept responsibility or liability for failing to ; identify such patent or other protection. Copyright All drawings, photographs, articles, printed circuit boards, programmed integrated circuits, diskettes and software earners publishes in our hooks and magazines (other than in third-party advertisements) are copyright . and may not be reproduced or transmitted in any form or by any means. 1 including photocopying and recording, in whole or in part, without the prior permission of Eleklor Electronics (Publishing) in w riling. Such written permission must also be obtained before any part of these publications is stored in a retrieval system of any nature. Notwithstanding the above, printed- circuit boards may be produced for private ; and personal use without prior permission. Limitation of liability Elektor Electronics (Publishing) shall not be liable in I contract, tort, or otherwise, for any loss or damage suffered by the purchaser whatsoever or howsoever arising out of, or in connexion with, the supplj of goods or services by Elektor Electronics (Publishing) other than to supply goods as described or. at the option of Elektor Electronics i Publishing), to refund the purchaser any money paid in respect ot the g oods. Law Any question relating to the supply of goods and services by Elektor Electronics (Publishing) shall be determined in all respects by the law f s of England, January 2004 \ ' - - made by completing and sending the appropriate transfer deposit form to the National Giro Centre (UK) or to your national Giro Centre. Cheques and postal orders should be made payable to Elektor Electronics (Publishing ^ Do not send cash through the mail. i i i i Subscription conditions | The standard subscription order period is twelve months. If a permanent change of address curing the subscription period means that copies have to be despatched by a more expensive service, no extra charge will be made. Conversely, no refund will be made, nor expiry date extended, if a change of address allows the use of a cheaper service. i i Student applications, which qualify for a 20% (twenty per cent) reduction to current rates, must be supported by evidence of studentship signed by the head of the college, school or university faculty. A standard Student Subscription costs £31.60, a Student Subscription- Plus costs £37.60 (UK only). : I I Please note that new subscriptions take about four weeks from receipt or order to become effective. I 1 Cancelled subscriptions will be subject to a charge of 25 A (twenty-five per cent) of the full subscription price or £7.50. whichever is the higher, plus the cost of any issues already dispatched, Subsclptions cannot be cancelled after they have mn tor six months or more. E J January 2004 70 Elektor Electronics 2 2004 Books from Elektor Electronics Audio & Video 302 Circuits 302 citCniltS I Summer Ctrcuils oomptlsboo 1682, 1683. 1634 £ 10.35 USS 21.80 304 Circuits Summer Circuits coma^twi 1963, 1939, 1990 C I RCUiTS £ 13^ 43 uss 21 . 00 304 ■ i Lasers: TRE&rr.t'vD PtACVCL — C 305 305 Circuits . Summer Cucu'te campfeban 1961. 1992. 1993 CIRCUITS r 75.55 USS 310 0 307 Circuits S-.-T.r-? Circuits c^mp 'EiIofl 193". 1999, 1933 £ 18.20 USS 31- 03 CIRCUITS 308 Circuits ^ ^ Summer Circuits compiJaS&ft 2000. 2991. 2032 £18.20 USS 37.00 55 Lasers: Theory and Praclice A -.Tusiite hzz'.n r rj przcr-zs': lee cT:eee j s. £20. 75: USS 42.03 Build your own Electronic Test Instruments Fo r good reasons (cost, diaSenge} many researches, EjiUiLJSiiStE J " j E pfE rirTiE^tEfE * E IQ '2_ !2 T£5i t ristnj rnEfT'i tr z ~~ e.c! f g s . £ 16.60 USS 33.00 Electronic test instruments Build your own Audio Valve Amplifiers Tp.'z :::> ::.ee Util ^e '."E rr':":: ve.Se e maJcBig a cmis'badL £ 15,55 USS 31 M Hj-zcc-z- 1G4 : : . P3 fsefutiesass Handbook for Sound Technicians A boot on itie technical aspects of the mcoctSrtg studio, £20.16 USS 42.00 Designing Audio Circuits How doss spe&ch, rrmsw:. of. irKtegd, any sound get from the record, CO. or cassette tape to the foutf- sp&efcar? Tr e toz>: E'Cia-.-iL’i ts ; : : z a “ s ■? : £20 Jo USS 42.00 Build your awn High- End Audio Equipment For those vjtro carmot pay _ ... prices for high end equipment a sofubon offered in this book; bu&i your cwn at ctwtsxfefab!-? cost Savirr-js £ 15.55 USS 31.00 Modern High-end Valve Amplifiers V^y£ amplifiers based go :: : :i : e"e : - : e cambera trf etossed tednoidgy and modem components. Hie result exceBent sonic qaaity afrd a rprwal of the valve ampS- Nr. £25.95 USS 52.00 Order now using the Order Form in the Readers Services section in this issue Matchbox Basic Computer Ttus books describes :i — r j = :. - :r □" system Losing a pro- gramming Sar-guags cafled MEL (MatchBox Language), viftkh riss its origins in BASIC amt Pascal, £25.95 USS 52.00 ST62 Microcontroller FrzctcsJ program mino ci the ST62 series o: fi^rocontrofiers from £GS Thomson. £24,35 USS 50.08 m /.vpwcncf: Eg ■ i Computers T FaiifHiitding in Computers and Digital Circuits Dictionary of Monitor Technology A piCfl ssring boo?: o! l-.sl'- passed rarige vrttfch dearty documents ait aspects of the tfSVE&pfBEIit Of OOfnjHftff manta is £ 26 . 35 ms 52.08 Faultfinding in Computers and Digital Circuits This book covers fauttfiraL '"3 • r : sor systems, rraefocorr- trotters and industrial PCs, but also in consumer Items such as pEfsonai computers, midli/Eedk ttevkes, rifcptal tef^onandsoofL £ 3 ?. 15 USS 63.00 PICs in Practice The PXCIBCSk. fsmiy s a series of iracnnorc-i froiets that tend them seVss s brcstf vari- e:, of appMsboos. £24.95 USS 53.00 SCSV303<2 I *m.. t j hi m >■ « i 'i- See also www.eiektor-electronics.co.uk s — WH The PC bi s ~ i PC SERVICE .t xd repair r - i.-t L-; »■ rLt-?E The I2C Bus ' " i : : : ■ : : e e -: =:: ■ : , e . Viitft the tetihftteaJ spedhoa- taas of thet 2 C bus. £25.35, USS 52.00 PC Service and Repair This book provides the infotmaSno ,-z-l r=Ed :o be abte to deal with o^mputer system (suits wfieraircr they occur. £ 31.15 VS$ 53.00 ;ci a Elektor Electronics (Publishing) P.O. Box 190 * Tunbridge Wells TN5 7WY * England, SCSI THE 1SSASD OLIS 15 X — Short Course 8051/6032 Microcontrollers A ooutse dscnbmg tfta fur dvrs re i - : s-ofri'isrs Ei 5^ fT; I IE ' zziz I ‘.3 make a comptefe in^fo- cofmoB^ system based qn an f.t£S-51 canfroBet 29.85VSS20.00 SCSI RQJ.f E r : pmv3 ’.ik- :: e "i" - ouf a pfoifem in a SCSI sys- IE~. £ 24.85mS SOW PC interfaces under Windows lifeaEureroEnt and control using standard polls PC Interfaces can be used for more thin just Uk prift- tcr, mouse, modem arid wy- stfdfi £ 25.05 USS 52.00 Telephone +44 (0) 1580 200 657 Fox +44 (0} 1580 200 616 wv/w. elekfor-e I edronics.co.uk uiks To book your website space contact Bernard Hubbard . J. -jr — - ■.«» — Tel (0)1 242 51 0760 Fax: 0044 (0)1242 226626 BETA LAYOUT A VAV. fJCu -pool .€Qin tvfi n „ « t = Beta layout Ltd Award- winning site in both English and German offers prototype PCBs at a fraction of the cost of the usual manufacturers’ prices. BURN TECHNOLOGY LTD H e t rv /wii i,jTff h a e mrr a p it fi m I i Lt|J . ii k 1 l l i . u If ; ! i LL- b U 1 1 ( Distributors of a wide range of device programmers, package adaptors, test and soldering equipment. Order online and get free delivery on ail orders over £30.00. COMPUCUT h up'/AvvAY. comp u curie r s .com Computer Numerical Control from your home PC. Great for tricky jobs, and accurate repetitive work. We supply: - Software - Interface - Manual - Support Price £250 plus postage. CONFORD ELECTRONICS lightweight portable battery- mains audio units offering the highest technical performance. Microphone, Phantom Power and Headphone Amplifiers. Balanced unbalanced signal lines with extensive RFI protection. CROWNHILL ASSOCIATES LTD o tel 01353 666709 fax 01353 666710 * Manufacturers of production quality device programmers ■ PIC Programmers * PIC Development tools * Manufacturers of Smart Cards * Smart Card Programmers * Design & Development Services Crawnhill Associates Limited 32 Broad Street Ely. Cambridge CB7 4 AH Tel: 01353 666709 Fax: 01353 666710 DANBURY ELECTRONICS Here you will find our mains and output transformers in Mike Holme's range of valve/tube amplifiers (P P & SE). Also circuits, parts lists, chassis, advice. DEBUG INNOVATIONS UK sl f i ■ A, -j ■ 1 1 a j-|ir fjphi an I nn f\Y f-t. f j c - jp n m S I L Lp ,J s i l'i j in UU 1J La y 1 1 Ii G L Lr '+ 0.11 U 1 1 D , \j? LJl 1 1 Introducing hassle free prototyping * RF/ Analogue ■ High speed digital * Surface mount * 0,1” grid ■ Power planes * Unique patch architecture forget custom PCBs. start your project now! EASYSYNC EasySync Ltd sells a wide range of single and multi- port USB to RS232/RS422 and RS485 converters at competitive prices, ELM ELECTRONICS Offering a variety of unique and low cost integrated circuits for the experimenter. Secure ordering via the web site with worldwide shipping. ELNEC • device programmer manufacturer jf • selling through contracted distributors all over the world • universal and dedicated device programmers • excellent support and after sale support • free 5W updates • once a months new SW release • reliable HW • three years warranty for most programmers IRVAN INTERNATIONAL Co. Power Electronics and Solar Energy Design and Consultants. Also offers; Discount prices of: • Ultra Briahi LEDs • PCB LED Cluster Kits • Laser Pointers • Solar Modules • Batteries FOREST ELECTRONIC DEVELOPMENT FED supply PIC programmers, Basic modules, and development software including a PIC C Compiler, Prog n Drop Visual Development and a well featured debugging environment. FUTURLEC Save up to 60% on • Electronic Components • Microcontrollers, PIC, Atm el • Development Boards, Programmers Huge range of products available on-line for immediate delivery, at very competitive prices, FUTURE TECHNOLOGY DEVICES FTDI designs and sells USB-UART and USB-FiFO interface Lc.’s. Complete with PC drivers, these devices simplify the task of designing or upgrading peripherals to USB HAMMOND ELECTRONICS tel: 01256 812812. Small die-cast, plastic and metal enclosures for the hobbyist and professional. Widely available from major distributors. MOP ELECTRONICS Leaders in Device Programming Solutions, •Online shop •Low Cost Adapters for all Programmers • Single Site and Gang Programmers • Support for virtually any Programmable Device / f fig- r pa NEW WAVE CONCEPTS Software for hobbyists: • Liveware circuit simulation software, only £29.36 • PCB Wizard circuit design software, only £29,36 Available from all Maplin Electronics stores and wvAv.mapfin.co.uk PICBAS1C • Pic basic & Pic Basic Pro • Fast efficient powerful compilers • Parallax stamp compatible code • Write in basic-compile to hex • 12c, 14c. 16c(f) and 17c pics POND ELECTRONICS tef ^353-1-821-5060 fax +353-1-820-9384 Innovative systems tor PIC development & embedded applications, • pFIash876 • PIC C Compilers & Programmers • MtcroStack • Basic Stamp • Custom development Service QUASAR ELECTRONICS ~/7>ZT2~S CKjtS ■■ *r jrK I W * :: ~ v £ i Over 300 electronic kits, projects and ready built units for hobby, education and industrial applications including PIC/ATMEL programming solutions. Online ordering facilities Tel: -4- 0 870 246 1826 Fax: +44 (OJ 870 460 1045 E rn ail: sales&Qu asa rB ectro nics .c o m M * K faf 7T~ rr. — 1 72 Elektor Electronics 2 2004 y ms 1(231! [fir ROBOT ELECTRONICS n ” 1 i i v i : I'A / 1 1 ► ■ ( yj ■ i rn ri t r j j '! '• a i. jJT -mJ J i II 1 I r ■ i 9 .< iji lj «_b L ts> l Lfl/U L* j il • L;u * Ultrasonic rangefinders ■ Motor H-Bridge controllers * Magnetic Compasses * RC servos and controllers * PJC programmers and components * Electronic Design/ Development and Manufacturer to industry SPICEAGE AND SPICYCLE rr r* i ’ "k i . r |-j ■ .. r*» .r-? i r jrt ■Jj r-p -jo ^ph it I h >i I/. b i j j* f i . Jy LJ h~ r - ' Spicycle circuit design program (schematic drawing, well-featured PC 8 drawing, Spice Age simulation). SuperRIter digital and analogue filter synthesis and optimisation. Download a free working evaluation and enjoy software renowned for its high quality at prices that make if seem like Christmas all year round. Make contact with Those Engineers (020 8906 01 55), real engineers, who will understand your needs. TECHNOBOTS The 1 S .Li rlJ ii gifting onitj Spirit le SIS. Welcome to Technobots - g| the one stop shop especially for the remote operated robot builder, wm radio control and engineering hobbyist. TELNET The site shows graphically Telnets wide range of quality second-user test and measurement equipment including oscilloscopes and spectrum analysers. ULTRALEDS tel: 0871 7110413 Large range of low cost Ultra bright leds and Led related lighting products. Major credit cards taken online with same day depatch. USB INSTRUMENTS VIEWCOM it*. .USD 1 giro merits 11 . a 1 LaC J i .Lift USB Instruments specialises in PC based instrumentation products and software such as Oscilloscopes, Data Loggers, Logic Anal ays ers which interface to your PC via USB tel: 020 8471 9338 fax: 020 8552 0946 * Mail Order supplier of: * Integrated Circuits and Components. * Kit and parts for Etektor projects. * Transistors. FETs. Capacitors, Resistors, Crystals, etc and hard to find devices. Viewcom Electronics, 77 Upperton Road West Piaistow, London El 3 9LT i i i i i i i i i t i i i i i i i i i ] t i ] I i i J L I u Elektor Electronics have a feature to help customers to promote their websites. Net Link'' - a permanent feature of the magazine where you will be able to highlight your site on a regular basis. - For just £ 1 20 + VAT (£10.90 per issue for eleven issues ) Elektor v. ill publish \ our company name, a 25-word description and your website address. ■ For £300 + VAT for the year (£27.27 per issue for eleven issues i we will publish the abo\ e plus run a 3cm deep full colour screen shot from your site. Places are limited and spaces will go on a strictly first come, first served basis, please fax back your order today! 1 wish to promote my company, please book my space: * Text insertion only for £ 1 20 + VAT ■ Text and photo for £300 + VAT NAME: ORGANISATION: JOR TITLE: I l i ADDRESS:... i f - ......................... . i i i i I .................TEL: PLEASE COMPLETE COUPON BELOW AND FAX BACK TO 0044^0)1242 226626 COMPAN Y NAME WEB ADDRESS. t I 25 WORD DESCRIPTION., i t IT.......... | t — — - - ( I l f ■J. sqji mm m smr^as Only one magazine tests its projects and circuits in its own lab beforepublication - ELECTOR ELECTRONICS THE ELECTRONICS & COMPUTER MAGAZINE rffif Contact: Worldwide Subscription Service Ltd, Unit 4 Gibbs Reed Farm, Pashley Road, Ticehurst TIMS 7HE Telephone: (+44) (O) 1580 200657 Fax: (+44) (0) 1580 200616 Or visit our Website: www.elektor-electronics.co.uk 2 2004 Elektor Electronics 73 SNEAK PRFVIRA/ Next month in Elector Electronics Multi -Function Frequency Meter The simple construction of tins instrument belies its power, versatility and ease of use. At the hear: of the emeu:; vve find an AT90S2013 mhore-zorurche: running software for a plethora of functions, including - Pulse duration of positive or negative halt cycles, in microseconds and milliseconds Period, in micro se eon d s and m u 1 1 se corn; s - frequency, using gate rimes of 0.1 s, 1.0 s and 10.0 s - Event counter (7 digits - Stopwatch with 0.01 s resolution DRM Receiver Theory is fine as long as it is followed by a practical applica- tion. After our introductory article on Digital Radio Mondiale (DRM) in the December 2002 issue and the Experimental DRM Receiver in the December 2003 issue, vie nov; follow suit and embark an a full-blown construction project. Our DRM Receiver is tuned ever an PS 232 interface and supplies an MPEG-4 output signal for decoding by your PC soundcard. The circuit is simple and inexpensive, yet guarantees digital quality from short-wave broadcasts. Also... .'find Power, Hands-On CPLDs (2). Failsafe fro RC Models. Cede Lock. Bistable Relay Driver BASCOM AYR for CF Cards, IE Servo Motor Interface for RCX. RESERVE YOUR COPY NOW! The March 2004 issue goes on sale on Friday 24 February 2004 (UK distribution only). Article titles and mag azin e contents subject to change. UK subscribers will receive the magazine a few days before this date. NEWSAGENTS ORDER FORM SHOP SAVE / HOME DELIVERY Please save / deliver one copy of Elektor Electronics magazine for me each month THE ELECTRONICS & COMPUTIR MAGAZINE Name: Address: Post code: Telephone: Date: Signature: Please cut out or photocopy this form, com- plete details and hand to your newsagent. Elektor Electronics is published on the third Friday of each month, except in July. Distribution S.O.R. by Seymour (NS), Index of Beta Layout NM Links . . cor- 63 T 72 Bum Ted oology LTD, Net Links ...... w^r.cw .72 am.vk.cQfn . .7 aw v/. ccfnpj cuiltrs .cam .72 wav tor *ord* 's€.£3.l'‘ .72 - 29 ....... MW& CrOtVI-E' CCJA: .72 - AVM.nui-kfcmP.vdM .60, 72 .... — iiv/o /a:b;;5 tom .72 ..... VAYf. clsiel m,L k ..23 -.iHvw.easjfS) r cco, uk . .72 — ... ..Viivi e-rrietectornfcs sen J2 . . .WA’A einec. ten ....................... .72 — ... .vmW'&nrc rioo.uk. .,.60 ....... srssr-'vLccni . 72 mv. foretf co.uk .8, 60 -iVV, ‘A’ ?j‘l' : 5C.££ jp ,72 Future Techno’oo/ Devices, ?M Links - - .,-.v,v, fit, : cc-w ,72 Hammond Electronics, Nei Links -•••-. . ■ ■ y ;; -- . 72 DP - ■ w Id 'Qi.cc 7i ......... 55 Advertisers CMS Coropuct/L Jlet Links ConftmJ Bectronics, Net Links Cricklewood ..... .... Grownhfl, Net Links .... Danbury, Net Links Deb.:.: Innovations, Net Links Display Electronics Easy sync, Net Links ELM Bectranics Net Links, . . Efraec : Net Links Enoori Ervan, Nd Links Forest Net Links ..... FuMec. Net Links ..... MGR Electronics, MM Links .vmw. npqefectmnics.co.uk .72 fist Links 72. 73 New Wave Concepts, Net Links wm:new A^m-amcepts.co/n ... ..... .72 Number One Systems . . \mi¥mmbefme.com ........ 62 PAGM .............. PCS Shop Rcbasic, Met Links ... Prco Pond Electronics, Net Links Quasar Electronics. Net links . . . Roiwt Electronics, Net links .... . ,mw,:pagm.co. uk ....................... .2 . AYAw.tfKpchsliQp.com 68 . /.Witt 3 Cb?5 C.CQ.Vk - - - 72 . Amw-{tn$aqcom .6 . a 72 . .61. 72 mmrotmi^ecifmcsco.tik .73 Spiceage and Spicycte, Net Links spite**:? ::r 73 Stewart of Reading .mwjsiettm . .... .29 Tecfinohots, Net links vw s vAecrrzbQts.CQ.it * .73 TetneL Net Links ..... — ....... .............. .73 Ultialeds f Net Links .......... .mm.ultaIeosM.uk ........ 73 USB Instruments, Net Links way* -inslrur.eois.CD - 73 Viewcom. Net Links ■ v.,/f 73 Kit Radio Company ^OfneinAKso co * 'yaaftac . rtn i ...... .63 Ubcaiter — . ; ■ 'sect .76 LPRS . . . . . .5^K/^re,co.uir ..... .75 Matrix M yfrii media Ltd : ~:ss"a ,7 Miifwd tostmmems cWnst.de ~Dn.co.n: to ADVERTISING SPACE for the : .»ue of 23 Hath ZOO 4 may he reserved not taler than 25 February 2004 with Elektor Bectranics (Pubfishtvg) Advertisefneni Office - 3 Crescent Terrace - Cfoeftennam GL5Q OPE - England - Te’epbozs 01242 510 760 - Fax 01242 226 626 -emrarf: be j ~e r i' .i::z: 3 >•■:- "acrj.uk !□ wIkhh aB correspondence, copy nstfuctians and artwork should Do addressed. 74 Elektor Electronics 2 2004 "@asy°Slada©^ Settling the new standard in sh©irt rang© radio© software solutions. Easy Radio is a simple, off-the-shelf solution to getting radio control and communication products to market - fast. Experience has shown that less than 5% of customers who have a genuine need for a wireless solution actually succeed In putting a product on the market! Why? Writing software for a "piece of wire" is one thing P doing the same with no wire present simply doesn't work. There are many, many problems to overcome the first time this exercise Is undertaken and there may be little time to acquire this new skill. In response to this problem LPRS has created a protocol which will take care of all the communications requirements of the "link" - we called it - EASY RADIO! The software takes care of Tx encoding and Rx decoding as well as RS232, TTL or whatever standard data the user wishes to input, A true data-in - data-out, result is achieved. In the case of transceivers data is buffered on chip and retries are programmed in. It is in transceiver applications that the software really comes into its o v v n a s two - wa y wireless communication is particularly difficult to achieve - reliably. The "easy-Radio" software converts inputted dais into what we refer to as an "'efficient over air format' which results in less missed data and extended range. LPRS will also customize the software to meet your specific needs , often FREE of charge! The software is available with most of our range of modules in particular our NEW ER4Q0 900 "S' 7 series of Tx, Rx and Txcvrs. These not only have the ER protocol already embedded but also offer the user unparalleled flexibility in choosing: a Power output levels n Data rate 2 and most useful - frequency selection wvvw.e a sy-Radlo.com/uk Radio transceiver takes protocols onboard for two-way stress-less wireless The ER400TRS is an extremely compact licence-exempt intelligent radio transceiver module designed to make best use of the company's innovative Easy- Radio technology. The UK designed and manufactured device houses a. complete transmitter and receiver system with all communications protocols embedded In onboard memory to allow OEMs to add wireless capabilities to their products without the need to understand radio technology. The modules are compliant with EN3Q0-220-3 and EN301 489-3 for unlicensed use in the pan-European 433- 434MHz band. All of this comes in a tiny 9-pin single-inline package which is smaller than most conventional receivers. The new transceiver will suit any wireless application that requires two-way data or where it Is essential that a receiving node Issues a "receipt'' to confirm reception of transmitted data. These include equipment such as remote date acquisition systems, handheld terminals and electronic point of sate terminals. The ER40DTRS transceiver Is supplied "reedy-to-run out-of-the-box 7 ' from LPRS. Alternatively, designers can make use of a range of user- programmable functions to customise their radio links to their own specifications using simple software commands. The data rate of the link defaults to the industry standard of 19,2KbITs, but can be programmed to any rate between 4.8 and 76.8Kbit s. A Mne-oTsite range of 260m is easily attainable. All encoding and decoding functions are also handled onboard. The transmitter power output Is also programmable up to the legal maximum ERP of lOmW, using a standard 50ohm antenna type, such as a whip, helical or PCS loop. www.lprs.co.uk/1 Easy Radi© cuts through the noise to get to market fast Developed for applications where reliable radio communication In noisy RF environments is essential the CDPTX4-4:8!-ER transmitter end CDPRX3-41B -ER receiver offer a high performance, narrow band, FM radio link and operate In the 433-4 MHz or 868- 870MHz unlicensed bands for Europe. Both pans feature embedded "Easy-Radio" software protocols eliminating the need to write complex radio software and able to accept customer's data in a number of standard forms. By providing an instant radio link no specialist RF knowledge Is required end end - system time to market Is minimised. By using narrow band transmission operating range is typically 1 Km in external applications and 150m in internal. The units operate from a supply voltage between 3-5VDC and require less than 25mA of power. Data transfer rate Is 4,800 bps and for orders over lOQpcs customised operating software can be provided, often free of charge. Typical applications would be remote control systems where speed to market is valued and where signal integrity is essential. www.lprs.co.uk/2 LPRS Limited, Two Rivers Industrial Estate, Station Lane, Witney, Oxon OX28 48H Telephone: +44 (0) 1993 709418 Fax: +44 0 1993 708575 Email: info 4easy-Radto.co.uk www.lprsxo.uk LPRS LOW POWER RADIO SOLUTIONS www. labcenter. co. uli info@labcenter, to, uk Proteus VSM - Co-simulation and debugging for popular Micro-controllers • Supports PIC, AVR, 8051, HC11 and ARM micro-controllers. • Co-simulate target firmware with your hardware design, • Includes interactive peripheral models for LED and LCD displays, switches, keypads, virtual terminal and much, much more. • Provides source level debugging for popular compilers and assemblers from Crownhill, IAR, Keil, and others. mm. The Comalete Electronics Design System \ r\ k ' b ■ mm * * 1 Li- 1 "! Schematic & PC B Layout TT? t-t jr r#T J Mr.: Powerful & flexible schematic capture. Auto-component placement and rip-up/retry PCB routing. Polygonal gridless ground planes. Libraries of over 8000 schematic and 1000 PCB parts. Bill of materials, DRC reports and much more. Mixed Mode SPICE Circuit Simulation Berkeley SPICE3F5 simulator with custom extensions for true mixed mode and interactive simulation. 6 virtual instruments and 14 graph based analysis types. 6000 models including TTL, CMOS and PLD digital parts. Fully compatible with manufacturers' SPICE models. ATK 'W m 1 in Version 6 • Drag and drop toolbars. • Visual PCB packaging tool. • Improved route editing. • Point and click DRC report. • Multiple design rules {per net) • Multiple undo/redo. Call Now for Upgrade Pricing