Oculus Quest and Building for Unity — Oculus
Welcome to the Oculus Developer Forums!

Your participation on the forum is subject to the Oculus Code of Conduct.

In general, please be respectful and kind. If you violate the Oculus Code of Conduct, your access to the developer forums may be revoked at the discretion of Oculus staff.

Oculus Quest and Building for Unity

NemoKradNemoKrad Posts: 4
Hi all,

Forgive me if this has been raided before, but I did a search here and on the web and found nothing that would help. 

Bottom line is, I have just got my self a Quest, and love it, but now would like to deploy something of my own to it. I have it set in developer mode, I can see from running adb.exe devices that it is there and accessible. I have updated my Android SDK and in my test Unity project, installed the Oculus samples. I am trying to build and deploy the AvatarGrab scene.

Plug in my Quest, and do a Build and run, first I get this pop up

Now, as I say, I have updated my SDK(s), after getting this error again and again I pretty much installed them all :/

Unity is configured for the right folder too

And I have the project set like this (was told to use 19 as a friend who has released a game for the quest used the same):

So, I continue telling Unity to use the highest it can find, I gets to "checking android devices" and then errors with this:

Can anyone see what I am doing wrong here? I know I must be doing something daft right?

Thanks for taking a look at this, and I hope you can point me in the right direction :)


  • TsuyoiRaionTsuyoiRaion Posts: 1
    1) Unity requires a very specific version of android SDK to build to android, even if it prompts you to update to the latest version, DON'T

    2) You don't have the NDK installed and assigned, something you should always do if building to mobile platforms.

    3) Don't use embedded JDK, install it manually and use the appropriate version.

    Versions for each SDK, NDK & JDK for building to android will make the difference if it successfully builds or fails. Something that's not quiet apparent nor indicated by the engine itself and something i spent quiet some time figuring out myself after many trials and errors.

    But once you do the setup 1 time, it should work for any other versions of unity and builds for your games (Y)
  • simondarksidejsimondarksidej Posts: 1
    One of the best guides I've seen around is this one by the Skarred Ghost

    Main points to recognise when using any Android device from Unity:
    Hope that helps.
  • NemoKradNemoKrad Posts: 4
    Hi both, thanks for the responses :)
    • ADB is installed as I can run it and see my device is available. Going to re install off that link.
    • Now I have install a load of Android SDK stuff, how o I know what I should be removing? What is the Unity Android SDK?
    • My device is unlocked, done from the paired app, and confirmed in the device too
    • As I say, I can see it with ADB.

  • NemoKradNemoKrad Posts: 4
    OK, still have the error when checking for compatible Android devices....
  • lsummerslsummers Posts: 25 Oculus Start Member
    edited June 15
    This is a fun issue I hit last week too.

    #1 - Unity is now requiring an updated version of Android SDK Tools.  Unfortunately, this isn't compatible with what most of us have installed (the stand alone GUI android SDK).  That was deprecated by Google.  There are work arounds, but the lazy fix is to uninstall, and reinstall, by installing the full Android Studio (which is now the only way to access the Android SDK GUI).  After that, it still won't work fully however, as Unity has its Build script using the new Android SDK Tools 26.x. but Build and Run is using Android SDK Tools 25.x.  Smart move by Unity :P. Means if you continue on that path you will need to manually install the APKs.

    #2 - try doing a "Build" only, and manually installing the APK using ADB. 

    From there, you could probably fix the Unity built script to install the APK properly.  Or just manually install the APK each time you do a build. 

    Ugly, I know, and more importantly this likely could break other versions of Unity you have installed on their build methods.  But yeah its a known Unity issue that the Unity team may, or may never, get around to fixing.
  • NemoKradNemoKrad Posts: 4
    I installed the latest build of Unity, and it deploys now. But  my apps run, then just close, so still have an issue, but deploying now at least :)
Sign In or Register to comment.