Rev. 2.50 256 June 22, 2017 Rev. 2.50 257 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
Using the UART Function
TousetheUARTfunction,severalimportantstepsmustbeimplementedtoensurethattheUART
moduleoperatesnormally:
• TheSPIpin-remappingfunctionmustbeproperlyconguredwhentheSPIfunctionalpinsof
themicrocontrollerareusedtocontroltheUARTmoduleandfordatatransmissionanddata
reception.TocorrectlyconnecttheMCUMasterSPItotheUARTModuleSlaveSPI,theSIM
pin-remappingsettingsforPCKandPINTintheMCUPRM0registershouldbethesameasthe
valueslistedinthefollowingtable.
♦
HT66FU30
– PRM0Register–PCKandPINTpin-remapsetup
Bit 1 0
Name SIMPS0 PCKPS
Setting value 1 1
♦
HT66FU40/HT66FU50
– PRM0Register–PCKandPINTpin-remapsetup
Bit 2 1 0
Name
SIMPS1 SIMPS0 PCKPS
Setting value 0 1 1
♦
HT66FU60
– PRM0Register–PCKandPINTpin-remapsetup
Bit 2 1 0
Name
SIMPS1 SIMPS0 PCKPS
Setting value 1 1 1
• TheSIMoperatingmodecontrolbitsSIM2~SIM0,intheSIMC0registerhavetobecongured
toenabletheSIMtooperateintheSPImastermodewithadifferentSPIclockfrequency.
♦
SIMoperatingmodecontrolbitsSIM2~SIM0intheSIMC0Register
Bit 2 1 0
Name SIM2
SIM1 SIM0
value 100,011,010,001,000
000:SPImastermode;SPIclockisf
SYS
/4
001:SPImastermode;SPIclockisf
SYS
/16
010:SPImastermode;SPIclockisf
SYS
/64
011:SPImastermode;SPIclockisf
TBC
100:SPImastermode;SPIclockisTM0CCRPmatchfrequency/2
101~111:mustnotbeused