1.. _stm32g081b_eval_board: 2 3ST STM32G081B Evaluation 4######################## 5 6Overview 7******** 8The STM32G081B-EVAL Evaluation board is a high-end development platform, for 9Arm Cortex-M0+ core-based STM32G081RBT6 microcontroller, with USB Type-C and 10power delivery controller interfaces (UCPD), compliant with USB type-C r1.2 11and USB PD specification r3.0, two I2Cs, two SPIs, five USARTs, one LP UART, 12one 12-bit ADC, two 12-bit DACs, two GP comparators, two LP timers, internal 1332 KB SRAM and 128 KB Flash, CEC, SWD debugging support. The full range of 14hardware features on the STM32G081B-EVAL Evaluation board includes a mother 15board, a legacy peripheral daughterboard and a USB-C and Power Delivery 16daughterboard, which help to evaluate all peripherals (USB Type-C connector 17with USB PD, motor control connector, RS232, RS485, Audio DAC, microphone ADC, 18TFT LCD, IrDA, IR LED, IR receiver, LDR, MicroSD card, CEC on two HDMI 19connectors, smart card slot, RF E2PROM & Temperature sensor…), and to develop 20applications. 21 22The board integrates an ST-LINK/V2-1 as an embedded in-circuit debugger and 23programmer for the STM32 MCU. The daughterboard and extension connectors 24provide an easy way to connect a daughterboard or wrapping board for the 25user's specific applications. 26 27The USB-C and Power Delivery daughterboard 28features two independent USB-C ports controlled by an STM32G0. USB-C port 1 29is dual role power (DRP) and can provide up-to 45 W. USB-C Port 2 is sink 30only. Both support USB PD protocol and alternate mode functionality. 31 32Application firmware examples are provided to evaluate the USB-C technology 33through various use cases. 34 35 36 37- Mother board 38 - STM32G081RBT6 microcontroller with 128 Kbytes of Flash memory and 39 32 Kbytes of RAM in LQFP64 package 40 - MCU voltage choice fixed 3.3 V or adjustable from 1.65 V to 3.6 V 41 - I2C compatible serial interface 42 - RTC with backup battery 43 - 8-Gbyte or more SPI interface microSD card 44 - Potentiometer 45 - 4 color user LEDs and one LED as MCU low-power alarm 46 - Reset, Tamper and User buttons 47 - 4-direction control and selection joystick 48 - Board connectors: 49 - 5 V power jack 50 - RS-232 and RS485 communications 51 - Stereo audio jack including analog microphone input 52 - microSD card 53 - Extension I2C connector 54 - Motor-control connector 55 - Board extension connectors: 56 - Daughterboard connectors for legacy peripheral daughter board or 57 USB-C daughterboard 58 - Extension connectors for daughterboard or wire-wrap board 59 - Flexible power-supply options: 60 - 5 V power jack 61 - ST-LINK/V2-1 USB connector 62 - Daughterboard 63 - On-board ST-LINK/V2-1 debugger/programmer with USB re-enumeration 64 capability: mass storage, virtual COM port and debug port 65 - Legacy peripheral daughterboard 66 - IrDA transceiver 67 - IR LED and IR receiver 68 - Light dependent resistor (LDR) 69 - Temperature Sensor 70 - Board connectors: 71 - Two HDMI connectors with DDC and CEC 72 - Smart card slot 73 - USB-C and Power Delivery daughterboard 74 - Mux for USB3.1 Gen1 / DisplayPort input and Type-C port1 output 75 - Mux for Type-C port2 input and DisplayPort output / USB2.0 76 - VCONN on Type-C port1 77 - USB PD on Type-C port1 78 - Board connectors: 79 - Type-C port1 DRP (dual-role port) 80 - Type-C port2 Sink 81 - DisplayPort input 82 - DisplayPort output 83 - USB 3.1 Gen1 Type-B receptacle 84 - USB2.0 Type-A receptacle 85 - 19 V power jack for USB PD 86 87.. image:: img/stm32g081b_eval.jpg 88 :align: center 89 :alt: STM32G081B-EVAL 90 91More information about the board can be found at the `STM32G081B-EVAL website`_. 92 93 94More information about STM32G081RB can be found here: 95- `G081RB on www.st.com`_ 96- `STM32G081 reference manual`_ 97 98 99Supported Features 100================== 101 102The Zephyr stm32g081b_eval board configuration supports the following hardware features: 103 104+-----------+------------+-------------------------------------+ 105| Interface | Controller | Driver/Component | 106+===========+============+=====================================+ 107| NVIC | on-chip | nested vector interrupt controller | 108+-----------+------------+-------------------------------------+ 109| UART | on-chip | serial port-polling; | 110| | | serial port-interrupt | 111+-----------+------------+-------------------------------------+ 112| UCPD | on-chip + ucpd | 113+-----------+------------+-------------------------------------+ 114| ADC | on-chip | adc | 115+-----------+------------+-------------------------------------+ 116| GPIO | on-chip | gpio | 117+-----------+------------+-------------------------------------+ 118| WATCHDOG | on-chip | independent watchdog | 119+-----------+------------+-------------------------------------+ 120 121Other hardware features are not yet supported in this Zephyr port. 122 123The default configuration can be found in the defconfig file: 124``boards/arm/stm32g081b_eval/stm32g081b_eval_defconfig`` 125 126Connections and IOs 127=================== 128 129Each of the GPIO pins can be configured by software as output (push-pull or open-drain), as 130input (with or without pull-up or pull-down), or as peripheral alternate function. Most of the 131GPIO pins are shared with digital or analog alternate functions. All GPIOs are high current 132capable except for analog inputs. 133 134Default Zephyr Peripheral Mapping: 135---------------------------------- 136 137- UART_3 TX/RX : PC10/PC11 (ST-Link Virtual Port Com) 138- UCPD2 : PD0/PD2 139- BUTTON (JOY_SEL) : PA0 140- BUTTON (JOY_LEFT) : PC8 141- BUTTON (JOY_DOWN) : PC3 142- BUTTON (JOY_RIGHT) : PC7 143- BUTTON (JOY_UP) : PC2 144- VBUS DISCHARGE : PB14 145- LED1 : PD5 146- LED2 : PD6 147- LED3 : PD8 148- LED4 : PD9 149 150For mode details please refer to `STM32G0 Evaluation board User Manual`_. 151 152Programming and Debugging 153************************* 154 155Applications for the ``stm32g081b_eval`` board configuration can be built and 156flashed in the usual way (see :ref:`build_an_application` and 157:ref:`application_run` for more details). 158 159Flashing 160======== 161 162The STM32G081B Evaluation board includes an ST-LINK/V2-1 embedded debug tool interface. 163 164.. code-block:: console 165 166 $ west flash 167 168Flashing an application to the STM32G081B_EVAL 169---------------------------------------------- 170 171Here is an example for the :zephyr:code-sample:`blinky` application. 172 173.. zephyr-app-commands:: 174 :zephyr-app: samples/basic/blinky 175 :board: stm32g081b_eval 176 :goals: build flash 177 178You will see the LED blinking every second. 179 180Debugging 181========= 182 183You can debug an application in the usual way. Here is an example for the 184:ref:`hello_world` application. 185 186.. zephyr-app-commands:: 187 :zephyr-app: samples/hello_world 188 :board: stm32g081b_eval 189 :maybe-skip-config: 190 :goals: debug 191 192References 193********** 194 195.. target-notes:: 196 197.. _STM32G081B-EVAL website: 198 https://www.st.com/en/evaluation-tools/stm32g081b-eval.html 199 200.. _STM32G081 reference manual: 201 https://www.st.com/resource/en/reference_manual/rm0444-stm32g0x1-advanced-armbased-32bit-mcus-stmicroelectronics.pdf 202 203.. _STM32G0 Evaluation board User Manual: 204 https://www.st.com/resource/en/user_manual/um2403-evaluation-board-with-stm32g081rb-mcu-stmicroelectronics.pdf 205 206.. _G081RB on www.st.com: 207 https://www.st.com/en/microcontrollers/stm32g081rb.html 208