Hello everyone.

We have decided to phase out the Mixed Reality Forums over the next few months in favor of other ways to connect with us.

The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.

The plan between now and the beginning of May is to clean up old, unanswered questions that are no longer relevant. The forums will remain open and usable.

On May 1st we will be locking the forums to new posts and replies. They will remain available for another three months for the purposes of searching them, and then they will be closed altogether on August 1st.

So, where does that leave our awesome community to ask questions? Well, there are a few places we want to engage with you. For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality. If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers. And always feel free to hit us up on Twitter @MxdRealityDev.

Sleepmode Tap Missing in the Device Portal

I wanted to change the sleep mode from 5 to 30 minutes or turn it off at the Device Portal, but the sleep mode tab is missing. Where is it now? How can I change it to at least 30 minutes?

I tested it on 3 hololenses. No Device Portal shows the sleep mode tab anymore.
I used developer und commercial hololenses.

I already tried https://www.tattichan.work/entry/2017/07/17/
I used the unity script. But it doesn't seem to work.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Networking;

public class Sleepmode : MonoBehaviour
{

[Tooltip("DevicePortal URL")]
public string url = "127.0.0.1:10080";
[Tooltip("DevicePortal UserName")]
public string usr = "username";
[Tooltip("DevicePortal Password")]
public string pass = "pass";

void Update()
{
    if (Input.GetKeyDown(KeyCode.S))
    {
        StartCoroutine(OnSetVideoIdle());
        StartCoroutine(OnSetStanbyIdle());
    }
}


//ValueAC = 0 & ValueDC = 0 " , 
IEnumerator OnSetVideoIdle()
{
    WWWForm form = new WWWForm();
    var req = UnityWebRequest.Post(" http://" + url + "/api/power/cfg/SCHEME_CURRENT/SUB_SLEEP/VIDEOIDLE?ValueAC=0&ValueDC=0", form);
    req.SetRequestHeader("AUTHORIZATION", Authenticate(usr, pass));
    yield return req.SendWebRequest();
}

IEnumerator OnSetStanbyIdle()
{
    WWWForm form = new WWWForm();
    var req = UnityWebRequest.Post("http://" + url + "/api/power/cfg/SCHEME_CURRENT/SUB_SLEEP/STANDBYIDLE?ValueAC=0&ValueDC=0", form);
    req.SetRequestHeader("AUTHORIZATION", Authenticate(usr, pass));
    yield return req.SendWebRequest();
}
string Authenticate(string username, string password)
{
    string auth = username + ":" + password;
    auth = System.Convert.ToBase64String(System.Text.Encoding.GetEncoding("ISO-8859-1").GetBytes(auth));
    auth = "Basic" + auth;
    return auth;
}

}

Would be good to add the sleep mode to the hololens menu and not always use the device potal to change it.

What else can I Do? Thanks in advance.

Sophiena

Sign In or Register to comment.