AP_HAL: add simulator for RDS02UF rangefinder

This commit is contained in:
Peter Barker 2023-05-13 11:24:27 +10:00 committed by Peter Barker
parent 96ae4367a2
commit 6943ea59b1
2 changed files with 6 additions and 0 deletions

View File

@ -163,6 +163,9 @@ void SIMState::fdm_input_local(void)
if (leddarone != nullptr) { if (leddarone != nullptr) {
leddarone->update(sitl_model->rangefinder_range()); leddarone->update(sitl_model->rangefinder_range());
} }
if (rds02uf != nullptr) {
rds02uf->update(sitl_model->rangefinder_range());
}
if (USD1_v0 != nullptr) { if (USD1_v0 != nullptr) {
USD1_v0->update(sitl_model->rangefinder_range()); USD1_v0->update(sitl_model->rangefinder_range());
} }

View File

@ -19,6 +19,7 @@
#include <SITL/SIM_RF_Lanbao.h> #include <SITL/SIM_RF_Lanbao.h>
#include <SITL/SIM_RF_BLping.h> #include <SITL/SIM_RF_BLping.h>
#include <SITL/SIM_RF_LeddarOne.h> #include <SITL/SIM_RF_LeddarOne.h>
#include <SITL/SIM_RF_RDS02UF.h>
#include <SITL/SIM_RF_USD1_v0.h> #include <SITL/SIM_RF_USD1_v0.h>
#include <SITL/SIM_RF_USD1_v1.h> #include <SITL/SIM_RF_USD1_v1.h>
#include <SITL/SIM_RF_MaxsonarSerialLV.h> #include <SITL/SIM_RF_MaxsonarSerialLV.h>
@ -139,6 +140,8 @@ private:
SITL::RF_BLping *blping; SITL::RF_BLping *blping;
// simulated LeddarOne rangefinder: // simulated LeddarOne rangefinder:
SITL::RF_LeddarOne *leddarone; SITL::RF_LeddarOne *leddarone;
// simulated RDS02UF rangefinder:
SITL::RF_RDS02UF *rds02uf;
// simulated USD1 v0 rangefinder: // simulated USD1 v0 rangefinder:
SITL::RF_USD1_v0 *USD1_v0; SITL::RF_USD1_v0 *USD1_v0;
// simulated USD1 v1 rangefinder: // simulated USD1 v1 rangefinder: