Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Endpoint Registration Failure Due to OTA Cluster #310

Closed
schrodingersket opened this issue Jul 1, 2020 · 12 comments
Closed

Endpoint Registration Failure Due to OTA Cluster #310

schrodingersket opened this issue Jul 1, 2020 · 12 comments

Comments

@schrodingersket
Copy link
Contributor

Commit 3f57b46 broke endpoint registration for both the Wiser (0x0b) and ZLO (0x01) endpoints; I receive the following error for all commits after that on startup (which, notably, does not crash the application but does prevent reporting for clusters on endpoints which did not fully register):

eApp_ZLO_RegisterEndpoint 1

The error is printed from here:

vLog_Printf ( TRACE_ZB_CONTROLBRIDGE_TASK,LOG_CRIT,"eApp_ZLO_RegisterEndpoint %x\n", eZCL_Status );

After adding some log output, it looks like the first failure is when registering the OTA Server cluster in the Wiser endpoint.

@schrodingersket
Copy link
Contributor Author

schrodingersket commented Jul 7, 2020

Just wanted to add some additional context to this. If I don't register all of the endpoints (Wiser, Livolo, Terncy, etc.), the application successfully starts, and the ZLO endpoint is successfully registered.

My initial thought is that this has to do with insufficient RAM when initializing all of the desired endpoints (particularly the OTA cluster); NXP recommends
sharing common cluster instances across endpoints in JN-UG-3115 to decrease RAM utilization. Are we doing this currently? If not, I think it would be a good idea to do so, since adding new endpoints for various manufacturers won't scale if we initialize a new endpoint for each one.

@badzz
Copy link
Contributor

badzz commented Jul 7, 2020

Are you sure the problem is new ?

@schrodingersket
Copy link
Contributor Author

Yep. v3.1c did not have this issue; commit 3f57b46 fails on a clean build, but the one before (6000f73) works fine. I also tested ~10-12 commits in between 3f57b46 and v3.1d HEAD (8d94e69 at the time of this comment) with the same result.

@badzz
Copy link
Contributor

badzz commented Jul 7, 2020

But do you have a runtime.error or a compile error ?

@fairecasoimeme
Copy link
Owner

Hello,
I already had this kind of issue. I updated the basic cluster file. Could you try to recompile and test ?

@schrodingersket
Copy link
Contributor Author

I'm still seeing this as of 6ac632d. @badzz It's a runtime error.

Here's the UART output after a RESET:

u8NumberOfRegEndpoints : 0



 Status : 0

u8NumberOfRegEndpoints : 1

u8NumberOfRegEndpoints : 2



 Status : 0

u8NumberOfRegEndpoints : 3



 Status : 0

eApp_ZLO_RegisterEndpoint 1



tsCLD_Groups 4

tsCLD_GroupTableEntry 28Got bdb event 2

Got bdb event 1

Got stack event 2

@badzz
Copy link
Contributor

badzz commented Jul 8, 2020

ok issue is due to the number of timer available and needed . each endpoint with ota (5 currently) uses 1 timer.
If I try to increase the number of timer by 1, it crashes on startup ..

@schrodingersket
Copy link
Contributor Author

Is there a reason we couldn't share a single OTA cluster instance across all endpoints? If I understand correctly, there would then only be a single timer necessary, yeah?

@badzz
Copy link
Contributor

badzz commented Jul 8, 2020 via email

@schrodingersket
Copy link
Contributor Author

Excellent. Happy to help with that if you like. I'm looking at potentially adding a couple of endpoints for some manufacturer-specific clusters (air quality data from Climax and Develco, in particular), so I'll be in and around those modules anyway.

@badzz
Copy link
Contributor

badzz commented Jul 9, 2020

#315

@schrodingersket
Copy link
Contributor Author

Closing in favor of #315

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants