Hello again! I hope everyone is okay.
My question is related to Microsoft Hololens and its battery level. I would like to see the battery level via Node-Red. I did some ways but I took several mistakes.
I can't see the continuation of the mistake I showed with the question mark above. There are three points, but the after is not visible.
[
{
"id": "f52f54bdcee82b3b",
"type": "tab",
"label": "Flow 2",
"disabled": false,
"info": "",
"env": []
},
{
"id": "fd6b79463afb23e8",
"type": "http request",
"z": "f52f54bdcee82b3b",
"name": "GET",
"method": "GET",
"ret": "txt",
"paytoqs": "ignore",
"url": "",
"tls": "49d6016a.ababa",
"persist": false,
"proxy": "",
"insecureHTTPParser": false,
"authType": "basic",
"senderr": false,
"headers": [],
"x": 490,
"y": 260,
"wires": [
[
"b308c2fd0e691cad",
"ed1023e20a8ada5d"
]
]
},
{
"id": "078df7799eb627e9",
"type": "debug",
"z": "f52f54bdcee82b3b",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 870,
"y": 180,
"wires": []
},
{
"id": "f30652210ab7dd28",
"type": "change",
"z": "f52f54bdcee82b3b",
"name": "/api/power/battery",
"rules": [
{
"t": "set",
"p": "url",
"pt": "msg",
"to": "https://192.168.X.XX/api/power/battery",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 310,
"y": 260,
"wires": [
[
"fd6b79463afb23e8"
]
]
},
{
"id": "5b61151766da5f29",
"type": "inject",
"z": "f52f54bdcee82b3b",
"name": "",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": "",
"topic": "",
"payload": "",
"payloadType": "date",
"x": 100,
"y": 260,
"wires": [
[
"f30652210ab7dd28"
]
]
},
{
"id": "7ab3473ee519d437",
"type": "ui_text",
"z": "f52f54bdcee82b3b",
"group": "f2436bee621336a5",
"order": 0,
"width": 0,
"height": 0,
"name": "",
"label": "battery : ",
"format": "{{msg.payload}}",
"layout": "row-spread",
"className": "",
"x": 1140,
"y": 280,
"wires": []
},
{
"id": "359a43bbd65e3c8b",
"type": "ui_gauge",
"z": "f52f54bdcee82b3b",
"name": "",
"group": "f2436bee621336a5",
"order": 0,
"width": 0,
"height": 0,
"gtype": "donut",
"title": "Gauge",
"label": "%",
"format": "{{msg.payload}}",
"min": 0,
"max": "100",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"diff": false,
"className": "",
"x": 1150,
"y": 340,
"wires": []
},
{
"id": "ddc382f5628a457b",
"type": "function",
"z": "f52f54bdcee82b3b",
"name": "ff",
"func": "msg.payload = Math.floor( msg.payload.RemainingCapacity / msg.payload.MaximumCapacity * 100 );\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 850,
"y": 340,
"wires": [
[
"359a43bbd65e3c8b",
"7ab3473ee519d437"
]
]
},
{
"id": "b308c2fd0e691cad",
"type": "json",
"z": "f52f54bdcee82b3b",
"name": "",
"property": "payload",
"action": "",
"pretty": false,
"x": 650,
"y": 260,
"wires": [
[
"078df7799eb627e9",
"ddc382f5628a457b"
]
]
},
{
"id": "ed1023e20a8ada5d",
"type": "debug",
"z": "f52f54bdcee82b3b",
"name": "debug 25",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 620,
"y": 140,
"wires": []
},
{
"id": "49d6016a.ababa",
"type": "tls-config",
"name": "",
"cert": "",
"key": "",
"ca": "",
"verifyservercert": false
},
{
"id": "f2436bee621336a5",
"type": "ui_group",
"name": "HoloLens",
"tab": "690c7d582fe7bd12",
"order": 1,
"disp": true,
"width": "6"
},
{
"id": "690c7d582fe7bd12",
"type": "ui_tab",
"name": "Home",
"icon": "dashboard"
}
]
Note: As you can see IP address contains XX. But in flow, I tried real numbers.
I found some information about the connection between Node-Red and Hololens. Unfortunately, this is the Japanese language. I did not understand anything. Thank you in advance!