Hololens2 with MRTK 2.6.1 Losing Head Pose after device Sleep - unity3d

On Hololens2 if the device goes to sleep (or press the power button off then on) and resume my app I lose head pose tracking.
I'm using MRTK 2.6.1 with Unity 2019.4.18f and the XR SDK approach.
I'm testing using the instructions here https://learn.microsoft.com/en-us/windows/mixed-reality/develop/unity/tutorials/mr-learning-base-02?tabs=winxr
I'm using the DefaultHololens2XRSDKConfiguration profile.
Everything is generally fine, but after I put the headset down and it goes to sleep, or i press the power button off and on. Then launch my app again (it's still running in the background), then the head tracking is lost.
The wrist tap menu is still tracked fine. The app seems to be getting hand tracking fine (but is offset becaues the head pose position is stuck.
If i close the app and open again tracking is fine.
No errors show up in the Unity debug log (even with verbose MRTK logging on).
Any ideas? Or anyone else able to test this with similar setup?
I might try the Open XR approach next.
Cheers

This is a known issue with a fix in development still, it is recommended to keep checking the Unity releases for 2019 with getting on latest LTS for now.

This issue is fixed in Windows XR SDK 2.8 which requires Unity 2019.4.25 or later.

Related

Failed to initialize Vuforia Engine

Im trying to embed my vuforia project to my flutter app,
Everything runs fine at first open, but idk why everytime i open the app again, the error pop up on the unity screen:
The problem i could specify is, Vuforia try check / get / something about the Camera Permission, since the first open it ask for Camera Permission, it run good, but second, while the permission already granted, the error show up.
I tried to ungrant the permission, open app again, it work again because it request for the permission.
Any suggestions of what and where the thing must i change? It's quite annoying to ungrant the permission everytime i open the app.
Regards, Slim!
Vuforia error
This happens to me when I have Vuforia running in the Editor (playing a game) and changing some code while it's running. Then, when coming back into Unity, it stops playing because of recompiling. But that apparently causes Vuforia to crash, and it will come up with that error screen on the next play.
My workaround is to stop a running game in Unity before changing (saving) any code, so recompiling doesn't crash Vuforia.

Unity3D Player Error "Receiving unhandled NULL exception Obtained 22 stack frames."

I have developed a Unity3d Mac standalone app, which crashed after a while with the above mentioned error - the whole app gets frozen.
I have pages with a video, which I load and un-load dynamically when entering/exit the page. Most of the time the app crashed when I leave the page with the video to the menu. Anyone any idea, I did find anything valuable answer to this matter :(
----- Tests -----
After a few test runs, I narrowed it down to the video. Not sure what exactly the issue is, but when I played a video and leave the page the app freezes...sometimes immediately, sometimes after a while.
Unity 2018.1f
Tested on : Mac OSX 10.12.6 & OSX 10.11.6
After long tests and try-outs, we found a general problem with Unity and continues playing videos. After updating everything, as well as to the latest Unity2018.2 version - it finally was working well. As per Unity changelog, they did some fixes on the VideoPlayer.
Good luck.

Running google-vr unity daydream app on google pixel

Im trying to run the sample app provided in the daydream page on the google pixel phone.
1) I chnaged the build settings to android.
2) Went to player settings enabled Virtual reality support and selected google daydream as the platform.
3) I changed the Minumum API to API level 24.
4) I added the folder containing my adb to the path variable in windows.
5) I also set the path of the android SDk.
6) I enabled USB debuggin on Pixel
However when I run my app , I get the following errors:
Device daydream not supported in Editor Mode. Please run on target device.
And..
Failed to read from controller emulator app event socket.
Verify that the controller emulator app is running.
build the apk and start it on your device. build and play requires adb.
As I suppouse, you want to DEBUG your Daydream app on your Programming Environment (Unity in this case).
Note:This solution allows you to debug on your PC but you'll need one Pixel Phone connected to your PC, and one Daydream Controller.
First of all I recommend you to download the samples provided by Google on Github if you have not done it yet:
https://github.com/googlevr/gvr-unity-sdk/releases
When you load any scene you'll see that the Daydream basic set is composed for a hierarchy like:
The two selected components are key for your porpouse cause if you want to debug Daydream from your PC you'll need to "link" your daydream controller with InstantPreview App. Instant preview will downloaded instantly on your phone if you got in your scene the "GvrInstantPreviewMain".
InstanPreview Google Info: https://developers.google.com/vr/develop/unity/instant-preview
When the app has been opened, can happen 3 things on your pixel phone:
Everything works as it should.
Daydream Instant Preview infom to correct the device by USB.
Kind of Grey screen with some text.
If you're on 2.
This seems to happen when your Unity Project is desynchronized from your phone and you'll see something like:
Close InstantPreviewApplication on your phone, close your unity project (remember to save your progress), and open again your unity project. That has almost always solved me.
If you're on 3.
This seems to happens when instan preview is waiting for Unity Play Mode.
You only need to press Play on you Unity Poject.
Remember to press (and mantain) synchronize button on your Daydream controller if you can move the headset camera but can't find your controller reticle.
This works for me.
I also append my own Unity project with this scheme that works bought for Daydream and GearVR in case helps someone else to test my solution:
https://github.com/ls29322/VR_GalleryApp

