This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

FLOAT转换为整数,用联合体转换,错误 incomplete type is not allowed

typedef struct ADC_SAMPLE
{
Uint16 buffer[240];
Uint16 ADC_SAMPLETIMES;
Uint16 ADC_CHANNEL_NUM;
float AD_Sample_InitValue0;
float AD_Sample_InitValue1;
float AD_Sample_InitValue2;
float AD_Sample_InitValue3;
float AD_Sample_InitValue4;
float AD_Sample_InitValue5;
float AD_Sample_InitValue6;
float AD_Sample_InitValue7;
float AD_Sample_InitValue8;
float AD_Sample_InitValue9;
float AD_Sample_InitValue10;
float AD_Sample_InitValue11;
float AD_Value0;
float AD_Value1;
float AD_Value2;
float AD_Value3;
float AD_Value4;
float AD_Value5;
float AD_Value6;
float AD_Value7;
float AD_Value8;
float AD_Value9;
float AD_Value10;
float AD_Value11;
union sampleresult AD_SampleResult;
union abnormal_status Recorder_AbnormalStatus;
union floatConvert AD_Float;
} ADCSAMPLE;

union floatConvert
{
struct
{
Uint16 word0;
Uint16 word1;
}FloattoWord;
float value;
};