You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
first of all I think this is the best plugin for blinds in homebridge.
Is simple, reliable and it works fine also in homekit app with iOS 12.
I was thinking about the "problem" of current status for insteon accessories.
And I wrote this piece of code to retrieve current status for insteon device.
In insteon devices status of a blinds is saved in a buffstatus.xml after the device is called with a request code 0x19.
example: http://xxxxx:xxxxx@ip_address:25105/3?02623296C20F1900=I=3
in buff status you will find in BS tag element a string where in a position you will have FF is the blinds is open and 00 if the blinds is closed.
If someone has the time to take a look and give me some hints how to integrate in homebridge-blinds will be awesome, anywise thank you for the great job.
Standalone code is working fine, but I have some problem to integrate in this code.
var XMLHttpRequest = require('node-http-xhr');
var btoa = require('btoa');
var xhttp = new XMLHttpRequest();
xhttp.onreadystatechange = function() {
if (this.readyState == 3 && this.status == 200) {
myFunction(this);
}
};
xhttp.open("GET", "http://ip_address:25105/buffstatus.xml", true);
xhttp.setRequestHeader("Authorization", "Basic " + btoa("xxx:xxxxxx"));
xhttp.withCredentials = true;
xhttp.send();
function myFunction(xml) {
var xmlDoc = xml.responseText;
console.log("risultato:" + xmlDoc.substring(52,54));
if (xmlDoc.substring(52,54)== 'FF')
{
this.lastPosition= 1;
}
}
The text was updated successfully, but these errors were encountered:
I think your idea could be integrated quite easily.
I'm wondering if something as simple as modifying the getCurrentPosition function would do it. Instead of sending this.lastPosition you could just amend this to the value you like. Also, see #14. If you make progress using this idea we can try to integrate it into the plugin.
@xuncia. In the latest release, I've added a feature (position_url) which should accommodate this. I'm not sure how it would work with the polling frequency, but if you decide to revert to this plugin, I'd be happy to continue tuning it.
Hello,
first of all I think this is the best plugin for blinds in homebridge.
Is simple, reliable and it works fine also in homekit app with iOS 12.
I was thinking about the "problem" of current status for insteon accessories.
And I wrote this piece of code to retrieve current status for insteon device.
In insteon devices status of a blinds is saved in a buffstatus.xml after the device is called with a request code 0x19.
example:
http://xxxxx:xxxxx@ip_address:25105/3?02623296C20F1900=I=3
in buff status you will find in BS tag element a string where in a position you will have FF is the blinds is open and 00 if the blinds is closed.
If someone has the time to take a look and give me some hints how to integrate in homebridge-blinds will be awesome, anywise thank you for the great job.
Standalone code is working fine, but I have some problem to integrate in this code.
The text was updated successfully, but these errors were encountered: