From 29ac65c44db00d0879856c98b57ddb5a7e896f36 Mon Sep 17 00:00:00 2001 From: Abhay Deshpande Date: Thu, 28 Sep 2023 19:21:25 -0700 Subject: [PATCH] Fix sim connection (#266) --- src/Rover.cpp | 2 +- src/world_interface/simulator_interface.cpp | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Rover.cpp b/src/Rover.cpp index c768e870b..075339690 100644 --- a/src/Rover.cpp +++ b/src/Rover.cpp @@ -132,8 +132,8 @@ void parseCommandLine(int argc, char** argv) { int main(int argc, char** argv) { parseCommandLine(argc, argv); Globals::AUTONOMOUS = false; - robot::world_interface_init(); Globals::websocketServer.start(); + robot::world_interface_init(); auto mcProto = std::make_unique(Globals::websocketServer); Globals::websocketServer.addProtocol(std::move(mcProto)); rospub::init(); diff --git a/src/world_interface/simulator_interface.cpp b/src/world_interface/simulator_interface.cpp index 5152bd0d9..f469f7c10 100644 --- a/src/world_interface/simulator_interface.cpp +++ b/src/world_interface/simulator_interface.cpp @@ -39,7 +39,8 @@ const std::map motorNameMap = { {motorid_t::elbow, "elbow"}, {motorid_t::forearm, "forearm"}, {motorid_t::wrist, "wrist"}, - {motorid_t::hand, "hand"}}; + {motorid_t::hand, "hand"}, + {motorid_t::activeSuspension, "activeSuspension"}}; DataPoint lastAttitude; std::mutex attitudeMutex;