Merged
Conversation
…t and improving command-line help output. Fixed initialization of event data by adding static CharacterString for message text.
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request fixes a bug in event notification parsing and enhances the example applications for sending event notifications. The main issue was an off-by-one error in the event parsing loop that caused the first argument to be skipped.
Changes:
- Fixed event parsing to start from index 0 instead of 1 in
event_notify_parsefunction - Added new
Send_UEvent_Notify_Devicefunction for sending unconfirmed event notifications by device ID - Enhanced
apps/uevent/main.cwith device binding logic, event loop, and comprehensive help text - Updated
apps/event/main.cto use the fixed parsing logic and added usage examples
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/bacnet/event.c | Fixed loop initialization in event_notify_parse from argi = 1 to argi = 0 to correctly parse all arguments |
| src/bacnet/basic/service/s_uevent.h | Added declaration for new Send_UEvent_Notify_Device function |
| src/bacnet/basic/service/s_uevent.c | Implemented Send_UEvent_Notify_Device to send notifications by device ID using address cache lookup |
| apps/uevent/main.c | Added device binding logic, event loop with timeout handling, receive buffer, and extensive help documentation |
| apps/event/main.c | Updated to use fixed event_notify_parse with proper error handling and added usage example |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.