|
|
@@ -3077,10 +3077,10 @@ void CResistAlarmMng::ThreadProcMove(DWORD_PTR param)
|
|
|
ii = map2.find(it->tmEnd - 1);
|
|
|
ASSERT(ii != map2.end());
|
|
|
last_value = ii->second.end_val;
|
|
|
- auto dif = abs(last_value - first_value);
|
|
|
+ auto dif = last_value - first_value;
|
|
|
auto strLog = fmt::format("[摩擦力判断]{} first:{} last:{} dif:{}",
|
|
|
CTime(it->time / 1000).Format("%Y-%m-%d %H:%M:%S"), first_value, last_value, dif);
|
|
|
- if (dif > 1000)
|
|
|
+ if (dif > 1000 || dif < -1000)
|
|
|
{
|
|
|
SPDLOG_INFO(strLog);
|
|
|
if (it->tmEnd - it->tmStart >= 4)
|
|
|
@@ -3088,8 +3088,9 @@ void CResistAlarmMng::ThreadProcMove(DWORD_PTR param)
|
|
|
FRICTION_RESIST info;
|
|
|
info.peak_time = it->time;
|
|
|
info.peak_val = it->val;
|
|
|
- info.show_time = it->time; //暂时赋值峰值
|
|
|
- info.show_val = last_value;
|
|
|
+ info.show_time = ii->first * 1000;
|
|
|
+ info.show_val = dif; //稳态值显示差值
|
|
|
+ info.curr_val = last_value; //显示的位置
|
|
|
info.tmStart = it->tmStart;
|
|
|
info.tmEnd = it->tmEnd;
|
|
|
info.t = strLog;
|
|
|
@@ -3309,7 +3310,7 @@ void CResistAlarmMng::ThreadProcMove(DWORD_PTR param)
|
|
|
|
|
|
for (auto& it : lstFriction)
|
|
|
{
|
|
|
- CResistAlarmMng::InsertToDBByMove(mo, mp, it.peak_time, it.tmStart, it.tmEnd, it.peak_val, it.bUpOrDown == eUpOrDownInfo::UOD_DOWN ? -it.show_val :it.show_val, 2,
|
|
|
+ CResistAlarmMng::InsertToDBByMove(mo, mp, it.show_time, it.tmStart, it.tmEnd, it.curr_val, it.show_val, 2,
|
|
|
(uint8_t)eDaoChaPosi::DCP_UNKNOWN, (uint8_t)ePowerName::PN_FRICTION, fmt::format("稳态值:{}", it.show_val));
|
|
|
|
|
|
//CMonitorObjectMng::Instance()->UpdateZZJEPOS(mo + "." + mp, DAOCHA_POSITION::MP_QUARTO); //四开
|