Commit 78c665fa authored by roangel's avatar roangel
Browse files

Fixed name of DBChanged topic name in GUI and PPSClient

parent 74908be7
......@@ -39,7 +39,7 @@ MainWindow::MainWindow(int argc, char **argv, QWidget *parent) :
setpointPublisher = nodeHandle.advertise<Setpoint>("SafeControllerService/Setpoint", 1);
setpointSubscriber = nodeHandle.subscribe("SafeControllerService/Setpoint", 1, &MainWindow::setpointCallback, this);
DBChangedSubscriber = nodeHandle.subscribe("my_GUI/DBChanged", 1, &MainWindow::DBChangedCallback, this);
DBChangedSubscriber = nodeHandle.subscribe("/my_GUI/DBChanged", 1, &MainWindow::DBChangedCallback, this);
// communication with PPS Client, just to make it possible to communicate through terminal also we use PPSClient's name
......@@ -88,6 +88,7 @@ void MainWindow::enableGUI()
void MainWindow::DBChangedCallback(const std_msgs::Int32& msg)
{
loadCrazyflieContext();
ROS_INFO("context reloaded in student_GUI");
}
void MainWindow::setpointCallback(const Setpoint& newSetpoint)
......
......@@ -467,7 +467,7 @@ int main(int argc, char* argv[])
safeControllerServiceSetpointPublisher = namespaceNodeHandle.advertise<d_fall_pps::Setpoint>("SafeControllerService/Setpoint", 1);
// subscriber for DBChanged
ros::Subscriber DBChangedSubscriber = namespaceNodeHandle.subscribe("my_GUI/DBChanged", 1, DBChangedCallback);
ros::Subscriber DBChangedSubscriber = namespaceNodeHandle.subscribe("/my_GUI/DBChanged", 1, DBChangedCallback);
//start with safe controller
flying_state = STATE_MOTORS_OFF;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment