rp-rs/rp2040-pac

Add atomic XOR/set/clear access

Opened this issue · 3 comments

hmvp commented

While I suspect this is something that might be added through svd2rust I still think its useful to mention here:

According to 2.1.2 from the datasheet most registers allow XORing, setting or clearing of individual bits by writing to offset 0x1000, 0x2000 or 0x3000 from the base register. This is useful in a lot of cases to circumvent a read/modify cycle.

Afaik this is not supported by the pac at the moment..

I opened an issue upstream rust-embedded/svd2rust#535

For reference the rp2040-hal currently implements it via the atomic_register_access module