Forum Discussion
grumpyfurey
3 years agoExplorer
Quest Link Automation
Hi! 👋 I have a Unity VR application added to a Windows PC's Oculus application displaying on a Meta Quest 2 headset via Quest Link cable. The Unity application runs all day in a Museum exhibition e...
- 3 years ago
Hi again! 👋
mreimer: Thanks for sharing that link. It presented the same adb solution I ended up finding elsewhere, but implemented with additional clever plug and play automation I found really interesting. Cheers!
TL;DR: With adb installed, via the command line run:
adb shell am start -S com.oculus.xrstreamingclient/.MainActivityHere's some more context about my search for the answer, plus follow up frustrations I'm still keen to solve.
As instructed by Oculus support I installed the Windows Meta Quest Developer Hub (MQDH) application. With MQDH running and the Quest 2 headset connected to the PC via Quest Link cable, opening the MQDH "Device Manager" section I saw the "Meta Quest Link" action presented in its "Device Actions" panel:
Enabling the action connected the headset and PC without having to manually go through their setup menus:
This felt like a great win. Bypassing both headset and PC menus with a single click? Woohoo!
Unfortunately when you subsequently disable the setting, while the headset and PC Quest Link connection successfully disconnects (sending you back to the Oculus home environment from the Quest Link environment), the headset also unmounts from the PC, meaning you can't re-enable the setting via the "Meta Quest Link" action again without manually removing then reconnecting the Quest Link cable:
Referring back to Oculus support's original instructions regarding custom commands, I searched through these forums until I found the following comment:
Custom Command Solution for ODH to create a toggle off/on Quest Link outside the device. Start Link (button 1): adb shell am start -S com.oculus.xrstreamingclient/.MainActivity Stop Link (button 2): adb shell am force-stop com.oculus.xrstreamingclientVia MQDH's "Custom Commands" panel, I added both of the adb commands found in the above comment:
Re-establishing the headset and PC cable connection, I ran my "Start Quest Link" command:
The headset and PC connected without having to manually go through their setup menus which was the same successful outcome as running the previously mentioned "Meta Quest Link" action, and I now had a command that could run directly via the command line (custom commands are just console commands) which means I could theoretically wrap it in a script file to run whenever I needed it to. Woohoo!
I then ran my "Stop Quest Link" command:
Unfortunately, while the headset and PC Quest Link connection successfully disconnected, the headset once again unmounted from the PC, meaning I couldn't successfully re-run my "Start Quest Link" command without manually removing then reconnecting the Quest Link cable (same problem as the MQDH "Meta Quest Link" action).
When re-running my "Start Quest Link" command, the Quest Link environment would begin to boot then after a short while I'd be pushed back to the Oculus home environment where I'd see a "PC Disconnected" dialog:
I'm guessing under the hood the MQDH "Meta Quest Link" action is probably using those same adb commands I found elsewhere in this forum. Both MQDH action and adb commands enable the Quest Link connection seamlessly, but when disabling the connection they also unmount the headset leaving users to manually unplug then reconnect cables to re-enable Quest Link again.
Notably, if you disable your Quest Link connection from within the headset experience…
Quest Link Menu → Disable Quest Link → Disable
…both MQDH "Meta Quest Link" action and custom commands can be re-enabled without having to manually reconnect cables.
Alas, automated re-enabling of the Quest Link connection eludes me, but my original issue is answered so I'm marking my question as solved.
Thanks for listening, and hope this helps someone facing similar issues in the future.
🤓✌️
FunkyTanuki
3 years agoRetired Support
Hey there, this sounds like a very interesting idea. While I don't have any info regarding this specifically, I hope someone here in the community can help you further on this. Good luck!
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 21 days ago
- 2 months ago
- 2 years ago