Raspberry Pi Board Configuration Files

I want to run PX4 on Raspberry Pi 3 like Navio2 but using custom sensors and additional features. Perhaps will modify the code and write few device driver.

I searched and found the board startup and configuration files located in Firmware/boards/px4/raspberrypi/ but could not figure out how and where the Raspberry Pi GPIOs have been configured. Which file configures the pin assignment?

Also looked into Firmware/boards/emlid/navio2/ but could not find the detail.

I specifically need information for the following Raspberry Pi pins

18 GPIO 24 (assigned to RCIO PC10 for Navio2)
29 GPIO 5 (assigned to RCIO PC11 for Navio2)

32 GPIO 12 (assigned to RCIO Clock for Navio2)
33 GPIO 13 (assigned to RCIO Data for Navio2)

35 GPIO 19 (assigned to RCIO MISO for Navio2)
36 GPIO 16 (assigned to RCIO Chip Select for Navio2)
38 GPIO 20 (assigned to RCIO MOSI for Navio2)
40 GPIO 21 (assigned to RCIO SCLK for Navio2)

Im just curious , i have tinkered with a raspberry pi 3 a little just as a desktop, but wanted to what the advantages if any for using the RBpi in conjunction with a pixhawk FC, are there any additional features it will give as far as control or just a project you want to explore

The advantage of Raspberry Pi over STM32…

and the patched Linux can run in real time. The PX4 code runs as a single process and modules as threads. Please correct if I am wrong.
As for the endless possible features you can think of, for example if you need to stream HD video along with telemetry over a wireless link, STM32 will crawl.

A common approach is to have the safety critical flight code on STM32 (because it doesn’t need more and has been proven to work reliably) and then have fancier things like computer vision/obstacle avoidance/streaming HD, etc. on a “companion computer” such as a Raspberry Pi. The two are usually connected via serial and can communicate using MAVLink.

This way you can iterate quickly and try all sorts (even risky) algorithms on the companion while relying on robust flight code on an STM32.