microsoft / MixedRealityToolkit-Unity

This repository is for the legacy Mixed Reality Toolkit (MRTK) v2. For the latest version of the MRTK please visit https://github.com/MixedRealityToolkit/MixedRealityToolkit-Unity
https://aka.ms/mrtkdocs
MIT License
6k stars 2.12k forks source link

Unable to locate Azure spatial anchors; Multi-user shared experience tutorial #9272

Closed ghostravenstorm closed 3 years ago

ghostravenstorm commented 3 years ago

Describe the bug

Following the multi-user demo with the lunar rover, other users are not able to locate the shared Azure spatial anchor. When the program gets to AnchorModuleScript.FindAzureAnchor(string), and the message "Looking for Azure anchor... please wait..." appears, the search process seems to get stuck here and no anchor is found. I can confirm that Client A is creating an anchor with ID "xyz" and Client B is receiving anchor id "xyz" via Photon and searches for that particular anchor. But the system just fails to find anything.

To reproduce

Expected behavior

Finding the Azure spatial anchor shouldn't take more than a few seconds. I had this working in my main project (that borrows MRTK tutorial code) and the tutorial itself. Now today nothing using this code is able to get Azure spatial anchors.

I haven't been able to figure out if something is wrong with Azure services, or maybe I hit a quota limit with spawning anchors. I just know that this tutorial was working before, and now it's not.

I also noticed that this tutorial code with spatial anchors somehow doesn't affect the graphs on the dashboard. Running the sample project from the Azure Spatial Anchors SDK github I'm able to see the graph "anchors created" count up, but this MRTK tutorial doesn't seem to affect it.

Client A image

Client B image

Your setup (please complete the following information)

Target platform (please complete the following information)

PattyUnity commented 3 years ago

I also encountered the same issue. I could start session, create anchor and get anchor ID but when find anchor button is pressed, it stuck there forever with this log "Looking for Azure anchor... please wait"

image

I wonder if it has something to do with the quality of the anchor when it's created? According to https://docs.microsoft.com/en-us/azure/spatial-anchors/concepts/guidelines-effective-anchor-experiences, it's recommended to scan the anchor position from various perspective but how to do that? Once I click Create Anchor button, the anchor is created in a few seconds which doesn't provide enough time to include various perspective.

miyocrosoft commented 3 years ago

In my case, changing the wifi network profile of Hololens2 to "Public" worked fine, but I don't know why.

MaxWang-MS commented 3 years ago

Hi @Sean-Kerawala could you take a look at the issue since it seems to be external to MRTK?

MarkoXR commented 3 years ago

Are there any updates on this issue? I am having the same problem.

F1batman commented 3 years ago

If I set wifi to private then run it until it says please wait then switch back to public while the app is still running. Then select Find Azure Anchor again it says it is unable to find the anchot then set it to 0,0,0. I did get it to work once when swapping to or from public but have not been able to replicate.

MarkoXR commented 3 years ago

Updating the ASA SDK Core and Windows to v2.10.2 solved the issue for me: https://github.com/Azure/azure-spatial-anchors-samples/issues/291 Edit: if you are using MR Feature Tool you have to manually refresh the Discover Features to see the new versions

F1batman commented 3 years ago

Thanks Heaps thats what fixed it for me.