Part number - CC3000 (ARM M core)
I looked over several Pragma Pack forum posts, but couldn't find a smoking gun... I suspect an obscure compiler switch somewhere... Question from customer:
I’m trying to define a packed structure within my code. Currently I am using the Strict ANSI mode to compile and I would like to keep it that way. If you check the GCC extension and disable Strict ANSI, you can pack a struct as follows:
struct __attribute__ ((__packed__)) struct_name {uint8_t data0; uint8_t data1;};
If you still want to use Strict ANSI, you should be able to use the pragma PACK as follows:
#pragma PACK (1)
struct struct_name {uint8_t data0; uint8_t data1;};
However, when I compile my project, it says “#163-D unrecognized #pragma”. The Help on CCS shows the pack pragma should be recognized. After searching, it seems the PACK pragma was first supported by IAR. I’ve seen some much older posts that says it was supposed to be available for CCS as well in the future. Any ideas?