From a53c4d4f9aa652812b02ce696aa072fbfea6d2a3 Mon Sep 17 00:00:00 2001 From: rmsyn Date: Sun, 21 May 2023 04:45:01 +0000 Subject: [PATCH] features: adds `rt` feature for gd32vf103-pac/rt Adds a `rt` feature to allow users to opt-in to using the `gd32vf103-pac/rt` feature. This exposes the `interrupt` macro, allowing users to define functions for system interrupts. This is preferable to using inline assembly to include the code in `eclic-mode-hack.S` which causes symbol collisions with user-defined interrupt functions, and strange bugs for handler execution. --- .github/workflows/ci.yml | 3 +++ Cargo.toml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8bf6a88..8b96de1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,3 +24,6 @@ jobs: - name: Check code run: cargo check --target ${{ matrix.target }} + + - name: Check rt feature + run: cargo check --target ${{ matrix.target }} --features rt diff --git a/Cargo.toml b/Cargo.toml index 8771848..158fc8f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,3 +21,6 @@ embedded-dma = "0.1.2" [dependencies.embedded-hal] version = "0.2.3" features = ["unproven"] + +[features] +rt = ["gd32vf103-pac/rt"]