Switchover between 2 DACs automatically via HQPlayer for native playback

I have a playlist in Roon with songs of PCM and DSD format. Roon is connected to HQPlayer.
I want to play songs of PCM format on DAC1, and songs of DSD format on DAC 2 automatically. That means: I want no manual tinkering neither in Roon nor in HQPlayer settings during the listening session.
How to achieve this?

DAC1: https://www.diyinhk.com/shop/home/160-pcm1704-r2r-nonoversampling-nos-audio-dac-with-fifo-reclock.html

DAC2: https://www.diyinhk.com/shop/audio-kits/145-768khz32bit-ak4493eq-dac-i2sdsd-input.html with XMOS 768k https://www.diyinhk.com/shop/audio-kits/159-isolated-xmos-768khz-dxd-dsd512dsd1024-high-quality-usb-to-i2sdsd-pcb-type-c.html

The DACs could be connected either to two different NAAs running on two different instances of an Asus Tinkerboard https://www.asus.com/us/Single-Board-Computer/Tinker-Board/ running on the DietPI OS https://dietpi.com/

Alternatively both DACs could be connected to the same NAA (2 different USB ports) on one Tinkerboard only.

Would it be a further option to register 2 different instances of HQPlayer in Roon and have it divert PCM material to HQPlayer instance 1 and DSD material to instance 2 always?

How is this solved in dual DACs containing both an R2R and a sigma delta component?

After some web search this seems to be feasible. This description states, that multiple hqplayer instances can be turned into Roon zones: https://kb.roonlabs.com/HQPlayer
The switchover between the zones shall be made in Roon automatically: an rpi with some scripting could do this e.g.: https://www.youplala.net/tag/roon/

Also the amp’s input selector shall select between the outputs of DAC1 and DAC2.
Again a job for the rpi either by simulating the amp’s infrared remote control, or by controlling the amp’s proprietary control-input. Alternatively if the two DACs and the controller were to be integrated into one common unit, signal relay(s) could be used for demultiplexing the DACs’ outputs.

What should be the trigger signal for the switchover controller?
Is the now playing: PCM / DSD information available via the Roon api in software? I mean without the RAAT SDK which is unavailable for hobbyists?
If no, a hardware solution remains:
the following LED PCB attached to the USB XMOS does the signalling according to the type of music played: https://www.diyinhk.com/shop/audio-kits/85-pcm1702-r2r-isolated-nonoversampling-nos-audio-dac-with-fifo-reclock.html
So both LED PCBs should drive optocouplers instead of LEDs, and feed the rpi with the now playing file type info.

Some switchover delay measurements are needed. If the startup delay of a track is too much, so the beginning is cropped, the rpi script shall add an additional Roon control sequence of pause + sufficient delay + rewind to the beginning of the currently played track + play after the zone switching.
Ideally the outputs are muted during this sequence. If this cannot be achieved by software alone, output mute signal relays shall be added.

Ideas for optimization welcome.

This might be bordering on the #tinkering area