mirror of
https://github.com/westonrobot/ugv_sdk
synced 2023-04-08 06:32:14 +08:00
renamed GetProtocolVersion() to GetParserProtocolVersion()
This commit is contained in:
@@ -49,7 +49,7 @@ int main(int argc, char **argv) {
|
||||
|
||||
bunker->Connect(device_name);
|
||||
|
||||
if (bunker->GetProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
if (bunker->GetParserProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
bunker->EnableCommandedMode();
|
||||
std::cout << "Protocol version 2" << std::endl;
|
||||
} else {
|
||||
|
||||
@@ -49,7 +49,7 @@ int main(int argc, char **argv) {
|
||||
|
||||
hunter->Connect(device_name);
|
||||
|
||||
if (hunter->GetProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
if (hunter->GetParserProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
hunter->EnableCommandedMode();
|
||||
std::cout << "Protocol version 2" << std::endl;
|
||||
} else {
|
||||
@@ -78,7 +78,7 @@ int main(int argc, char **argv) {
|
||||
<< state.motion_state.angular_velocity << std::endl;
|
||||
|
||||
auto actuator = hunter->GetActuatorState();
|
||||
if (hunter->GetProtocolVersion() == ProtocolVersion::AGX_V1) {
|
||||
if (hunter->GetParserProtocolVersion() == ProtocolVersion::AGX_V1) {
|
||||
for (int i = 0; i < 3; ++i) {
|
||||
printf("motor %d: current %f, rpm %d, driver temp %f, motor temp %f\n",
|
||||
actuator.actuator_state[i].motor_id,
|
||||
|
||||
@@ -49,7 +49,7 @@ int main(int argc, char **argv) {
|
||||
|
||||
scout->Connect(device_name);
|
||||
|
||||
if (scout->GetProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
if (scout->GetParserProtocolVersion() == ProtocolVersion::AGX_V2) {
|
||||
scout->EnableCommandedMode();
|
||||
std::cout << "Protocol version 2" << std::endl;
|
||||
} else {
|
||||
@@ -95,7 +95,7 @@ int main(int argc, char **argv) {
|
||||
<< state.motion_state.angular_velocity << std::endl;
|
||||
|
||||
auto actuator = scout->GetActuatorState();
|
||||
if (scout->GetProtocolVersion() == ProtocolVersion::AGX_V1) {
|
||||
if (scout->GetParserProtocolVersion() == ProtocolVersion::AGX_V1) {
|
||||
for (int i = 0; i < 4; ++i) {
|
||||
printf("motor %d: current %f, rpm %d, driver temp %f, motor temp %f\n",
|
||||
actuator.actuator_state[i].motor_id,
|
||||
|
||||
Reference in New Issue
Block a user