Go to file
Daniel Egger a8d868e76f
Merge pull request #108 from stm32-rs/simplify-serial-read
Simplify serial `read()` error handling
2020-04-09 19:30:17 +02:00
.cargo First release of stm32f0xx-hal based on stm32f042-hal 2018-12-06 23:04:26 +01:00
examples Optimize 8-bit SPI transfers and add 16-bit SPI transfers 2020-04-07 00:06:48 +02:00
src Simplify serial `read()` error handling 2020-04-09 17:51:05 +02:00
tools More parametrisation and added section sizes as requested 2020-02-18 09:51:49 +01:00
.gitignore First release of stm32f0xx-hal based on stm32f042-hal 2018-12-06 23:04:26 +01:00
.travis.yml Mention MSRV of 1.39.0 and test it in CI 2020-02-02 14:25:51 +01:00
CHANGELOG.md Simplify serial `read()` error handling 2020-04-09 17:51:05 +02:00
Cargo.toml Add thumbv6m-none-eabi target to docs. 2020-04-05 10:42:29 -07:00
LICENSE-0BSD.txt Added forgotten LICENSE file 2018-12-16 21:40:57 +01:00
README.md Mention MSRV of 1.39.0 and test it in CI 2020-02-02 14:25:51 +01:00
memory.x Use the smallest available flash& ram size 2018-12-18 17:21:30 +01:00
openocd.cfg First release of stm32f0xx-hal based on stm32f042-hal 2018-12-06 23:04:26 +01:00
openocd_program.sh First release of stm32f0xx-hal based on stm32f042-hal 2018-12-06 23:04:26 +01:00

README.md

stm32f0xx-hal

Travis Crates.io docs.rs

stm32f0xx-hal contains a hardware abstraction on top of the peripheral access API for the STMicro STM32F0xx family of microcontrollers.

This crate replaces the stm32f042-hal by a more ubiquitous version suitable for additional families. The idea behind this crate is to gloss over the slight differences in the various peripherals available on those MCUs so a HAL can be written for all chips in that same family without having to cut and paste crates for every single model.

This crate relies on Adam Greig's fantastic stm32f0 crate to provide appropriate register definitions, and implements a partial set of the embedded-hal traits. Some of the implementation was shamelessly adapted from the stm32f103xx-hal crate by Jorge Aparicio.

Collaboration on this crate is highly welcome, as are pull requests!

Supported Configurations

  • stm32f030 (stm32f030x4, stm32f030x6, stm32f030x8, stm32f030xc)
  • stm32f031
  • stm32f038
  • stm32f042
  • stm32f048
  • stm32f051
  • stm32f058
  • stm32f070 (stm32f070x6, stm32f070xb)
  • stm32f071
  • stm32f072
  • stm32f078
  • stm32f091
  • stm32f098

Getting Started

The examples folder contains several example programs. To compile them, one must specify the target device as cargo feature:

$ cargo build --features=stm32f030xc

To use stm32f0xx-hal as a dependency in a standalone project the target device feature must be specified in the Cargo.toml file:

[dependencies]
cortex-m = "0.6.0"
cortex-m-rt = "0.6.8"
stm32f0xx-hal = {version = "0.15", features = ["stm32f030xc"]}

If you are unfamiliar with embedded development using Rust, there are a number of fantastic resources available to help.

Minimum supported Rust version

The minimum supported Rust version at the moment is 1.39.0. Older versions may compile, especially when some features are not used in your application.

Changelog

See CHANGELOG.md.

License

0-Clause BSD License, see LICENSE-0BSD.txt for more details.