AP_Scripting: set timestamp for received messages

This commit is contained in:
bugobliterator 2023-05-14 16:26:43 +10:00 committed by Andrew Tridgell
parent 28d49834c0
commit f9edc1c37b

View File

@ -343,10 +343,9 @@ void AP_Scripting::handle_message(const mavlink_message_t &msg, const mavlink_ch
return; return;
} }
struct mavlink_msg data {msg, chan}; struct mavlink_msg data {msg, chan, AP_HAL::millis()};
WITH_SEMAPHORE(mavlink_data.sem); WITH_SEMAPHORE(mavlink_data.sem);
for (uint16_t i = 0; i < mavlink_data.accept_msg_ids_size; i++) { for (uint16_t i = 0; i < mavlink_data.accept_msg_ids_size; i++) {
if (mavlink_data.accept_msg_ids[i] == -1) { if (mavlink_data.accept_msg_ids[i] == -1) {
return; return;