Signed number grief.

I don't see how this helps:

typedef long device_t;
...
const device_t deviceWordLength = sizeof(device_t)<<2;

deviceWordLength is a characteristic of the input device. You can call it the length of the device's reply, or you can call it the position of the reply's sign bit. In this code, it depends only on the characteristics of the long data type.

What am I missing?