mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-20 12:59:05 +08:00
ll40ls: fixed typo errors.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
This commit is contained in:
parent
6a8b25a1b9
commit
5fd483dbf8
@ -128,17 +128,17 @@ LidarLiteI2C::probe()
|
||||
|
||||
set_device_address(addresses[i]);
|
||||
|
||||
/*
|
||||
The probing is divided in two cases. One to detect v1, v2 and v3 and one to
|
||||
detect v3HP. The reason for this is that registers are not consistent
|
||||
between different versions. The v3HP doesn't have the HW VERSION (or at least no version is specified)
|
||||
while v1, v2 and some v3 don't have the unit id register.
|
||||
It would be better if we had a proper WHOAMI register.
|
||||
*/
|
||||
/**
|
||||
* The probing is divided into different cases. One to detect v2, one for v3 and v1 and one for v3HP.
|
||||
* The reason for this is that registers are not consistent between different versions.
|
||||
* The v3HP doesn't have the HW VERSION (or at least no version is specified),
|
||||
* v1 and v3 don't have the unit id register while v2 has both.
|
||||
* It would be better if we had a proper WHOAMI register.
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
check for hw and sw versions for v1, v2 and v3
|
||||
/**
|
||||
* check for hw and sw versions for v1, v2 and v3
|
||||
*/
|
||||
if ((read_reg(LL40LS_HW_VERSION, _hw_version) == OK) &&
|
||||
(read_reg(LL40LS_SW_VERSION, _sw_version) == OK)) {
|
||||
@ -397,8 +397,8 @@ int LidarLiteI2C::collect()
|
||||
|
||||
// We detect if V3HP is being used
|
||||
if (_is_V3hp) {
|
||||
signal_min = LL40LS_SIGNAL_STRENGH_MIN_V3HP;
|
||||
signal_max = LL40LS_SIGNAL_STRENGH_MAX_V3HP;
|
||||
signal_min = LL40LS_SIGNAL_STRENGTH_MIN_V3HP;
|
||||
signal_max = LL40LS_SIGNAL_STRENGTH_MAX_V3HP;
|
||||
signal_value = ll40ls_signal_strength;
|
||||
|
||||
} else {
|
||||
@ -414,7 +414,7 @@ int LidarLiteI2C::collect()
|
||||
read before it is ready, so only consider it
|
||||
an error if more than 100ms has elapsed.
|
||||
*/
|
||||
PX4_INFO("peak strenght read failed");
|
||||
PX4_INFO("peak strength read failed");
|
||||
|
||||
DEVICE_DEBUG("error reading peak strength from sensor: %d", ret);
|
||||
perf_count(_comms_errors);
|
||||
|
||||
@ -67,8 +67,8 @@ static constexpr uint8_t LL40LS_UNIT_ID_LOW = 0x17;
|
||||
|
||||
static constexpr uint8_t LL40LS_SIG_COUNT_VAL_REG = 0x02; /* Maximum acquisition count register */
|
||||
static constexpr uint8_t LL40LS_SIG_COUNT_VAL_MAX = 0xFF; /* Maximum acquisition count max value */
|
||||
static constexpr int LL40LS_SIGNAL_STRENGH_MIN_V3HP = 70; // Min signal strength for V3HP
|
||||
static constexpr int LL40LS_SIGNAL_STRENGH_MAX_V3HP = 255; // Max signal strength for V3HP
|
||||
static constexpr int LL40LS_SIGNAL_STRENGTH_MIN_V3HP = 70; // Min signal strength for V3HP
|
||||
static constexpr int LL40LS_SIGNAL_STRENGTH_MAX_V3HP = 255; // Max signal strength for V3HP
|
||||
|
||||
static constexpr int LL40LS_SIGNAL_STRENGTH_LOW =
|
||||
24; // Minimum (relative) signal strength value for accepting a measurement
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user