Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pollen-robotics/stm32f0
Rust API for the STM32F0 micro controller
https://github.com/pollen-robotics/stm32f0
Last synced: 3 months ago
JSON representation
Rust API for the STM32F0 micro controller
- Host: GitHub
- URL: https://github.com/pollen-robotics/stm32f0
- Owner: pollen-robotics
- License: apache-2.0
- Created: 2017-10-10T12:59:39.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-08-07T08:01:15.000Z (over 6 years ago)
- Last Synced: 2024-08-08T19:39:25.776Z (6 months ago)
- Language: Rust
- Size: 1.06 MB
- Stars: 17
- Watchers: 6
- Forks: 3
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Rust API for the STM32F0 micro controller
[![Build Status](https://travis-ci.org/pollen-robotics/stm32f0.svg?branch=master)](https://travis-ci.org/pollen-robotics/stm32f0)
The API is composed of two main crates:
* the stm32f0x2 is the raw API as generated via [svd2rust](https://github.com/japaric/svd2rust)
* the stm32f0_hal is a higher level API with GPIO, LED, UART, etc support## Installation
First you need to setup your environment to cross compile it for armv6. You can find good instructions for Win/Mac/Linux [here](https://japaric.github.io/discovery/03-setup/README.html).
Then you can build both workspaces directly from the root using ```xargo build --target thumbv6m-none-eabi```.
>**Warning: due to some recent APIs break, you should use the nightly 25-12-2017! We will fix that real soon.**
## Usage
You can find examples in the [stm32f0_hal/examples](./stm32f0_hal/examples) folder. They can be built directly.
For instance, to build the *blinky* example: ```xargo build --target thumbv6m-none-eabi --example blinky```.
You can generate the doc via ```xargo doc``` for a complete API.
## Troubleshoot
### Xargo version
If you encounter an error such as: ```error: no matching version = 0.0.0 found for package compiler_builtins (required by sysroot)```
Make sure you downgrade your xargo version to 0.3.8: ```cargo install xargo --vers 0.3.8 -f```