Error in Unit 2 in Advanced Modern C++

I don’t understand this build error in the odom_listener program.

Hi @knair56,

the error message says that on the odom_listener.cpp there is a call to an undefined function called display_pos inside the odomCallback function.

Maybe you created a method called display_pos that has to be called with instance.display_pos(x, y) and you are calling it as if it was a function, like display_pos(x,y).

Or maybe it is defined correctly, but you didn’t link the library (didn’t add the correct dependencies) in the CMakeLists.txt file.

Please let us know if you managed to make it work.

I didn’t have any luck. I think I may have missed a step or few steps in the previous unit. Is there a way I can reset course progress?

Hi @knair56,

to reset your workspace, you can just remove the devel and build folders and compile the workspace again:

cd ~/catkin_ws

rm -rf devel build


source devel/setup.bash

If what you want to reset is your code, you can just download to your local computer the src folder (just in case you want a backup), and then remove the content of the src folder.

Then you will have a really clean environment.

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.