|
@@ -27,6 +27,15 @@ card_location_base::card_location_base(const std::string&type,uint32_t id,uint16
|
|
|
{
|
|
|
select_tool_manage::instance()->create_tool(type,m_sel_tool,m_smo_tool);
|
|
|
m_his_location_card.reset(new location_card(m_id,m_type,cid));
|
|
|
+
|
|
|
+ m_cb_pdoa.set_capacity(5);
|
|
|
+ m_cb_tof.set_capacity(5);
|
|
|
+ m_cb_point.set_capacity(5);
|
|
|
+ for(int index = 0; index < 5; ++index){
|
|
|
+ m_cb_pdoa.push_back(100);
|
|
|
+ m_cb_tof.push_back(0);
|
|
|
+ m_cb_point.push_back(point(0,0));
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
void card_location_base::do_status(int st)
|
|
@@ -106,10 +115,10 @@ void card_location_base::make_his_location(uint64_t t,const point & pt,bool bclo
|
|
|
//坐标点输入业务入口
|
|
|
void card_location_base::on_location(const std::vector<point>&vp,const std::vector<loc_message> &lm )
|
|
|
{
|
|
|
- auto it = lm.cbegin();
|
|
|
-
|
|
|
- loc_point pt;
|
|
|
- if(it != lm.cend()){
|
|
|
+ log_info("[business] card_location_base::on_location");
|
|
|
+ loc_point pt = m_sel_tool->select_solution(vp, lm);
|
|
|
+ pt.y = -pt.y;
|
|
|
+ /*if(it != lm.cend()){
|
|
|
switch((*it).m_loc_type){
|
|
|
case LDT_TOF:
|
|
|
pt = m_sel_tool->select_solution(vp,lm);
|
|
@@ -124,7 +133,7 @@ void card_location_base::on_location(const std::vector<point>&vp,const std::vect
|
|
|
log_info("[pdoa] position's size = %d, x=%.2f, y=%.2f", vp.size(), pt.x, pt.y);
|
|
|
break;
|
|
|
}
|
|
|
- }
|
|
|
+ }*/
|
|
|
|
|
|
auto site_ptr = get_area_tool()->m_site;
|
|
|
int sid = 0;
|
|
@@ -202,7 +211,7 @@ void card_location_base::on_message(zloop<task*>* loop, message_tdoa_locinfo& lo
|
|
|
* */
|
|
|
void card_location_base::on_message(zloop<task*>* loop, message_pdoa_locinfo& loc, bool is_history)
|
|
|
{
|
|
|
- log_info("[pdoa] start calc location");
|
|
|
+ //log_info("[pdoa] start calc location");
|
|
|
m_ct = loc.m_card_ct;
|
|
|
auto site_ptr = sit_list::instance()->get(loc.m_site_id);
|
|
|
if(!site_ptr){
|