User`s guide
Rev. 1.10 126 November 14, 2014 Rev. 1.10 127 November 14, 2014
HT66FW2230
Wireless Charger A/D Flash 8-Bit MCU
TM Interrupts
TheStandardTypeTMandCompactTypeTMhavetwointerruptseach.AlloftheTMinterrupts
arecontainedwithintheMulti-functionInterrupts.ForeachoftheStandardandCompactTypeTM
therearetwointerruptrequestagsTnPFandTnAFandtwoenablebitsTnPEandTnAE.ATM
interruptrequestwilltakeplacewhenanyoftheTMrequestagsareset,asituationwhichoccurs
whenaTMcomparatorPorcomparatorAmatchsituationhappens.
Toallowtheprogramtobranchtoitsrespectiveinterruptvectoraddress,theglobalinterruptenable
bit,EMI,andtherespectiveTMInterruptenablebit,andassociatedMulti-functioninterruptenable
bit,MFnF(MF0ForMF1F),mustrstbeset.Whentheinterruptisenabled,thestackisnotfull
andaTMcomparatormatchsituationoccurs,asubroutinecalltotherelevantTMInterruptvector
locations,willtakeplace.WhentheTMinterruptisserviced,theEMIbitwillbeautomatically
clearedtodisableotherinterrupts,howeveronlytherelatedMFnFag(MF0ForMF1F)willbe
automaticallycleared.AstheTMinterruptrequestagswillnotbeautomaticallycleared,theyhave
tobeclearedbytheapplicationprogram.
I
2
C Interrupt
An I
2
CInterruptrequestwilltakeplacewhentheI
2
CInterruptrequestflag,IICF,isset,which
occurswhenabyteofdatahasbeenreceivedortransmittedbytheI
2
Cinterface.Toallowthe
programtobranchtoitsrespectiveinterruptvectoraddress,theglobalinterruptenablebit,EMI,and
theSerialInterfaceInterruptenablebit,IICE,mustrstbeset.Whentheinterruptisenabled,the
stackisnotfullandabyteofdatahasbeentransmittedorreceivedbytheI
2
Cinterface,asubroutine
calltotherespectiveInterruptvector,willtakeplace.WhentheI
2
CInterfaceInterruptisserviced,
theinterruptrequestag,IICF,willbeautomaticallyresetandtheEMIbitwillbeclearedtodisable
otherinterrupts.
Interrupt Wake-up Function
Eachoftheinterruptfunctionshasthecapabilityofwakingupthemicrocontrollerwheninthe
SLEEPorIDLEMode.Awake-upisgeneratedwhenaninterruptrequestagchangesfromlowto
highandisindependentofwhethertheinterruptisenabledornot.Therefore,eventhoughthedevice
isintheSLEEPorIDLEModeanditssystemoscillatorstopped,situationssuchasexternaledge
transitionsontheexternalinterruptpins,alowpowersupplyvoltagemaycausetheirrespective
interruptagtobesethighandconsequentlygenerateaninterrupt.Caremustthereforebetakenif
spuriouswake-upsituationsaretobeavoided.Ifaninterruptwake-upfunctionistobedisabledthen
thecorrespondinginterruptrequestagshouldbesethighbeforethedeviceenterstheSLEEPor
IDLEMode.Theinterruptenablebitshavenoeffectontheinterruptwake-upfunction.