|
| 1 | +.. zephyr:board:: nucleo_f072rb |
| 2 | +
|
| 3 | +Overview |
| 4 | +******** |
| 5 | +The STM32 Nucleo-64 development board with STM32F072RB MCU, supports Arduino and ST morpho connectivity. |
| 6 | + |
| 7 | +The STM32 Nucleo board provides an affordable, and flexible way for users to try out new concepts, |
| 8 | +and build prototypes with the STM32 microcontroller, choosing from the various |
| 9 | +combinations of performance, power consumption, and features. |
| 10 | + |
| 11 | +The Arduino* Uno V3 connectivity support and the ST morpho headers allow easy functionality |
| 12 | +expansion of the STM32 Nucleo open development platform with a wide choice of |
| 13 | +specialized shields. |
| 14 | + |
| 15 | +The STM32 Nucleo board integrates the ST-LINK/V2-1 debugger and programmer. |
| 16 | + |
| 17 | +The STM32 Nucleo board comes with the STM32 comprehensive software HAL library together |
| 18 | +with various packaged software examples. |
| 19 | + |
| 20 | +More information about the board can be found at the `Nucleo F072RB website`_. |
| 21 | + |
| 22 | +Hardware |
| 23 | +******** |
| 24 | +Nucleo F072RB provides the following hardware components: |
| 25 | + |
| 26 | +- STM32 microcontroller in QFP64 package |
| 27 | +- Two types of extension resources: |
| 28 | + |
| 29 | + - Arduino* Uno V3 connectivity |
| 30 | + - ST morpho extension pin headers for full access to all STM32 I/Os |
| 31 | + |
| 32 | +- On-board ST-LINK/V2-1 debugger/programmer with SWD connector: |
| 33 | + |
| 34 | + - Selection-mode switch to use the kit as a standalone ST-LINK/V2-1 |
| 35 | + |
| 36 | +- Flexible board power supply: |
| 37 | + |
| 38 | + - USB VBUS or external source (3.3V, 5V, 7 - 12V) |
| 39 | + - Power management access point |
| 40 | + |
| 41 | +- Three LEDs: |
| 42 | + |
| 43 | + - USB communication (LD1), user LED (LD2), power LED (LD3) |
| 44 | + |
| 45 | +- Two push-buttons: USER and RESET |
| 46 | +- USB re-enumeration capability. Three different interfaces supported on USB: |
| 47 | + |
| 48 | + - Virtual COM port |
| 49 | + - Mass storage |
| 50 | + - Debug port |
| 51 | + |
| 52 | +More information about STM32F072RB can be found in |
| 53 | +the `STM32F072 reference manual`_ . |
| 54 | + |
| 55 | + |
| 56 | +Supported Features |
| 57 | +================== |
| 58 | + |
| 59 | +The Zephyr ``nucleo_f072rb`` board supports the following hardware features: |
| 60 | + |
| 61 | ++-----------+------------+-------------------------------------+ |
| 62 | +| Interface | Controller | Driver/Component | |
| 63 | ++===========+============+=====================================+ |
| 64 | +| NVIC | on-chip | nested vector interrupt controller | |
| 65 | ++-----------+------------+-------------------------------------+ |
| 66 | +| UART | on-chip | serial port-polling; | |
| 67 | +| | | serial port-interrupt | |
| 68 | ++-----------+------------+-------------------------------------+ |
| 69 | +| PINMUX | on-chip | pinmux | |
| 70 | ++-----------+------------+-------------------------------------+ |
| 71 | +| GPIO | on-chip | gpio | |
| 72 | ++-----------+------------+-------------------------------------+ |
| 73 | +| CLOCK | on-chip | reset and clock control | |
| 74 | ++-----------+------------+-------------------------------------+ |
| 75 | +| FLASH | on-chip | flash memory | |
| 76 | ++-----------+------------+-------------------------------------+ |
| 77 | +| WATCHDOG | on-chip | independent watchdog | |
| 78 | ++-----------+------------+-------------------------------------+ |
| 79 | +| I2C | on-chip | i2c controller | |
| 80 | ++-----------+------------+-------------------------------------+ |
| 81 | +| SPI | on-chip | SPI controller | |
| 82 | ++-----------+------------+-------------------------------------+ |
| 83 | +| RTC | on-chip | rtc | |
| 84 | ++-----------+------------+-------------------------------------+ |
| 85 | + |
| 86 | +Other hardware features are not yet supported in this Zephyr port. |
| 87 | + |
| 88 | +The default configuration can be found in |
| 89 | +:zephyr_file:`boards/st/nucleo_f072rb/nucleo_f072rb_defconfig` |
| 90 | + |
| 91 | +Connections and IOs |
| 92 | +=================== |
| 93 | + |
| 94 | +Each of the GPIO pins can be configured by software as output (push-pull or open-drain), as |
| 95 | +input (with or without pull-up or pull-down), or as peripheral alternate function. Most of the |
| 96 | +GPIO pins are shared with digital or analog alternate functions. All GPIOs are high current |
| 97 | +capable except for analog inputs. |
| 98 | + |
| 99 | +Board connectors: |
| 100 | +----------------- |
| 101 | +.. image:: img/nucleo_f072rb_connectors.webp |
| 102 | + :align: center |
| 103 | + :alt: Nucleo F072RB connectors |
| 104 | + |
| 105 | +Default Zephyr Peripheral Mapping: |
| 106 | +---------------------------------- |
| 107 | + |
| 108 | +- UART_1 TX/RX : PA9/PA10 |
| 109 | +- UART_2 TX/RX : PA2/PA3 (ST-Link Virtual COM Port) |
| 110 | +- I2C1 SCL/SDA : PB8/PB9 (Arduino I2C) |
| 111 | +- I2C2 SCL/SDA : PB10/PB11 |
| 112 | +- SPI1 NSS/SCK/MISO/MOSI : PB6/PA5/PA6/PA7 (Arduino SPI) |
| 113 | +- SPI2 SCK/MISO/MOSI : PB13/PB14/PB15 |
| 114 | +- USER_PB : PC13 |
| 115 | +- LD1 : PA5 |
| 116 | + |
| 117 | +For more details please refer to `STM32 Nucleo-64 board User Manual`_. |
| 118 | + |
| 119 | +Programming and Debugging |
| 120 | +************************* |
| 121 | + |
| 122 | +Nucleo F072RB board includes an ST-LINK/V2-1 embedded debug tool interface. |
| 123 | + |
| 124 | +Applications for the ``nucleo_f072rb`` board configuration can be built and |
| 125 | +flashed in the usual way (see :ref:`build_an_application` and |
| 126 | +:ref:`application_run` for more details). |
| 127 | + |
| 128 | +Flashing |
| 129 | +======== |
| 130 | + |
| 131 | +The board is configured to be flashed using west `STM32CubeProgrammer`_ runner, |
| 132 | +so its :ref:`installation <stm32cubeprog-flash-host-tools>` is required. |
| 133 | + |
| 134 | +Alternatively, OpenOCD or JLink can also be used to flash the board using |
| 135 | +the ``--runner`` (or ``-r``) option: |
| 136 | + |
| 137 | +.. code-block:: console |
| 138 | +
|
| 139 | + $ west flash --runner openocd |
| 140 | + $ west flash --runner jlink |
| 141 | +
|
| 142 | +Flashing an application to Nucleo F072RB |
| 143 | +---------------------------------------- |
| 144 | + |
| 145 | +Here is an example for the :zephyr:code-sample:`blinky` application. |
| 146 | + |
| 147 | +.. zephyr-app-commands:: |
| 148 | + :zephyr-app: samples/basic/blinky |
| 149 | + :board: nucleo_f072rb |
| 150 | + :goals: build flash |
| 151 | + |
| 152 | +You will see the LED blinking every second. |
| 153 | + |
| 154 | +Debugging |
| 155 | +========= |
| 156 | + |
| 157 | +You can debug an application in the usual way. Here is an example for the |
| 158 | +:zephyr:code-sample:`hello_world` application. |
| 159 | + |
| 160 | +.. zephyr-app-commands:: |
| 161 | + :zephyr-app: samples/hello_world |
| 162 | + :board: nucleo_f072rb |
| 163 | + :maybe-skip-config: |
| 164 | + :goals: debug |
| 165 | + |
| 166 | +References |
| 167 | +********** |
| 168 | + |
| 169 | +.. target-notes:: |
| 170 | + |
| 171 | +.. _Nucleo F072RB website: |
| 172 | + https://www.st.com/en/evaluation-tools/nucleo-f072rb.html |
| 173 | + |
| 174 | +.. _STM32F072 reference manual: |
| 175 | + https://www.st.com/resource/en/reference_manual/dm00031936.pdf |
| 176 | + |
| 177 | +.. _STM32 Nucleo-64 board User Manual: |
| 178 | + https://www.st.com/resource/en/user_manual/dm00105823.pdf |
| 179 | + |
| 180 | +.. _STM32CubeProgrammer: |
| 181 | + https://www.st.com/en/development-tools/stm32cubeprog.html |
0 commit comments