Here's an extension of the original program I gave. Choose an "endianness" and copy the key.ints into the rd_key of your struct.
Code:
#include <stdio.h>
//#define METHOD_ONE
int main() {
char dek[] = "016211c7f60824a8ec5df54737a08ad0"
"a11b2e451160601a94ccd53555a335ab";
union {
unsigned char bytes[32];
unsigned int ints[8];
} key;
unsigned x;
int i, j;
#ifdef METHOD_ONE
for (i = 0; i < 32; i++) {
sscanf(dek+i*2, "%2x", &x);
key.bytes[i] = x;
}
#else
for (i = 0; i < 8; i++)
for (j = 0; j < 4; j++) {
sscanf(dek+(i*4+j)*2, "%2x", &x);
key.bytes[i*4+3-j] = x;
}
#endif
// Print string
printf("%s\n", dek);
// Print bytes
for (i = 0; i < 32; i++) printf("%02x", key.bytes[i]);
printf("\n");
// Print ints
for (i = 0; i < 8; i++) printf("%08x", key.ints[i]);
printf("\n");
return 0;
}