aboutsummaryrefslogtreecommitdiff
path: root/embassy-mcxa/src
diff options
context:
space:
mode:
authorMathis Deroo <[email protected]>2025-12-09 10:42:30 -0800
committerMathis Deroo <[email protected]>2025-12-09 10:52:12 -0800
commit06c16ca54dc846efa4b256620b4658a5b8378f81 (patch)
treebf7f7bfd5fbca86e30dbeaa48eb9ed54cb305ceb /embassy-mcxa/src
parentbea34ace6b4d8af29d2deb169ddb3d7c258498ee (diff)
Fix cmdlX and cmdhX access using updated PAC
Signed-off-by: Mathis Deroo <[email protected]>
Diffstat (limited to 'embassy-mcxa/src')
-rw-r--r--embassy-mcxa/src/adc.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/embassy-mcxa/src/adc.rs b/embassy-mcxa/src/adc.rs
index f4ac133d7..abcdf86f8 100644
--- a/embassy-mcxa/src/adc.rs
+++ b/embassy-mcxa/src/adc.rs
@@ -449,23 +449,23 @@ impl<'a, I: Instance, M: ModeAdc> Adc<'a, I, M> {
449 macro_rules! write_cmd { 449 macro_rules! write_cmd {
450 ($idx:expr) => {{ 450 ($idx:expr) => {{
451 paste! { 451 paste! {
452 adc.[<cmdl $idx>]().write(|w| unsafe { 452 adc.[<cmdl $idx>]().write(|w| {
453 w.adch() 453 w.adch()
454 .bits(config.channel_number.into()) 454 .variant(config.channel_number)
455 .mode() 455 .mode()
456 .bit(config.conversion_resolution_mode.into()) 456 .variant(config.conversion_resolution_mode)
457 }); 457 });
458 adc.[<cmdh $idx>]().write(|w| unsafe { 458 adc.[<cmdh $idx>]().write(|w| unsafe {
459 w.next() 459 w.next()
460 .bits(config.chained_next_command_number.into()) 460 .variant(config.chained_next_command_number)
461 .loop_() 461 .loop_()
462 .bits(config.loop_count) 462 .bits(config.loop_count)
463 .avgs() 463 .avgs()
464 .bits(config.hardware_average_mode.into()) 464 .variant(config.hardware_average_mode)
465 .sts() 465 .sts()
466 .bits(config.sample_time_mode.into()) 466 .variant(config.sample_time_mode)
467 .cmpen() 467 .cmpen()
468 .bits(config.hardware_compare_mode.into()) 468 .variant(config.hardware_compare_mode)
469 .wait_trig() 469 .wait_trig()
470 .bit(config.enable_wait_trigger) 470 .bit(config.enable_wait_trigger)
471 .lwi() 471 .lwi()