File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -68,13 +68,20 @@ void ExampleRobotWrapper::initializeRobotWithDashboard()
6868
6969void ExampleRobotWrapper::handleRobotProgramState (bool program_running)
7070{
71+ // Print the text in green so we see it better
7172 std::cout << " \033 [1;32mProgram running: " << std::boolalpha << program_running << " \033 [0m\n " << std::endl;
72- program_running_ = program_running;
7373 if (program_running)
7474 {
7575 std::lock_guard<std::mutex> lk (program_running_mutex_);
76+ program_running_ = program_running;
7677 program_running_cv_.notify_one ();
7778 }
79+ else
80+ {
81+ std::lock_guard<std::mutex> lk (program_not_running_mutex_);
82+ program_running_ = program_running;
83+ program_not_running_cv_.notify_one ();
84+ }
7885}
7986
8087void ExampleRobotWrapper::startRTDECommununication (const bool consume_data)
You can’t perform that action at this time.
0 commit comments