C++ library for the pan tilt hat and PID

Is there a c++ library available for controlling the pan tilt hat and a PID controller to handle the movement? I’m integrating a Raspberry Pi with this hat in an ROS2 system, and the node (including the PID controller) needs to be written in c++.