debugging
This commit is contained in:
parent
7858d6ef12
commit
1be83c8f93
@ -76,7 +76,7 @@ bool Robotiq2fSocketAdapter::sendCommand(const std::string& cmd) {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string Robotiq2fSocketAdapter::receiveResponse(int timeout_ms=2000) {
|
std::string Robotiq2fSocketAdapter::receiveResponse(int timeout_ms) {
|
||||||
std::lock_guard<std::mutex> lock(socketMutex_);
|
std::lock_guard<std::mutex> lock(socketMutex_);
|
||||||
if (*sockfd_ < 0) {
|
if (*sockfd_ < 0) {
|
||||||
std::cerr << "Attempted to receive response on a disconnected socket.\n";
|
std::cerr << "Attempted to receive response on a disconnected socket.\n";
|
||||||
@ -342,7 +342,7 @@ std::tuple<int, ObjectStatus> Robotiq2fSocketAdapter::move_and_wait_for_pos(int
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Robotiq2fSocketAdapter::auto_calibrate(bool log=true) {
|
void Robotiq2fSocketAdapter::auto_calibrate(bool log) {
|
||||||
// Open in case we are holding an object
|
// Open in case we are holding an object
|
||||||
std::tuple<int, ObjectStatus> result = move_and_wait_for_pos(open_position_, 64, 1);
|
std::tuple<int, ObjectStatus> result = move_and_wait_for_pos(open_position_, 64, 1);
|
||||||
if (std::get<1>(result) != ObjectStatus::AT_DEST) {
|
if (std::get<1>(result) != ObjectStatus::AT_DEST) {
|
||||||
|
Loading…
Reference in New Issue
Block a user