STM32F031x4 STM32F031x6 ARM -based 32-bit MCU with up to 32 Kbyte Flash, 9 timers, ADC and communication interfaces, 2.0 - 3.6 V Datasheet - production data Features Core: ARM 32-bit Cortex -M0 CPU, frequency up to 48 MHz LQFP32 7x7 mm UFQFPN32 5x5 mm WLCSP25 TSSOP20 Memories LQFP48 7x7 mm UFQFPN28 4x4 mm 2.1x2.1 mm 6.5x4.4 mm 16 to 32 Kbytes of Flash memory 1 x 16-bit timer, with IC/OC and OCN, 4 Kbytes of SRAM with HW parity deadtime generation, emergency stop and modulator gate for IR control CRC calculation unit 1 x 16-bit timer with 1 IC/OC Reset and power management Independent and system watchdog timers Digital and I/Os supply: 2.0 to 3.6 V SysTick timer: 24-bit downcounter Analog supply: V = from V to 3.6 V DDA DD Calendar RTC with alarm and periodic wakeup Power-on/Power-down reset (POR/PDR) from Stop/Standby Programmable voltage detector (PVD) Low power modes: Sleep, Stop and Communication interfaces 2 Standby 1 x I C interface, supporting Fast Mode Plus (1 Mbit/s) with 20 mA current sink, V supply for RTC and backup registers BAT SMBus/PMBus, and wakeup from Stop Clock management mode 4 to 32 MHz crystal oscillator 1 x USART supporting master synchronous 32 kHz oscillator for RTC with calibration SPI and modem control, ISO7816 Internal 8 MHz RC with x6 PLL option interface, LIN, IrDA capability, auto baud Internal 40 kHz RC oscillator rate detection and wakeup feature Up to 39 fast I/Os 1 x SPI (18 Mbit/s) with 4 to 16 2 programmable bit frames, with I S interface All mappable on external interrupt vectors multiplexed Up to 26 I/Os with 5 V tolerant capability Serial wire debug (SWD) 5-channel DMA controller 96-bit unique ID 1 12-bit, 1.0 s ADC (up to 10 channels) Extended temperature range: -40 to +105C Conversion range: 0 to 3.6V All packages ECOPACK 2 Separate analog supply from 2.4 up to 3.6 V Table 1. Device summary Up to 9 timers Reference Part number 1 x 16-bit 7-channel advanced-control timer for 6 channels PWM output, with deadtime STM32F031C6, STM32F031E6, generation and emergency stop STM32F031x6 STM32F031F6, STM32F031G6, 1 x 32-bit and 1 x 16-bit timer, with up to 4 STM32F031K6 IC/OC, usable for IR control decoding STM32F031C4, STM32F031F4, STM32F031x4 1 x 16-bit timer, with 2 IC/OC, 1 OCN, STM32F031G4, STM32F031K4 deadtime generation and emergency stop May 2017 DocID025743 Rev 6 1/106 This is information on a product in full production. www.st.comContents STM32F031x4 STM32F031x6 Contents 1 Introduction 8 2 Description . 9 3 Functional overview 11 3.1 ARM -Cortex -M0 core .11 3.2 Memories 11 3.3 Boot modes 11 3.4 Cyclic redundancy check calculation unit (CRC) . 12 3.5 Power management . 12 3.5.1 Power supply schemes . 12 3.5.2 Power supply supervisors . 12 3.5.3 Voltage regulator 12 3.5.4 Low-power modes . 13 3.6 Clocks and startup 13 3.7 General-purpose inputs/outputs (GPIOs) . 14 3.8 Direct memory access controller (DMA) 15 3.9 Interrupts and events 15 3.9.1 Nested vectored interrupt controller (NVIC) 15 3.9.2 Extended interrupt/event controller (EXTI) 15 3.10 Analog-to-digital converter (ADC) 15 3.10.1 Temperature sensor 16 3.10.2 Internal voltage reference (V ) . 16 REFINT 3.10.3 V battery voltage monitoring . 16 BAT 3.11 Timers and watchdogs . 17 3.11.1 Advanced-control timer (TIM1) . 17 3.11.2 General-purpose timers (TIM2, 3, 14, 16, 17) 17 3.11.3 Independent watchdog (IWDG) . 18 3.11.4 System window watchdog (WWDG) . 18 3.11.5 SysTick timer . 19 3.12 Real-time clock (RTC) and backup registers 19 2 3.13 Inter-integrated circuit interface (I C) 19 3.14 Universal synchronous/asynchronous receiver/transmitter (USART) . 20 2/106 DocID025743 Rev 6