Skip to content

Commit dbb6625

Browse files
bors[bot]hargoniXrichardeoinnewAM
authored
Merge #236 #305
236: Migrate to Rust 2021 as part of the public testing r=richardeoin a=hargoniX Migration to Rust 2021 as part of the public testing. We did actually catch one ICE bug with this \o/: rust-lang/rust#87426 305: remove release mode requirement from USB examples r=richardeoin a=newAM This was fixed in usb-device: rust-embedded-community/usb-device#41 Co-authored-by: Henrik Böving <[email protected]> Co-authored-by: Richard Meadows <[email protected]> Co-authored-by: Alex Martens <[email protected]>
3 parents 80f8676 + 2cf6553 + 522a76f commit dbb6625

File tree

10 files changed

+19
-21
lines changed

10 files changed

+19
-21
lines changed

.github/bors.toml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@ block_labels = ["wip"]
22
delete_merged_branches = true
33
status = [
44
"Rustfmt",
5-
"ci (1.52.0, stm32h743)",
6-
"ci (1.52.0, stm32h753)",
7-
"ci (1.52.0, stm32h743v)",
8-
"ci (1.52.0, stm32h753v)",
9-
"ci (1.52.0, stm32h747cm7)",
10-
"ci (1.52.0, stm32h7b3)",
11-
"ci (1.52.0, stm32h7b0)",
12-
"ci (1.52.0, stm32h735)",
5+
"ci (1.56.1, stm32h743)",
6+
"ci (1.56.1, stm32h753)",
7+
"ci (1.56.1, stm32h743v)",
8+
"ci (1.56.1, stm32h753v)",
9+
"ci (1.56.1, stm32h747cm7)",
10+
"ci (1.56.1, stm32h7b3)",
11+
"ci (1.56.1, stm32h7b0)",
12+
"ci (1.56.1, stm32h735)",
1313
"ci (stable, stm32h743)",
1414
"ci (stable, stm32h753)",
1515
"ci (stable, stm32h743v)",

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
strategy:
1212
matrix: # All permutations of {rust, mcu}
1313
rust:
14-
- 1.52.0 # MSRV
14+
- 1.56.1 # MSRV
1515
- stable
1616
mcu:
1717
- stm32h743

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## [Unreleased]
44

5+
* MSRV increased to 1.56.1
6+
57
## [v0.11.0] 2021-12-18
68

79
* **Breaking**: Simplified API for reading device signature

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ authors = ["Andrew Straw <[email protected]>",
1010
"Matthew Meyer <[email protected]>",
1111
"Florian Jung <[email protected]>",
1212
"Matt Ickstadt <[email protected]>"]
13-
edition = "2018"
13+
edition = "2021"
1414
categories = ["embedded", "hardware-support", "no-std"]
1515
description = "Hardware Abstraction Layer implementation for STM32H7 series microcontrollers"
1616
keywords = ["arm", "cortex-m", "stm32h7xx", "hal", "embedded-hal"]

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ stm32h7xx-hal
77
[![Bors enabled](https://bors.tech/images/badge_small.svg)](https://app.bors.tech/repositories/12691)
88
[![CI](https://github.com/stm32-rs/stm32h7xx-hal/workflows/Continuous%20integration/badge.svg)](https://github.com/stm32-rs/stm32h7xx-hal/actions)
99
[![Crates.io](https://img.shields.io/crates/v/stm32h7xx-hal.svg)](https://crates.io/crates/stm32h7xx-hal)
10-
![Minimum rustc version](https://img.shields.io/badge/rustc-1.52.0+-yellow.svg)
10+
![Minimum rustc version](https://img.shields.io/badge/rustc-1.56.1+-yellow.svg)
1111

1212
[_stm32h7xx-hal_](https://github.com/stm32-rs/stm32h7xx-hal) contains
1313
a hardware abstraction layer on top of the peripheral access API for
@@ -111,7 +111,7 @@ programming interfaces are only available on the high density connectors.
111111
Minimum supported Rust version
112112
------------------------------
113113

114-
The Minimum Supported Rust Version (MSRV) at the moment is **1.52.0**. Older
114+
The Minimum Supported Rust Version (MSRV) at the moment is **1.56.1**. Older
115115
versions **may** compile, especially when some features are not used
116116
in your application.
117117

examples/mdma_bursts.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,15 +112,15 @@ fn main() -> ! {
112112
let mut cycles = 0;
113113
for _ in 0..10 {
114114
cycles += {
115-
let start = DWT::get_cycle_count();
115+
let start = DWT::cycle_count();
116116

117117
// Start block
118118
transfer.start(|_| {});
119119

120120
// Wait for transfer to complete
121121
while !transfer.get_transfer_complete_flag() {}
122122

123-
DWT::get_cycle_count() - start
123+
DWT::cycle_count() - start
124124
};
125125
}
126126

examples/sdmmc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,14 +141,14 @@ fn main() -> ! {
141141
let mut buffer = [0u8; 5120];
142142

143143
cp.DWT.enable_cycle_counter();
144-
let start = pac::DWT::get_cycle_count();
144+
let start = pac::DWT::cycle_count();
145145

146146
for i in 0..10 {
147147
// Read 10 blocks
148148
sdmmc.read_blocks(10 * i, &mut buffer).unwrap();
149149
}
150150

151-
let end = pac::DWT::get_cycle_count();
151+
let end = pac::DWT::cycle_count();
152152
let duration = (end - start) as f32 / ccdr.clocks.c_ck().0 as f32;
153153

154154
info!("Read 100 blocks at {} bytes/s", 5120. / duration);

examples/usb_passthrough.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
//! Dual CDC-ACM serial port example using polling in a busy loop.
22
//!
33
//! Characters written to one serial port appear on both.
4-
//!
5-
//! Note: This example must be built in release mode to work reliably
64
#![no_std]
75
#![no_main]
86

examples/usb_serial.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
//! CDC-ACM serial port example using polling in a busy loop
2-
//!
3-
//! Note: This example must be built in release mode to work reliably
42
#![no_std]
53
#![no_main]
64

src/time.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,6 +273,6 @@ pub struct Instant {
273273
impl Instant {
274274
/// Ticks elapsed since the `Instant` was created
275275
pub fn elapsed(&self) -> u32 {
276-
DWT::get_cycle_count().wrapping_sub(self.now)
276+
DWT::cycle_count().wrapping_sub(self.now)
277277
}
278278
}

0 commit comments

Comments
 (0)