Fix the Galileo trimix detection.

Originally, I assumed that the trimix firmware update changed the model
number from 0x11 (Galileo) to 0x19 (Galileo Trimix). But that assumption
appears to be wrong because I received data from a Galileo with model
number 0x11, but with the trimix data format. Another explanation might
be that the trimix data format is not specific to the trimix firmware.

Anyway, this is easily fixed by treating both models identically.
This commit is contained in:
Jef Driesen 2015-03-07 10:07:35 +01:00
parent 5a1f1293d2
commit bcb2925a25

View File

@ -375,7 +375,7 @@ uwatec_smart_parser_get_field (dc_parser_t *abstract, dc_field_type_t type, unsi
unsigned int header = parser->headersize;
unsigned int trimix = 0;
if (parser->model == GALILEOTRIMIX) {
if (parser->model == GALILEO || parser->model == GALILEOTRIMIX) {
if (size < 44)
return DC_STATUS_DATAFORMAT;
@ -501,7 +501,7 @@ uwatec_smart_parser_samples_foreach (dc_parser_t *abstract, dc_sample_callback_t
unsigned int header = parser->headersize;
unsigned int trimix = 0;
if (parser->model == GALILEOTRIMIX) {
if (parser->model == GALILEO || parser->model == GALILEOTRIMIX) {
if (size < 44)
return DC_STATUS_DATAFORMAT;