// Determine how many messages were skipped accounting for 0-wraparound
int16_tlostMessages=message.seq-expectedIndex;
if(lostMessages<0)
{
lostMessages+=256;
}
// Console generates excessive load at high loss rates, needs better GUI visualization
//qDebug() << QString("Lost %1 messages for comp %4: expected sequence ID %2 but received %3.").arg(lostMessages).arg(expectedIndex).arg(message.seq).arg(message.compid);
totalLossCounter+=lostMessages;
currLossCounter+=lostMessages;
}
if(message.seq!=expectedIndex)
{
// Determine how many messages were skipped accounting for 0-wraparound
int16_tlostMessages=message.seq-expectedIndex;
if(lostMessages<0)
{
// Usually, this happens in the case of an out-of order packet
lostMessages=0;
}
else
{
// Console generates excessive load at high loss rates, needs better GUI visualization
//qDebug() << QString("Lost %1 messages for comp %4: expected sequence ID %2 but received %3.").arg(lostMessages).arg(expectedIndex).arg(message.seq).arg(message.compid);
* Typically this is used to send lowlevel information like the battery voltage to the plotting facilities of
* the groundstation
* the groundstation. The data here should be converted to human-readable values before being passed, so ideally
* SI units.
*
* @param uasId ID of this system
* @param name name of the value, e.g. "battery voltage"
* @param unit The units this variable is in as an abbreviation. For system-dependent (such as raw ADC values) use "raw", for bitfields use "bits", for true/false or on/off use "bool", for unitless values use "-".
* @param value the value that changed
* @param msec the timestamp of the message, in milliseconds