• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mavlink / MAVSDK / 7253873526

18 Dec 2023 09:13PM UTC coverage: 37.119% (-0.2%) from 37.344%
7253873526

push

github

web-flow
Merge pull request #2093 from prokas-nikos/dist_sensor_orientation

Customizing distance sensor to add orientation for multiple sensor support

0 of 165 new or added lines in 2 files covered. (0.0%)

1 existing line in 1 file now uncovered.

10071 of 27132 relevant lines covered (37.12%)

115.98 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

1.52
/src/mavsdk/plugins/telemetry/telemetry.cpp
1
// WARNING: THIS FILE IS AUTOGENERATED! As such, it should not be edited.
2
// Edits need to be made to the proto files
3
// (see https://github.com/mavlink/MAVSDK-Proto/blob/master/protos/telemetry/telemetry.proto)
4

5
#include <iomanip>
6

7
#include "telemetry_impl.h"
8
#include "plugins/telemetry/telemetry.h"
9

10
namespace mavsdk {
11

12
using Position = Telemetry::Position;
13
using Heading = Telemetry::Heading;
14
using Quaternion = Telemetry::Quaternion;
15
using EulerAngle = Telemetry::EulerAngle;
16
using AngularVelocityBody = Telemetry::AngularVelocityBody;
17
using GpsInfo = Telemetry::GpsInfo;
18
using RawGps = Telemetry::RawGps;
19
using Battery = Telemetry::Battery;
20
using Health = Telemetry::Health;
21
using RcStatus = Telemetry::RcStatus;
22
using StatusText = Telemetry::StatusText;
23
using ActuatorControlTarget = Telemetry::ActuatorControlTarget;
24
using ActuatorOutputStatus = Telemetry::ActuatorOutputStatus;
25
using Covariance = Telemetry::Covariance;
26
using VelocityBody = Telemetry::VelocityBody;
27
using PositionBody = Telemetry::PositionBody;
28
using Odometry = Telemetry::Odometry;
29
using DistanceSensor = Telemetry::DistanceSensor;
30
using ScaledPressure = Telemetry::ScaledPressure;
31
using PositionNed = Telemetry::PositionNed;
32
using VelocityNed = Telemetry::VelocityNed;
33
using PositionVelocityNed = Telemetry::PositionVelocityNed;
34
using GroundTruth = Telemetry::GroundTruth;
35
using FixedwingMetrics = Telemetry::FixedwingMetrics;
36
using AccelerationFrd = Telemetry::AccelerationFrd;
37
using AngularVelocityFrd = Telemetry::AngularVelocityFrd;
38
using MagneticFieldFrd = Telemetry::MagneticFieldFrd;
39
using Imu = Telemetry::Imu;
40
using GpsGlobalOrigin = Telemetry::GpsGlobalOrigin;
41
using Altitude = Telemetry::Altitude;
42

43
Telemetry::Telemetry(System& system) : PluginBase(), _impl{std::make_unique<TelemetryImpl>(system)}
×
44
{}
×
45

46
Telemetry::Telemetry(std::shared_ptr<System> system) :
1✔
47
    PluginBase(),
48
    _impl{std::make_unique<TelemetryImpl>(system)}
1✔
49
{}
1✔
50

51
Telemetry::~Telemetry() {}
1✔
52

53
Telemetry::PositionHandle Telemetry::subscribe_position(const PositionCallback& callback)
×
54
{
55
    return _impl->subscribe_position(callback);
×
56
}
57

58
void Telemetry::unsubscribe_position(PositionHandle handle)
×
59
{
60
    _impl->unsubscribe_position(handle);
×
61
}
×
62

63
Telemetry::Position Telemetry::position() const
×
64
{
65
    return _impl->position();
×
66
}
67

68
Telemetry::HomeHandle Telemetry::subscribe_home(const HomeCallback& callback)
×
69
{
70
    return _impl->subscribe_home(callback);
×
71
}
72

73
void Telemetry::unsubscribe_home(HomeHandle handle)
×
74
{
75
    _impl->unsubscribe_home(handle);
×
76
}
×
77

78
Telemetry::Position Telemetry::home() const
×
79
{
80
    return _impl->home();
×
81
}
82

83
Telemetry::InAirHandle Telemetry::subscribe_in_air(const InAirCallback& callback)
×
84
{
85
    return _impl->subscribe_in_air(callback);
×
86
}
87

88
void Telemetry::unsubscribe_in_air(InAirHandle handle)
×
89
{
90
    _impl->unsubscribe_in_air(handle);
×
91
}
×
92

93
bool Telemetry::in_air() const
×
94
{
95
    return _impl->in_air();
×
96
}
97

98
Telemetry::LandedStateHandle Telemetry::subscribe_landed_state(const LandedStateCallback& callback)
×
99
{
100
    return _impl->subscribe_landed_state(callback);
×
101
}
102

103
void Telemetry::unsubscribe_landed_state(LandedStateHandle handle)
×
104
{
105
    _impl->unsubscribe_landed_state(handle);
×
106
}
×
107

108
Telemetry::LandedState Telemetry::landed_state() const
×
109
{
110
    return _impl->landed_state();
×
111
}
112

113
Telemetry::ArmedHandle Telemetry::subscribe_armed(const ArmedCallback& callback)
×
114
{
115
    return _impl->subscribe_armed(callback);
×
116
}
117

118
void Telemetry::unsubscribe_armed(ArmedHandle handle)
×
119
{
120
    _impl->unsubscribe_armed(handle);
×
121
}
×
122

123
bool Telemetry::armed() const
×
124
{
125
    return _impl->armed();
×
126
}
127

128
Telemetry::VtolStateHandle Telemetry::subscribe_vtol_state(const VtolStateCallback& callback)
×
129
{
130
    return _impl->subscribe_vtol_state(callback);
×
131
}
132

133
void Telemetry::unsubscribe_vtol_state(VtolStateHandle handle)
×
134
{
135
    _impl->unsubscribe_vtol_state(handle);
×
136
}
×
137

138
Telemetry::VtolState Telemetry::vtol_state() const
×
139
{
140
    return _impl->vtol_state();
×
141
}
142

143
Telemetry::AttitudeQuaternionHandle
144
Telemetry::subscribe_attitude_quaternion(const AttitudeQuaternionCallback& callback)
×
145
{
146
    return _impl->subscribe_attitude_quaternion(callback);
×
147
}
148

149
void Telemetry::unsubscribe_attitude_quaternion(AttitudeQuaternionHandle handle)
×
150
{
151
    _impl->unsubscribe_attitude_quaternion(handle);
×
152
}
×
153

154
Telemetry::Quaternion Telemetry::attitude_quaternion() const
×
155
{
156
    return _impl->attitude_quaternion();
×
157
}
158

159
Telemetry::AttitudeEulerHandle
160
Telemetry::subscribe_attitude_euler(const AttitudeEulerCallback& callback)
×
161
{
162
    return _impl->subscribe_attitude_euler(callback);
×
163
}
164

165
void Telemetry::unsubscribe_attitude_euler(AttitudeEulerHandle handle)
×
166
{
167
    _impl->unsubscribe_attitude_euler(handle);
×
168
}
×
169

170
Telemetry::EulerAngle Telemetry::attitude_euler() const
×
171
{
172
    return _impl->attitude_euler();
×
173
}
174

175
Telemetry::AttitudeAngularVelocityBodyHandle Telemetry::subscribe_attitude_angular_velocity_body(
×
176
    const AttitudeAngularVelocityBodyCallback& callback)
177
{
178
    return _impl->subscribe_attitude_angular_velocity_body(callback);
×
179
}
180

181
void Telemetry::unsubscribe_attitude_angular_velocity_body(AttitudeAngularVelocityBodyHandle handle)
×
182
{
183
    _impl->unsubscribe_attitude_angular_velocity_body(handle);
×
184
}
×
185

186
Telemetry::AngularVelocityBody Telemetry::attitude_angular_velocity_body() const
×
187
{
188
    return _impl->attitude_angular_velocity_body();
×
189
}
190

191
Telemetry::CameraAttitudeQuaternionHandle
192
Telemetry::subscribe_camera_attitude_quaternion(const CameraAttitudeQuaternionCallback& callback)
×
193
{
194
    return _impl->subscribe_camera_attitude_quaternion(callback);
×
195
}
196

197
void Telemetry::unsubscribe_camera_attitude_quaternion(CameraAttitudeQuaternionHandle handle)
×
198
{
199
    _impl->unsubscribe_camera_attitude_quaternion(handle);
×
200
}
×
201

202
Telemetry::Quaternion Telemetry::camera_attitude_quaternion() const
×
203
{
204
    return _impl->camera_attitude_quaternion();
×
205
}
206

207
Telemetry::CameraAttitudeEulerHandle
208
Telemetry::subscribe_camera_attitude_euler(const CameraAttitudeEulerCallback& callback)
×
209
{
210
    return _impl->subscribe_camera_attitude_euler(callback);
×
211
}
212

213
void Telemetry::unsubscribe_camera_attitude_euler(CameraAttitudeEulerHandle handle)
×
214
{
215
    _impl->unsubscribe_camera_attitude_euler(handle);
×
216
}
×
217

218
Telemetry::EulerAngle Telemetry::camera_attitude_euler() const
×
219
{
220
    return _impl->camera_attitude_euler();
×
221
}
222

223
Telemetry::VelocityNedHandle Telemetry::subscribe_velocity_ned(const VelocityNedCallback& callback)
×
224
{
225
    return _impl->subscribe_velocity_ned(callback);
×
226
}
227

228
void Telemetry::unsubscribe_velocity_ned(VelocityNedHandle handle)
×
229
{
230
    _impl->unsubscribe_velocity_ned(handle);
×
231
}
×
232

233
Telemetry::VelocityNed Telemetry::velocity_ned() const
×
234
{
235
    return _impl->velocity_ned();
×
236
}
237

238
Telemetry::GpsInfoHandle Telemetry::subscribe_gps_info(const GpsInfoCallback& callback)
×
239
{
240
    return _impl->subscribe_gps_info(callback);
×
241
}
242

243
void Telemetry::unsubscribe_gps_info(GpsInfoHandle handle)
×
244
{
245
    _impl->unsubscribe_gps_info(handle);
×
246
}
×
247

248
Telemetry::GpsInfo Telemetry::gps_info() const
×
249
{
250
    return _impl->gps_info();
×
251
}
252

253
Telemetry::RawGpsHandle Telemetry::subscribe_raw_gps(const RawGpsCallback& callback)
×
254
{
255
    return _impl->subscribe_raw_gps(callback);
×
256
}
257

258
void Telemetry::unsubscribe_raw_gps(RawGpsHandle handle)
×
259
{
260
    _impl->unsubscribe_raw_gps(handle);
×
261
}
×
262

263
Telemetry::RawGps Telemetry::raw_gps() const
×
264
{
265
    return _impl->raw_gps();
×
266
}
267

268
Telemetry::BatteryHandle Telemetry::subscribe_battery(const BatteryCallback& callback)
×
269
{
270
    return _impl->subscribe_battery(callback);
×
271
}
272

273
void Telemetry::unsubscribe_battery(BatteryHandle handle)
×
274
{
275
    _impl->unsubscribe_battery(handle);
×
276
}
×
277

278
Telemetry::Battery Telemetry::battery() const
×
279
{
280
    return _impl->battery();
×
281
}
282

283
Telemetry::FlightModeHandle Telemetry::subscribe_flight_mode(const FlightModeCallback& callback)
×
284
{
285
    return _impl->subscribe_flight_mode(callback);
×
286
}
287

288
void Telemetry::unsubscribe_flight_mode(FlightModeHandle handle)
×
289
{
290
    _impl->unsubscribe_flight_mode(handle);
×
291
}
×
292

293
Telemetry::FlightMode Telemetry::flight_mode() const
×
294
{
295
    return _impl->flight_mode();
×
296
}
297

298
Telemetry::HealthHandle Telemetry::subscribe_health(const HealthCallback& callback)
×
299
{
300
    return _impl->subscribe_health(callback);
×
301
}
302

303
void Telemetry::unsubscribe_health(HealthHandle handle)
×
304
{
305
    _impl->unsubscribe_health(handle);
×
306
}
×
307

308
Telemetry::Health Telemetry::health() const
×
309
{
310
    return _impl->health();
×
311
}
312

313
Telemetry::RcStatusHandle Telemetry::subscribe_rc_status(const RcStatusCallback& callback)
×
314
{
315
    return _impl->subscribe_rc_status(callback);
×
316
}
317

318
void Telemetry::unsubscribe_rc_status(RcStatusHandle handle)
×
319
{
320
    _impl->unsubscribe_rc_status(handle);
×
321
}
×
322

323
Telemetry::RcStatus Telemetry::rc_status() const
×
324
{
325
    return _impl->rc_status();
×
326
}
327

328
Telemetry::StatusTextHandle Telemetry::subscribe_status_text(const StatusTextCallback& callback)
2✔
329
{
330
    return _impl->subscribe_status_text(callback);
2✔
331
}
332

333
void Telemetry::unsubscribe_status_text(StatusTextHandle handle)
1✔
334
{
335
    _impl->unsubscribe_status_text(handle);
1✔
336
}
1✔
337

338
Telemetry::StatusText Telemetry::status_text() const
×
339
{
340
    return _impl->status_text();
×
341
}
342

343
Telemetry::ActuatorControlTargetHandle
344
Telemetry::subscribe_actuator_control_target(const ActuatorControlTargetCallback& callback)
×
345
{
346
    return _impl->subscribe_actuator_control_target(callback);
×
347
}
348

349
void Telemetry::unsubscribe_actuator_control_target(ActuatorControlTargetHandle handle)
×
350
{
351
    _impl->unsubscribe_actuator_control_target(handle);
×
352
}
×
353

354
Telemetry::ActuatorControlTarget Telemetry::actuator_control_target() const
×
355
{
356
    return _impl->actuator_control_target();
×
357
}
358

359
Telemetry::ActuatorOutputStatusHandle
360
Telemetry::subscribe_actuator_output_status(const ActuatorOutputStatusCallback& callback)
×
361
{
362
    return _impl->subscribe_actuator_output_status(callback);
×
363
}
364

365
void Telemetry::unsubscribe_actuator_output_status(ActuatorOutputStatusHandle handle)
×
366
{
367
    _impl->unsubscribe_actuator_output_status(handle);
×
368
}
×
369

370
Telemetry::ActuatorOutputStatus Telemetry::actuator_output_status() const
×
371
{
372
    return _impl->actuator_output_status();
×
373
}
374

375
Telemetry::OdometryHandle Telemetry::subscribe_odometry(const OdometryCallback& callback)
×
376
{
377
    return _impl->subscribe_odometry(callback);
×
378
}
379

380
void Telemetry::unsubscribe_odometry(OdometryHandle handle)
×
381
{
382
    _impl->unsubscribe_odometry(handle);
×
383
}
×
384

385
Telemetry::Odometry Telemetry::odometry() const
×
386
{
387
    return _impl->odometry();
×
388
}
389

390
Telemetry::PositionVelocityNedHandle
391
Telemetry::subscribe_position_velocity_ned(const PositionVelocityNedCallback& callback)
×
392
{
393
    return _impl->subscribe_position_velocity_ned(callback);
×
394
}
395

396
void Telemetry::unsubscribe_position_velocity_ned(PositionVelocityNedHandle handle)
×
397
{
398
    _impl->unsubscribe_position_velocity_ned(handle);
×
399
}
×
400

401
Telemetry::PositionVelocityNed Telemetry::position_velocity_ned() const
×
402
{
403
    return _impl->position_velocity_ned();
×
404
}
405

406
Telemetry::GroundTruthHandle Telemetry::subscribe_ground_truth(const GroundTruthCallback& callback)
×
407
{
408
    return _impl->subscribe_ground_truth(callback);
×
409
}
410

411
void Telemetry::unsubscribe_ground_truth(GroundTruthHandle handle)
×
412
{
413
    _impl->unsubscribe_ground_truth(handle);
×
414
}
×
415

416
Telemetry::GroundTruth Telemetry::ground_truth() const
×
417
{
418
    return _impl->ground_truth();
×
419
}
420

421
Telemetry::FixedwingMetricsHandle
422
Telemetry::subscribe_fixedwing_metrics(const FixedwingMetricsCallback& callback)
×
423
{
424
    return _impl->subscribe_fixedwing_metrics(callback);
×
425
}
426

427
void Telemetry::unsubscribe_fixedwing_metrics(FixedwingMetricsHandle handle)
×
428
{
429
    _impl->unsubscribe_fixedwing_metrics(handle);
×
430
}
×
431

432
Telemetry::FixedwingMetrics Telemetry::fixedwing_metrics() const
×
433
{
434
    return _impl->fixedwing_metrics();
×
435
}
436

437
Telemetry::ImuHandle Telemetry::subscribe_imu(const ImuCallback& callback)
×
438
{
439
    return _impl->subscribe_imu(callback);
×
440
}
441

442
void Telemetry::unsubscribe_imu(ImuHandle handle)
×
443
{
444
    _impl->unsubscribe_imu(handle);
×
445
}
×
446

447
Telemetry::Imu Telemetry::imu() const
×
448
{
449
    return _impl->imu();
×
450
}
451

452
Telemetry::ScaledImuHandle Telemetry::subscribe_scaled_imu(const ScaledImuCallback& callback)
×
453
{
454
    return _impl->subscribe_scaled_imu(callback);
×
455
}
456

457
void Telemetry::unsubscribe_scaled_imu(ScaledImuHandle handle)
×
458
{
459
    _impl->unsubscribe_scaled_imu(handle);
×
460
}
×
461

462
Telemetry::Imu Telemetry::scaled_imu() const
×
463
{
464
    return _impl->scaled_imu();
×
465
}
466

467
Telemetry::RawImuHandle Telemetry::subscribe_raw_imu(const RawImuCallback& callback)
×
468
{
469
    return _impl->subscribe_raw_imu(callback);
×
470
}
471

472
void Telemetry::unsubscribe_raw_imu(RawImuHandle handle)
×
473
{
474
    _impl->unsubscribe_raw_imu(handle);
×
475
}
×
476

477
Telemetry::Imu Telemetry::raw_imu() const
×
478
{
479
    return _impl->raw_imu();
×
480
}
481

482
Telemetry::HealthAllOkHandle Telemetry::subscribe_health_all_ok(const HealthAllOkCallback& callback)
×
483
{
484
    return _impl->subscribe_health_all_ok(callback);
×
485
}
486

487
void Telemetry::unsubscribe_health_all_ok(HealthAllOkHandle handle)
×
488
{
489
    _impl->unsubscribe_health_all_ok(handle);
×
490
}
×
491

492
bool Telemetry::health_all_ok() const
×
493
{
494
    return _impl->health_all_ok();
×
495
}
496

497
Telemetry::UnixEpochTimeHandle
498
Telemetry::subscribe_unix_epoch_time(const UnixEpochTimeCallback& callback)
×
499
{
500
    return _impl->subscribe_unix_epoch_time(callback);
×
501
}
502

503
void Telemetry::unsubscribe_unix_epoch_time(UnixEpochTimeHandle handle)
×
504
{
505
    _impl->unsubscribe_unix_epoch_time(handle);
×
506
}
×
507

508
uint64_t Telemetry::unix_epoch_time() const
×
509
{
510
    return _impl->unix_epoch_time();
×
511
}
512

513
Telemetry::DistanceSensorHandle
514
Telemetry::subscribe_distance_sensor(const DistanceSensorCallback& callback)
×
515
{
516
    return _impl->subscribe_distance_sensor(callback);
×
517
}
518

519
void Telemetry::unsubscribe_distance_sensor(DistanceSensorHandle handle)
×
520
{
521
    _impl->unsubscribe_distance_sensor(handle);
×
522
}
×
523

524
Telemetry::DistanceSensor Telemetry::distance_sensor() const
×
525
{
526
    return _impl->distance_sensor();
×
527
}
528

529
Telemetry::ScaledPressureHandle
530
Telemetry::subscribe_scaled_pressure(const ScaledPressureCallback& callback)
×
531
{
532
    return _impl->subscribe_scaled_pressure(callback);
×
533
}
534

535
void Telemetry::unsubscribe_scaled_pressure(ScaledPressureHandle handle)
×
536
{
537
    _impl->unsubscribe_scaled_pressure(handle);
×
538
}
×
539

540
Telemetry::ScaledPressure Telemetry::scaled_pressure() const
×
541
{
542
    return _impl->scaled_pressure();
×
543
}
544

545
Telemetry::HeadingHandle Telemetry::subscribe_heading(const HeadingCallback& callback)
×
546
{
547
    return _impl->subscribe_heading(callback);
×
548
}
549

550
void Telemetry::unsubscribe_heading(HeadingHandle handle)
×
551
{
552
    _impl->unsubscribe_heading(handle);
×
553
}
×
554

555
Telemetry::Heading Telemetry::heading() const
×
556
{
557
    return _impl->heading();
×
558
}
559

560
Telemetry::AltitudeHandle Telemetry::subscribe_altitude(const AltitudeCallback& callback)
×
561
{
562
    return _impl->subscribe_altitude(callback);
×
563
}
564

565
void Telemetry::unsubscribe_altitude(AltitudeHandle handle)
×
566
{
567
    _impl->unsubscribe_altitude(handle);
×
568
}
×
569

570
Telemetry::Altitude Telemetry::altitude() const
×
571
{
572
    return _impl->altitude();
×
573
}
574

575
void Telemetry::set_rate_position_async(double rate_hz, const ResultCallback callback)
×
576
{
577
    _impl->set_rate_position_async(rate_hz, callback);
×
578
}
×
579

580
Telemetry::Result Telemetry::set_rate_position(double rate_hz) const
×
581
{
582
    return _impl->set_rate_position(rate_hz);
×
583
}
584

585
void Telemetry::set_rate_home_async(double rate_hz, const ResultCallback callback)
×
586
{
587
    _impl->set_rate_home_async(rate_hz, callback);
×
588
}
×
589

590
Telemetry::Result Telemetry::set_rate_home(double rate_hz) const
×
591
{
592
    return _impl->set_rate_home(rate_hz);
×
593
}
594

595
void Telemetry::set_rate_in_air_async(double rate_hz, const ResultCallback callback)
×
596
{
597
    _impl->set_rate_in_air_async(rate_hz, callback);
×
598
}
×
599

600
Telemetry::Result Telemetry::set_rate_in_air(double rate_hz) const
×
601
{
602
    return _impl->set_rate_in_air(rate_hz);
×
603
}
604

605
void Telemetry::set_rate_landed_state_async(double rate_hz, const ResultCallback callback)
×
606
{
607
    _impl->set_rate_landed_state_async(rate_hz, callback);
×
608
}
×
609

610
Telemetry::Result Telemetry::set_rate_landed_state(double rate_hz) const
×
611
{
612
    return _impl->set_rate_landed_state(rate_hz);
×
613
}
614

615
void Telemetry::set_rate_vtol_state_async(double rate_hz, const ResultCallback callback)
×
616
{
617
    _impl->set_rate_vtol_state_async(rate_hz, callback);
×
618
}
×
619

620
Telemetry::Result Telemetry::set_rate_vtol_state(double rate_hz) const
×
621
{
622
    return _impl->set_rate_vtol_state(rate_hz);
×
623
}
624

625
void Telemetry::set_rate_attitude_quaternion_async(double rate_hz, const ResultCallback callback)
×
626
{
627
    _impl->set_rate_attitude_quaternion_async(rate_hz, callback);
×
628
}
×
629

630
Telemetry::Result Telemetry::set_rate_attitude_quaternion(double rate_hz) const
×
631
{
632
    return _impl->set_rate_attitude_quaternion(rate_hz);
×
633
}
634

635
void Telemetry::set_rate_attitude_euler_async(double rate_hz, const ResultCallback callback)
×
636
{
637
    _impl->set_rate_attitude_euler_async(rate_hz, callback);
×
638
}
×
639

640
Telemetry::Result Telemetry::set_rate_attitude_euler(double rate_hz) const
×
641
{
642
    return _impl->set_rate_attitude_euler(rate_hz);
×
643
}
644

645
void Telemetry::set_rate_camera_attitude_async(double rate_hz, const ResultCallback callback)
×
646
{
647
    _impl->set_rate_camera_attitude_async(rate_hz, callback);
×
648
}
×
649

650
Telemetry::Result Telemetry::set_rate_camera_attitude(double rate_hz) const
×
651
{
652
    return _impl->set_rate_camera_attitude(rate_hz);
×
653
}
654

655
void Telemetry::set_rate_velocity_ned_async(double rate_hz, const ResultCallback callback)
×
656
{
657
    _impl->set_rate_velocity_ned_async(rate_hz, callback);
×
658
}
×
659

660
Telemetry::Result Telemetry::set_rate_velocity_ned(double rate_hz) const
×
661
{
662
    return _impl->set_rate_velocity_ned(rate_hz);
×
663
}
664

665
void Telemetry::set_rate_gps_info_async(double rate_hz, const ResultCallback callback)
×
666
{
667
    _impl->set_rate_gps_info_async(rate_hz, callback);
×
668
}
×
669

670
Telemetry::Result Telemetry::set_rate_gps_info(double rate_hz) const
×
671
{
672
    return _impl->set_rate_gps_info(rate_hz);
×
673
}
674

675
void Telemetry::set_rate_battery_async(double rate_hz, const ResultCallback callback)
×
676
{
677
    _impl->set_rate_battery_async(rate_hz, callback);
×
678
}
×
679

680
Telemetry::Result Telemetry::set_rate_battery(double rate_hz) const
×
681
{
682
    return _impl->set_rate_battery(rate_hz);
×
683
}
684

685
void Telemetry::set_rate_rc_status_async(double rate_hz, const ResultCallback callback)
×
686
{
687
    _impl->set_rate_rc_status_async(rate_hz, callback);
×
688
}
×
689

690
Telemetry::Result Telemetry::set_rate_rc_status(double rate_hz) const
×
691
{
692
    return _impl->set_rate_rc_status(rate_hz);
×
693
}
694

695
void Telemetry::set_rate_actuator_control_target_async(
×
696
    double rate_hz, const ResultCallback callback)
697
{
698
    _impl->set_rate_actuator_control_target_async(rate_hz, callback);
×
699
}
×
700

701
Telemetry::Result Telemetry::set_rate_actuator_control_target(double rate_hz) const
×
702
{
703
    return _impl->set_rate_actuator_control_target(rate_hz);
×
704
}
705

706
void Telemetry::set_rate_actuator_output_status_async(double rate_hz, const ResultCallback callback)
×
707
{
708
    _impl->set_rate_actuator_output_status_async(rate_hz, callback);
×
709
}
×
710

711
Telemetry::Result Telemetry::set_rate_actuator_output_status(double rate_hz) const
×
712
{
713
    return _impl->set_rate_actuator_output_status(rate_hz);
×
714
}
715

716
void Telemetry::set_rate_odometry_async(double rate_hz, const ResultCallback callback)
×
717
{
718
    _impl->set_rate_odometry_async(rate_hz, callback);
×
719
}
×
720

721
Telemetry::Result Telemetry::set_rate_odometry(double rate_hz) const
×
722
{
723
    return _impl->set_rate_odometry(rate_hz);
×
724
}
725

726
void Telemetry::set_rate_position_velocity_ned_async(double rate_hz, const ResultCallback callback)
×
727
{
728
    _impl->set_rate_position_velocity_ned_async(rate_hz, callback);
×
729
}
×
730

731
Telemetry::Result Telemetry::set_rate_position_velocity_ned(double rate_hz) const
×
732
{
733
    return _impl->set_rate_position_velocity_ned(rate_hz);
×
734
}
735

736
void Telemetry::set_rate_ground_truth_async(double rate_hz, const ResultCallback callback)
×
737
{
738
    _impl->set_rate_ground_truth_async(rate_hz, callback);
×
739
}
×
740

741
Telemetry::Result Telemetry::set_rate_ground_truth(double rate_hz) const
×
742
{
743
    return _impl->set_rate_ground_truth(rate_hz);
×
744
}
745

746
void Telemetry::set_rate_fixedwing_metrics_async(double rate_hz, const ResultCallback callback)
×
747
{
748
    _impl->set_rate_fixedwing_metrics_async(rate_hz, callback);
×
749
}
×
750

751
Telemetry::Result Telemetry::set_rate_fixedwing_metrics(double rate_hz) const
×
752
{
753
    return _impl->set_rate_fixedwing_metrics(rate_hz);
×
754
}
755

756
void Telemetry::set_rate_imu_async(double rate_hz, const ResultCallback callback)
×
757
{
758
    _impl->set_rate_imu_async(rate_hz, callback);
×
759
}
×
760

761
Telemetry::Result Telemetry::set_rate_imu(double rate_hz) const
×
762
{
763
    return _impl->set_rate_imu(rate_hz);
×
764
}
765

766
void Telemetry::set_rate_scaled_imu_async(double rate_hz, const ResultCallback callback)
×
767
{
768
    _impl->set_rate_scaled_imu_async(rate_hz, callback);
×
769
}
×
770

771
Telemetry::Result Telemetry::set_rate_scaled_imu(double rate_hz) const
×
772
{
773
    return _impl->set_rate_scaled_imu(rate_hz);
×
774
}
775

776
void Telemetry::set_rate_raw_imu_async(double rate_hz, const ResultCallback callback)
×
777
{
778
    _impl->set_rate_raw_imu_async(rate_hz, callback);
×
779
}
×
780

781
Telemetry::Result Telemetry::set_rate_raw_imu(double rate_hz) const
×
782
{
783
    return _impl->set_rate_raw_imu(rate_hz);
×
784
}
785

786
void Telemetry::set_rate_unix_epoch_time_async(double rate_hz, const ResultCallback callback)
×
787
{
788
    _impl->set_rate_unix_epoch_time_async(rate_hz, callback);
×
789
}
×
790

791
Telemetry::Result Telemetry::set_rate_unix_epoch_time(double rate_hz) const
×
792
{
793
    return _impl->set_rate_unix_epoch_time(rate_hz);
×
794
}
795

796
void Telemetry::set_rate_distance_sensor_async(double rate_hz, const ResultCallback callback)
×
797
{
798
    _impl->set_rate_distance_sensor_async(rate_hz, callback);
×
799
}
×
800

801
Telemetry::Result Telemetry::set_rate_distance_sensor(double rate_hz) const
×
802
{
803
    return _impl->set_rate_distance_sensor(rate_hz);
×
804
}
805

806
void Telemetry::set_rate_altitude_async(double rate_hz, const ResultCallback callback)
×
807
{
808
    _impl->set_rate_altitude_async(rate_hz, callback);
×
809
}
×
810

811
Telemetry::Result Telemetry::set_rate_altitude(double rate_hz) const
×
812
{
813
    return _impl->set_rate_altitude(rate_hz);
×
814
}
815

816
void Telemetry::get_gps_global_origin_async(const GetGpsGlobalOriginCallback callback)
×
817
{
818
    _impl->get_gps_global_origin_async(callback);
×
819
}
×
820

821
std::pair<Telemetry::Result, Telemetry::GpsGlobalOrigin> Telemetry::get_gps_global_origin() const
×
822
{
823
    return _impl->get_gps_global_origin();
×
824
}
825

826
bool operator==(const Telemetry::Position& lhs, const Telemetry::Position& rhs)
×
827
{
828
    return ((std::isnan(rhs.latitude_deg) && std::isnan(lhs.latitude_deg)) ||
×
829
            rhs.latitude_deg == lhs.latitude_deg) &&
×
830
           ((std::isnan(rhs.longitude_deg) && std::isnan(lhs.longitude_deg)) ||
×
831
            rhs.longitude_deg == lhs.longitude_deg) &&
×
832
           ((std::isnan(rhs.absolute_altitude_m) && std::isnan(lhs.absolute_altitude_m)) ||
×
833
            rhs.absolute_altitude_m == lhs.absolute_altitude_m) &&
×
834
           ((std::isnan(rhs.relative_altitude_m) && std::isnan(lhs.relative_altitude_m)) ||
×
835
            rhs.relative_altitude_m == lhs.relative_altitude_m);
×
836
}
837

838
std::ostream& operator<<(std::ostream& str, Telemetry::Position const& position)
×
839
{
840
    str << std::setprecision(15);
×
841
    str << "position:" << '\n' << "{\n";
×
842
    str << "    latitude_deg: " << position.latitude_deg << '\n';
×
843
    str << "    longitude_deg: " << position.longitude_deg << '\n';
×
844
    str << "    absolute_altitude_m: " << position.absolute_altitude_m << '\n';
×
845
    str << "    relative_altitude_m: " << position.relative_altitude_m << '\n';
×
846
    str << '}';
×
847
    return str;
×
848
}
849

850
bool operator==(const Telemetry::Heading& lhs, const Telemetry::Heading& rhs)
×
851
{
852
    return (
853
        (std::isnan(rhs.heading_deg) && std::isnan(lhs.heading_deg)) ||
×
854
        rhs.heading_deg == lhs.heading_deg);
×
855
}
856

857
std::ostream& operator<<(std::ostream& str, Telemetry::Heading const& heading)
×
858
{
859
    str << std::setprecision(15);
×
860
    str << "heading:" << '\n' << "{\n";
×
861
    str << "    heading_deg: " << heading.heading_deg << '\n';
×
862
    str << '}';
×
863
    return str;
×
864
}
865

866
bool operator==(const Telemetry::Quaternion& lhs, const Telemetry::Quaternion& rhs)
1✔
867
{
868
    return ((std::isnan(rhs.w) && std::isnan(lhs.w)) || rhs.w == lhs.w) &&
3✔
869
           ((std::isnan(rhs.x) && std::isnan(lhs.x)) || rhs.x == lhs.x) &&
3✔
870
           ((std::isnan(rhs.y) && std::isnan(lhs.y)) || rhs.y == lhs.y) &&
3✔
871
           ((std::isnan(rhs.z) && std::isnan(lhs.z)) || rhs.z == lhs.z) &&
4✔
872
           (rhs.timestamp_us == lhs.timestamp_us);
2✔
873
}
874

875
std::ostream& operator<<(std::ostream& str, Telemetry::Quaternion const& quaternion)
×
876
{
877
    str << std::setprecision(15);
×
878
    str << "quaternion:" << '\n' << "{\n";
×
879
    str << "    w: " << quaternion.w << '\n';
×
880
    str << "    x: " << quaternion.x << '\n';
×
881
    str << "    y: " << quaternion.y << '\n';
×
882
    str << "    z: " << quaternion.z << '\n';
×
883
    str << "    timestamp_us: " << quaternion.timestamp_us << '\n';
×
884
    str << '}';
×
885
    return str;
×
886
}
887

888
bool operator==(const Telemetry::EulerAngle& lhs, const Telemetry::EulerAngle& rhs)
×
889
{
890
    return ((std::isnan(rhs.roll_deg) && std::isnan(lhs.roll_deg)) ||
×
891
            rhs.roll_deg == lhs.roll_deg) &&
×
892
           ((std::isnan(rhs.pitch_deg) && std::isnan(lhs.pitch_deg)) ||
×
893
            rhs.pitch_deg == lhs.pitch_deg) &&
×
894
           ((std::isnan(rhs.yaw_deg) && std::isnan(lhs.yaw_deg)) || rhs.yaw_deg == lhs.yaw_deg) &&
×
895
           (rhs.timestamp_us == lhs.timestamp_us);
×
896
}
897

898
std::ostream& operator<<(std::ostream& str, Telemetry::EulerAngle const& euler_angle)
×
899
{
900
    str << std::setprecision(15);
×
901
    str << "euler_angle:" << '\n' << "{\n";
×
902
    str << "    roll_deg: " << euler_angle.roll_deg << '\n';
×
903
    str << "    pitch_deg: " << euler_angle.pitch_deg << '\n';
×
904
    str << "    yaw_deg: " << euler_angle.yaw_deg << '\n';
×
905
    str << "    timestamp_us: " << euler_angle.timestamp_us << '\n';
×
906
    str << '}';
×
907
    return str;
×
908
}
909

910
bool operator==(
×
911
    const Telemetry::AngularVelocityBody& lhs, const Telemetry::AngularVelocityBody& rhs)
912
{
913
    return ((std::isnan(rhs.roll_rad_s) && std::isnan(lhs.roll_rad_s)) ||
×
914
            rhs.roll_rad_s == lhs.roll_rad_s) &&
×
915
           ((std::isnan(rhs.pitch_rad_s) && std::isnan(lhs.pitch_rad_s)) ||
×
916
            rhs.pitch_rad_s == lhs.pitch_rad_s) &&
×
917
           ((std::isnan(rhs.yaw_rad_s) && std::isnan(lhs.yaw_rad_s)) ||
×
918
            rhs.yaw_rad_s == lhs.yaw_rad_s);
×
919
}
920

921
std::ostream&
922
operator<<(std::ostream& str, Telemetry::AngularVelocityBody const& angular_velocity_body)
×
923
{
924
    str << std::setprecision(15);
×
925
    str << "angular_velocity_body:" << '\n' << "{\n";
×
926
    str << "    roll_rad_s: " << angular_velocity_body.roll_rad_s << '\n';
×
927
    str << "    pitch_rad_s: " << angular_velocity_body.pitch_rad_s << '\n';
×
928
    str << "    yaw_rad_s: " << angular_velocity_body.yaw_rad_s << '\n';
×
929
    str << '}';
×
930
    return str;
×
931
}
932

933
bool operator==(const Telemetry::GpsInfo& lhs, const Telemetry::GpsInfo& rhs)
×
934
{
935
    return (rhs.num_satellites == lhs.num_satellites) && (rhs.fix_type == lhs.fix_type);
×
936
}
937

938
std::ostream& operator<<(std::ostream& str, Telemetry::GpsInfo const& gps_info)
×
939
{
940
    str << std::setprecision(15);
×
941
    str << "gps_info:" << '\n' << "{\n";
×
942
    str << "    num_satellites: " << gps_info.num_satellites << '\n';
×
943
    str << "    fix_type: " << gps_info.fix_type << '\n';
×
944
    str << '}';
×
945
    return str;
×
946
}
947

948
bool operator==(const Telemetry::RawGps& lhs, const Telemetry::RawGps& rhs)
×
949
{
950
    return (rhs.timestamp_us == lhs.timestamp_us) &&
×
951
           ((std::isnan(rhs.latitude_deg) && std::isnan(lhs.latitude_deg)) ||
×
952
            rhs.latitude_deg == lhs.latitude_deg) &&
×
953
           ((std::isnan(rhs.longitude_deg) && std::isnan(lhs.longitude_deg)) ||
×
954
            rhs.longitude_deg == lhs.longitude_deg) &&
×
955
           ((std::isnan(rhs.absolute_altitude_m) && std::isnan(lhs.absolute_altitude_m)) ||
×
956
            rhs.absolute_altitude_m == lhs.absolute_altitude_m) &&
×
957
           ((std::isnan(rhs.hdop) && std::isnan(lhs.hdop)) || rhs.hdop == lhs.hdop) &&
×
958
           ((std::isnan(rhs.vdop) && std::isnan(lhs.vdop)) || rhs.vdop == lhs.vdop) &&
×
959
           ((std::isnan(rhs.velocity_m_s) && std::isnan(lhs.velocity_m_s)) ||
×
960
            rhs.velocity_m_s == lhs.velocity_m_s) &&
×
961
           ((std::isnan(rhs.cog_deg) && std::isnan(lhs.cog_deg)) || rhs.cog_deg == lhs.cog_deg) &&
×
962
           ((std::isnan(rhs.altitude_ellipsoid_m) && std::isnan(lhs.altitude_ellipsoid_m)) ||
×
963
            rhs.altitude_ellipsoid_m == lhs.altitude_ellipsoid_m) &&
×
964
           ((std::isnan(rhs.horizontal_uncertainty_m) &&
×
965
             std::isnan(lhs.horizontal_uncertainty_m)) ||
×
966
            rhs.horizontal_uncertainty_m == lhs.horizontal_uncertainty_m) &&
×
967
           ((std::isnan(rhs.vertical_uncertainty_m) && std::isnan(lhs.vertical_uncertainty_m)) ||
×
968
            rhs.vertical_uncertainty_m == lhs.vertical_uncertainty_m) &&
×
969
           ((std::isnan(rhs.velocity_uncertainty_m_s) &&
×
970
             std::isnan(lhs.velocity_uncertainty_m_s)) ||
×
971
            rhs.velocity_uncertainty_m_s == lhs.velocity_uncertainty_m_s) &&
×
972
           ((std::isnan(rhs.heading_uncertainty_deg) && std::isnan(lhs.heading_uncertainty_deg)) ||
×
973
            rhs.heading_uncertainty_deg == lhs.heading_uncertainty_deg) &&
×
974
           ((std::isnan(rhs.yaw_deg) && std::isnan(lhs.yaw_deg)) || rhs.yaw_deg == lhs.yaw_deg);
×
975
}
976

977
std::ostream& operator<<(std::ostream& str, Telemetry::RawGps const& raw_gps)
×
978
{
979
    str << std::setprecision(15);
×
980
    str << "raw_gps:" << '\n' << "{\n";
×
981
    str << "    timestamp_us: " << raw_gps.timestamp_us << '\n';
×
982
    str << "    latitude_deg: " << raw_gps.latitude_deg << '\n';
×
983
    str << "    longitude_deg: " << raw_gps.longitude_deg << '\n';
×
984
    str << "    absolute_altitude_m: " << raw_gps.absolute_altitude_m << '\n';
×
985
    str << "    hdop: " << raw_gps.hdop << '\n';
×
986
    str << "    vdop: " << raw_gps.vdop << '\n';
×
987
    str << "    velocity_m_s: " << raw_gps.velocity_m_s << '\n';
×
988
    str << "    cog_deg: " << raw_gps.cog_deg << '\n';
×
989
    str << "    altitude_ellipsoid_m: " << raw_gps.altitude_ellipsoid_m << '\n';
×
990
    str << "    horizontal_uncertainty_m: " << raw_gps.horizontal_uncertainty_m << '\n';
×
991
    str << "    vertical_uncertainty_m: " << raw_gps.vertical_uncertainty_m << '\n';
×
992
    str << "    velocity_uncertainty_m_s: " << raw_gps.velocity_uncertainty_m_s << '\n';
×
993
    str << "    heading_uncertainty_deg: " << raw_gps.heading_uncertainty_deg << '\n';
×
994
    str << "    yaw_deg: " << raw_gps.yaw_deg << '\n';
×
995
    str << '}';
×
996
    return str;
×
997
}
998

999
bool operator==(const Telemetry::Battery& lhs, const Telemetry::Battery& rhs)
×
1000
{
1001
    return (rhs.id == lhs.id) &&
×
1002
           ((std::isnan(rhs.temperature_degc) && std::isnan(lhs.temperature_degc)) ||
×
1003
            rhs.temperature_degc == lhs.temperature_degc) &&
×
1004
           ((std::isnan(rhs.voltage_v) && std::isnan(lhs.voltage_v)) ||
×
1005
            rhs.voltage_v == lhs.voltage_v) &&
×
1006
           ((std::isnan(rhs.current_battery_a) && std::isnan(lhs.current_battery_a)) ||
×
1007
            rhs.current_battery_a == lhs.current_battery_a) &&
×
1008
           ((std::isnan(rhs.capacity_consumed_ah) && std::isnan(lhs.capacity_consumed_ah)) ||
×
1009
            rhs.capacity_consumed_ah == lhs.capacity_consumed_ah) &&
×
1010
           ((std::isnan(rhs.remaining_percent) && std::isnan(lhs.remaining_percent)) ||
×
1011
            rhs.remaining_percent == lhs.remaining_percent);
×
1012
}
1013

1014
std::ostream& operator<<(std::ostream& str, Telemetry::Battery const& battery)
×
1015
{
1016
    str << std::setprecision(15);
×
1017
    str << "battery:" << '\n' << "{\n";
×
1018
    str << "    id: " << battery.id << '\n';
×
1019
    str << "    temperature_degc: " << battery.temperature_degc << '\n';
×
1020
    str << "    voltage_v: " << battery.voltage_v << '\n';
×
1021
    str << "    current_battery_a: " << battery.current_battery_a << '\n';
×
1022
    str << "    capacity_consumed_ah: " << battery.capacity_consumed_ah << '\n';
×
1023
    str << "    remaining_percent: " << battery.remaining_percent << '\n';
×
1024
    str << '}';
×
1025
    return str;
×
1026
}
1027

1028
bool operator==(const Telemetry::Health& lhs, const Telemetry::Health& rhs)
×
1029
{
1030
    return (rhs.is_gyrometer_calibration_ok == lhs.is_gyrometer_calibration_ok) &&
×
1031
           (rhs.is_accelerometer_calibration_ok == lhs.is_accelerometer_calibration_ok) &&
×
1032
           (rhs.is_magnetometer_calibration_ok == lhs.is_magnetometer_calibration_ok) &&
×
1033
           (rhs.is_local_position_ok == lhs.is_local_position_ok) &&
×
1034
           (rhs.is_global_position_ok == lhs.is_global_position_ok) &&
×
1035
           (rhs.is_home_position_ok == lhs.is_home_position_ok) &&
×
1036
           (rhs.is_armable == lhs.is_armable);
×
1037
}
1038

1039
std::ostream& operator<<(std::ostream& str, Telemetry::Health const& health)
×
1040
{
1041
    str << std::setprecision(15);
×
1042
    str << "health:" << '\n' << "{\n";
×
1043
    str << "    is_gyrometer_calibration_ok: " << health.is_gyrometer_calibration_ok << '\n';
×
1044
    str << "    is_accelerometer_calibration_ok: " << health.is_accelerometer_calibration_ok
×
1045
        << '\n';
×
1046
    str << "    is_magnetometer_calibration_ok: " << health.is_magnetometer_calibration_ok << '\n';
×
1047
    str << "    is_local_position_ok: " << health.is_local_position_ok << '\n';
×
1048
    str << "    is_global_position_ok: " << health.is_global_position_ok << '\n';
×
1049
    str << "    is_home_position_ok: " << health.is_home_position_ok << '\n';
×
1050
    str << "    is_armable: " << health.is_armable << '\n';
×
1051
    str << '}';
×
1052
    return str;
×
1053
}
1054

1055
bool operator==(const Telemetry::RcStatus& lhs, const Telemetry::RcStatus& rhs)
×
1056
{
1057
    return (rhs.was_available_once == lhs.was_available_once) &&
×
1058
           (rhs.is_available == lhs.is_available) &&
×
1059
           ((std::isnan(rhs.signal_strength_percent) && std::isnan(lhs.signal_strength_percent)) ||
×
1060
            rhs.signal_strength_percent == lhs.signal_strength_percent);
×
1061
}
1062

1063
std::ostream& operator<<(std::ostream& str, Telemetry::RcStatus const& rc_status)
×
1064
{
1065
    str << std::setprecision(15);
×
1066
    str << "rc_status:" << '\n' << "{\n";
×
1067
    str << "    was_available_once: " << rc_status.was_available_once << '\n';
×
1068
    str << "    is_available: " << rc_status.is_available << '\n';
×
1069
    str << "    signal_strength_percent: " << rc_status.signal_strength_percent << '\n';
×
1070
    str << '}';
×
1071
    return str;
×
1072
}
1073

1074
bool operator==(const Telemetry::StatusText& lhs, const Telemetry::StatusText& rhs)
×
1075
{
1076
    return (rhs.type == lhs.type) && (rhs.text == lhs.text);
×
1077
}
1078

1079
std::ostream& operator<<(std::ostream& str, Telemetry::StatusText const& status_text)
×
1080
{
1081
    str << std::setprecision(15);
×
1082
    str << "status_text:" << '\n' << "{\n";
×
1083
    str << "    type: " << status_text.type << '\n';
×
1084
    str << "    text: " << status_text.text << '\n';
×
1085
    str << '}';
×
1086
    return str;
×
1087
}
1088

1089
bool operator==(
×
1090
    const Telemetry::ActuatorControlTarget& lhs, const Telemetry::ActuatorControlTarget& rhs)
1091
{
1092
    return (rhs.group == lhs.group) && (rhs.controls == lhs.controls);
×
1093
}
1094

1095
std::ostream&
1096
operator<<(std::ostream& str, Telemetry::ActuatorControlTarget const& actuator_control_target)
×
1097
{
1098
    str << std::setprecision(15);
×
1099
    str << "actuator_control_target:" << '\n' << "{\n";
×
1100
    str << "    group: " << actuator_control_target.group << '\n';
×
1101
    str << "    controls: [";
×
1102
    for (auto it = actuator_control_target.controls.begin();
×
1103
         it != actuator_control_target.controls.end();
×
1104
         ++it) {
×
1105
        str << *it;
×
1106
        str << (it + 1 != actuator_control_target.controls.end() ? ", " : "]\n");
×
1107
    }
1108
    str << '}';
×
1109
    return str;
×
1110
}
1111

1112
bool operator==(
×
1113
    const Telemetry::ActuatorOutputStatus& lhs, const Telemetry::ActuatorOutputStatus& rhs)
1114
{
1115
    return (rhs.active == lhs.active) && (rhs.actuator == lhs.actuator);
×
1116
}
1117

1118
std::ostream&
1119
operator<<(std::ostream& str, Telemetry::ActuatorOutputStatus const& actuator_output_status)
×
1120
{
1121
    str << std::setprecision(15);
×
1122
    str << "actuator_output_status:" << '\n' << "{\n";
×
1123
    str << "    active: " << actuator_output_status.active << '\n';
×
1124
    str << "    actuator: [";
×
1125
    for (auto it = actuator_output_status.actuator.begin();
×
1126
         it != actuator_output_status.actuator.end();
×
1127
         ++it) {
×
1128
        str << *it;
×
1129
        str << (it + 1 != actuator_output_status.actuator.end() ? ", " : "]\n");
×
1130
    }
1131
    str << '}';
×
1132
    return str;
×
1133
}
1134

1135
bool operator==(const Telemetry::Covariance& lhs, const Telemetry::Covariance& rhs)
×
1136
{
1137
    return (rhs.covariance_matrix == lhs.covariance_matrix);
×
1138
}
1139

1140
std::ostream& operator<<(std::ostream& str, Telemetry::Covariance const& covariance)
×
1141
{
1142
    str << std::setprecision(15);
×
1143
    str << "covariance:" << '\n' << "{\n";
×
1144
    str << "    covariance_matrix: [";
×
1145
    for (auto it = covariance.covariance_matrix.begin(); it != covariance.covariance_matrix.end();
×
1146
         ++it) {
×
1147
        str << *it;
×
1148
        str << (it + 1 != covariance.covariance_matrix.end() ? ", " : "]\n");
×
1149
    }
1150
    str << '}';
×
1151
    return str;
×
1152
}
1153

1154
bool operator==(const Telemetry::VelocityBody& lhs, const Telemetry::VelocityBody& rhs)
×
1155
{
1156
    return ((std::isnan(rhs.x_m_s) && std::isnan(lhs.x_m_s)) || rhs.x_m_s == lhs.x_m_s) &&
×
1157
           ((std::isnan(rhs.y_m_s) && std::isnan(lhs.y_m_s)) || rhs.y_m_s == lhs.y_m_s) &&
×
1158
           ((std::isnan(rhs.z_m_s) && std::isnan(lhs.z_m_s)) || rhs.z_m_s == lhs.z_m_s);
×
1159
}
1160

1161
std::ostream& operator<<(std::ostream& str, Telemetry::VelocityBody const& velocity_body)
×
1162
{
1163
    str << std::setprecision(15);
×
1164
    str << "velocity_body:" << '\n' << "{\n";
×
1165
    str << "    x_m_s: " << velocity_body.x_m_s << '\n';
×
1166
    str << "    y_m_s: " << velocity_body.y_m_s << '\n';
×
1167
    str << "    z_m_s: " << velocity_body.z_m_s << '\n';
×
1168
    str << '}';
×
1169
    return str;
×
1170
}
1171

1172
bool operator==(const Telemetry::PositionBody& lhs, const Telemetry::PositionBody& rhs)
×
1173
{
1174
    return ((std::isnan(rhs.x_m) && std::isnan(lhs.x_m)) || rhs.x_m == lhs.x_m) &&
×
1175
           ((std::isnan(rhs.y_m) && std::isnan(lhs.y_m)) || rhs.y_m == lhs.y_m) &&
×
1176
           ((std::isnan(rhs.z_m) && std::isnan(lhs.z_m)) || rhs.z_m == lhs.z_m);
×
1177
}
1178

1179
std::ostream& operator<<(std::ostream& str, Telemetry::PositionBody const& position_body)
×
1180
{
1181
    str << std::setprecision(15);
×
1182
    str << "position_body:" << '\n' << "{\n";
×
1183
    str << "    x_m: " << position_body.x_m << '\n';
×
1184
    str << "    y_m: " << position_body.y_m << '\n';
×
1185
    str << "    z_m: " << position_body.z_m << '\n';
×
1186
    str << '}';
×
1187
    return str;
×
1188
}
1189

1190
std::ostream& operator<<(std::ostream& str, Telemetry::Odometry::MavFrame const& mav_frame)
×
1191
{
1192
    switch (mav_frame) {
×
1193
        case Telemetry::Odometry::MavFrame::Undef:
×
1194
            return str << "Undef";
×
1195
        case Telemetry::Odometry::MavFrame::BodyNed:
×
1196
            return str << "Body Ned";
×
1197
        case Telemetry::Odometry::MavFrame::VisionNed:
×
1198
            return str << "Vision Ned";
×
1199
        case Telemetry::Odometry::MavFrame::EstimNed:
×
1200
            return str << "Estim Ned";
×
1201
        default:
×
1202
            return str << "Unknown";
×
1203
    }
1204
}
1205
bool operator==(const Telemetry::Odometry& lhs, const Telemetry::Odometry& rhs)
×
1206
{
1207
    return (rhs.time_usec == lhs.time_usec) && (rhs.frame_id == lhs.frame_id) &&
×
1208
           (rhs.child_frame_id == lhs.child_frame_id) && (rhs.position_body == lhs.position_body) &&
×
1209
           (rhs.q == lhs.q) && (rhs.velocity_body == lhs.velocity_body) &&
×
1210
           (rhs.angular_velocity_body == lhs.angular_velocity_body) &&
×
1211
           (rhs.pose_covariance == lhs.pose_covariance) &&
×
1212
           (rhs.velocity_covariance == lhs.velocity_covariance);
×
1213
}
1214

1215
std::ostream& operator<<(std::ostream& str, Telemetry::Odometry const& odometry)
×
1216
{
1217
    str << std::setprecision(15);
×
1218
    str << "odometry:" << '\n' << "{\n";
×
1219
    str << "    time_usec: " << odometry.time_usec << '\n';
×
1220
    str << "    frame_id: " << odometry.frame_id << '\n';
×
1221
    str << "    child_frame_id: " << odometry.child_frame_id << '\n';
×
1222
    str << "    position_body: " << odometry.position_body << '\n';
×
1223
    str << "    q: " << odometry.q << '\n';
×
1224
    str << "    velocity_body: " << odometry.velocity_body << '\n';
×
1225
    str << "    angular_velocity_body: " << odometry.angular_velocity_body << '\n';
×
1226
    str << "    pose_covariance: " << odometry.pose_covariance << '\n';
×
1227
    str << "    velocity_covariance: " << odometry.velocity_covariance << '\n';
×
1228
    str << '}';
×
1229
    return str;
×
1230
}
1231

1232
bool operator==(const Telemetry::DistanceSensor& lhs, const Telemetry::DistanceSensor& rhs)
×
1233
{
1234
    return ((std::isnan(rhs.minimum_distance_m) && std::isnan(lhs.minimum_distance_m)) ||
×
1235
            rhs.minimum_distance_m == lhs.minimum_distance_m) &&
×
1236
           ((std::isnan(rhs.maximum_distance_m) && std::isnan(lhs.maximum_distance_m)) ||
×
1237
            rhs.maximum_distance_m == lhs.maximum_distance_m) &&
×
1238
           ((std::isnan(rhs.current_distance_m) && std::isnan(lhs.current_distance_m)) ||
×
NEW
1239
            rhs.current_distance_m == lhs.current_distance_m) &&
×
NEW
1240
           (rhs.orientation == lhs.orientation);
×
1241
}
1242

1243
std::ostream& operator<<(std::ostream& str, Telemetry::DistanceSensor const& distance_sensor)
×
1244
{
1245
    str << std::setprecision(15);
×
1246
    str << "distance_sensor:" << '\n' << "{\n";
×
1247
    str << "    minimum_distance_m: " << distance_sensor.minimum_distance_m << '\n';
×
1248
    str << "    maximum_distance_m: " << distance_sensor.maximum_distance_m << '\n';
×
1249
    str << "    current_distance_m: " << distance_sensor.current_distance_m << '\n';
×
NEW
1250
    str << "    orientation: " << distance_sensor.orientation << '\n';
×
1251
    str << '}';
×
1252
    return str;
×
1253
}
1254

1255
bool operator==(const Telemetry::ScaledPressure& lhs, const Telemetry::ScaledPressure& rhs)
×
1256
{
1257
    return (rhs.timestamp_us == lhs.timestamp_us) &&
×
1258
           ((std::isnan(rhs.absolute_pressure_hpa) && std::isnan(lhs.absolute_pressure_hpa)) ||
×
1259
            rhs.absolute_pressure_hpa == lhs.absolute_pressure_hpa) &&
×
1260
           ((std::isnan(rhs.differential_pressure_hpa) &&
×
1261
             std::isnan(lhs.differential_pressure_hpa)) ||
×
1262
            rhs.differential_pressure_hpa == lhs.differential_pressure_hpa) &&
×
1263
           ((std::isnan(rhs.temperature_deg) && std::isnan(lhs.temperature_deg)) ||
×
1264
            rhs.temperature_deg == lhs.temperature_deg) &&
×
1265
           ((std::isnan(rhs.differential_pressure_temperature_deg) &&
×
1266
             std::isnan(lhs.differential_pressure_temperature_deg)) ||
×
1267
            rhs.differential_pressure_temperature_deg == lhs.differential_pressure_temperature_deg);
×
1268
}
1269

1270
std::ostream& operator<<(std::ostream& str, Telemetry::ScaledPressure const& scaled_pressure)
×
1271
{
1272
    str << std::setprecision(15);
×
1273
    str << "scaled_pressure:" << '\n' << "{\n";
×
1274
    str << "    timestamp_us: " << scaled_pressure.timestamp_us << '\n';
×
1275
    str << "    absolute_pressure_hpa: " << scaled_pressure.absolute_pressure_hpa << '\n';
×
1276
    str << "    differential_pressure_hpa: " << scaled_pressure.differential_pressure_hpa << '\n';
×
1277
    str << "    temperature_deg: " << scaled_pressure.temperature_deg << '\n';
×
1278
    str << "    differential_pressure_temperature_deg: "
×
1279
        << scaled_pressure.differential_pressure_temperature_deg << '\n';
×
1280
    str << '}';
×
1281
    return str;
×
1282
}
1283

1284
bool operator==(const Telemetry::PositionNed& lhs, const Telemetry::PositionNed& rhs)
×
1285
{
1286
    return ((std::isnan(rhs.north_m) && std::isnan(lhs.north_m)) || rhs.north_m == lhs.north_m) &&
×
1287
           ((std::isnan(rhs.east_m) && std::isnan(lhs.east_m)) || rhs.east_m == lhs.east_m) &&
×
1288
           ((std::isnan(rhs.down_m) && std::isnan(lhs.down_m)) || rhs.down_m == lhs.down_m);
×
1289
}
1290

1291
std::ostream& operator<<(std::ostream& str, Telemetry::PositionNed const& position_ned)
×
1292
{
1293
    str << std::setprecision(15);
×
1294
    str << "position_ned:" << '\n' << "{\n";
×
1295
    str << "    north_m: " << position_ned.north_m << '\n';
×
1296
    str << "    east_m: " << position_ned.east_m << '\n';
×
1297
    str << "    down_m: " << position_ned.down_m << '\n';
×
1298
    str << '}';
×
1299
    return str;
×
1300
}
1301

1302
bool operator==(const Telemetry::VelocityNed& lhs, const Telemetry::VelocityNed& rhs)
×
1303
{
1304
    return ((std::isnan(rhs.north_m_s) && std::isnan(lhs.north_m_s)) ||
×
1305
            rhs.north_m_s == lhs.north_m_s) &&
×
1306
           ((std::isnan(rhs.east_m_s) && std::isnan(lhs.east_m_s)) ||
×
1307
            rhs.east_m_s == lhs.east_m_s) &&
×
1308
           ((std::isnan(rhs.down_m_s) && std::isnan(lhs.down_m_s)) || rhs.down_m_s == lhs.down_m_s);
×
1309
}
1310

1311
std::ostream& operator<<(std::ostream& str, Telemetry::VelocityNed const& velocity_ned)
×
1312
{
1313
    str << std::setprecision(15);
×
1314
    str << "velocity_ned:" << '\n' << "{\n";
×
1315
    str << "    north_m_s: " << velocity_ned.north_m_s << '\n';
×
1316
    str << "    east_m_s: " << velocity_ned.east_m_s << '\n';
×
1317
    str << "    down_m_s: " << velocity_ned.down_m_s << '\n';
×
1318
    str << '}';
×
1319
    return str;
×
1320
}
1321

1322
bool operator==(
×
1323
    const Telemetry::PositionVelocityNed& lhs, const Telemetry::PositionVelocityNed& rhs)
1324
{
1325
    return (rhs.position == lhs.position) && (rhs.velocity == lhs.velocity);
×
1326
}
1327

1328
std::ostream&
1329
operator<<(std::ostream& str, Telemetry::PositionVelocityNed const& position_velocity_ned)
×
1330
{
1331
    str << std::setprecision(15);
×
1332
    str << "position_velocity_ned:" << '\n' << "{\n";
×
1333
    str << "    position: " << position_velocity_ned.position << '\n';
×
1334
    str << "    velocity: " << position_velocity_ned.velocity << '\n';
×
1335
    str << '}';
×
1336
    return str;
×
1337
}
1338

1339
bool operator==(const Telemetry::GroundTruth& lhs, const Telemetry::GroundTruth& rhs)
×
1340
{
1341
    return ((std::isnan(rhs.latitude_deg) && std::isnan(lhs.latitude_deg)) ||
×
1342
            rhs.latitude_deg == lhs.latitude_deg) &&
×
1343
           ((std::isnan(rhs.longitude_deg) && std::isnan(lhs.longitude_deg)) ||
×
1344
            rhs.longitude_deg == lhs.longitude_deg) &&
×
1345
           ((std::isnan(rhs.absolute_altitude_m) && std::isnan(lhs.absolute_altitude_m)) ||
×
1346
            rhs.absolute_altitude_m == lhs.absolute_altitude_m);
×
1347
}
1348

1349
std::ostream& operator<<(std::ostream& str, Telemetry::GroundTruth const& ground_truth)
×
1350
{
1351
    str << std::setprecision(15);
×
1352
    str << "ground_truth:" << '\n' << "{\n";
×
1353
    str << "    latitude_deg: " << ground_truth.latitude_deg << '\n';
×
1354
    str << "    longitude_deg: " << ground_truth.longitude_deg << '\n';
×
1355
    str << "    absolute_altitude_m: " << ground_truth.absolute_altitude_m << '\n';
×
1356
    str << '}';
×
1357
    return str;
×
1358
}
1359

1360
bool operator==(const Telemetry::FixedwingMetrics& lhs, const Telemetry::FixedwingMetrics& rhs)
×
1361
{
1362
    return ((std::isnan(rhs.airspeed_m_s) && std::isnan(lhs.airspeed_m_s)) ||
×
1363
            rhs.airspeed_m_s == lhs.airspeed_m_s) &&
×
1364
           ((std::isnan(rhs.throttle_percentage) && std::isnan(lhs.throttle_percentage)) ||
×
1365
            rhs.throttle_percentage == lhs.throttle_percentage) &&
×
1366
           ((std::isnan(rhs.climb_rate_m_s) && std::isnan(lhs.climb_rate_m_s)) ||
×
1367
            rhs.climb_rate_m_s == lhs.climb_rate_m_s);
×
1368
}
1369

1370
std::ostream& operator<<(std::ostream& str, Telemetry::FixedwingMetrics const& fixedwing_metrics)
×
1371
{
1372
    str << std::setprecision(15);
×
1373
    str << "fixedwing_metrics:" << '\n' << "{\n";
×
1374
    str << "    airspeed_m_s: " << fixedwing_metrics.airspeed_m_s << '\n';
×
1375
    str << "    throttle_percentage: " << fixedwing_metrics.throttle_percentage << '\n';
×
1376
    str << "    climb_rate_m_s: " << fixedwing_metrics.climb_rate_m_s << '\n';
×
1377
    str << '}';
×
1378
    return str;
×
1379
}
1380

1381
bool operator==(const Telemetry::AccelerationFrd& lhs, const Telemetry::AccelerationFrd& rhs)
×
1382
{
1383
    return ((std::isnan(rhs.forward_m_s2) && std::isnan(lhs.forward_m_s2)) ||
×
1384
            rhs.forward_m_s2 == lhs.forward_m_s2) &&
×
1385
           ((std::isnan(rhs.right_m_s2) && std::isnan(lhs.right_m_s2)) ||
×
1386
            rhs.right_m_s2 == lhs.right_m_s2) &&
×
1387
           ((std::isnan(rhs.down_m_s2) && std::isnan(lhs.down_m_s2)) ||
×
1388
            rhs.down_m_s2 == lhs.down_m_s2);
×
1389
}
1390

1391
std::ostream& operator<<(std::ostream& str, Telemetry::AccelerationFrd const& acceleration_frd)
×
1392
{
1393
    str << std::setprecision(15);
×
1394
    str << "acceleration_frd:" << '\n' << "{\n";
×
1395
    str << "    forward_m_s2: " << acceleration_frd.forward_m_s2 << '\n';
×
1396
    str << "    right_m_s2: " << acceleration_frd.right_m_s2 << '\n';
×
1397
    str << "    down_m_s2: " << acceleration_frd.down_m_s2 << '\n';
×
1398
    str << '}';
×
1399
    return str;
×
1400
}
1401

1402
bool operator==(const Telemetry::AngularVelocityFrd& lhs, const Telemetry::AngularVelocityFrd& rhs)
×
1403
{
1404
    return ((std::isnan(rhs.forward_rad_s) && std::isnan(lhs.forward_rad_s)) ||
×
1405
            rhs.forward_rad_s == lhs.forward_rad_s) &&
×
1406
           ((std::isnan(rhs.right_rad_s) && std::isnan(lhs.right_rad_s)) ||
×
1407
            rhs.right_rad_s == lhs.right_rad_s) &&
×
1408
           ((std::isnan(rhs.down_rad_s) && std::isnan(lhs.down_rad_s)) ||
×
1409
            rhs.down_rad_s == lhs.down_rad_s);
×
1410
}
1411

1412
std::ostream&
1413
operator<<(std::ostream& str, Telemetry::AngularVelocityFrd const& angular_velocity_frd)
×
1414
{
1415
    str << std::setprecision(15);
×
1416
    str << "angular_velocity_frd:" << '\n' << "{\n";
×
1417
    str << "    forward_rad_s: " << angular_velocity_frd.forward_rad_s << '\n';
×
1418
    str << "    right_rad_s: " << angular_velocity_frd.right_rad_s << '\n';
×
1419
    str << "    down_rad_s: " << angular_velocity_frd.down_rad_s << '\n';
×
1420
    str << '}';
×
1421
    return str;
×
1422
}
1423

1424
bool operator==(const Telemetry::MagneticFieldFrd& lhs, const Telemetry::MagneticFieldFrd& rhs)
×
1425
{
1426
    return ((std::isnan(rhs.forward_gauss) && std::isnan(lhs.forward_gauss)) ||
×
1427
            rhs.forward_gauss == lhs.forward_gauss) &&
×
1428
           ((std::isnan(rhs.right_gauss) && std::isnan(lhs.right_gauss)) ||
×
1429
            rhs.right_gauss == lhs.right_gauss) &&
×
1430
           ((std::isnan(rhs.down_gauss) && std::isnan(lhs.down_gauss)) ||
×
1431
            rhs.down_gauss == lhs.down_gauss);
×
1432
}
1433

1434
std::ostream& operator<<(std::ostream& str, Telemetry::MagneticFieldFrd const& magnetic_field_frd)
×
1435
{
1436
    str << std::setprecision(15);
×
1437
    str << "magnetic_field_frd:" << '\n' << "{\n";
×
1438
    str << "    forward_gauss: " << magnetic_field_frd.forward_gauss << '\n';
×
1439
    str << "    right_gauss: " << magnetic_field_frd.right_gauss << '\n';
×
1440
    str << "    down_gauss: " << magnetic_field_frd.down_gauss << '\n';
×
1441
    str << '}';
×
1442
    return str;
×
1443
}
1444

1445
bool operator==(const Telemetry::Imu& lhs, const Telemetry::Imu& rhs)
×
1446
{
1447
    return (rhs.acceleration_frd == lhs.acceleration_frd) &&
×
1448
           (rhs.angular_velocity_frd == lhs.angular_velocity_frd) &&
×
1449
           (rhs.magnetic_field_frd == lhs.magnetic_field_frd) &&
×
1450
           ((std::isnan(rhs.temperature_degc) && std::isnan(lhs.temperature_degc)) ||
×
1451
            rhs.temperature_degc == lhs.temperature_degc) &&
×
1452
           (rhs.timestamp_us == lhs.timestamp_us);
×
1453
}
1454

1455
std::ostream& operator<<(std::ostream& str, Telemetry::Imu const& imu)
×
1456
{
1457
    str << std::setprecision(15);
×
1458
    str << "imu:" << '\n' << "{\n";
×
1459
    str << "    acceleration_frd: " << imu.acceleration_frd << '\n';
×
1460
    str << "    angular_velocity_frd: " << imu.angular_velocity_frd << '\n';
×
1461
    str << "    magnetic_field_frd: " << imu.magnetic_field_frd << '\n';
×
1462
    str << "    temperature_degc: " << imu.temperature_degc << '\n';
×
1463
    str << "    timestamp_us: " << imu.timestamp_us << '\n';
×
1464
    str << '}';
×
1465
    return str;
×
1466
}
1467

1468
bool operator==(const Telemetry::GpsGlobalOrigin& lhs, const Telemetry::GpsGlobalOrigin& rhs)
×
1469
{
1470
    return ((std::isnan(rhs.latitude_deg) && std::isnan(lhs.latitude_deg)) ||
×
1471
            rhs.latitude_deg == lhs.latitude_deg) &&
×
1472
           ((std::isnan(rhs.longitude_deg) && std::isnan(lhs.longitude_deg)) ||
×
1473
            rhs.longitude_deg == lhs.longitude_deg) &&
×
1474
           ((std::isnan(rhs.altitude_m) && std::isnan(lhs.altitude_m)) ||
×
1475
            rhs.altitude_m == lhs.altitude_m);
×
1476
}
1477

1478
std::ostream& operator<<(std::ostream& str, Telemetry::GpsGlobalOrigin const& gps_global_origin)
×
1479
{
1480
    str << std::setprecision(15);
×
1481
    str << "gps_global_origin:" << '\n' << "{\n";
×
1482
    str << "    latitude_deg: " << gps_global_origin.latitude_deg << '\n';
×
1483
    str << "    longitude_deg: " << gps_global_origin.longitude_deg << '\n';
×
1484
    str << "    altitude_m: " << gps_global_origin.altitude_m << '\n';
×
1485
    str << '}';
×
1486
    return str;
×
1487
}
1488

1489
bool operator==(const Telemetry::Altitude& lhs, const Telemetry::Altitude& rhs)
×
1490
{
1491
    return ((std::isnan(rhs.altitude_monotonic_m) && std::isnan(lhs.altitude_monotonic_m)) ||
×
1492
            rhs.altitude_monotonic_m == lhs.altitude_monotonic_m) &&
×
1493
           ((std::isnan(rhs.altitude_amsl_m) && std::isnan(lhs.altitude_amsl_m)) ||
×
1494
            rhs.altitude_amsl_m == lhs.altitude_amsl_m) &&
×
1495
           ((std::isnan(rhs.altitude_local_m) && std::isnan(lhs.altitude_local_m)) ||
×
1496
            rhs.altitude_local_m == lhs.altitude_local_m) &&
×
1497
           ((std::isnan(rhs.altitude_relative_m) && std::isnan(lhs.altitude_relative_m)) ||
×
1498
            rhs.altitude_relative_m == lhs.altitude_relative_m) &&
×
1499
           ((std::isnan(rhs.altitude_terrain_m) && std::isnan(lhs.altitude_terrain_m)) ||
×
1500
            rhs.altitude_terrain_m == lhs.altitude_terrain_m) &&
×
1501
           ((std::isnan(rhs.bottom_clearance_m) && std::isnan(lhs.bottom_clearance_m)) ||
×
1502
            rhs.bottom_clearance_m == lhs.bottom_clearance_m);
×
1503
}
1504

1505
std::ostream& operator<<(std::ostream& str, Telemetry::Altitude const& altitude)
×
1506
{
1507
    str << std::setprecision(15);
×
1508
    str << "altitude:" << '\n' << "{\n";
×
1509
    str << "    altitude_monotonic_m: " << altitude.altitude_monotonic_m << '\n';
×
1510
    str << "    altitude_amsl_m: " << altitude.altitude_amsl_m << '\n';
×
1511
    str << "    altitude_local_m: " << altitude.altitude_local_m << '\n';
×
1512
    str << "    altitude_relative_m: " << altitude.altitude_relative_m << '\n';
×
1513
    str << "    altitude_terrain_m: " << altitude.altitude_terrain_m << '\n';
×
1514
    str << "    bottom_clearance_m: " << altitude.bottom_clearance_m << '\n';
×
1515
    str << '}';
×
1516
    return str;
×
1517
}
1518

1519
std::ostream& operator<<(std::ostream& str, Telemetry::Result const& result)
×
1520
{
1521
    switch (result) {
×
1522
        case Telemetry::Result::Unknown:
×
1523
            return str << "Unknown";
×
1524
        case Telemetry::Result::Success:
×
1525
            return str << "Success";
×
1526
        case Telemetry::Result::NoSystem:
×
1527
            return str << "No System";
×
1528
        case Telemetry::Result::ConnectionError:
×
1529
            return str << "Connection Error";
×
1530
        case Telemetry::Result::Busy:
×
1531
            return str << "Busy";
×
1532
        case Telemetry::Result::CommandDenied:
×
1533
            return str << "Command Denied";
×
1534
        case Telemetry::Result::Timeout:
×
1535
            return str << "Timeout";
×
1536
        case Telemetry::Result::Unsupported:
×
1537
            return str << "Unsupported";
×
1538
        default:
×
1539
            return str << "Unknown";
×
1540
    }
1541
}
1542

1543
std::ostream& operator<<(std::ostream& str, Telemetry::FixType const& fix_type)
×
1544
{
1545
    switch (fix_type) {
×
1546
        case Telemetry::FixType::NoGps:
×
1547
            return str << "No Gps";
×
1548
        case Telemetry::FixType::NoFix:
×
1549
            return str << "No Fix";
×
1550
        case Telemetry::FixType::Fix2D:
×
1551
            return str << "Fix 2D";
×
1552
        case Telemetry::FixType::Fix3D:
×
1553
            return str << "Fix 3D";
×
1554
        case Telemetry::FixType::FixDgps:
×
1555
            return str << "Fix Dgps";
×
1556
        case Telemetry::FixType::RtkFloat:
×
1557
            return str << "Rtk Float";
×
1558
        case Telemetry::FixType::RtkFixed:
×
1559
            return str << "Rtk Fixed";
×
1560
        default:
×
1561
            return str << "Unknown";
×
1562
    }
1563
}
1564

1565
std::ostream& operator<<(std::ostream& str, Telemetry::FlightMode const& flight_mode)
×
1566
{
1567
    switch (flight_mode) {
×
1568
        case Telemetry::FlightMode::Unknown:
×
1569
            return str << "Unknown";
×
1570
        case Telemetry::FlightMode::Ready:
×
1571
            return str << "Ready";
×
1572
        case Telemetry::FlightMode::Takeoff:
×
1573
            return str << "Takeoff";
×
1574
        case Telemetry::FlightMode::Hold:
×
1575
            return str << "Hold";
×
1576
        case Telemetry::FlightMode::Mission:
×
1577
            return str << "Mission";
×
1578
        case Telemetry::FlightMode::ReturnToLaunch:
×
1579
            return str << "Return To Launch";
×
1580
        case Telemetry::FlightMode::Land:
×
1581
            return str << "Land";
×
1582
        case Telemetry::FlightMode::Offboard:
×
1583
            return str << "Offboard";
×
1584
        case Telemetry::FlightMode::FollowMe:
×
1585
            return str << "Follow Me";
×
1586
        case Telemetry::FlightMode::Manual:
×
1587
            return str << "Manual";
×
1588
        case Telemetry::FlightMode::Altctl:
×
1589
            return str << "Altctl";
×
1590
        case Telemetry::FlightMode::Posctl:
×
1591
            return str << "Posctl";
×
1592
        case Telemetry::FlightMode::Acro:
×
1593
            return str << "Acro";
×
1594
        case Telemetry::FlightMode::Stabilized:
×
1595
            return str << "Stabilized";
×
1596
        case Telemetry::FlightMode::Rattitude:
×
1597
            return str << "Rattitude";
×
1598
        default:
×
1599
            return str << "Unknown";
×
1600
    }
1601
}
1602

1603
std::ostream& operator<<(std::ostream& str, Telemetry::StatusTextType const& status_text_type)
×
1604
{
1605
    switch (status_text_type) {
×
1606
        case Telemetry::StatusTextType::Debug:
×
1607
            return str << "Debug";
×
1608
        case Telemetry::StatusTextType::Info:
×
1609
            return str << "Info";
×
1610
        case Telemetry::StatusTextType::Notice:
×
1611
            return str << "Notice";
×
1612
        case Telemetry::StatusTextType::Warning:
×
1613
            return str << "Warning";
×
1614
        case Telemetry::StatusTextType::Error:
×
1615
            return str << "Error";
×
1616
        case Telemetry::StatusTextType::Critical:
×
1617
            return str << "Critical";
×
1618
        case Telemetry::StatusTextType::Alert:
×
1619
            return str << "Alert";
×
1620
        case Telemetry::StatusTextType::Emergency:
×
1621
            return str << "Emergency";
×
1622
        default:
×
1623
            return str << "Unknown";
×
1624
    }
1625
}
1626

1627
std::ostream& operator<<(std::ostream& str, Telemetry::LandedState const& landed_state)
×
1628
{
1629
    switch (landed_state) {
×
1630
        case Telemetry::LandedState::Unknown:
×
1631
            return str << "Unknown";
×
1632
        case Telemetry::LandedState::OnGround:
×
1633
            return str << "On Ground";
×
1634
        case Telemetry::LandedState::InAir:
×
1635
            return str << "In Air";
×
1636
        case Telemetry::LandedState::TakingOff:
×
1637
            return str << "Taking Off";
×
1638
        case Telemetry::LandedState::Landing:
×
1639
            return str << "Landing";
×
1640
        default:
×
1641
            return str << "Unknown";
×
1642
    }
1643
}
1644

1645
std::ostream& operator<<(std::ostream& str, Telemetry::VtolState const& vtol_state)
×
1646
{
1647
    switch (vtol_state) {
×
1648
        case Telemetry::VtolState::Undefined:
×
1649
            return str << "Undefined";
×
1650
        case Telemetry::VtolState::TransitionToFw:
×
1651
            return str << "Transition To Fw";
×
1652
        case Telemetry::VtolState::TransitionToMc:
×
1653
            return str << "Transition To Mc";
×
1654
        case Telemetry::VtolState::Mc:
×
1655
            return str << "Mc";
×
1656
        case Telemetry::VtolState::Fw:
×
1657
            return str << "Fw";
×
1658
        default:
×
1659
            return str << "Unknown";
×
1660
    }
1661
}
1662

1663
} // namespace mavsdk
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc