Connecting a Raspberry Pi to QGC

I want to operate a Raspberry Pi aboard an UAV for atmospheric measurements.
It is a DJI drone which will be operated with the DJI software.

I’m an absolute newbie in this field and have no idea if the following is easily possible with QGC:

  1. Send down measurement data (e.g. CO2 concentration) from the Raspberry to QGC via MAVLINK and SIK Radio (the amount of data is tiny; few numbers per second)
  2. Show/Display the data during flight in QGC
  3. Use QGC to send commands like start/stop measurements to the Raspberry

Has anyone experience with this or could link me to some useful demo code (Python preferred) from which I can start?

Many thanks in advance for any helpful comment!
Cheers Max