Skip to content

Conversation

@glopesdev
Copy link
Collaborator

@glopesdev glopesdev commented Nov 18, 2025

As described in #71, error handling is a growing concern for consistent implementation of Harp device interfaces.

Remove ambiguous versioning string

This version string was already ambiguous and will be superseded altogether by tags in this repository.

Move error handling to messaging patterns section

The new sub-section aims to provide clearer guidelines on how various kinds of errors should be handled and reported.

Clarify rejection of register writes

Account for possibility to flag events as errors

In the near-future we may want to use this as an explicit exception
throwing mechanism used by the Parse operator.

Clarify error handling recommendations

Move messaging patterns to device specification

To further clarify and separate the specification of device operation
from the binary protocol, we move all messaging patterns to Device.md.

This greatly reduces the number of cross-references and duplicate
terminology across both documents.

Closes #71
Closes #55

@glopesdev glopesdev requested a review from a team November 18, 2025 10:00
@glopesdev glopesdev added the documentation Improvements or additions to documentation label Nov 18, 2025
@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch 8 times, most recently from 77a5e9c to a87d3f6 Compare November 18, 2025 12:11
@glopesdev
Copy link
Collaborator Author

@bruno-f-cruz We could probably also resolve #55 in this PR. Leaving it here for discussion.

@bruno-f-cruz
Copy link
Member

bruno-f-cruz commented Nov 18, 2025

@bruno-f-cruz We could probably also resolve #55 in this PR. Leaving it here for discussion.

If the goal of "mute replies" is to stop any feedback from a command from the device, then I still think that suppressing the error response falls within this category.
My interpretation is that the error message is that it is still trying to fulfil the 1 request : 1 response contract. By enabling disabling this flag one would be instructing the device to explicitly NOT follow the contract.

@glopesdev
Copy link
Collaborator Author

glopesdev commented Nov 18, 2025

By disabling this flag one would be instructing the device to explicitly NOT follow the contract.

Just to clarify, I'm assuming you mean here to set the flag. I'm fine with any interpretation, but I would be interested in hearing from @filcarv and @Poofjunior what exactly is implemented in core.atxmega and core.pico and whether both match this (and each other).

If not, we need to decide what to change to make things consistent.

@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch from b07ec13 to 3e5b7f2 Compare December 6, 2025 11:31
@glopesdev
Copy link
Collaborator Author

If the goal of "mute replies" is to stop any feedback from a command from the device, then I still think that suppressing the error response falls within this category.

@bruno-f-cruz Indeed, I just tested this and at least on the ATXmega core, the error responses are indeed suppressed if the MuteReplies flag is set.

Interestingly, this also suppresses the reply to the OperationControl message itself that sets this flag. While I understand the logic that leads to this, one might want to know that the operation control was set, and not just lost. It is not crucial for now, but wanted to leave this observation here for future reference.

@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch from 3e5b7f2 to 2d4af89 Compare December 8, 2025 14:28
To further clarify and separate the specification of device operation
from the binary protocol, we move all messaging patterns to Device.md.

This greatly reduces the number of cross-references and duplicate
terminology across both documents.
@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch from 2d4af89 to 36f7abf Compare December 8, 2025 14:34
@glopesdev glopesdev changed the title Move error handling to messaging patterns Move messaging patterns to device specification Dec 8, 2025
@glopesdev glopesdev changed the title Move messaging patterns to device specification Move all messaging patterns to device specification Dec 8, 2025
@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch from dc26e30 to 09c1c88 Compare December 15, 2025 23:23
Specifically, we want to clarify the payload should send the register
contents after the request is processed.
@glopesdev glopesdev force-pushed the dev/error-bit-clarifications branch from 55cc9fc to 0951e74 Compare December 16, 2025 10:33
@glopesdev glopesdev merged commit 8891561 into harp-tech:main Dec 16, 2025
1 check passed
@glopesdev glopesdev deleted the dev/error-bit-clarifications branch December 16, 2025 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error bit should be used only to validate message payload MUTE_RPL Behavior on Write Errors

2 participants