mirror of
https://github.com/thooge/esp32-nmea2000-obp60.git
synced 2025-12-14 06:23:07 +01:00
#103: using formatters
This commit is contained in:
@@ -493,6 +493,11 @@ double formatKnots(double cv)
|
||||
return cv * 3600.0 / 1852.0;
|
||||
}
|
||||
|
||||
double formatKmh(double cv)
|
||||
{
|
||||
return cv *3600.0 / 1000.0;
|
||||
}
|
||||
|
||||
uint32_t mtr2nm(uint32_t m)
|
||||
{
|
||||
return m / 1852;
|
||||
@@ -523,4 +528,4 @@ public:
|
||||
};
|
||||
static XWriter xwriter;
|
||||
ARDUINOJSON_NAMESPACE::TextFormatter<XWriter> testWriter(xwriter);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -129,6 +129,7 @@ double formatCourse(double cv);
|
||||
double formatDegToRad(double deg);
|
||||
double formatWind(double cv);
|
||||
double formatKnots(double cv);
|
||||
double formatKmh(double cv);
|
||||
uint32_t mtr2nm(uint32_t m);
|
||||
double mtr2nm(double m);
|
||||
|
||||
@@ -251,4 +252,4 @@ class GwBoatData{
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user