This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

TASKS, EVENTS and REGISTERS

Hi,

I am writing a code base on the reference manual of nRF51422. In section 29, UART, I don't understand the differences between TASKS, EVENTS and REGISTERS. Aren't they all registers? If yes why they are not explained after this declaration, if no why they have offset value (therefor register address). There also some bits in REGISTERS with the same name to some of TASKS and EVENTS.

I saw in the libraries provided with SDK that they are defined all together (in an structure) with respect to their offset values. So it is likely that they all are registers. It is getting complicated. Can any one explain it to me?

  • Tim.D Sorry for confusing text. Like butch mentioned, I meant that triggering a TASK and reading an EVENT status can now be done atomically since there are dedicated registers for those. Otherwise if lot of events and tasks bits are squeezed into one register, then you need to do masking and/or bit shifting before you can trigger/read TASKS/EVENTS. Do you agree?

    I would have updated my answer with less confusing text but then these comments would become confusing, so i am leaving the text unchanged.

Related