koktaildotcom / homey-mi-flora

Integrate Xiaomi Mi Flora Plant Sensor into Homey
MIT License
11 stars 13 forks source link

Mobile interface not shown in new (beta) app #3

Closed TedTolboom closed 6 years ago

TedTolboom commented 6 years ago

Hi @koktaildotcom,

Great app, thanks for the effort.

I noticed that the mobile interface is showing correctly on the old web interface:

schermafbeelding 2018-04-10 om 08 00 08

But on the new (beta) app, the interface only shows a blank screen (adding a screenshot doesn't make sense). I tried to optimize the icons (with illustrator) to check if that resolves this issue (see PR#2), but that is not the case...

I'll see if I can look into it this evening.

PS. I would propose to setup a paypalme account and replace your current contribution link to that one; saves Paypal fees... ;-P

TedTolboom commented 6 years ago

Thinking out loud...

this could be caused by the custom capabilities being defined as setable and at the same time being added to a sensor component of the mobile interface... Currently not in reach of my Homey, will try this evening.

But for sure, it is not needed to have these custom capabilities as setable, since only the device (and not the user) will update the capability values.

TedTolboom commented 6 years ago

Just updated the PR to change setable to false and remove the obsolete min, max and step size (only needed for setting). Did not test it myself yet.

koktaildotcom commented 6 years ago

Thanks @TedTolboom! Your PR resolved the issue. The above assumption of the custom capabilities being defined as setable didn't cause it because i revert that code (they must be settable in the sync process.)

I think it was the missing battery_capability with the battery sensor.

TedTolboom commented 6 years ago

@koktaildotcom indeed it must have been the battery component being empty...

On the custom capability required to be setable in the sync process; that is not correct. Setable only reflects to the user being able to manually change the value from the user interface. In this case, this is not needed / wanted (for the user to manually update the fertility value).

All updates originating from the app / device driver (including sync) are not affected by changing settable to false.

But glad it is working now ;-P