Homey Community Forum

Heimdall - Let Homey watch over your home

app
security
official

#347

ok, should I disable all apps and only have xiaomi and heimdall running, is that what you suggest, and see if Hemdall then works?


#348

Yes, that’s ok. Please wait like 5 minutes before sending the log.


#349

ok, disabled all apps except xiaomi and heimdall. restarted heimdall and waited 5 minh. then send diag 8f3e0462-1f8f-40b3-aa85-103c359aee1a


#350

This log makes it a bit clearer, no devices are enumerated. I do see disarming and arming with a 10 second delay and I guess you triggered one motion sensor cause I see an error when it tries to find the alarm_motion capability, but in an empty device.
Could you try to disable the Xiaomi app and enable another one with devices and try again?


#351

ok disabled all except philio and heimdall, restarted heimdall and waited 5min, then send diag c47da127-eca9-4068-8cf8-d85469e3f512


#352

one more diag, forgott to enable device in heimdall 345d4979-646e-4a1d-a882-f63781fd7cdb


#353

Yeah, I just saw the second one come in. Unfortunately there is no device enumeration in these logs either so it seems to me it’s not app related.
I’ll have to give the code between the initialisation and enumeration a good look and I will get back to you because I’m a little bit out of idea’s at the moment. This won’t be today, I’ll do my best to report back tomorrow.


#354

thanks, I wait for your answer :slight_smile: It woul’d be great to have this working!


#355

In the deleted post above yours I had the same thing going on with my coolcam door sensors and pirs. Working fine except in heimdall, with no reports in the last 24 hour. This was since the coolcam app updated 5 days ago. Rebooting didn’t help. I “fixed” mine by going to app and rebooting the coolcam app and after that rebooted the heimdall app. Working like a charm again.

Side note, I’m still on honey 1.5.


#356

I think the app crashed here.
I noticed a flow wasn’t working so I checked the flow and the Heimdall-card was ‘unavailable’.
Went to the app-settings and it was marked with a paused symbol.
After restarting the app flowcis ok again.
Made a report: 4e70d4c1-234a-4c55-8f10-552793fc99ac


#357

@Krosso I’ve been going through the code trying to figure out what is happening but I’m not sure yet. The first step (init) is printed in the log and the second step is reading settings from Homey’s memory. That doesn’t print anything to the log, but there’s also no error so I have to assume that part is working well. After that the devices are enumerated which should be logging plenty but that never happens.
2 things can happen, some weird situation in which Heimdall crashes -> that should be visible in the logs plus you wouldn’t be able to use the app afterwards but you can.
So I think Heimdall gets into a loop waiting for a device to become ready (that part does not log anything unfortunately)
I’d like to see an overview of your devices. Can you please go to https://developers.athom.com and login. Then select Tools - API Playground which will lead to this screen:

Next remove the // in front of Homey.devices.getDevices({ online: true }); and click RUN
Now wait a little and copy the full response in a text file and mail it to me. I’ll PM you my email address.


#358

@Fire69 unfortunately the log you sent contained no information so I can’t look into it, sorry.


#359

Hm, too bad. I’ll keep an eye on it and try a new report if it should happen again.


#360

@Krosso, thanks for the log, found the problem.

You have 4 devices that are not ready. If you open the devices.txt you sent me and search for "ready":NULL you can find which are. Resolving that problem is one thing, Heimdall handling that in a decent way is another.

Heimdall has code to wait for a device to become ready, this is to make sure that when your Homey reboots and all apps start Heimdall doesn’t finish enumerating devices before apps that support those devices are fully started.
Unfortunately your devices never reach the ready state so Heimdall never finishes enumerating.

I’ve now made a change in Heimdall where it will wait a maximum of 10 seconds on a device to become ready and then moves to the next one, so 1 faulty device can not prevent Heimdall from starting. When this happens a line is written to the apps log and to the History which can be checked on the Dashboard

This does however creates a problem to be fixed: what if a device becomes ready after it has been skipped by the enumeration process?
I’m not yet sure how I will handle that, I’ve several options for it, but in the mean time I will release the version with the dirty fix to the app store so you can use the app.
(Seeing the number of installs and the number of reports this error is statistically not significant enough to not release this version, < 0.1%)


#361

Hello

Thanks for checking this

When do you think the new version is out in app store?

Meanwhile…

There is 3 remote controlls and 1 media streaming unit that is not ready
L

I can try to remove these, then it shoul’d work with the present version or?

/Regards Per


#362

No problem.

I really can’t tell you when the new version will be available. Someone at Athom will have to approve it before I can publish it, sometimes that takes an hour, sometimes it takes several days.

Yes, If you remove the devices it should work, disabling the apps that make them available will not work, that can actually be a cause of the enumerating not completing in the current version.

Btw, I’ve created an issue on Github for me as a reminder and for others to be informed about the progress of the definitive fix for the enumerating process: https://github.com/daneedk/com.uc.heimdall/issues/34


#363

Ok, if it is not out before tomorrow, I try removing the not ready devices and do some tests
J

Thanks again

/Regards Per


#364

New version published

Version 2.0.7

  • Improved device enumeration

This update fixes a problem where a device is not in ready state during the start of Heimdall and never becomes ready.
Now Heimdall will move on to the next device after 10 seconds. This means it will take longer for Heimdall to start and any sensor that becomes available after the app start will not be usable. A fix for the latter will be in the next version. Seeing the number of installs and the number of reports this error is statistically not significant enough to not release this version, < 0.1%

@Krosso, please let me know if this version fixes the problem you are having.


#365

The new version fixed my problem and now heimdall is working for me :slight_smile:
Thanks for fast response!!


#366

I’m glad its working for you now!