mirror of
https://gitlab.fdmci.hva.nl/technische-informatica-sm3/ti-projectten/rooziinuubii79.git
synced 2025-08-03 11:55:00 +00:00
refactor: use dynamic port detection for Kobuki communication setup
This commit is contained in:
@@ -37,8 +37,9 @@ std::string findKobukiPort()
|
||||
|
||||
void setup()
|
||||
{
|
||||
std::string port = findKobukiPort();
|
||||
unsigned char *null_ptr(0);
|
||||
robot.startCommunication("/dev/ttyUSB0", true, null_ptr);
|
||||
robot.startCommunication((port.c_str()), true, null_ptr);
|
||||
// connect mqtt server and sub to commands
|
||||
client.connect();
|
||||
client.subscribe("home/commands");
|
||||
|
Reference in New Issue
Block a user