Using Overbridge, you won’t need any audio cables for the Analog Keys (all audio can be streamed over USB) so no inputs used on the Qu.
Similarly, you wouldn’t need to connect any audio cables from the Heat if you got one.
With the Rytm, you might want to connect the main L/R to the mixer as only 8 voices can be streamed via Overbridge. So I stream the 8 drum voices with Overbridge and the main stereo (carrying the FX) as audio to the mixer.
The Machinedrum obviously doesn’t use Overbridge, so you could then connect the main outs and the 4 individual outs.
All told that would use 8 of the 16 mono inputs on the Qu. So you’d still have 8 free mono inputs plus 3 stereo inputs for future gear.