Rev. 2.50 200 June 22, 2017 Rev. 2.50 201 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
Peripheral Clock Output
ThePeripheralClockOutputallowsthedevicetosupplyexternalhardwarewithaclocksignal
synchronisedtothemicrocontrollerclock.
Peripheral Clock Operation
Astheperipheralclockoutputpin,PCK,issharedwithI/Oline,therequiredpinfunctionischosen
viaPCKENintheSIMC0register.ThePeripheralClockfunctioniscontrolledusingtheSIMC0
register.TheclocksourceforthePeripheralClockOutputcanoriginatefromeithertheTM0CCRP
matchfrequency/2oradividedratiooftheinternalf
SYS
clock.ThePCKENbitintheSIMC0register
istheoverallon/offcontrol,settingPCKENbitto"1"enablesthePeripheralClock,settingPCKEN
bitto"0"disablesit.TherequireddivisionratioofthesystemclockisselectedusingthePCKP1
andPCKP0bitsinthesameregister.IfthedeviceenterstheSLEEPModethiswilldisablethe
PeripheralClockoutput.
SIMC0 Register
Bit 7 6 5 4 3 2 1 0
Name SIM2
SIM1 SIM0 PCKEN PCKP1 PCKP0 SIMEN —
R/W R/W R/W R/W R/W R/W R/W R/W —
POR
1 1 1 0 0 0 0 —
Bit7~5 SIM2, SIM1, SIM0:SIMoperatingmodecontrol
000:SPImastermode;SPIclockisf
SYS
/4
001:SPImastermode;SPIclockisf
SYS
/16
010:SPImastermode;SPIclockisf
SYS
/64
011:SPImastermode;SPIclockisf
TBC
100:SPImastermode;SPIclockisTM0CCRPmatchfrequency/2
101:SPIslavemode
110:I
2
Cslavemode
111:Unusedmode
ThesebitssetuptheoveralloperatingmodeoftheSIMfunction.Aswellasselecting
iftheI
2
CorSPIfunction,theyareusedtocontroltheSPIMaster/Slaveselectionand
theSPIMasterclockfrequency.TheSPIclockisafunctionofthesystemclockbut
canalsobechosentobesourcedfromtheTM0.IftheSPISlaveModeisselectedthen
theclockwillbesuppliedbyanexternalMasterdevice.
Bit4 PCKEN:PCKoutputpincontrol
0:Disable
1:Enable
Bit3~2 PCKP1, PCKP0:selectPCKoutputpinfrequency
00:f
SYS
01:f
SYS
/4
10:f
SYS
/8
11:TM0CCRPmatchfrequency/2
Bit1 SIMEN:SIMcontrol
0:Disable
1:Enable
Thebitistheoverallon/offcontrolfortheSIMinterface.WhentheSIMENbitis
clearedtozerotodisabletheSIMinterface,theSDI,SDO,SCKandSCS,orSDA
andSCLlineswillbeinaoatingconditionandtheSIMoperatingcurrentwillbe
reducedtoaminimumvalue.WhenthebitishightheSIMinterfaceisenabled.The
SIMcongurationoptionmusthaverstenabledtheSIMinterfaceforthisbittobe
effective.NotethatwhentheSIMENbitchangesfromlowtohighthecontentsofthe
SPIcontrolregisterswillbeinanunknownconditionandshouldthereforebefirst
initialisedbytheapplicationprogram.
Bit0 Unimplemented,readas“0”