LightEmittingDiodes,orLED's,arediscretecompo-nentsabletoproducelightwhenacurrentpasses

throughthem.Mostmicrocontrollerdesignsuseoneor

moreLED's.Thisapplicationhighlightstheutilityof

drivingmultipleLED'swithaminimumnumberofI/O

pins.Typically,eachI/OdrivesorsourcesasingleLED.

Todrivemorethanone,ahighI/Ocountisrequired.In

ordertoreduceI/Orequirements,LED'saremulti-plexedinamatrix(asfoundonakeyboard).Thecom-plementaryLEDdrivemethodproposestoimplement

evenmoreLEDswhileusingfewerI/O.

LEDsarepolarizedandcanonlyoperatewhencurrent

flowsfromanodetocathode(unlikeaswitch).Wecan

thereforetakeadvantageofthisfact.Table1showsthe

numberofpossibleLEDswithrespecttothenumberof

I/Opinsrequired.Fifty-sixLEDscanbedrivenusing

only8pins.TheonlydrawbackisthatonlyoneLEDcan

bedrivenatatime.

MTB029ComplementaryLEDDriveTHEORYOFOPERATIONAuthor:Jean-ClaudeRebicPioneer-StandardSomemicrocontrollersavailabletodaycansinkhighcurrent,whileothersofferalimitednumberofpinstosourcehighcurrent.MicrochipmicrocontrollershaveaINTRODUCTIONveryexiblepinstructure.Whenapinisconguredasaninput,th

驱动互补LED

驱动互补LED