Tag: Embedded Rust

  • Getting Started with CH32V003 Firmware in Rust

    Getting Started with CH32V003 Firmware in Rust

    I have been working on a small project using the WCH CH32V003 and thought it would be fun to make a version of the firmware for it in Rust. I started by having a look around for hardware support and getting started guides. As it turns out, there is a HAL and hardware support by…

  • BLE in Embedded Rust

    I wanted to make a Bluetooth widget and I wanted to learn more Rust, so I went about looking what options there are for enabling BLE in an Embedded Rust project. First off, I could probably have done this on a Raspberry Pi and saved myself a few headaches, but I specifically want to get…

  • Doing Knurling Sessions 2020 Q4 in 2021 Q2

    I’m going through Knurling Sessions 2020 Q4, an excellent course/project from the Knurling project. It was originally available only to sponsors of the project but is now open to everyone for free. I decided to use the latest version of all crates instead of following the instructions to the letter. Here are some notes on…

  • Find the type of a variable in Rust

    I was trying to make an abstraction in Rust and found myself navigating a lot of code to determine the type of pwm below so I could put it in a struct: A quicker way to find it is to add an empty type, : () and check the compilation error: I’m using Visual Studio…

  • Embedded Rust Toolchains

    I recently started learning Embedded Rust. As I mentioned at the top of the last post, there are a couple of toolchain options: OpenOCD + GDB probe-rs + cargo-embed Turns out there is also a third one that I just discovered: probe-rs + probe-run This was a little confusing at first, I was unsure what…

  • Embedded Rust: Timer Timeout Problem

    TL;DR: When doing timing critical stuff, use the –release flag to get a faster binary!For example: cargo embed –release. I’m learning Embedded Rust on a STM32 Bluepill board (with a STM32F103 microcontroller). At the time of writing there seems to be two toolchain options: The “official” Embedded Rust way, using OpenOCD and ARM-compatible GDB. Up-and-coming…