Subject:
|
Help with pointers
|
Newsgroups:
|
lugnet.robotics.handyboard
|
Date:
|
Thu, 25 Mar 1999 16:00:55 GMT
|
Original-From:
|
Thomas Hauri <thomas.hauri@zhwin.ch=NoMoreSpam=>
|
Viewed:
|
678 times
|
| |
![Post a public reply to this message](/news/icon-reply.gif) | |
Hi all
little question:
How can I ad a value to a pointer ??
int *px, x;
px = &x;
px = px + 1; (????? pointing to the lowbyte of x for example)
Is it just NOT possible with IC or am I missunderstanding anything ????
Thanks for any help.
--
Thomas Hauri
ZHW Zuercher Hochschule Winterthur
University of applied sciences
Technikumstr.9 /PF
CH-8401 Winterthur
Switzerland
Phone : +41 52 267 74 79
Fax : +41 52 268 74 79
Mail : Thomas.Hauri@zhwin.ch
HP : http://www.zhwin.ch
|
|
Message has 1 Reply: ![](/news/x.gif) | | Re: Help with pointers
|
| (...) When you do pointer arithmatic, you work in increments of what the pointer points to. So if you have a pointer to an int, as in the above example, when you add one to it, you actually make it point to the next int, not the next byte or word. (...) (25 years ago, 25-Mar-99, to lugnet.robotics.handyboard)
|
2 Messages in This Thread: ![You are here](/news/here.gif) ![](/news/46.gif) ![Re: Help with pointers -handyboard@media.mit.edu (Keith Hearn) (25-Mar-99 to lugnet.robotics.handyboard)](/news/x.gif)
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|