async_port: updated latest async_port impl from wrp_sdk

This commit is contained in:
Ruixiang Du
2022-01-06 11:40:18 +08:00
parent 99e6e6aba1
commit 035231a806
9 changed files with 93 additions and 108 deletions

View File

@@ -15,7 +15,7 @@ bool ProtocolDectctor::Connect(std::string can_name) {
can_ = std::make_shared<AsyncCAN>(can_name);
can_->SetReceiveCallback(
std::bind(&ProtocolDectctor::ParseCANFrame, this, std::placeholders::_1));
return can_->StartListening();
return can_->Open();
}
ProtocolVersion ProtocolDectctor::DetectProtocolVersion(uint32_t timeout_sec) {