Skip to content

Commit

Permalink
Update OpenVario.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
Blaubart committed Jun 10, 2024
1 parent c08c7cd commit 2f20b90
Showing 1 changed file with 35 additions and 6 deletions.
41 changes: 35 additions & 6 deletions src/Device/Driver/OpenVario.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -244,12 +244,6 @@ OpenVarioDevice::ParseNMEA(const char *_line, NMEAInfo &info)
{
if (!VerifyNMEAChecksum(_line))
return false;

NMEAInputLine line(_line);
if (line.ReadCompare("$POV"))
return POV(line, info);

return false;
}

bool
Expand Down Expand Up @@ -280,16 +274,51 @@ OpenVarioDevice::POV(NMEAInputLine &line, NMEAInfo &info)
break;

switch (type) {
/*
case 'E': {
info.ProvideTotalEnergyVario(value);
break;
}
*/
case 'H': {
info.humidity_available = true;
info.humidity = value;
break;
}
/*
case 'P': {
AtmosphericPressure pressure = AtmosphericPressure::HectoPascal(value);
info.ProvideStaticPressure(pressure);
break;
}
case 'Q': {
AtmosphericPressure pressure = AtmosphericPressure::Pascal(value);
info.ProvideDynamicPressure(pressure);
break;
}
case 'R': {
AtmosphericPressure pressure = AtmosphericPressure::HectoPascal(value);
info.ProvidePitotPressure(pressure);
break;
}
case 'S': {
value = Units::ToSysUnit(value, Unit::KILOMETER_PER_HOUR);
info.ProvideTrueAirspeed(value);
break;
}
*/
case 'T': {
info.temperature = Temperature::FromCelsius(value);
info.temperature_available = true;
break;
}
/*
case 'V': {
info.voltage = value;
info.voltage_available.Update(info.clock);
break;
}
*/
}
}

Expand Down

0 comments on commit 2f20b90

Please sign in to comment.