Skip to content

Commit fdeba5a

Browse files
committed
Add MASK[UPDATE_MASK] field for 1170 FlexPWM
They're documented in rev 3 of the i.MX RT 1170 reference manual. I noticed they're missing when adding output masking in the -hal.
1 parent f7a3baa commit fdeba5a

4 files changed

Lines changed: 27 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
Add support for NXP's i.MX RT 1189 dual-core MCUs. An `"imxrt1189_cm33"` feature
66
targets the Cortex-M33, and an `"imxrt1189_cm7"` feature targets the Cortex-M7.
77

8+
Add the `MASK[UPDATE_MASK]` fields for FlexPWM on 1170 MCUs.
9+
810
## [0.6.1] 2024-12-19
911

1012
Remove the following peripheral instances from the 1176 API. The base address

devices/imxrt1176_cm4.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,15 @@ PWM?:
198198
bitWidth: 1
199199
access: read-write
200200

201+
# Missing in these SVDs, but documented in the reference manual.
202+
"PWM*":
203+
MASK:
204+
_add:
205+
UPDATE_MASK:
206+
bitOffset: 12
207+
bitWidth: 4
208+
access: read-write
209+
201210
MCM:
202211
_add:
203212
_interrupts:

devices/imxrt1176_cm7.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,15 @@ PWM?:
138138
bitWidth: 1
139139
access: read-write
140140

141+
# Missing in these SVDs, but documented in the reference manual.
142+
"PWM*":
143+
MASK:
144+
_add:
145+
UPDATE_MASK:
146+
bitOffset: 12
147+
bitWidth: 4
148+
access: read-write
149+
141150
CM7_MCM:
142151
_add:
143152
_interrupts:

src/blocks/imxrt1176_cm4/pwm.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,13 @@ pub mod MASK {
109109
pub const MASKA_1: u16 = 0x01;
110110
}
111111
}
112+
pub mod UPDATE_MASK {
113+
pub const offset: u16 = 12;
114+
pub const mask: u16 = 0x0f << offset;
115+
pub mod R {}
116+
pub mod W {}
117+
pub mod RW {}
118+
}
112119
}
113120
#[doc = "Software Controlled Output Register"]
114121
pub mod SWCOUT {

0 commit comments

Comments
 (0)