1.. _stm32l4r9i_disco_board:
2
3ST STM32L4R9I Discovery
4#######################
5
6Overview
7********
8
9The 32L4R9IDISCOVERY Discovery kit is a complete demonstration and development platform
10for STMicroelectronics Arm® Cortex®-M4 core-based STM32L4R9AI microcontroller.
11
12Leveraging the innovative ultra-low-power oriented features, 640 Kbytes of embedded RAM,
13graphics performance (Chrom-ART Accelerator), and DSI controller offered by the STM32L4R9AI,
14the 32L4R9IDISCOVERY Discovery kit enables users to easily prototype applications with
15state-of-the-art energy efficiency, as well as stunning audio and graphics rendering with direct
16support for AMOLED DSI round LCD display.
17
18For even more user-friendliness, the on-board ST-LINK/V2-1 debugger provides out-of-the-box
19programming and debugging capabilities.
20
21.. image:: img/stm32l4r9i_disco.jpg
22    :align: center
23    :alt: STM32L4R9I-DISCO
24
25More information about the board can be found at the `STM32L4R9I-DISCOVERY website`_.
26More information about STM32L4R9 can be found here:
27
28- `STM32L4R9/S9 on www.st.com`_
29- `STM32L4+ Series reference manual`_
30- `STM32L4R5xx/R7xx/R9xx datasheet`_
31
32Supported Features
33==================
34
35The current Zephyr stm32l4r9i_disco board configuration supports the following hardware features:
36
37+-----------+------------+-------------------------------------+
38| Interface | Controller | Driver/Component                    |
39+===========+============+=====================================+
40| NVIC      | on-chip    | nested vector interrupt controller  |
41+-----------+------------+-------------------------------------+
42| UART      | on-chip    | serial port-polling                 |
43+-----------+------------+-------------------------------------+
44| PINMUX    | on-chip    | pinmux                              |
45+-----------+------------+-------------------------------------+
46| GPIO      | on-chip    | gpio                                |
47+-----------+------------+-------------------------------------+
48| FLASH     | on-chip    | on-chip flash memory;               |
49|           |            | external OctoSPI memory             |
50+-----------+------------+-------------------------------------+
51| ADC       | on-chip    | ADC Controller                      |
52+-----------+------------+-------------------------------------+
53| RTC       | on-chip    | Real Time Clock                     |
54+-----------+------------+-------------------------------------+
55| I2C       | on-chip    | i2c                                 |
56+-----------+------------+-------------------------------------+
57| SPI       | on-chip    | spi                                 |
58+-----------+------------+-------------------------------------+
59| PWM       | on-chip    | pwm                                 |
60+-----------+------------+-------------------------------------+
61| SDMMC     | on-chip    | sd/mmc                              |
62+-----------+------------+-------------------------------------+
63
64Other hardware features are not yet supported on Zephyr porting.
65
66The default configuration can be found in the defconfig file:
67
68	:zephyr_file:`boards/st/stm32l4r9i_disco/stm32l4r9i_disco_defconfig`
69
70
71Pin Mapping
72===========
73
74For more details, please refer to `STM32L4R9I-DISCOVERY website`_.
75
76System Clock
77============
78
79The STM32L4R9AI System Clock can be driven by an internal or external oscillator,
80as well as by the main PLL clock. By default, the System clock is driven by
81the PLL clock at 120MHz. PLL clock is driven by a 4MHz medium speed internal clock.
82
83Serial Port
84===========
85
86The STM32L4R9I Discovery board has up to 6 U(S)ARTs.
87The Zephyr console output is assigned to UART2, which is connected to the onboard
88ST-LINK Virtual COM port interface. Default communication settings are 115200 8N1.
89
90
91Programming and Debugging
92*************************
93
94Flashing
95========
96
97The STM32L4R9I Discovery board includes an ST-LINK/V2-1 debug tool.
98
99Applications for the ``stm32l4r9i_disco`` board configuration can be
100built and flashed in the usual way (see :ref:`build_an_application`
101and :ref:`application_run` for more details).
102
103
104Flashing an application to STM32L4R9I Discovery
105-----------------------------------------------
106
107Connect the STM32L4R9I Discovery to your host computer using the ST-LINK
108USB port, then run a serial host program to connect with the board. For example:
109
110.. code-block:: console
111
112   $ minicom -b 115200 -D /dev/ttyACM0
113
114You can then build and flash applications in the usual way.
115Here is an example for the :ref:`hello_world` application.
116
117.. zephyr-app-commands::
118   :zephyr-app: samples/hello_world
119   :board: stm32l4r9i_disco
120   :goals: build flash
121
122You should see the following message in the serial host program:
123
124.. code-block:: console
125
126   $ Hello World! stm32l4r9i_disco
127
128
129Debugging
130=========
131
132You can debug an application in the usual way.  Here is an example for the
133:ref:`hello_world` application.
134
135.. zephyr-app-commands::
136    :zephyr-app: samples/hello_world
137    :board: stm32l4r9i_disco
138    :goals: debug
139
140.. _STM32L4R9I-DISCOVERY website:
141    https://www.st.com/en/evaluation-tools/32l4r9idiscovery.html
142
143.. _STM32L4R9/S9 on www.st.com:
144    https://www.st.com/en/microcontrollers-microprocessors/stm32l4r9-s9.html
145
146.. _STM32L4+ Series reference manual:
147    https://www.st.com/resource/en/reference_manual/rm0432-stm32l4-series-advanced-armbased-32bit-mcus-stmicroelectronics.pdf
148
149.. _STM32L4R5xx/R7xx/R9xx datasheet:
150    https://www.st.com/resource/en/datasheet/stm32l4r5vi.pdf
151