boards/st/nucleo_l412rb_p/doc/index.rst
.. zephyr:board:: nucleo_l412rb_p
Overview
The Nucleo L412RB board features an ARM Cortex-M4 based STM32L412RB MCU with a wide range of connectivity support and configurations. Here are some highlights of the Nucleo L412RB board:
STM32 microcontroller in LQFP64 package
1 user LED shared with ARDUINO®
1 user and 1 reset push-buttons
32.768 kHz crystal oscillator
Two types of extension resources:
On-board ST-LINK debugger/programmer with USB re-enumeration capability: mass storage, Virtual COM port and debug port
Flexible power-supply options: ST-LINK, USB VBUS, or external sources
Board specific features
External SMPS to generate Vcore logic supply
24 MHz HSE
Board connectors:
Arm® Mbed Enabled™ compliant
More information about the board can be found at the Nucleo L412RB-P website_.
Hardware
Nucleo L412RB-P provides the following hardware components:
STM32L412RBT6 in LQFP64 package
Ultra-low-power with FlexPowerControl
Core: Arm® 32-bit Cortex®-M4 CPU with FPU, Adaptive real-time accelerator (ART Accelerator™ ) allowing 0-wait-state execution from Flash memory, frequency up to 80 MHz, MPU, 100DMIPS and DSP instructions
Performance benchmark
Energy benchmark
Clock Sources:
Up to 52 fast I/Os, most 5 V-tolerant
RTC with HW calendar, alarms and calibration
Up to 12 capacitive sensing channels: support touchkey, linear and rotary touch sensors
10x timers:
Memories
Rich analog peripherals (independent supply)
12x communication interfaces
14-channel DMA controller
True random number generator
CRC calculation unit, 96-bit unique ID
Development support: serial wire debug (SWD), JTAG, Embedded Trace Macrocell™
All packages are ECOPACK2 compliant
Note: the current board revision is C. (MB1319C)
More information about STM32L412RB can be found here:
STM32L412RB on www.st.com_STM32L412 reference manual_.. zephyr:board-supported-hw::
Nucleo L412RB-P Board has 5 GPIO controllers (Ports A, B, C, D and H). These controllers are responsible for pin muxing, input/output, pull-up, etc.
.. image:: img/nucleo_l412rb_p_pinout.jpg :align: center :alt: Nucleo L412RB-P
For more details please refer to ST Nucleo L412RB-P User Manual_.
Note: SPI2 CS pin (PB12) is not located on the Arduino connector.
Nucleo L412RB-P System Clock could be driven by internal or external oscillator, as well as main PLL clock. By default System clock is driven by PLL clock at 80MHz, driven by 16MHz high speed internal oscillator.
Nucleo L412RB-P board has 3 U(S)ARTs and 1 LPUART. The Zephyr console output is assigned to LPUART1. Default settings are 115200 8N1.
Programming and Debugging
.. zephyr:board-supported-runners::
Nucleo L412RB-P board includes an ST-LINK/V2-1 embedded debug tool interface.
Applications for the nucleo_l412rb_p board configuration can be built and
flashed in the usual way (see :ref:build_an_application and
:ref:application_run for more details).
The board is configured to be flashed using west STM32CubeProgrammer_ runner,
so its :ref:installation <stm32cubeprog-flash-host-tools> is required.
Alternatively, OpenOCD or JLink can also be used to flash the board using
the --runner (or -r) option:
.. code-block:: console
$ west flash --runner openocd $ west flash --runner jlink
Connect the Nucleo L412RB-P to your host computer using the USB port, then run a serial host program to connect with your Nucleo board.
.. code-block:: console
$ minicom -D /dev/ttyACM0
Now build and flash an application. Here is an example for
:zephyr:code-sample:hello_world.
.. zephyr-app-commands:: :zephyr-app: samples/hello_world :board: nucleo_l412rb_p :goals: build flash
You should see the following message on the console:
.. code-block:: console
$ Hello World! nucleo_l412rb_p
You can debug an application in the usual way. Here is an example for the
:zephyr:code-sample:hello_world application.
.. zephyr-app-commands:: :zephyr-app: samples/hello_world :board: nucleo_l412rb_p :maybe-skip-config: :goals: debug
.. _Nucleo L412RB-P website: https://www.st.com/en/evaluation-tools/nucleo-l412rb-p.html
.. _ST Nucleo L412RB-P User Manual: https://www.st.com/resource/en/user_manual/dm00387966-stm32-nucleo-64-p-boards-stmicroelectronics.pdf
.. _STM32L412RB on www.st.com: https://www.st.com/en/microcontrollers-microprocessors/stm32l412rb.html
.. _STM32L412 reference manual: https://www.st.com/resource/en/reference_manual/dm00151940-stm32l41xxx42xxx43xxx44xxx45xxx46xxx-advanced-armbased-32bit-mcus-stmicroelectronics.pdf
.. _STM32CubeProgrammer: https://www.st.com/en/development-tools/stm32cubeprog.html