Skip to content

Document the RELY log message #30061

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 2 commits into from
May 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Tools/autotest/vehicle_test_suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -3099,7 +3099,6 @@ def LoggerDocumentation_greylist(self):
"IREG", # INS something
"ISBD", # InertialSensor batch logging
"ISBH", # InertialSensor batch logging
"RELY", # relay
"RTCM", # GPS
"SBRE", # septentrio

Expand Down
20 changes: 15 additions & 5 deletions libraries/AP_Relay/AP_Relay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -400,11 +400,21 @@ void AP_Relay::set_pin_by_instance(uint8_t instance, bool value)
if (initial_value != value) {
set_pin(pin, value);
#if HAL_LOGGING_ENABLED
AP::logger().Write("RELY", "TimeUS,Instance,State", "s#-", "F--", "QBB",
AP_HAL::micros64(),
instance,
value);
#endif
// @LoggerMessage: RELY
// @Description: Relay state
// @Field: TimeUS: Time since system startup
// @Field: Instance: relay instance number
// @Field: State: current state
AP::logger().Write(
"RELY",
"TimeUS," "Instance," "State",
"s" "#" "-",
"F" "-" "-",
"Q" "B" "B",
AP_HAL::micros64(),
instance,
value);
#endif // HAL_LOGGING_ENABLED
}
}

Expand Down
Loading