Datenblatt-Suchmaschine für elektronische Bauteile |
|
HT46R003B Datenblatt(PDF) 14 Page - Holtek Semiconductor Inc |
|
HT46R003B Datenblatt(HTML) 14 Page - Holtek Semiconductor Inc |
14 / 76 page Rev. 1.00 1� ��ne 1�� �01� Rev. 1.00 15 ��ne 1�� �01� HT46R003B Cost-Effective A/D 8-bit OTP MCU HT46R003B Cost-Effective A/D 8-bit OTP MCU 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 TB LP R eg is te r Da ta 14 b it s Pr og ra m Me mo ry La st p age o r TB HP R egi st er Table Program Example Theaccompanyingexampleshowshowthetablepointerandtabledataisdefinedandretrievedfrom thedevice.Thisexampleusesrawtabledatalocatedinthelastpagewhichisstoredthereusingthe ORGstatement.ThevalueatthisORGstatementis“0300H”whichreferstothestartaddressofthe lastpagewithinthe1KProgramMemoryofthemicrocontroller. Thetablepointerissetheretohaveaninitialvalueof“06H”.Thiswillensurethatthefirstdataread fromthedatatablewillbeattheProgramMemoryaddress“0306H”or6locationsafterthestartof thelastpage.Notethatthevalueforthetablepointerisreferencedtothefirstaddressofthepresent pageifthe“TABRDC[m]”instructionisbeingused.Thehighbyteofthetabledatawhichinthis caseisequaltozerowillbetransferredtotheTBLHregisterautomaticallywhenthe“TABRDL [m]”instructionisexecuted. BecausetheTBLHregisterisaread-onlyregisterandcannotberestored,careshouldbetaken toensureitsprotectionifboththemainroutineandInterruptServiceRoutineusethetableread instructions.Ifusingthetablereadinstructions,theInterruptServiceRoutinesmaychangethe valueofTBLHandsubsequentlycauseerrorsifusedagainbythemainroutine.Asaruleitis recommendedthatsimultaneoususeofthetablereadinstructionsshouldbeavoided.However,in situationswheresimultaneoususecannotbeavoided,theinterruptsshouldbedisabledpriortothe executionofanymainroutinetable-readinstructions.Notethatalltablerelatedinstructionsrequire twoinstructioncyclestocompletetheiroperation. Table Read Program Example tempreg1 db ? ; temporary register #1 tempreg2 db ? ; temporary register #2 : mov a,06h ; initialize table pointer - note that this address ; is referenced mov tblp, a ; to the last page or present page : tabrdl tempreg1 ; transfers value in table referenced by table pointer ; to tempreg1 ; data at prog. memory address “0306H” transferred to tempreg1 ; and TBLH dec tblp ; reduce value of table pointer by one tabrdl tempreg2 ; transfers value in table referenced by table pointer ; to tempreg2 ; data at prog. memory address “0305H” transferred to ; tempreg2 and TBLH ; in this example the data “1AH” is transferred to tempreg1 and ; data “0FH” to register tempreg2 ; the value “00H” will be transferred to the high byte ; register TBLH : org 0300h ; sets initial address of last page dc 00Ah, 00Bh, 00Ch, 00Dh, 00Eh, 00Fh, 01Ah, 01Bh : |
Ähnliche Teilenummer - HT46R003B |
|
Ähnliche Beschreibung - HT46R003B |
|
|
Link URL |
Privatsphäre und Datenschutz |
ALLDATASHEETDE.COM |
War ALLDATASHEET hilfreich? [ DONATE ] |
Über Alldatasheet | Werbung | Kontakt | Privatsphäre und Datenschutz | Linktausch | Hersteller 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 |