Skip to content

Commit

Permalink
RpmControl: call local message instance after message name following …
Browse files Browse the repository at this point in the history
…the convention
  • Loading branch information
MaEtUgR committed Dec 12, 2024
1 parent 4a9931f commit 404c394
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,12 @@ class RpmControl : public ModuleParams
float getActuatorCorrection()
{
if (_rpm_sub.updated()) {
rpm_s rpm_input{};
rpm_s rpm{};

if (_rpm_sub.copy(&rpm_input)) {
_rpm_estimate = rpm_input.rpm_estimate;
_rpm_raw = rpm_input.rpm_raw;
_timestamp_last_rpm_measurement = rpm_input.timestamp;
if (_rpm_sub.copy(&rpm)) {
_rpm_estimate = rpm.rpm_estimate;
_rpm_raw = rpm.rpm_raw;
_timestamp_last_rpm_measurement = rpm.timestamp;
}
}

Expand Down

0 comments on commit 404c394

Please sign in to comment.