aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDario Nieuwenhuis <[email protected]>2025-09-02 15:50:28 +0000
committerGitHub <[email protected]>2025-09-02 15:50:28 +0000
commit1405b1affa1b81bb50e6a39456793d968d39f63f (patch)
tree9c4928e8d047c362c5dc4a6c8fc9b92a96b7194e
parentf247fcf817e3c215b8ba2396ca360dfc914c6c60 (diff)
parent010f4b08aa6846ffdbf906398caaceb4eb9c1c39 (diff)
Merge pull request #4633 from phycrax/derive-copy-qspi-cfg
embassy-stm32: Derive Clone, Copy for QSPI Config
-rw-r--r--embassy-stm32/CHANGELOG.md1
-rw-r--r--embassy-stm32/src/qspi/mod.rs2
2 files changed, 3 insertions, 0 deletions
diff --git a/embassy-stm32/CHANGELOG.md b/embassy-stm32/CHANGELOG.md
index dfb8ca066..133defcc6 100644
--- a/embassy-stm32/CHANGELOG.md
+++ b/embassy-stm32/CHANGELOG.md
@@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
9## Unreleased - ReleaseDate 9## Unreleased - ReleaseDate
10 10
11- fix: Fixed STM32H5 builds requiring time feature 11- fix: Fixed STM32H5 builds requiring time feature
12- feat: Derive Clone, Copy for QSPI Config
12 13
13## 0.4.0 - 2025-08-26 14## 0.4.0 - 2025-08-26
14 15
diff --git a/embassy-stm32/src/qspi/mod.rs b/embassy-stm32/src/qspi/mod.rs
index 1e20d7cd3..c0cd216f0 100644
--- a/embassy-stm32/src/qspi/mod.rs
+++ b/embassy-stm32/src/qspi/mod.rs
@@ -17,6 +17,7 @@ use crate::rcc::{self, RccPeripheral};
17use crate::{peripherals, Peri}; 17use crate::{peripherals, Peri};
18 18
19/// QSPI transfer configuration. 19/// QSPI transfer configuration.
20#[derive(Clone, Copy)]
20pub struct TransferConfig { 21pub struct TransferConfig {
21 /// Instruction width (IMODE) 22 /// Instruction width (IMODE)
22 pub iwidth: QspiWidth, 23 pub iwidth: QspiWidth,
@@ -46,6 +47,7 @@ impl Default for TransferConfig {
46} 47}
47 48
48/// QSPI driver configuration. 49/// QSPI driver configuration.
50#[derive(Clone, Copy)]
49pub struct Config { 51pub struct Config {
50 /// Flash memory size representend as 2^[0-32], as reasonable minimum 1KiB(9) was chosen. 52 /// Flash memory size representend as 2^[0-32], as reasonable minimum 1KiB(9) was chosen.
51 /// If you need other value the whose predefined use `Other` variant. 53 /// If you need other value the whose predefined use `Other` variant.