diff --git a/CMakeLists.txt b/CMakeLists.txt index a86e2a9..fd6f57a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,7 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) add_executable(z1_ctrl main.cpp) target_link_libraries(z1_ctrl libZ1_${CMAKE_HOST_SYSTEM_PROCESSOR}.so) -find_package(gazebo) -if(${gazebo_FOUND}) +find_package(catkin) +if(${catkin_FOUND}) add_subdirectory(sim) endif() \ No newline at end of file diff --git a/include/FSM/State_TeachRepeat.h b/include/FSM/State_TeachRepeat.h index 9d816bf..b366a91 100755 --- a/include/FSM/State_TeachRepeat.h +++ b/include/FSM/State_TeachRepeat.h @@ -18,7 +18,6 @@ private: bool _reachedStart = false; bool _finishedRepeat = false; size_t _index = 0; - size_t _indexPast; Vec6 _trajStartQ, _trajStartQd; double _trajStartGripperQ, _trajStartGripperQd; diff --git a/include/control/armSDK.h b/include/control/armSDK.h index 194b7ec..6b534c2 100644 --- a/include/control/armSDK.h +++ b/include/control/armSDK.h @@ -7,7 +7,7 @@ class ARMSDK : public CmdPanel{ public: ARMSDK(std::vector events, - EmptyAction emptyAction, const char* IP, uint port, double dt = 0.002); + EmptyAction emptyAction, const char* sdkIP, uint sdkPort, uint ownPort, double dt = 0.002); ~ARMSDK(); SendCmd getSendCmd(); int getState(size_t channelID = 0); diff --git a/include/message/LowlevelState.h b/include/message/LowlevelState.h index 935a47d..f25be08 100755 --- a/include/message/LowlevelState.h +++ b/include/message/LowlevelState.h @@ -53,7 +53,7 @@ public: double getGripperTauFiltered(); private: size_t _dof = 6; - int temporatureLimit = 80.0;// centigrade + int temporatureLimit = 80;// centigrade std::vector _isMotorConnectedCnt; std::vector _isMotorLostConnection; }; diff --git a/lib/libZ1_aarch64.so b/lib/libZ1_aarch64.so index afd061f..1932d53 100755 Binary files a/lib/libZ1_aarch64.so and b/lib/libZ1_aarch64.so differ diff --git a/lib/libZ1_x86_64.so b/lib/libZ1_x86_64.so index 304231e..27c3983 100755 Binary files a/lib/libZ1_x86_64.so and b/lib/libZ1_x86_64.so differ diff --git a/main.cpp b/main.cpp index 33b59d1..82243ba 100644 --- a/main.cpp +++ b/main.cpp @@ -45,7 +45,7 @@ int main(int argc, char **argv){ ctrlComp->ioInter = new IOUDP(ctrlComp->ctrl_IP.c_str(), ctrlComp->ctrl_port); ctrlComp->geneObj(); if(ctrlComp->ctrl == Control::SDK){ - ctrlComp->cmdPanel = new ARMSDK(events, emptyAction, "127.0.0.1", 8072, 0.002); + ctrlComp->cmdPanel = new ARMSDK(events, emptyAction, "127.0.0.1", 8072, 8071, 0.002); }else if(ctrlComp->ctrl == Control::KEYBOARD){ events.push_back(new StateAction("`", (int)ArmFSMStateName::BACKTOSTART)); events.push_back(new StateAction("1", (int)ArmFSMStateName::PASSIVE)); diff --git a/sim/sim_ctrl.cpp b/sim/sim_ctrl.cpp index 9133047..fe00e93 100644 --- a/sim/sim_ctrl.cpp +++ b/sim/sim_ctrl.cpp @@ -48,7 +48,7 @@ int main(int argc, char **argv){ ctrlComp->ioInter = new IOROS(); ctrlComp->geneObj(); if(ctrlComp->ctrl == Control::SDK){ - ctrlComp->cmdPanel = new ARMSDK(events, emptyAction, "127.0.0.1", 8072, 0.002); + ctrlComp->cmdPanel = new ARMSDK(events, emptyAction, "127.0.0.1", 8072, 8071, 0.002); }else if(ctrlComp->ctrl == Control::KEYBOARD){ events.push_back(new StateAction("`", (int)ArmFSMStateName::BACKTOSTART)); events.push_back(new StateAction("1", (int)ArmFSMStateName::PASSIVE));