-
Notifications
You must be signed in to change notification settings - Fork 7
uctypes for DMA CTRL reg #3
Copy link
Copy link
Open
Description
RP2040 docs state that any write to CTRL on Alias 0 (DMA_CHAN_ADDRESS + 0xC offset) starts the transfer... You're mapping this 4 bytes to bitfields uctypes struct, so every write access to any bit field probably writes CTRL, i.e. starts DMA... Results may be unpredictable and hardly depend on sequence of field assignments. We should treat building of CTRL value in transactional manner (compute whole 32bit value and then assign) - C API does it this way. Probably your code works due to update to EN field as last operation, but this is pure luck
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels