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

Pointer Variable on LCD

Hi all...
i need to print a value of pointer variable in 16x2 LCD...
for Eg.

void main()
{
int *a = 20;
int b;
*a=&b;
print_LCD(value of pointer variable a)
}


here is a simple example where i have declared a pointer variable 'a' whoes value is 20.
and then i stored the value of pointer variable at the address of variable b.
but i need to print the value of pointer variable on LCD screen.
how can i do this....
can anybody help me please....

Parents
  • A pointer is a variable that stores a memory address.
    So your variable "a" is "a pointer to int" so it stores the address of a memory cell capable of storing an integer.

    And the indirection of the pointer allows you to access the memory at that address. So the indirection of "a" accesses an integer variable storage space.

Reply
  • A pointer is a variable that stores a memory address.
    So your variable "a" is "a pointer to int" so it stores the address of a memory cell capable of storing an integer.

    And the indirection of the pointer allows you to access the memory at that address. So the indirection of "a" accesses an integer variable storage space.

Children