Rev. 2.50 244 June 22, 2017 Rev. 2.50 245 June 22, 2017
HT66F20/HT66F30/HT66F40/HT66F50/HT66F60
HT66FU30/HT66FU40/HT66FU50/HT66FU60
A/D Flash MCU with EEPROM
HT66F20/HT66F30/HT66F40/HT66F50/HT66F60
HT66FU30/HT66FU40/HT66FU50/HT66FU60
A/D Flash MCU with EEPROM
UCR1 register
TheUCR1registertogetherwiththeUCR2registerarethetwoUARTcontrolregistersthatareused
tosetthevariousoptionsfortheUARTfunctionsuchasoverallon/offcontrol,paritycontrol,data
transferbitlength,etc.Furtherexplanationoneachofthebitsisgivenbelow:
Bit 7 6 5 4 3 2 1 0
Name UARTEN BNO PREN PRT STOPS TXBRK RX8 TX8
R/W R/W R/W R/W R/W R/W R/W R W
POR 0 0 0 0 0 0 × 0
“×
” unknown
Bit7 UARTEN:UARTfunctionenablecontrol
0:DisableUART.TXandRXpinsareinthestateofhighimpedance
1:EnableUART.TXandRXpinsfunctionasUARTpins
TheUARTENbitistheUARTenablebit.Whenthisbitisequalto0,theUART
willbedisabledandtheRXpinaswellastheTXpinwillbeinthestateofhigh
impedance.Whenthebitisequalto1,theUARTwillbeenabledandtheTXandRX
pinswillfunctionasdenedbytheTXENandRXENenablecontrolbits.Whenthe
UARTisdisabled,itwillemptythebuffersoanycharacterremaininginthebufferwill
bediscarded.Inaddition,thevalueofthebaudratecounterwillbereset.IftheUART
isdisabled,allerrorandstatusagswillbereset.AlsotheTXEN,RXEN,TXBRK,
RXIF,OERR,FERR,PERRandNFbitswillbecleared,whiletheTIDLE,TXIFand
RIDLEbitswillbeset.OthercontrolbitsinUCR1,UCR2andBRGregisterswill
remainunaffected.IftheUARTisactiveandtheUARTENbitiscleared,allpending
transmissionsandreceptionswillbeterminatedandthemodulewillberesetasdened
above.WhentheUARTisre-enabled,itwillrestartinthesameconguration.
Bit6 BNO:Numberofdatatransferbitsselection
0:8-bitdatatransfer
1:9-bitdatatransfer
Thisbitisusedtoselectthedatalengthformat,whichcanhaveachoiceofeither8-bit
or9-bitformat.Whenthisbitisequalto1,a9-bitdatalengthformatwillbeselected.
Ifthebitisequalto0,thenan8-bitdatalengthformatwillbeselected.If9-bitdata
lengthformatisselected,thenbitsRX8andTX8willbeusedtostorethe9thbitofthe
receivedandtransmitteddatarespectively.
Bit5 PREN:Parityfunctionenablecontrol
0:Parityfunctionisdisabled
1:Parityfunctionisenabled
Thisistheparityenablebit.Whenthisbitisequalto1,theparityfunctionwillbe
enabled.Ifthebitisequalto0,thentheparityfunctionwillbedisabled.
Bit4 PRT:Paritytypeselectionbit
0:Evenparityforparitygenerator
1:Oddparityforparitygenerator
Thisbitistheparitytypeselectionbit.Whenthisbitisequalto1,oddparitytypewill
beselected.Ifthebitisequalto0,thenevenparitytypewillbeselected.
Bit3 STOPS:NumberofStopbitsselection
0:Onestopbitformatisused
1:Twostopbitsformatisused
Thisbitdeterminesifoneortwostopbitsaretobeused.Whenthisbitisequalto1,
twostopbitsareused.Ifthisbitisequalto0,thenonlyonestopbitisused.