MAVROS_EXTRA- Distance_sensor vs range finder. Minimal example

Hi all,
Let say, I have an external Lidar sensor connected to an offboard computer, and I want to send the distance to the pixhawk connected through TELEM2 using ROS.

I found two mavros_plugin: distance_sensor and rangefinder as in here:

  1. I am not sure what are the difference between them? which one should I use to send the message to the Pixhawk?
  2. Really appreciate if you can point me to a minimal example code of using these plugins.

Thank you.