Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
ivar4ever said:statement 1
*(unsigned int *)0x1000 = 0x0000;
statement 2
char *pLCD = (char *)&LCDM1
*pLCD=0x00;
statement-1
------------------
the address location 0x1000 is typecasted to fit a Unsigned integer, and then the value at that location is
being set to 0x0000.
it is similar to the following statements:
int *p;
p=(unsigned int *)0x1000;
*p=0x0000.
statement-2
-----------------
LCDM1 might be # defined to a particular address location / beind assinged with a value of an address
in these statements we are type casting it to a character pointer (dereferencing the pointer)
and assingning the ascii value 0 to it.
since p is a character pointer, any statement like
char a=*p;
will result in "NULL" being assinged to a.
Please dont forget the HELPED ME button.
It depends on what C compiler you are using. Some C compilers for PIC, such as Hi-Tech PIC C or BKND's CC5X can do that for you. I'm sure there are other C compilers for other families can do that as well.ivar4ever said:and i dont know how to place a variable at a particular address location(using C), since the address will be allocated by the compiler.
i think we can do it through assembly instrucitons. will refer and get back to you.