In my objective C code, I get the data like below
<0a000100 0000ccff 6f591800 0000001e 00000200 0000b8f9 6f591800 00000024 00000300 000038fd 6f591800 00000025 00000400 000074fd 6f591800 0000001e 00000500 00009bfd 6f594800 00000059 00000600 00000dfe 6f594800 00000060 00000700 0000daff 6f591800 0000001e 00000800 00008b00 70590000 00000000 00000900 00009bf2 6f591800 00000024 00000a00 000074f4 6f591800 00000024 0000>
But I want to convert them to char bytes array , so I can map it with my structures.
eg: It should be converted like this:
char rawData[] = {0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0xcc, 0xff,
0x6f, 0x59, 0x18, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x02, 0x00,
0x00, 0x00, 0xb8, 0xf9, 0x6f, 0x59, 0x18, 0x00, 0x00, 0x00, 0x00, 0x24,
0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x38, 0xfd, 0x6f, 0x59, 0x18, 0x00,
0x00, 0x00, 0x00, 0x25, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x74, 0xfd,
0x6f, 0x59, 0x18, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x05, 0x00,
0x00, 0x00, 0x9b, 0xfd, 0x6f, 0x59, 0x48, 0x00, 0x00, 0x00, 0x00, 0x59,
0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x0d, 0xfe, 0x6f, 0x59, 0x48, 0x00,
0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0xda, 0xff,
0x6f, 0x59, 0x18, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x08, 0x00,
0x00, 0x00, 0x8b, 0x00, 0x70, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x9b, 0xf2, 0x6f, 0x59, 0x18, 0x00,
0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x74, 0xf4,
0x6f, 0x59, 0x18, 0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00};
NSData *sampleData = [NSData dataWithBytes:rawData length:sizeof(rawData)];