Closed Lateadapter closed 2 months ago
Hi Steffen,
you forgot to get the ise_id of the datapoint as described in the readme. You took the ise_id of the channel and added 1, which by chance gave you the ise_id of the datapoint. What you actually need to todo is: Get the ise_id of the device from the devicelist, which in your case is 8978. And then get the datapoints via http://x.x.x.x/addons/xmlapi/state.cgi?device_id=8978. There you get ise_id of the desired datapoint, which will be 9006. Hope this helps.
Best regards Sebastian
Hi Sebastian,
many thanks for the quick response. Indeed I was trying in the beginning to follow the readme but it didn't work. So I tried again according the proven way "Wer lesen kann, ist klar im Vorteil!" and again - no success. In the end it goes beyond my software knowledge - there is probably something in the browser setups.
For anyone, who will recognize similar issues, following my findings:
<token desc="">IdK......mPg</token>
).
With http://x.x.x.x/addons/xmlapi/statelist.cgi?sid=@oW.....cr5@ I got the complete list of all states of all components, but never the preselected component with http://x.x.x.x/addons/xmlapi/state.cgi?device_id=8978
resp. http://x.x.x.x/addons/xmlapi/state.cgi?sid=@oW.....cr5@&device_id=8978 as described in xmlapi doc
After further trial and errors I found the working command:
http://x.x.x.x/addons/xmlapi/state.cgi?device_id=8978&sid=@oW.....cr5@ (device_id and sid in reverse arrangement)
Question now: Is it somehow possible to use the token string as originally defined under "tokenlist.cgi" ?Firefox made it! I just don't know, why.
Best regards, Steffen
Hi Steffen,
I can not reproduce the described behavior. For me it is working with the IdK......mPg sid as well as the @oW.....cr5@ sid in all combinations device_id first, sid second and the other way around, tested in FF, Chrome and IE. Everything works fine. If you have further issues with the XML-API, you could open an issue at https://github.com/homematic-community/XML-API.
Question now: Is it somehow possible to use the token string as originally defined under "tokenlist.cgi" ?
The module uses the token from the config.js defined as ccuXmlApiTokenId.
Best Regards Sebastian
Hi Sebastian,
again, many thanks for the great module and your support effort. Because of your response I also did repeat everything and big surprise (for me) - all combinations are working, as you wrote. I don't know why, but now it seems clear that the problem was sitting in front of the computer! I'm sorry, that I did waste your time - if you agree, I would delete the recent (misleading) comment.
Regards, Steffen
Hi Steffen, all good, no need to delete. Happy to help. Best Regards Sebastian
Hi Sebastian,
meanwhile I'm using the module untouched for many month, even after change to token based XML-API. However, today by chance I found some strange behavior: One of my HmIP Window Sensors was not correctly implemented - just copy/paste error in the config.js of Magic Mirror. So there was a need to redefine the "ise_id". Surprisingly no one of the "ise_id's" used in the config.js was listed after calling of http://x.x.x.x/addons/xmlapi/devicelist.cgi?sid=yyy ... but the module is working! The Id's were selected originally using the old XML-API 1.x
Finally there seems to be always a required difference of "+1" in ise_id.
Sample: XML-API "Fenster Arbeitszimmer ... ise_id="9005" "
`
`
needs to be selected in config.js as id: '9006'
{ id: '9006', name: 'AZ', type: 'window_warn_open', icon: '/modules/MMM-Homematic/icons/open_window.png', iconSize: 'small', warnColor: 'gray', iconPosition: 'left', warnOnly: 'true' },
BTW - selecting the id '9005' in Magig Mirror config.js will result in endless module loading...
So far - I know how to handle the issue, but for someone starting with the module it could become frustrating.
Regards, Steffen