1.. _gd32vf103v_eval: 2 3GigaDevice GD32VF103V-EVAL 4########################## 5 6Overview 7******** 8 9The GD32V103V-EVAL board is a hardware platform that enables prototyping 10on GD32VF103VB RISC-V MCU. 11 12The GD32VF103VB features a single-core RISC-V 32-bit MCU which can run up 13to 108 MHz with flash accesses zero wait states, 128 KiB of Flash, 32 KiB of 14SRAM and 80 GPIOs. 15 16.. image:: img/gd32vf103v_eval.jpg 17 :align: center 18 :alt: gd32vf103v_eval 19 20Hardware 21******** 22 23- GD32VF103VBT6 MCU 24- AT24C02C 2Kb EEPROM 25- GD25Q16 16Mbit SPI and QSPI NOR Flash 26- 4 x User LEDs 27- 1 x Joystick (L/R/U/D/C) 28- 2 x USART (RS-232 at J1/J2 connectors) 29- 1 x POT connected to an ADC input 30- USB FS connector 31- Headphone interface 32- 1 x CAN 33- 3.2" RGB-LCD (320x240) 34- GD-Link on board programmer 35- J-Link/JTAG connector 36 37For more information about the GD32VF103 SoC and GD32VF103V-EVAL board: 38 39- `GigaDevice RISC-V Mainstream SoC Website`_ 40- `GD32VF103 Datasheet`_ 41- `GD32VF103 User Manual`_ 42- `GD32VF103V-EVAL Documents`_ 43 44Supported Features 45================== 46 47The board configuration supports the following hardware features: 48 49.. list-table:: 50 :header-rows: 1 51 52 * - Peripheral 53 - Kconfig option 54 - Devicetree compatible 55 * - GPIO 56 - :kconfig:option:`CONFIG_GPIO` 57 - :dtcompatible:`gd,gd32-gpio` 58 * - Machine timer 59 - :kconfig:option:`CONFIG_RISCV_MACHINE_TIMER` 60 - :dtcompatible:`riscv,machine-timer` 61 * - Nuclei ECLIC Interrupt Controller 62 - :kconfig:option:`CONFIG_NUCLEI_ECLIC` 63 - :dtcompatible:`nuclei,eclic` 64 * - PWM 65 - :kconfig:option:`CONFIG_PWM` 66 - :dtcompatible:`gd,gd32-pwm` 67 * - USART 68 - :kconfig:option:`CONFIG_SERIAL` 69 - :dtcompatible:`gd,gd32-usart` 70 * - ADC 71 - :kconfig:option:`CONFIG_ADC` 72 - :dtcompatible:`gd,gd32-adc` 73 74Serial Port 75=========== 76 77The GD32VF103V-EVAL board has two serial communications port. The default port 78is USART0 with TX connected at PA9 and RX at PA10. 79 80Programming and Debugging 81************************* 82 83Before programming your board make sure to configure boot and serial jumpers 84as follows: 85 86- JP2/3: Select 2-3 for both (boot from user memory) 87- JP5/6: Select 1-2 positions (labeled as ``USART0``) 88 89Using GD-Link 90============= 91 92The GD32VF103V-EVAL includes an onboard programmer/debugger (GD-Link) which 93allows flash programming and debugging over USB. There is also a JTAG header 94(JP1) which can be used with tools like Segger J-Link. 95 96#. Build the Zephyr kernel and the :ref:`hello_world` sample application: 97 98 .. zephyr-app-commands:: 99 :zephyr-app: samples/hello_world 100 :board: gd32vf103v_eval 101 :goals: build 102 :compact: 103 104#. Run your favorite terminal program to listen for output. On Linux the 105 terminal should be something like ``/dev/ttyUSB0``. For example: 106 107 .. code-block:: console 108 109 minicom -D /dev/ttyUSB0 -o 110 111 The -o option tells minicom not to send the modem initialization 112 string. Connection should be configured as follows: 113 114 - Speed: 115200 115 - Data: 8 bits 116 - Parity: None 117 - Stop bits: 1 118 119#. To flash an image: 120 121 .. zephyr-app-commands:: 122 :zephyr-app: samples/hello_world 123 :board: gd32vf103v_eval 124 :goals: flash 125 :compact: 126 127 You should see "Hello World! gd32vf103v_eval" in your terminal. 128 129#. To debug an image: 130 131 .. zephyr-app-commands:: 132 :zephyr-app: samples/hello_world 133 :board: gd32vf103v_eval 134 :goals: debug 135 :compact: 136 137 138.. _GigaDevice RISC-V Mainstream SoC Website: 139 https://www.gigadevice.com/products/microcontrollers/gd32/risc-v/mainstream-line/ 140 141.. _GD32VF103 Datasheet: 142 https://www.gigadevice.com/datasheet/gd32vf103xxxx-datasheet/ 143 144.. _GD32VF103 User Manual: 145 https://www.gd32mcu.com/data/documents/userManual/GD32VF103_User_Manual_Rev1.4.pdf 146 147.. _GD32VF103V-EVAL Documents: 148 https://github.com/riscv-mcu/GD32VF103_Demo_Suites/tree/master/GD32VF103V_EVAL_Demo_Suites/Docs 149