Rev. 1.71 128 April 11, 2017 Rev. 1.71 129 April 11, 2017
HT66F002/HT66F0025/HT66F003/HT66F004
Cost-Effective A/D Flash MCU with EEPROM
HT66F002/HT66F0025/HT66F003/HT66F004
Cost-Effective A/D Flash MCU with EEPROM
CPLA [m]
ComplementDataMemorywithresultinACC
Description EachbitofthespeciedDataMemoryislogicallycomplemented(1′scomplement).Bitswhich
previouslycontaineda1arechangedto0andviceversa.Thecomplementedresultisstoredin
theAccumulatorandthecontentsoftheDataMemoryremainunchanged.
Operation ACC←[m]
Affectedag(s) Z
DAA [m]
Decimal-AdjustACCforadditionwithresultinDataMemory
Description ConvertthecontentsoftheAccumulatorvaluetoaBCD(BinaryCodedDecimal)value
resultingfromthepreviousadditionoftwoBCDvariables.Ifthelownibbleisgreaterthan9
orifACagisset,thenavalueof6willbeaddedtothelownibble.Otherwisethelownibble
remainsunchanged.Ifthehighnibbleisgreaterthan9oriftheCagisset,thenavalueof6
willbeaddedtothehighnibble.Essentially,thedecimalconversionisperformedbyadding
00H,06H,60Hor66HdependingontheAccumulatorandagconditions.OnlytheCag
maybeaffectedbythisinstructionwhichindicatesthatiftheoriginalBCDsumisgreaterthan
100,itallowsmultipleprecisiondecimaladdition.
Operation [m]←ACC+00Hor
[m]←ACC+06Hor
[m]←ACC+60Hor
[m]←ACC+66H
Affectedag(s) C
DEC [m]
DecrementDataMemory
Description DatainthespeciedDataMemoryisdecrementedby1.
Operation [m]←[m]−1
Affectedag(s) Z
DECA[m] DecrementDataMemorywithresultinACC
Description DatainthespeciedDataMemoryisdecrementedby1.Theresultisstoredinthe
Accumulator.ThecontentsoftheDataMemoryremainunchanged.
Operation ACC←[m]−1
Affectedag(s) Z
HALT
Enterpowerdownmode
Description Thisinstructionstopstheprogramexecutionandturnsoffthesystemclock.Thecontentsof
theDataMemoryandregistersareretained.TheWDTandprescalerarecleared.Thepower
downagPDFissetandtheWDTtime-outagTOiscleared.
Operation TO←0
PDF←1
Affectedag(s) TO,PDF
INC [m]
IncrementDataMemory
Description DatainthespeciedDataMemoryisincrementedby1.
Operation [m]←[m]+1
Affectedag(s) Z
INCA [m]
IncrementDataMemorywithresultinACC
Description DatainthespeciedDataMemoryisincrementedby1.TheresultisstoredintheAccumulator.
ThecontentsoftheDataMemoryremainunchanged.
Operation ACC←[m]+1
Affectedag(s) Z