The test app supports adding multiple Area Targets onto the device’s SD card, each in their own unique folder under the folder AreaTargetData. You can switch between – or activate multiple of your Area Target databases in the menu settings of the test app. The test app can also be a good starting template for your Area Target projects.
If it so happens that you do not have access to the environment for testing your Area Target, you can instead use the simulation mode that is available in the 9.0 Vuforia Engine SDK for Unity. See Unity Play Mode for more information.
NOTE: The HoloLens version of the app supports only a single Area Target Device Database.
Installing and Testing the Pre-built App on Android Devices
You can install the pre-built app vuforia-unity-android-areatargetstest-X-Y-Z.apk on an ARCore supported device by connecting the device to a PC with a USB cable, and then using the Android Debug Bridge (ADB).
- Connect the device to the developer desktop environment using a USB cable.
- Open a Cygwin bash shell or Windows Command Line and execute:
you will see:
List of devices attached
If the device list is empty, or a given device is not listed, kill the ADB server by executing:
- To install the application, navigate to the folder containing the downloaded APK (in our example, C:\Temp) and install APK using adb:
$ cd /cygdrive/c/temp
$ adb install vuforia-unity-android-areatargetstest-X-Y-Z.apk
As an alternative approach, you can copy the APK file to your device's Download folder and install it from a File Manager application directly on the device.
- Start the app once, so it creates default data directories. Close the app.
- While the device is still connected to your PC, proceed to create folder(s) with the name(s) of your device Database(s) in the following directory: /sdcard/Android/data/com.vuforia.engine.AreaTargetsTest/files/AreaTargetData/
NOTE: Folder AreaTargetData must be created as well if it does not exist yet.
- Copy the below listed output files from your target generation using the ATG:
- YourAreaTarget/YourAreaTarget.xml – Vuforia Dataset XML.
- YourAreaTarget/YourAreaTarget.dat – Vuforia Dataset binary container.
- YourAreaTarget/YourAreaTarget.glb – converted 3D model of scanned space.
Start the app again and choose the Area Target you wish to test by pressing the DataSets icon to access the menu and select the Area Target database you wish to test. When the Area Target is loaded, and the space is recognized, you will notice that the provided model of the scanned space is rendered as a white outline over the physical environment. We recommend providing similar or other shaders on the space, or gridlines on the floor as UX elements to provide feedback to the users indicating that tracking is present. See Using a Navigation Mesh with Area Targets and Using Area Targets in Unity for more information.
NOTE: If you instead receive a missing Platform Sensor Fusion message as depicted below, then your device does not support Area Targets. For Area Targets to work, you will need an Android device that supports ARCore or an iOS device with ARKit.