Browse Source

///人卡(加速度状态),其值就是0和1,掘进机和采煤机,其值就是0~255,车辆,其值就需要乘以0.01,用于表示加速度值
double m_acc =0;

daiyueteng 6 years ago
parent
commit
eefa110660
3 changed files with 4 additions and 1 deletions
  1. 1 0
      card_base.cpp
  2. 2 0
      card_base.h
  3. 1 1
      card_car.h

+ 1 - 0
card_base.cpp

@@ -39,6 +39,7 @@ void card_location_base::on_location(const std::vector<point>&vp,const std::vect
 		//m.type=m_type;m.x=(int)x;m.y=(int)y;m.cmd=CMD_HANDLE;m.cardid=m_type<<32|m_id;
 		//cardMgr::instance()->tryPut(m);
 		double acc = lm[0].m_acc;
+        m_acc = lm[0].m_acc;
 		log_info("useful:card_id:%d,ct:%d,timestamp:%llu, loc_point,x:%.2f,y:%.2f acc:%.2f",m_id,m_ct,m_time,pt.x,pt.y,acc);
 		do_business(lm.front().m_sit, pt, acc);
 	}

+ 2 - 0
card_base.h

@@ -63,6 +63,8 @@ struct card:point
 	int32_t  m_deptid;			//部门编号
 	int32_t  m_level_id;		//部门级别
 	int m_biz_stat;
+    ///人卡(加速度状态),其值就是0和1,掘进机和采煤机,其值就是0~255,车辆,其值就需要乘以0.01,用于表示加速度值
+    double m_acc =0;
 };
 
 struct card_location_base:card,std::enable_shared_from_this<card_location_base>

+ 1 - 1
card_car.h

@@ -19,7 +19,7 @@ struct car:card_location_base,card_area
 {
 	int m_vehicle_category_id=0;
     int m_vehicle_type_id=0;
-	double m_acc =0;
+    //double m_acc =0;
 
 public: