It should be : version = buffer[2] + (buffer[3] << 8);