GithubHelp home page GithubHelp logo

martinribelotta / ch32v307-gnumake Goto Github PK

View Code? Open in Web Editor NEW
7.0 1.0 1.0 2.29 MB

Makefile project for ch32v307

License: MIT License

C 97.48% Assembly 0.52% CMake 0.28% C++ 1.10% Python 0.44% RPC 0.19%
ch32v307 embedded make makefile risc-v riscv wch firmware

ch32v307-gnumake's Introduction

CH32V307 floss tools project template

This project provide a functional cmake/ninja project for ch32v307 MCU using standard risc-v gcc toolchain and (for now) WCH openOCD (with wlink and ch32xxx flash support)

Software provides

  • RT-Thread 4.1.1 port for risc-v rv32imafc using QingKeV4 (a.k.a. RISC-V4F in WCH literature)
  • FPU support (F) and compressed mode support (C)
  • Support RISC-V4F fast stack saving/restore on interrupt without the WCH propietary gcc extensions
  • UART1 serial over WCHLink
  • USB Device support (implementing USB CDC example) via CherryUSB
  • Implemented RT-Thread drivers: ADC, DAC, GPIO, SoftI2C, UART
  • FinSH shell over UART1

Requeriments

  • CMake 3.16 or great
  • ninja build tool 1.10.0 or great
  • riscv none embed 8.2.0 or great (from WCH or xpack provider)

Build steps

  • Create build directory with mkdir build and move to this (cd build)
  • Generate cmake project using ninja (or your preferred tool): cmake ../ -G Ninja
  • If you preffer gnu make try cmake ../ -G 'Unix Makefile' or replace to your preferred tool)
  • Launch ninja to build all of code: ninja
  • If all pass ok, the files firmware.elf, firmware.elf.bin and firmware.elf.hex appears in build directory
  • Additionally, you found the files firmware.elf.map and firmware.elf.lst containing memmory mapping and disassembler of the ELF file

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.