| Electronic Components Datasheet Search |
|
HT45F12 Datasheet(PDF) 59 Page - Holtek Semiconductor Inc |
|
|
|||||||||||||||||||||||||||||
HT45F12 Datasheet(HTML) 59 Page - Holtek Semiconductor Inc |
|
59 / 104 page ![]() Rev. 0.00 58 �e�te��e� ��� �01� Rev. 0.00 59 �e�te��e� ��� �01� HT45F12 8-Bit Flash MCU with Op Amps & Comparators HT45F12 8-Bit Flash MCU with Op Amps & Comparators Ex te rm al E ve nt o r In te r nal E v ent In cr em en t Ti me r C ont ro ll er Ti me r+ 1T im er +2 Ti me r+ 3 Event Counter Mode Timing Chart (TE= 1) Pulse Width Capture Mode Inthismode,theTimer/EventCountercanbeutilisedtomeasurethewidthofexternalpulses appliedtotheexternaltimerpin.Tooperateinthismode,theOperatingModeSelectbitpair,TM1/ TM0,intheTimerControlRegistermustbesettothecorrectvalueasshown. Bit7 Bit6 1 1 ControlRegisterOperatingModeSelectBitsforthePulseWidthMeasurementMode Inthismodetheinternalclock,fSYSisusedastheinternalclockforthe8-bitTimer/EventCounter. However,theclocksourceisfurtherdividedbyaprescaler,thevalueofwhichisdeterminedby thePrescalerRateSelectbitsTPSC2~TPSC0,whicharebits2~0oftheTimerControlRegister. AfterotherbitsintheTimerControlRegisterhavebeensetup,theenablebitTON,whichisbit4of theTimerControlRegister,canbesethightoenabletheTimer/EventCounter,howeveritwillnot actuallystartcountinguntilanactiveedgeisreceivedontheexternaltimerpin. IftheActiveEdgeSelectbitTE,whichisbit3oftheTimerControlRegister,islow,onceahightolow transitionhasbeenreceivedontheexternaltimerpin,theTimer/EventCounterwillstartcountinguntil theexternaltimerpinreturnstoitsoriginalhighlevel.Atthispointtheenablebitwillbeautomatically resettozeroandtheTimer/EventCounterwillstopcounting.IftheActiveEdgeSelectbitishigh,the Timer/EventCounterwillbegincountingoncealowtohightransitionhasbeenreceivedontheexternal timerpinandstopcountingwhentheexternaltimerpinreturnstoitsoriginallowlevel.Asbefore, theenablebitwillbeautomaticallyresettozeroandtheTimer/EventCounterwillstopcounting.It isimportanttonotethatinthepulsewidthcaptureMode,theenablebitisautomaticallyresettozero whentheexternalcontrolsignalontheexternaltimerpinreturnstoitsoriginallevel,whereasinthe othertwomodestheenablebitcanonlyberesettozerounderprogramcontrol. TheresidualvalueintheTimer/EventCounter,whichcannowbereadbytheprogram,therefore representsthelengthofthepulsereceivedontheTMRpin.Astheenablebithasnowbeenreset, anyfurthertransitionsontheexternaltimerpinwillbeignored.Thetimercannotbeginfurtherpulse widthcaptureuntiltheenablebitissethighagainbytheprogram.Inthisway,singleshotpulse measurementscanbeeasilymade. ItshouldbenotedthatinthismodetheTimer/EventCounteriscontrolledbylogicaltransitionson theexternaltimerpinandnotbythelogiclevel.WhentheTimer/EventCounterisfullandoverflows, aninterruptsignalisgeneratedandtheTimer/EventCounterwillreloadthevaluealreadyloadedinto thepreloadregisterandcontinuecounting.TheinterruptcanbedisabledbyensuringthattheTimer/ EventCounterInterruptEnablebitinthecorrespondingInterruptControlRegisterisresettozero. AstheexternalpinissharedwithanI/Opin,toensurethatthepinisconfiguredtooperateasapulse widthcapturepin,twothingshavetohappen.ThefirstistoensurethattheOperatingModeSelect bitsintheTimerControlRegisterplacetheTimer/EventCounterinthepulsewidthcapturemode, thesecondistoensurethattheportcontrolregisterconfiguresthepinasaninput. |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |