Where's the leo_system.py script located?

I need to modify the leo_system script to publish on the relay topics added by the fw. This would prevent the headlights I’ve added to drain the batteries.

I can’t find the leo_system.py script file.

~$ roscd leo_bringup/
/opt/ros/noetic/share/leo_bringup$ ls
camera_info  cmake  config  launch  package.xml

What’s the best approach to modify it?

Nevermind, I found the file it’s at /opt/ros/noetic/lib/leo_bringup/leo_system

I highly advise against modifying the files under /opt/ros because these are distribution files and can be overwritten after updating the package. Instead, if you want to have a modified version of core leo package, create an overlay catkin workspace. We have explained how to do this here:

You can also write your own node and make it start together with other nodes on boot.

1 Like