Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
This repository was archived by the owner on Feb 17, 2024. It is now read-only.

Huawei LiteOS on GD32F303CCT6

NotificationsYou must be signed in to change notification settings

koendv/liteos-bluepillplus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a build of Huawei LiteOS 5.1.0 for GD32F303 onWeAct BluePill Plus . The demo does the following:

  • led blinks
  • usb cdc serial port echoes back all characters
  • usb hid device moves the mouse in small circles
  • Huawei LiteOS console on serial0 (PA9/PA10)
********Hello Huawei LiteOS********LiteOS Kernel Version : 5.1.0build data : Aug 17 2021 10:35:22**********************************OsAppInitcpu 0 entering schedulerapp init!Hello, welcome to liteos demo!Huawei LiteOS #

Installation

Download pre-built binaries fromreleases, boot in DFU mode, connect a usb-serial adapter to pin PA9/PA10 and install using

stm32flash -w Huawei_LiteOS.hex /dev/ttyUSB0

Developer notes

Patches are relative toHuawei Liteos

Do amake menuconfig, settarget family toGD,target toGD32F303RGT6_BearPi.

(Top) → Targets                          Huawei LiteOS Configuration    Family (GD)  --->    Target (GD32F303RGT6_BearPi)  --->[ ] Qspi peripherals[*] Enable Floating Pointer Unit[*] Enable Access Permission Control[ ] Enable Flash Patch

Makefile

Create binaries in intel hex format.

Makefile.patch

link script

The linker script is incomplete. This patch is needed to link.

GD32F303RGT6_BearPi.patch

WeAct BluePill-Plus

GD32F303RGT6_BearPi has a LED on pin PB0, WeAct BluePill Plus has a LED on pin PB2. This patch puts the led on pin PB2. Apply this patch if compiling for WeAct BluePill Plus. Skip this patch if compiling for GD32F303RGT6_BearPi.

WeActBluePillPlus.patch

usb device

The GD32F303 usb hardware seems register-compatible with STM32F103. The usb stack used islibusb_stm32, configuration is same as for STM32F103.

libusb_stm32 is a device-only usb stack for stm32 arm, optimized for speed and size. Compare withHa thach tinyusb.

Compiling

Huawei LiteOS 5.1.0 was compiled using gcc-9.4.0 andgcc-arm-none-eabi-9-2020-q2-update:

export PATH=/opt/xpack-arm-none-eabi-gcc-9.3.1-1.1/bin/:/opt/gcc-9.4.0/bin/:$PATHmake GCCLIB_PATH_32=/opt/xpack-arm-none-eabi-gcc-9.3.1-1.1/lib/gcc/arm-none-eabi/9.3.1/ CXXLIB_PATH_32=/opt/xpack-arm-none-eabi-gcc-9.3.1-1.1/arm-none-eabi/lib/

Firmware

Download firmware with a debugger or using a usb-serial converter.

To download via the serial port, connect a usb serial to the WeAct BluePill Plus:

  • RXD to pin A9
  • TXD to pin A10

Do not provide power via the USB connector and the +5V pin at the same time, or you risk short-circuit.

Boot in DFU mode:

  • press BOOT0 button
  • press RESET
  • release RESET
  • release BOOT0

Download the intel hex file via DFU. On linux:

stm32flash -w out/GD32F303RGT6_BearPi/Huawei_LiteOS.hex /dev/ttyUSB0

Reboot and you should have the LiteOS prompt on the serial port.

not truncated

About

Huawei LiteOS on GD32F303CCT6

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp