Hello, Can someone explain what it means??
#define IOPIN0 (*(volatile unsigned long *)(GPIO_BASE_ADDR + 0x00))
The controller using is LPC23xx/24xx.
BR Chethan
Ya got it now!!
In this case why we using volatile.....is their any special purpose??
Chethan
Haven't you looked at the description of the volatile keyword?
What is the difference between a normal memory variable and a register mapped to real hardware? When may a memory variable change content? When may a I/O register associated with processor pins change value? Would that matter to the compiler, when it generates the processor instructions?
Actually i know the concept.
Volatile is used to modify the memory content is existing in different file.
Is it correct ???
For remaining questions i don't have much deep knowledge. Kindly explain me those things also it looks to be interesting :) :)
No. You really should read up about volatile.
You seem to think about external declarations, which is something completely different.
Didn't you consider the hints I left about the need for volatile because of the difference between a normal RAM variable and a special function register? Volatile is even part of non-technical English. Nitroglycerin is volatile, as is the situation in Ukraine.
(making allowances for English as a foreign language)
Well, one common use of the 'volatile' qualifier is to indicate that memory content may bechanged by "another file".
So think how a hardware SFR (special function register) might have similar issues...
Is this essentially the same question as http://www.keil.com/forum/58484 ?