| 29 | // #define OHD_TELEMETRY_TESTING_ENABLE_PACKET_LOSS |
| 30 | |
| 31 | MEndpoint::MEndpoint(std::string tag, bool debug_mavlink_msg_packet_loss) |
| 32 | : TAG(std::move(tag)), |
| 33 | m_mavlink_channel(checkoutFreeChannel()), |
| 34 | m_debug_mavlink_msg_packet_loss(debug_mavlink_msg_packet_loss) { |
| 35 | openhd::log::get_default()->debug( |
| 36 | "{} using channel:{} debug_mavlink_msg_packet_los:{}", TAG, |
| 37 | m_mavlink_channel, m_debug_mavlink_msg_packet_loss); |
| 38 | } |
| 39 | |
| 40 | void MEndpoint::sendMessages(const std::vector<MavlinkMessage>& messages) { |
| 41 | if (messages.empty()) return; |