I want to create a global 22 character (+ NULL) string in C. I am initialising it like this:
#define SVN_REVISION "1143"
#define SERIAL_NUMBER "PST3201109270001"
char general_info[23] = SVN_REVISION SERIAL_NUMBER SAMPLING_FREQUENCY;
So far, this works fine. general_info is initialised with the concatenation of the two strings. Now, for the last two characters, I want them to be a 16-bit integer. But I can't simply do this:
#define SVN_REVISION "1143"
#define SERIAL_NUMBER "PST3201109270001"
#define SAMPLING_FREQUENCY (UINT16)500
char general_info[23] = SVN_REVISION SERIAL_NUMBER SAMPLING_FREQUENCY SAMPLING_FREQUENCY;
What can I do?