Getting started with Orbbec+Unity development with Astra Pro and Persee

by Dr Mike


Posted on January 2018



My previous post made it clear what I think about the chances of Orbbec being the crown prince of Kinect. The system architecture, especially of Persee, is full of promise. Before 2017 ended, we’ve got the long-promised support for Unity in Astra SDK 2.0.7 Beta release. My best Christmas present! Finally I’ll be able to dump (the good old) C++ and go for the high speed app development I’m famous for.

Given the fact that Orbbec's Unity bundle doesn't come with any documentation nor does the Orbbec community provide any entry level tutorials (“I just got my Persee today, now what?”), I thought it would be worthwhile bringing some clarity to the first steps. Hopefully this will save some hours and headaches. (Honestly, I spent too long figuring this out from zero in case of Persee.)

The case of Astra/Astra Pro is rather simple. Once you’ve unboxed the sensor you can already proceed with the software:

  • If you don’t have it already, get your Unity Editor (version 5.5.4f1 seems to work best)
  • Download the Astra SDK (I took “Astra SDK 2.0.7 Beta for Unity 5.5.4”, you can skip the sample files which are executables, we’re making the build here)
  • Unzip the bundle to reveal the Unity package (AstraSDKUnity554-v2.0.7-beta-d7a48b40ed.unitypackage)
  • Create a new Unity3D project
  • Import the package as custom package (in Assets menu)
  • Open the scene called TestScene in Scenes folder
  • Connect the sensor to your PC’s USB port
  • Click Play and enjoy!

Everything runs just like that. Well done Orbbec! Well, it isn’t pretty, but has all the necessary functionality that you’d need to get started with coding:

  • Body tracking (same as skeletal tracking in Kinect just a few joints less)
  • Raw video image
  • Grayscale depth map
  • Background removed mono-color depth image
  • Background removed color image

By the way: If you have any need to elevate the sensor above your desk, the box works perfectly!




So it is that simple with Astra and Astra Pro. But Persee is a bit trickier. Basically, what you get inside the box is:

  • The sensor mounted on top of the Android mini computer
  • Power cable (100-240 Volt compliant, i.e. works almost anywhere without any tricky adapters)
  • HDMI cable (a bit too short for anything)
  • Remote control (like what comes with your TV)

What you're going to need is:

  • Some sort of a display with HDMI input
  • (Optionally) Round “button” battery for the remote control (In case you lack the battery, you can use a USB mouse instead)




Batter models are CR2016, CR2025 and even CR2032 tested and proven to fit, although the last one is tricky to put inside. Basically any battery used in digital watches works. You can use a ruler, a coin or a scissors’ tip to open the backside of the remote. Punch it in the same way as in the picture.



There isn’t any power button, if that’s what you’re looking for. You can just switch power on from the switch on your socket or extension cable.


Once the power is on and you’re watching closely, the infrared light turns on for a second or so. If it doesn’t, your device may have been damaged during shipping. In that case: tough luck.

But how to get it up and running, run the sample project and turn the sample to your own demo scene? Here we go.

As Persee is indeed a mini Android computer, comparable to a smartphone except equipped with Astra Pro 3D sensor, you can simply plug in the power cable and connect the HDMI to your display. Here, I’m using my old 42’’ TV (which is pretty much the minimum size for any decent public space installation I used to make for Kinect).


After a few seconds you should be seeing a familiar Android home screen on your display. Da-daa! If you’re using a TV screen like here you may have to select the input source on it using the TV’s remote.

So, now if you’ve ever developed any Android apps for smartphones or tablets, the next things are pretty obvious. You’d need to build an .apk file from the Unity test scene and get it running on the device. Unfortunately, at this moment, there isn’t any USB debugging options available for Persee, so what my development process looks like is actually this:

  • Develop the app using Astra Pro sensor (not Persee), which is connected to my PC with USB cable, so USB debugging works conveniently like on any other device (smartphone, webcam, etc.)
  • Once my version is working as intended, I make an Android build (.apk) with build folder pointing to a shared Dropbox folder
  • After a while when Dropbox is synced the .apk file is accessible with Dropbox app on Persee
  • Install the .apk file and run the app on Persee

This way I can skip several manual steps of fumbling with USB sticks and the pre-installed ApkInstaller app and most of other manual steps. But indeed, I need two sensor devices. The only difference between the two is the minicomputer part under Persee. The sensor itself is exactly the same piece of hardware.


First, you can connect Persee to your WiFi, which is exactly the same as using any smartphone or tablet, except text input is, hmmmm, slow. Depending on your preference, you could connect a USB mouse to Persee and keep clicking through the characters of your WiFi password. I prefer this way as there are some limitations navigating some applications (including Dropbox) with just the remote control. Another option (I’m just assuming) is to use a touch screen as the display which might be the smoothest way to get around inside Persee.


Then, let’s enable the Developer Options of the device. It’s the classic Android trick done in Settings.


Go to About Device.


Scroll down to Build Number and keep pressing it until the notification tells you have activated the developer mode. You can try press it more to see the message below.


You can then install Dropbox. Go to main menu, select Google Play and find Dropbox app. Also, you may have to update the Google Play app before you can install anything and log in using a Google account. As I am a heavy user of Dropbox, I created separate accounts (Google and Dropbox) so I can keep things simple, isolated and I will save time in syncing files. (And of course, the development PC should have that Dropbox app installed also.)


Now, once Dropbox is installed, you can go back to your PC to prepare the .apk file. The scene is build-ready, so all you’d need to do is to tamper with a few settings. First, go to Build Settings.


Check if you need to install the Android support. Unity does good job in guiding through that process and if that doesn’t do, there’s plenty enough help around the internet. Once you have Android build capability, set the following:

  • Build System: Gradle (New)
  • Development Build: on

Development build is handy because you don’t need to do the app signing process now that we’re just trying to test thing out here.


Then open Player Settings as there are a couple of things prohibiting us to get the app running on Persee. Surprisingly, you don’t need to change API levels (“Gingerbread” API level 9 is just fine) or anything. Just make sure that you have:

  • Bundle Identifier: something else than the default value
  • Device Filter: ARMv7

Then, if not there already, add TestScene to the list of Scenes in Build and click Build.


Select your Dropbox folder as the build target, so you won’t need any manual steps in subsequent builds. Name your .apk file and click Save.


After Dropbox has synced the file, you can go back to Persee. In your Dropbox app you can now see the .apk file somewhere in the folder structure.


Download it, install it, and grant all permission.


The app opens automatically. There you go!


It took quite a few steps to set up the development process, but after this it gets pretty easy. I would still highlight that it is totally worth the money to have Astra Pro for development even if your main target is Persee. USB debugging is simply the fastest way to go. I’m just hoping it is coming to Persee soon in some future release of Astra SDK.

EDIT 3/2018: The above worked perfectly for the first release of the SDK in December 2017. Later I had problems with February 2018 version as I couldn't get the app installed on Persee no matter what. Fixed by choosing Install Location: Force Internal in the Player Settings.

EDIT 7/2018: The latest version 2.0.9 beta may require also the API level to be specified. Just set Minimum API Level: Android 6.0. 'Marshmallow' (API level 23) in the Player Settings. Good to go!

The next article will demonstrate easy modifications to the test scene and some basic code level stuff.


© 2014-2018 Improventions. All rights reserved.

Created by MGWalton

Powered by coconuts