Unity3d crashes when trying to change platform or building after upgrading to win10

http://prntscr.com/cfakce this is what happened when I'm entering any script, when I'm changing to mobile input this show up http://prntscr.com/cfalpw.
Whenever I'm trying to build the project or changing platform it crashes.
I changed my win7 to win10 (had to) and I think it may screwed my project but I'm not really sure, tried to search on Google for those errors and found nothing.
Someone told me on the Unity forum that it had something to do with UnityEditor but didn't had really idea how to fix it.
When I had win7 (before the change) everything worked perfectly fine.
Any ideas?
Unity version: Unity 5.4.0f3 (64-bit) thought it might help.
new: When I'm writing using at the start of any script it doesn't complete it to Unity.Engine or Unity.Editor it doesn't even have this option, like it got deleted or something. How do I bring back those Unity.editor and engine? I think it's the real problem :)
Another thing is that when I got win10 the C drive is now F and I've got new SSD drive which is the new C, everything stayed on the C drive but they didn't work or was used perfectly, so I redownloaded everything like Skype, steam, Origin and of course UNITY, the project folder I dragged to my desktop and then opened the game folder on this Unity I downloaded, I think that's what made the problem because when i enter Unity and press open, and going back to F drive>users>myname>dekstop>UNITY>mygame and open it in that path instead of what i have dragged (which it the same folder but on different place) it let me switch platform, does not let me build but at least it's not crashing just giving me the same errors without crashing, i don't know if this has something to do with but just gave the info cause maybe you will find this helpful to help me.

Google Tango: Failer to connect to tango service

so i was developing with unity and google tango. After pushing my application to the tablet it crashed with the message: "Failer to connect to tango service".
After rebooting the tablet i tried to start an application which was already on the tablet and it worked in the past. But also this application crashed. After rebooting again another application also crashed.
It seems as no application is able to start. I dont know why. I googled but i could not find any information about this. There were 2 pages on stack overflow but they got removed, so i get an "page not found" page.
Anyone was an idea how to fix this or what the problem could be ?
Thanks
for someone who maybe was the same prolem in the future:
solution for me was just installing the system update. It seems that the tango service is not working when the device has downloaded the updates but not installed it.
I ran into this problem when running the Depth Perception Tutorial. It can be one of two problems 1. the camera has crashed and you need to reset the device or 2. You need to download and install the latest Project Tango system update. You can do this by dragging your finger down the screen from the top left on the Project Tango device and applying the Tango Update. It will take a few minutes. You should not even have to reboot. Just Build and Run again. Worked for me.
The are multiple causes:
As mentioned before - the Tango Framework on the device is out of date + Tango core app is out of date.
Wrong implementation of Tango object's lifecycle. Tango object has its own strict life-cycle and if you do not implement it right it causes the Tango to malfunction.
Try to use Tango apps in order to calibrate the device