1.. _stm32f411e_disco_board:
2
3ST STM32F411E Discovery
4#######################
5
6Overview
7********
8
9The STM32F411E Discovery kit features an ARM Cortex-M4 based STM32F411VE MCU
10with a wide range of connectivity support and configurations.
11Here are some highlights of the STM32F411E-DISCO board:
12
13- STM32F411VET6 microcontroller featuring 512 KB of Flash memory, 128 KB of RAM in an LQFP100 package
14- On-board ST-LINK/V2 with selection mode switch to use the kit as a standalone STLINK/V2 (with SWD connector for programming and debugging)
15- Board power supply: through USB bus or from an external 5 V supply voltage
16- External application power supply: 3 V and 5 V
17- L3GD20(rev B) or I3G4250D(rev D): ST MEMS motion sensor, 3-axis digital output gyroscope.
18- LSM303DLHC(rev B) or LSM303AGR(rev D): ST MEMS system-in-package featuring a 3D digital linear acceleration sensor and a 3D digital magnetic sensor.
19- MP45DT02(rev B) or IMP34DT05(rev D), ST MEMS audio sensor, omnidirectional digital microphone
20- CS43L22, audio DAC with integrated class D speaker driver
21- Eight LEDs:
22    - LD1 (red/green) for USB communication
23    - LD2 (red) for 3.3 V power on
24    - Four user LEDs:
25        LD3 (orange), LD4 (green), LD5 (red) and LD6 (blue)
26    - Two USB OTG LEDs:
27        LD7 (green) VBus and LD8 (red) over-current
28- Two pushbuttons (user and reset)
29- USB OTG with micro-AB connector
30- Extension header for LQFP100 I/Os for a quick connection to the prototyping board and an easy probing
31
32.. image:: img/stm32f411e_disco.jpg
33     :align: center
34     :alt: STM32F411E-DISCO
35
36More information about the board can be found at the `32F411EDISCOVERY website`_.
37
38Hardware
39********
40
41STM32F411E-DISCO Discovery kit provides the following hardware components:
42
43- STM32F411VET6 in LQFP100 package
44- ARM |reg| 32-bit Cortex |reg| -M4 CPU with FPU
45- 100 MHz max CPU frequency
46- VDD from 1.7 V to 3.6 V
47- 512 KB Flash
48- 128 KB SRAM
49- GPIO with external interrupt capability
50- 1x12-bit, 2.4 MSPS ADC with 16 channels
51- DMA Controller
52- Up to 11 Timers (six 16-bit, two 32-bit, two watchdog timers and a SysTick timer)
53- USART/UART (3)
54- I2C (3)
55- SPI/I2S (5)
56- SDIO
57- USB 2.0 full-speed device/host/OTG controller with on-chip PHY
58- CRC calculation unit
59- 96-bit unique ID
60- RTC
61
62More information about STM32F411VE can be found here:
63       - `STM32F411VE website`_
64       - `STM32F411x reference manual`_
65
66Supported Features
67==================
68
69The Zephyr stm32f411e_disco board configuration supports the following
70hardware features:
71
72+-----------+------------+-------------------------------------+
73| Interface | Controller | Driver/Component                    |
74+===========+============+=====================================+
75| NVIC      | on-chip    | nested vector interrupt controller  |
76+-----------+------------+-------------------------------------+
77| UART      | on-chip    | serial port-polling;                |
78|           |            | serial port-interrupt               |
79+-----------+------------+-------------------------------------+
80| PINMUX    | on-chip    | pinmux                              |
81+-----------+------------+-------------------------------------+
82| GPIO      | on-chip    | gpio                                |
83+-----------+------------+-------------------------------------+
84| PWM       | on-chip    | pwm                                 |
85+-----------+------------+-------------------------------------+
86
87Other hardware features are not yet supported on Zephyr porting.
88
89The default configuration can be found in the defconfig file
90:zephyr_file:`boards/arm/stm32f411e_disco/stm32f411e_disco_defconfig`
91
92
93Pin Mapping
94===========
95
96STM32F411E-DISCO Discovery kit has 5 GPIO controllers. These controllers are
97responsible for pin muxing, input/output, pull-up, etc.
98
99For mode details please refer to `32F411EDISCOVERY board User Manual`_.
100
101Default Zephyr Peripheral Mapping:
102----------------------------------
103- UART_2_TX : PA2
104- UART_2_RX : PA3
105- LD3 : PD13 (PWM4 CH2)
106- LD4 : PD12 (PWM4 CH1)
107- LD5 : PD14 (PWM4 CH3)
108- LD6 : PD15 (PWM4 CH4)
109
110System Clock
111============
112
113STM32F411E-DISCO System Clock could be driven by an internal or external
114oscillator, as well as the main PLL clock. By default, the System clock is
115driven by the PLL clock at 100MHz, driven by the internal oscillator.
116
117Serial Port
118===========
119
120The STM32F411G Discovery kit has up to 3 UARTs. The Zephyr console output is
121assigned to UART2. Default settings are 115200 8N1.
122
123
124Programming and Debugging
125*************************
126
127Applications for the ``stm32f411e_disco`` board configuration can be built and
128flashed in the usual way (see :ref:`build_an_application` and
129:ref:`application_run` for more details).
130
131Flashing
132========
133
134STM32F411E-DISCO Discovery kit includes an ST-LINK/V2 embedded debug tool
135interface. This interface is supported by the openocd version included in
136Zephyr SDK.
137
138Flashing an application to STM32F411E-DISCO
139-------------------------------------------
140
141Connect the STM32F411E-DISCO Discovery kit to your host computer using the
142USB port. Then build and flash an application.
143
144Here is an example for the :zephyr:code-sample:`blinky` application.
145
146.. zephyr-app-commands::
147   :zephyr-app: samples/basic/blinky
148   :board: stm32f411e_disco
149   :goals: build flash
150
151In case you are using PCB revision B, you have to use an
152adapted board definition as the default PCB rev here is D:
153
154.. zephyr-app-commands::
155   :zephyr-app: samples/basic/blinky
156   :board: stm32f411e_disco@B
157   :goals: build flash
158
159You should see the orange led (LD3) blinking every second.
160
161Debugging
162=========
163
164You can debug applications in the usual way. Here is an example for
165the :zephyr:code-sample:`blinky` application.
166
167.. zephyr-app-commands::
168   :zephyr-app: samples/basic/blinky
169   :board: stm32f411e_disco
170   :maybe-skip-config:
171   :goals: debug
172
173References
174**********
175
176.. target-notes::
177
178.. _32F411EDISCOVERY website:
179   https://www.st.com/en/evaluation-tools/32f411ediscovery.html
180
181.. _32F411EDISCOVERY board User Manual:
182   https://www.st.com/resource/en/user_manual/dm00148985.pdf
183
184.. _STM32F411VE website:
185   https://www.st.com/en/microcontrollers/stm32f411ve.html
186
187.. _STM32F411x reference manual:
188   https://www.st.com/resource/en/reference_manual/dm00119316.pdf
189