boards/sipeed/longan_nano/doc/index.rst
.. zephyr:board:: longan_nano
Overview
The Sipeed Longan Nano and Longan Nano Lite is an simple and tiny development board with an GigaDevice GD32VF103 SoC that based on N200 RISC-V IP core by Nuclei system technology. More information can be found on:
Sipeed Longan website <https://longan.sipeed.com/en/>_GD32VF103 datasheet <https://www.gigadevice.com/datasheet/gd32vf103xxxx-datasheet/>_GD32VF103 user manual <https://www.gd32mcu.com/data/documents/userManual/GD32VF103_User_Manual_Rev1.4.pdf>_Nuclei website <https://www.nucleisys.com/download.php>_Nuclei Bumblebee core documents <https://github.com/nucleisys/Bumblebee_Core_Doc>_Nuclei ISA Spec <https://doc.nucleisys.com/nuclei_spec/>_Hardware
.. zephyr:board-supported-hw::
The microSD card reader in Longan Nano board is connected to SPI1.
USART0 is on the opposite end of the USB. Connect to TX0 (PA9) and RX0 (PA10).
Programming and debugging
.. zephyr:board-supported-runners::
Here is an example for building the :zephyr:code-sample:blinky application.
.. zephyr-app-commands:: :zephyr-app: samples/basic/blinky :board: longan_nano :goals: build flash
When using a custom toolchain it should be enough to have the downloaded
version of the binary in your PATH.
The default runner tries to flash the board via an external programmer using openocd. To flash via the USB port, select the DFU runner when flashing:
.. code-block:: console
west flash --runner dfu-util
You can debug an application in the usual way. Here is an example for the
:zephyr:code-sample:blinky application.
.. zephyr-app-commands:: :zephyr-app: samples/basic/blinky :board: longan_nano :maybe-skip-config: :goals: debug