| Electronic Components Datasheet Search |
|
HT45F3520 Datasheet(PDF) 22 Page - Holtek Semiconductor Inc |
|
|
|||||||||||||||||||||||||||||
HT45F3520 Datasheet(HTML) 22 Page - Holtek Semiconductor Inc |
|
22 / 134 page ![]() Rev. 1.10 �� De�e��e� 1�� �01� Rev. 1.10 �� De�e��e� 1�� �01� HT45F3520/HT45F3530 Personal Care Flash MCU HT45F3520/HT45F3530 Personal Care Flash MCU Special Vectors WithintheProgramMemory,certainlocationsarereservedfortheresetandinterrupts.Thelocation 000Hisreservedforusebythedeviceresetforprograminitialisation.Afteradeviceresetis initiated,theprogramwilljumptothislocationandbeginexecution. Look-up Table AnylocationwithintheProgramMemorycanbedefinedasalook-uptablewhereprogrammerscan storefixeddata.Tousethelook-uptable,thetablepointermustfirstbesetupbyplacingtheaddress ofthelookupdatatoberetrievedinthetablepointerregister,TBLP.Thisregisterdefinesthetotal addressofthelook-uptable. Aftersettingupthetablepointer,thetabledatacanberetrievedfromtheProgramMemoryusing the"TABRDC[m]"or"TABRDL[m]"instructions,respectively.Whentheinstructionisexecuted, thelowerordertablebytefromtheProgramMemorywillbetransferredtotheuserdefined DataMemoryregister[m]asspecifiedintheinstruction.Thehigherordertabledatabytefrom theProgramMemorywillbetransferredtotheTBLHspecialregister.Anyunusedbitsinthis transferredhigherorderbytewillbereadas"0". Theaccompanyingdiagramillustratestheaddressingdataflowofthelook-uptable. Re gi st er T BL H Us er S el ec te d Re gi st er Hi gh B yt eL ow B yt e PC H ig h By te TB LP R eg is te r Da ta 14 /1 5 bi ts Pr og ra m Me mo ry La st p age o r p re se nt p ag e (P C9 /P C1 0~ PC 8) Table Program Example Thefollowingexampleshowshowthetablepointerandtabledataisdefinedandretrievedfromthe microcontroller.ThisexampleusesrawtabledatalocatedintheProgramMemorywhichisstored thereusingtheORGstatement.ThevalueatthisORGstatementis"300H"whichreferstothestart addressofthelastpagewithinthe1KwordsProgramMemoryoftheHT45F3520.Thetablepointer issetupheretohaveaninitialvalueof"06H".Thiswillensurethatthefirstdatareadfromthedata tablewillbeattheProgramMemoryaddress"306H"or6locationsafterthestartofthelastpage. Notethatthevalueforthetablepointerisreferencedtothefirstaddressofthepresentpageifthe "TABRDC[m]"instructionisbeingused.Thehighbyteofthetabledatawhichinthiscaseisequal tozerowillbetransferredtotheTBLHregisterautomaticallywhenthe"TABRDC[m]"instruction isexecuted. BecausetheTBLHregisterisaread-onlyregisterandcannotberestored,careshouldbetaken toensureitsprotectionifboththemainroutineandInterruptServiceRoutineusetableread instructions.Ifusingthetablereadinstructions,theInterruptServiceRoutinesmaychangethe valueoftheTBLHandsubsequentlycauseerrorsifusedagainbythemainroutine.Asaruleitis recommendedthatsimultaneoususeofthetablereadinstructionsshouldbeavoided.However,in situationswheresimultaneoususecannotbeavoided,theinterruptsshouldbedisabledpriortothe executionofanymainroutinetable-readinstructions.Notethatalltablerelatedinstructionsrequire twoinstructioncyclestocompletetheiroperation. |
|
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 |