Skip to main content
LMorr.3
Senior
June 4, 2023
Solved

How to use CMSIS to set a bit or register

Each time I call SET_BIT to set a bit the register value remains at 0. All registers are 0 even after writing, as though they are read-only. For example, the following does not set the bit:

DMA2_Stream0->CR |= ((uint32_t)1);

What am I missing?

Thank you!

This topic has been closed for replies.
Tesla DeLorean
Tesla DeLoreanBest answer
Guru
June 4, 2023

>>What am I missing?

Probably a clock

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..

2 replies

Tesla DeLorean
Tesla DeLoreanBest answer
Guru
June 4, 2023

>>What am I missing?

Probably a clock

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
LMorr.3
LMorr.3Author
Senior
June 4, 2023

Yep, that was it, thank you!