修改避障日志
This commit is contained in:
@@ -247,7 +247,9 @@ void VisionService::finishAvoidance(int code, const QJsonObject &result)
|
||||
if (!m_avoidanceDiscarded && m_avoidanceEnabled && !m_shuttingDown && !m_releasing) {
|
||||
const double distance = result.value("distance_mm").toDouble();
|
||||
const bool warning = distance < m_config.warningDistanceMm;
|
||||
if (code != HVG_OK) {
|
||||
if (code == HVG_DISTANCE_UNKNOWN) {
|
||||
m_avoidanceLogKey.clear();
|
||||
} else if (code != HVG_OK) {
|
||||
logAvoidance("ERROR", QString("避障检测失败(code=%1):%2")
|
||||
.arg(code).arg(result.value("message").toString()));
|
||||
if (code == HVG_NOT_READY || code == HVG_DEVICE_ERROR || code == HVG_CONFIG_ERROR)
|
||||
|
||||
Reference in New Issue
Block a user