TOF / Range Finder sensor triggering landing gear servo

I’d like to trigger the landing gear servo when either a TOF or Range Finder sensor detects the ground/object at x distance.

Is it possible to map out an obstacle detection reaction to deploy landing gear?

Yes, it is, just write a tiny lua script and it will do that for you

are you using opentx/edgetx radio? then you can do it using the altitude telemetry and a logical switch. just make sure that legs down is set as part of the rc failsafe.