Trouble installing and running an app from adb

SOLVED
mgstauffalt
Settler

Trouble installing and running an app from adb

I tried installing an apk that was presented as running on Focus by Finch developers. I used 'adb install <apk path>', which came back with 'success', but I can't find it in the Focus main UI library menu item even after a restart. If I run 'adb install' again, it says error - already installed.

 

I've found the app listed on the Focus via the UI under Settings | More Settings | Apps, where I enabled the only permission option, for 'Storage'. But I can't launch it from there, and it's still not showing in the Focus. Any suggestions?

 

Thanks

Vive Staff

Re: Trouble installing and running an app from adb

Hi @mgstauffalt,

 

What kind of apps do you install on Focus?

In currently design, only app built by Wave SDK can run on Focus otherwise it may just close to see nothing.

Is this the case you mentioned?

Thanks.

mgstauffalt
Settler

Re: Trouble installing and running an app from adb

Hi Tony. I'm building Unity apps using the Finch SDK for their 6dof Shift controllers. I've figured out how to sideload and run an apk using adb. So that's working now.

 

I'm having other issues but that's probably with the Finch samples - I'm trying to sort it out with them. They don't use the WaveSDK but say their sample apps run for other devs, so that's confusing.

 

How do I get an app installed into the Focus Library, i.e. the launcher from the main UI?


Thanks.

Vive Staff
Solution

Re: Trouble installing and running an app from adb

Hi @mgstauffalt,

 

Good to know you have worked with Finch 6Dofs controller.

As you mention since Finch app doesn't build on Wave SDK so Launcher can't retrieve any related information to show in Library.

That's why you can sideload app via adb since it's supported by Android, but can't show in Launcher.

However I think Finch should eventually build their app by using Wave SDK to run on Focus.

 

Highlighted
tsdev
Visitor

Re: Trouble installing and running an app from adb

I'm having the same issue as well.  Looking for a solution to loading our own apks through adb.

mgstauffalt
Settler

Re: Trouble installing and running an app from adb

Thanks, that makes sense that the WaveVR sdk is needed. They've sent me a project using WaveVR so I'll be trying that soon.

mgstauffalt
Settler

Re: Trouble installing and running an app from adb


@tsdev wrote:

I'm having the same issue as well.  Looking for a solution to loading our own apks through adb.


Do you have Android Studio installed (with the adb driver if you're on windows)?

 

If so, start here:

https://developer.android.com/studio/run/device

 

Connect your Focus via usb, and you should get a pop-up window asking how you want to connect - choose 'file transer', or similar, but not 'charging'

 

Open a terminal/cmd/bash window and make sure the adb install is in path or cd to its dir. Mine is here:

C:\Users\mgsta\AppData\Local\Android\Sdk\platform-tools

 

The main commands I use then are:

 

‘adb devices’ and should get a device listed

 

‘adb install <path to apk>’ where path is path to apk file on your dev machine

 

'adb shell cmd package list packages -3' lists 3rd-party packages like yours

 

After an apk is installed, you have to know its 'activity' to run it:

'adb shell cmd package resolve-activity --brief <package-name>' - list the available activities for your package

 

'adb shell am start -n <package-name>/<activity-name>' - run the app with given activity

e.g. com.htc.bowshot_3DOF/com.htc.vr.unity.WVRUnityVRActivity

 

'adb shell am force-stop <package>' - stop an app (do NOT include the activity)

 

'adb uninstall <package>' - uninstall

 

adb quick tips:

http://community.viveport.com/t5/Vive-Wave-SDK/Focus-Android-Debug-Bridge-Quick-Tips/m-p/12668#M664