I've been meaning to get this into a user guide as well, but for the applications processor GPIO, here's an example of setting IO programmatically, in this case GPIOs 46/159:

https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-bind/-/blob/master/src/voxl-bind.c#L58

https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-bind/-/blob/master/src/voxl-bind.c#L147