We use NXP LPC2468 Microcontroller in our target board.
We use Keil tools to build and debug our embedded C++ application.
#define UART1_BASE_ADDR 0xE0010000 #define U1RBR (*(volatile unsigned long *)(UART1_BASE_ADDR + 0x00))
What is contents of U1RBR ?
Is it address 0xE0010000 ?
or
Is it the value stored at address 0xE0010000.
Thank you!
"ANY SFR that is read should be declared volatile"
I may have oversimplified just a tad, however none you mention are read
For example, some SFRs can be used to specify the communication speed of a serial port. The underlying hardware does not change these values in the background and therefore they do not have to be declared volatile.