Skip to content

Commit

Permalink
[Ninja][Nav] Debug of desire shape update during disassembly process.
Browse files Browse the repository at this point in the history
  • Loading branch information
sugihara-16 committed Nov 21, 2024
1 parent df1cdc1 commit 226a0ec
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions robots/ninja/include/ninja/ninja_navigation.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,8 @@ namespace aerial_robot_navigation
double com_roll_change_thresh_;
double com_pitch_change_thresh_;
double com_yaw_change_thresh_;

bool disassembly_flag_;

};
template<> inline KDL::Frame NinjaNavigator::getCom2Base()
Expand Down
3 changes: 2 additions & 1 deletion robots/ninja/src/ninja_navigation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ void NinjaNavigator::updateEntSysState()
}
if(control_flag_){
reconfig_flag_ = (pre_assembled_modules_ != module_num_) ? true : false;
disassembly_flag_ = (module_num_ < pre_assembled_modules_) ? true : false;
pre_assembled_modules_ = module_num_;
}
}
Expand Down Expand Up @@ -402,7 +403,7 @@ void NinjaNavigator::convertTargetPosFromCoG2CoM()
return;
} else if((!pre_assembled_ && current_assembled) || (current_assembled && reconfig_flag)){ //assembly or reconfig process
setTargetCoMPoseFromCurrState();
setTargetJointPosFromCurrState();
if(!disassembly_flag_) setTargetJointPosFromCurrState(); //bad implementation
ROS_INFO("switched");
pre_assembled_ = current_assembled;
return;
Expand Down

0 comments on commit 226a0ec

Please sign in to comment.