Thanks Everyone !!!
Type: Posts; User: MMC
Thanks Everyone !!!
I'm able to use
num = *((char*) buffer_input+44);
printf("num:%X\n",num);
printf("num:%d\n",num);
I used char instead of int ...
This gives me the hex and integer value...
Swoopy, I tried and suggestions and I'm now able to display hex values............ at a certain positions.
BUT....I still not able to set my position correctly.
Ex.
int num;
num = *((int *)...
Thanks Swoopy !
I'll give that a try and post my results.
Thanks Stoned_coder
But what I think I'm looking for is
Positions/bytes in my buffer
1234...............................................................38
...
I did received help on how to display a hex value.
I'm now looking for a way to extract a hex value out of a buffer.
Ex.
I have a buffer( 200 bytes long).
The first 38 bytes contains rt,...
Swoopy...I was just speaking with someone concerning my last post.
I guess what I'm really trying to do is......
Read ...say the first 200 characters into a buffer.
Within that buffer, is...
Thanks Swoopy
I was able to display the hex values !
My next step, I will try to incorporate this logic when reading a file with different data types.
Example
pos 1-10 = router
pos 11-29...
I'm trying to read in a hex value and display that value....any thoughts on how I can modify the following code.
Thanks in advance
File layout...
I'm trying to read a file that has hex values. I fread into a buffer, but I'm have trouble displaying the values via printf. Also, when I try to write the buffer, I'm getting one 0.
Any...
The following is code that works and sends "size" to my output file. My question is ...
I do want size to be outputted, but I also want additional information, such as fields from the...