Skip to content

handle response 0x8012 #113

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

Merged
merged 6 commits into from
Jan 20, 2022
Merged

handle response 0x8012 #113

merged 6 commits into from
Jan 20, 2022

Conversation

MichaelBitard
Copy link
Contributor

I assume this appeared since I updated my zigate 1 from 3.1d to 3.21 this morning.

I saw a strange closed PR here: #107 and the underlying issue is this one I guess: #104

Is there a way to easily test what I did in home assistant? I could copy paste the api.py and application.py into the home assistant folder but it seems a little by messy right?

@MichaelBitard
Copy link
Contributor Author

MichaelBitard commented Jan 8, 2022

I know I should handle this message in the application, but I don't know what it's for, I'm looking into it right now

EDIT: Ok I think from fairecasoimeme/ZiGate#350 we can safely discard it

Second Edit: I have a bunch of 0x9999 too, is this from here: APP_ZCL_cbEndpointCallback https://github.com/fairecasoimeme/ZiGate/blob/e54cabc22a49f33121e6e9c7cbecf779203b8ec7/ModuleRadio/Firmware/src/ZiGate/Source/ZigbeeNodeControlBridge/app_zcl_event_handler.c#L434 and can I safely discard them too or do we need to handle them differently?

@max5962
Copy link

max5962 commented Jan 18, 2022

I assume this appeared since I updated my zigate 1 from 3.1d to 3.21 this morning.

I saw a strange closed PR here: #107 and the underlying issue is this one I guess: #104

Is there a way to easily test what I did in home assistant? I could copy paste the api.py and application.py into the home assistant folder but it seems a little by messy right?

The PR is closed because they fork the project and cherry pick (when tested in their projects) the commit into zigpy-zigate

@max5962
Copy link

max5962 commented Jan 18, 2022

@max5962
Copy link

max5962 commented Jan 18, 2022

#104
They looking for volunteers for testing they fork in ZHA environment.

@MichaelBitard
Copy link
Contributor Author

I'm not really fond of using a fork, when there is no official communication from the maintainers of this repository to do so.

Is this repository unmaintained? @doudz

If so, I can make a pull request to change the README of this repository to explain that we should move to the https://github.com/zigbeefordomoticz/zigpy-zigate fork?

@doudz
Copy link
Collaborator

doudz commented Jan 19, 2022

I just have no time to work on this repo but PR are welcome :)

@@ -153,6 +155,8 @@ def zigate_callback_handler(self, msg, response, lqi):
elif msg == 0x8702: # APS Data confirm Fail
LOGGER.debug('APS Data confirm Fail %s %s', response[4], response[0])
self._handle_frame_failure(response[4], response[0])
elif msg == 0x9999: # ZCL event
LOGGER.debug('ZCL application started %s', response[0])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This debug message is not really understandable in my opinion, maybe something like "Extended error code %s" is better ?

Copy link
Contributor Author

@MichaelBitard MichaelBitard Jan 20, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not even knew it was an error, I thought it was a normal application response.

I changed it

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Logging an Error as a Debug looks strange

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have somewhere a documentation that could help me understand this 0x9999 event and what it means?

I have a bunch of them at each restart of home-assistant, I thought it was normal.

Is it ok if I raise this to a warning level @pipiche38?

@MichaelBitard
Copy link
Contributor Author

I just have no time to work on this repo but PR are welcome :)

Open source in a nutshell! :)

@pipiche38
Copy link

@MichaelBitard , for the documentation I would refer to https://www.nxp.com/docs/en/user-guide/JN-UG-3113.pdf
and if you go to section 10.2.5 you'll get the list of Extended Errors

In short these are Errors code trigger by the stack itself, which comes to provide more details on an error happening.
This could be related to a plugin command, but it could also be generated by the stack it self, when handling some incoming commands/messages from the zigbee network itself.

For instance Extended error code 0x80, 0x81, 0x82, 0x83 are showing some inconsistency or wrong sizing of the PDM.

I do agree with you that warning would probably be good.

@MichaelBitard MichaelBitard requested a review from doudz January 20, 2022 14:03
@MichaelBitard
Copy link
Contributor Author

Thanks @pipiche38 that makes sense!

@doudz
Copy link
Collaborator

doudz commented Jan 20, 2022

Looks good, thanks !

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

Successfully merging this pull request may close these issues.

4 participants