timeout change
This commit is contained in:
parent
0dbccdde44
commit
7c5340cdd6
|
@ -72,10 +72,10 @@ private:
|
|||
int armstate;
|
||||
int barrier;
|
||||
int message_number=0;
|
||||
int no_of_robots=0;
|
||||
uint8_t no_of_robots=0;
|
||||
/*tmp to be corrected*/
|
||||
int no_cnt=0;
|
||||
int old_val=0;
|
||||
uint8_t no_cnt=0;
|
||||
uint8_t old_val=0;
|
||||
std::string bzzfile_name, fcclient_name, armclient, modeclient, rcservice_name,bcfname,dbgfname,out_payload,in_payload,stand_by,xbeesrv_name;
|
||||
std::string stream_client_name;
|
||||
std::string relative_altitude_sub_name;
|
||||
|
|
|
@ -712,9 +712,9 @@ namespace rosbzz_node{
|
|||
old_val=neighbours_pos_map.size()+1;
|
||||
|
||||
}
|
||||
else if(old_val==neighbours_pos_map.size()+1){
|
||||
else if(no_cnt!=0 && old_val==neighbours_pos_map.size()+1){
|
||||
no_cnt++;
|
||||
if(no_cnt==3){
|
||||
if(no_cnt>=4){
|
||||
no_of_robots=neighbours_pos_map.size()+1;
|
||||
no_cnt=0;
|
||||
}
|
||||
|
|
|
@ -86,7 +86,7 @@ function barrier_ready() {
|
|||
#
|
||||
# Executes the barrier
|
||||
#
|
||||
WAIT_TIMEOUT = 100
|
||||
WAIT_TIMEOUT = 200
|
||||
timeW=0
|
||||
function barrier_wait(threshold, transf) {
|
||||
barrier.get(id)
|
||||
|
@ -136,6 +136,7 @@ function land() {
|
|||
uav_land()
|
||||
}
|
||||
else {
|
||||
timeW=0
|
||||
barrier = nil
|
||||
statef=idle
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue