Hi Folks,
In my case i am passing the void pointer which will be assigned with some memory to the firmware; in return firmware will fill this void pointer and returns.
My requirement is i have parse this filled data. But data filled by the firmware is complex.
e.g it will have following type of data :
struct1{
total_size_filled 4 byte;
Num_param 4 byte;
struct2 VARIABLE SIZE;
}
struct2{
size 4byte;
type 4 byte;
if(type == type1)
struct_type1; VARIABLE SIZE
else if(type == type2)
struct_type2; VARIABLE SIZE
}
// consider type == type1
struct_type1{
some_struct 12 byte;
struct_type1_1 VARIABLE;
struct_type1_2 VARIABLE;
}
struct_type1_1{
some_var 4 byte;
some_struct 16 byte;
}
struct_type1_2{
some_var 2 byte;
some_var 2 byte;
some_struct 20 byte;
}
Now i have to parse the above filled data.. Can you please suggest me something..
Can i use tree or vector to ???