Commit f48b6c3b authored by Lorenz Meier's avatar Lorenz Meier

Added 2 kPA offset to pressure measurements to get HIL closer to real conditions

parent b7edee79
......@@ -123,9 +123,10 @@ protected:
void enqueue(uint8_t* stream, uint8_t* index, mavlink_message_t* msg);
static const uint8_t systemId = 220;
static const int8_t systemId = 220;
static const uint8_t componentId = 200;
static const uint16_t version = 1000;
static const unsigned int barometerOffsetkPa = 2;
signals:
void valueChanged(int uasId, QString curve, double value, quint64 usec);
......
......@@ -667,8 +667,8 @@ void QGCXPlaneLink::readBytes()
/* current pressure at MSL in kPa */
double p1 = 1013.25 / 10.0;
/* measured pressure in hPa */
double p = abs_pressure / 10.0;
/* measured pressure in hPa, plus offset to simulate weather effects / offsets */
double p = abs_pressure / 10.0 + barometerOffsetkPa;
/*
* Solve:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment