From a0f84bd07d577d5c10e472fd86c87e21d5376764 Mon Sep 17 00:00:00 2001
From: Alberto Nidasio <alberto.nidasio@skywarder.eu>
Date: Sat, 7 May 2022 16:53:15 +0200
Subject: [PATCH] [Servo] Fixed ServoData header and print functions
---
src/shared/actuators/Servo/ServoData.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/shared/actuators/Servo/ServoData.h b/src/shared/actuators/Servo/ServoData.h
index bbed26513..b4ff14d35 100644
--- a/src/shared/actuators/Servo/ServoData.h
+++ b/src/shared/actuators/Servo/ServoData.h
@@ -34,11 +34,12 @@ struct ServoData
uint8_t channel;
float position;
- static std::string header() { return "timestamp,position\n"; }
+ static std::string header() { return "timestamp,timer,channel,position\n"; }
void print(std::ostream& os) const
{
- os << timestamp << "," << position << "\n";
+ os << timestamp << "," << timer << "," << channel << "," << position
+ << "\n";
}
};
--
GitLab