Fix a bug in the tank id.

Due to a bitshift with the wrong number of bits, the tank id was always
zero for the Uwatec trimix firmware.
This commit is contained in:
Jef Driesen 2015-08-20 09:08:56 +02:00
parent 922d219bdc
commit 5381714d08

View File

@ -962,7 +962,7 @@ uwatec_smart_parser_samples_foreach (dc_parser_t *abstract, dc_sample_callback_t
case PRESSURE:
if (table[id].absolute) {
if (parser->trimix) {
tank = (value & 0xF000) >> 24;
tank = (value & 0xF000) >> 12;
pressure = (value & 0x0FFF) / 4.0;
} else {
tank = table[id].index;