Activating and deactivating avoidance mode

My copter is composed of a MR0 card, a hereflow and I pilot it thanks to the Herelink. I don’t fly with the GPS, so I installed a lidar pointing upwards to avoid obstacles indoors. However, I would like to be able to activate and deactivate the avoidance mode from a button on the radio. How is this possible?

Wiki is your friend , look at function 40
And here