Compare const char * to const char
Try something like this:

typedef struct  {
  char id[2];
  ....
} Device;

const int DEVICES_MAX = 8;
Device Devices[DEVICES_MAX];

for (int i = 0; i &lt; DEVICES_MAX; i++) {
  Devices[i].id[0] = '1' + i;
  Devices[i].id[1] = 0;
  ...
}

for (int i = 0; i &lt; DEVICES_MAX; i++) {
  if (!strcmp(Devices[i].id, id)) {
  ...
}


Cheers!