Startup clock:Afterreset,themicrocontrollerrestartsbydefaultwithaninternal2MHzclock(HSI/8).Theprescalerratioandclocksourcecanbechangedbytheapplicationprogramassoonasthecodeexecutionstarts. •Clock securitysystem(CSS):Thisfeaturecanbeenabledbysoftware.IfanHSEclockfailureoccurs,theinternalRC(16MHz/8)isautomaticallyselectedbytheCSSandaninterruptcanoptionallybegenerated. •Configurable mainclockoutput(CCO):Thisoutputsanexternalclockforusebytheapplication.Table2:PeripheralclockgatingbitassignmentsinCLK_PCKENR1/2 registers PeripheralclockBitPeripheralclockBitPeripheralclockBitPeripheralclockBitADCPCKEN23ReservedPCKEN27UART1PCKEN13TIM1PCKEN17AWUPCKEN22ReservedPCKEN26ReservedPCKEN12ReservedPCKEN16ReservedPCKEN21ReservedPCKEN25SPIPCKEN11TIM2PCKEN15Reserved PCKEN20 Reserved PCKEN24 I2 C PCKEN10 TIM4 PCKEN14 Powermanagement 4.6Forefficentpowermanagement,theapplicationcanbeputinoneoffourdifferentlow-powermodes.Youcanconfigureeachmodetoobtainthebestcompromisebetweenlowestpowerconsumption,fasteststart-uptimeandavailablewakeupsources. • Waitmode:Inthismode,theCPUisstopped,butperipheralsarekeptrunning.Thewakeupisperformedbyaninternalorexternalinterruptorreset. •Active haltmodewithregulatoron:Inthismode,theCPUandperipheralclocksarestopped.Aninternalwakeupisgeneratedatprogrammableintervalsbytheautowakeup unit(AWU).Themainvoltageregulatoriskeptpoweredon,socurrentconsumptionishigherthaninactivehaltmodewithregulatoroff,butthewakeuptimeisfaster.WakeupistriggeredbytheinternalAWUinterrupt,externalinterruptorreset. •Active haltmodewithregulatoroff:Thismodeisthesameasactivehaltwithregulatoron,exceptthatthemainvoltageregulatorispoweredoff,sothewakeuptimeisslower. •Halt mode:Inthismodethemicrocontrollerusestheleastpower.TheCPUandperipheralclocksarestopped,themainvoltageregulatorispoweredoff.Wakeupistriggeredbyexternaleventorreset. Watchdogtimers 4.7Thewatchdogsystemisbasedontwoindependenttimersprovidingmaximumsecuritytotheapplications. Activationofthewatchdogtimersiscontrolledbyoptionbytesorbysoftware.Onceactivated,thewatchdogscannotbedisabledbytheuserprogramwithoutperforminga reset. |