Request new AFS capability to match easa regulations

Hello,

I want to make LUA script that put relay pin to zero when fence is breached or better when fence is breached from several meters.

I check the ardupilot_ap_scripting_binding generator:

[ardupilot/libraries/AP_Scripting/generator/description/bindings.desc at master · ArduPilot/ardupilot (github.com)]

and I don’t found anything about the fence status.

There is possibility to write lua script that take care from the fence breach status ?

I you have ideas about how to get fence status on LUA please share it.

Thank you so much for your help

For fence breaches, you can use Advance Failsafe.
You can set the AFS_TERM_PIN for the PIN (although you will need an inverter since it goes high at termination)
If you don’t set the AFS_TERM_ACTION to 42/43 then the AFS actions (crashing the plane deliberately or qland) will not be invoked, but the PIN you set will be switched to high.

If you need a scripting solution, which includes distance from the fence you will need custom firmware, where the relevant functions are bound to Lua. For that either get familiar with the source code and the dev environment, or contact somebody from the list of partners Commercial Support and Tools — Mission Planner documentation who will do it for you for a modest fee.

1 Like

Thank you so much for this reply

Maybe this below can be added on next updates ?

the afs capability to trigger the pin high or low when drone breach the fence at more than x meters, just 2 parameters more.

Do you think this can be added for the whole community soonly in minor release ?

This will permit to match with the easa sts02 c5 and c6 uav types regulations.

Thank you so much for your help and following.

Perhaps I read wrong, but Cat5 and Cat6 does not state that “providing means to prevent the operation volume” means that it should do a flight termination. I think the current fence implementation alongside with a remote pilot operated termination will satisfy the requirements of Cat5 and Cat6.

1 Like