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

mavlink / MAVSDK / 20150727601

11 Dec 2025 11:25PM UTC coverage: 47.204%. First build
20150727601

Pull #2737

github

web-flow
Merge 983e803f6 into ffe67358f
Pull Request #2737: Add RemoteId plugin

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

17631 of 37351 relevant lines covered (47.2%)

456.76 hits per line

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

0.0
/src/mavsdk/plugins/remote_id/remote_id.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/remote_id/remote_id.proto)
4

5
#include <iomanip>
6

7
#include "remote_id_impl.h"
8
#include "plugins/remote_id/remote_id.h"
9

10
namespace mavsdk {
11

12
using BasicId = RemoteId::BasicId;
13
using Location = RemoteId::Location;
14
using SystemId = RemoteId::SystemId;
15
using OperatorId = RemoteId::OperatorId;
16
using SelfId = RemoteId::SelfId;
17
using ArmStatus = RemoteId::ArmStatus;
18

NEW
19
RemoteId::RemoteId(System& system) : PluginBase(), _impl{std::make_unique<RemoteIdImpl>(system)} {}
×
20

NEW
21
RemoteId::RemoteId(std::shared_ptr<System> system) :
×
22
    PluginBase(),
NEW
23
    _impl{std::make_unique<RemoteIdImpl>(system)}
×
NEW
24
{}
×
25

NEW
26
RemoteId::~RemoteId() {}
×
27

NEW
28
RemoteId::Result RemoteId::set_basic_id(BasicId basic_id) const
×
29
{
NEW
30
    return _impl->set_basic_id(basic_id);
×
31
}
32

NEW
33
RemoteId::Result RemoteId::set_location(Location location) const
×
34
{
NEW
35
    return _impl->set_location(location);
×
36
}
37

NEW
38
RemoteId::Result RemoteId::set_system(SystemId system) const
×
39
{
NEW
40
    return _impl->set_system(system);
×
41
}
42

NEW
43
RemoteId::Result RemoteId::set_operator_id(OperatorId system) const
×
44
{
NEW
45
    return _impl->set_operator_id(system);
×
46
}
47

NEW
48
RemoteId::Result RemoteId::set_self_id(SelfId self_id) const
×
49
{
NEW
50
    return _impl->set_self_id(self_id);
×
51
}
52

NEW
53
RemoteId::ArmStatusHandle RemoteId::subscribe_arm_status(const ArmStatusCallback& callback)
×
54
{
NEW
55
    return _impl->subscribe_arm_status(callback);
×
56
}
57

NEW
58
void RemoteId::unsubscribe_arm_status(ArmStatusHandle handle)
×
59
{
NEW
60
    _impl->unsubscribe_arm_status(handle);
×
NEW
61
}
×
62

NEW
63
RemoteId::ArmStatus RemoteId::arm_status() const
×
64
{
NEW
65
    return _impl->arm_status();
×
66
}
67

NEW
68
std::ostream& operator<<(std::ostream& str, RemoteId::BasicId::IdType const& id_type)
×
69
{
NEW
70
    switch (id_type) {
×
NEW
71
        case RemoteId::BasicId::IdType::None:
×
NEW
72
            return str << "None";
×
NEW
73
        case RemoteId::BasicId::IdType::SerialNumber:
×
NEW
74
            return str << "Serial Number";
×
NEW
75
        case RemoteId::BasicId::IdType::CaaRegistrationId:
×
NEW
76
            return str << "Caa Registration Id";
×
NEW
77
        case RemoteId::BasicId::IdType::UtmAssignedUuid:
×
NEW
78
            return str << "Utm Assigned Uuid";
×
NEW
79
        case RemoteId::BasicId::IdType::SpecificSessionId:
×
NEW
80
            return str << "Specific Session Id";
×
NEW
81
        default:
×
NEW
82
            return str << "Unknown";
×
83
    }
84
}
85

NEW
86
std::ostream& operator<<(std::ostream& str, RemoteId::BasicId::UasType const& uas_type)
×
87
{
NEW
88
    switch (uas_type) {
×
NEW
89
        case RemoteId::BasicId::UasType::None:
×
NEW
90
            return str << "None";
×
NEW
91
        case RemoteId::BasicId::UasType::Aeroplane:
×
NEW
92
            return str << "Aeroplane";
×
NEW
93
        case RemoteId::BasicId::UasType::HelicopterOrMultirotor:
×
NEW
94
            return str << "Helicopter Or Multirotor";
×
NEW
95
        case RemoteId::BasicId::UasType::Gyroplane:
×
NEW
96
            return str << "Gyroplane";
×
NEW
97
        case RemoteId::BasicId::UasType::HybridLift:
×
NEW
98
            return str << "Hybrid Lift";
×
NEW
99
        case RemoteId::BasicId::UasType::Ornithopter:
×
NEW
100
            return str << "Ornithopter";
×
NEW
101
        case RemoteId::BasicId::UasType::Glider:
×
NEW
102
            return str << "Glider";
×
NEW
103
        case RemoteId::BasicId::UasType::Kite:
×
NEW
104
            return str << "Kite";
×
NEW
105
        case RemoteId::BasicId::UasType::FreeBalloon:
×
NEW
106
            return str << "Free Balloon";
×
NEW
107
        case RemoteId::BasicId::UasType::CaptiveBalloon:
×
NEW
108
            return str << "Captive Balloon";
×
NEW
109
        case RemoteId::BasicId::UasType::Airship:
×
NEW
110
            return str << "Airship";
×
NEW
111
        case RemoteId::BasicId::UasType::FreeFallParachute:
×
NEW
112
            return str << "Free Fall Parachute";
×
NEW
113
        case RemoteId::BasicId::UasType::Rocket:
×
NEW
114
            return str << "Rocket";
×
NEW
115
        case RemoteId::BasicId::UasType::TetheredPoweredAircraft:
×
NEW
116
            return str << "Tethered Powered Aircraft";
×
NEW
117
        case RemoteId::BasicId::UasType::GroundObstacle:
×
NEW
118
            return str << "Ground Obstacle";
×
NEW
119
        case RemoteId::BasicId::UasType::Other:
×
NEW
120
            return str << "Other";
×
NEW
121
        default:
×
NEW
122
            return str << "Unknown";
×
123
    }
124
}
NEW
125
bool operator==(const RemoteId::BasicId& lhs, const RemoteId::BasicId& rhs)
×
126
{
NEW
127
    return (rhs.id_type == lhs.id_type) && (rhs.ua_type == lhs.ua_type) &&
×
NEW
128
           (rhs.uas_id == lhs.uas_id);
×
129
}
130

NEW
131
std::ostream& operator<<(std::ostream& str, RemoteId::BasicId const& basic_id)
×
132
{
NEW
133
    str << std::setprecision(15);
×
NEW
134
    str << "basic_id:" << '\n' << "{\n";
×
NEW
135
    str << "    id_type: " << basic_id.id_type << '\n';
×
NEW
136
    str << "    ua_type: " << basic_id.ua_type << '\n';
×
NEW
137
    str << "    uas_id: " << basic_id.uas_id << '\n';
×
NEW
138
    str << '}';
×
NEW
139
    return str;
×
140
}
141

NEW
142
std::ostream& operator<<(std::ostream& str, RemoteId::Location::Status const& status)
×
143
{
NEW
144
    switch (status) {
×
NEW
145
        case RemoteId::Location::Status::Undeclared:
×
NEW
146
            return str << "Undeclared";
×
NEW
147
        case RemoteId::Location::Status::Ground:
×
NEW
148
            return str << "Ground";
×
NEW
149
        case RemoteId::Location::Status::Airborne:
×
NEW
150
            return str << "Airborne";
×
NEW
151
        case RemoteId::Location::Status::Emergency:
×
NEW
152
            return str << "Emergency";
×
NEW
153
        case RemoteId::Location::Status::RemoteIdSystemFailure:
×
NEW
154
            return str << "Remote Id System Failure";
×
NEW
155
        default:
×
NEW
156
            return str << "Unknown";
×
157
    }
158
}
159

NEW
160
std::ostream& operator<<(std::ostream& str, RemoteId::Location::HeightRef const& height_ref)
×
161
{
NEW
162
    switch (height_ref) {
×
NEW
163
        case RemoteId::Location::HeightRef::OverTakeoff:
×
NEW
164
            return str << "Over Takeoff";
×
NEW
165
        case RemoteId::Location::HeightRef::OverGround:
×
NEW
166
            return str << "Over Ground";
×
NEW
167
        default:
×
NEW
168
            return str << "Unknown";
×
169
    }
170
}
171

NEW
172
std::ostream& operator<<(std::ostream& str, RemoteId::Location::HorAcc const& hor_acc)
×
173
{
NEW
174
    switch (hor_acc) {
×
NEW
175
        case RemoteId::Location::HorAcc::Unknown:
×
NEW
176
            return str << "Unknown";
×
NEW
177
        case RemoteId::Location::HorAcc::Nm10:
×
NEW
178
            return str << "Nm 10";
×
NEW
179
        case RemoteId::Location::HorAcc::Nm4:
×
NEW
180
            return str << "Nm 4";
×
NEW
181
        case RemoteId::Location::HorAcc::Nm2:
×
NEW
182
            return str << "Nm 2";
×
NEW
183
        case RemoteId::Location::HorAcc::Nm1:
×
NEW
184
            return str << "Nm 1";
×
NEW
185
        case RemoteId::Location::HorAcc::Nm05:
×
NEW
186
            return str << "Nm 0 5";
×
NEW
187
        case RemoteId::Location::HorAcc::Nm03:
×
NEW
188
            return str << "Nm 0 3";
×
NEW
189
        case RemoteId::Location::HorAcc::Nm01:
×
NEW
190
            return str << "Nm 0 1";
×
NEW
191
        case RemoteId::Location::HorAcc::Nm005:
×
NEW
192
            return str << "Nm 0 05";
×
NEW
193
        case RemoteId::Location::HorAcc::Meter30:
×
NEW
194
            return str << "Meter 30";
×
NEW
195
        case RemoteId::Location::HorAcc::Meter10:
×
NEW
196
            return str << "Meter 10";
×
NEW
197
        case RemoteId::Location::HorAcc::Meter3:
×
NEW
198
            return str << "Meter 3";
×
NEW
199
        case RemoteId::Location::HorAcc::Meter1:
×
NEW
200
            return str << "Meter 1";
×
NEW
201
        default:
×
NEW
202
            return str << "Unknown";
×
203
    }
204
}
205

NEW
206
std::ostream& operator<<(std::ostream& str, RemoteId::Location::VerAcc const& ver_acc)
×
207
{
NEW
208
    switch (ver_acc) {
×
NEW
209
        case RemoteId::Location::VerAcc::Unknown:
×
NEW
210
            return str << "Unknown";
×
NEW
211
        case RemoteId::Location::VerAcc::Meter150:
×
NEW
212
            return str << "Meter 150";
×
NEW
213
        case RemoteId::Location::VerAcc::Meter45:
×
NEW
214
            return str << "Meter 45";
×
NEW
215
        case RemoteId::Location::VerAcc::Meter25:
×
NEW
216
            return str << "Meter 25";
×
NEW
217
        case RemoteId::Location::VerAcc::Meter10:
×
NEW
218
            return str << "Meter 10";
×
NEW
219
        case RemoteId::Location::VerAcc::Meter3:
×
NEW
220
            return str << "Meter 3";
×
NEW
221
        case RemoteId::Location::VerAcc::Meter1:
×
NEW
222
            return str << "Meter 1";
×
NEW
223
        default:
×
NEW
224
            return str << "Unknown";
×
225
    }
226
}
227

NEW
228
std::ostream& operator<<(std::ostream& str, RemoteId::Location::SpeedAcc const& speed_acc)
×
229
{
NEW
230
    switch (speed_acc) {
×
NEW
231
        case RemoteId::Location::SpeedAcc::Unknown:
×
NEW
232
            return str << "Unknown";
×
NEW
233
        case RemoteId::Location::SpeedAcc::MetersPerSecond10:
×
NEW
234
            return str << "Meters Per Second 10";
×
NEW
235
        case RemoteId::Location::SpeedAcc::MetersPerSecond3:
×
NEW
236
            return str << "Meters Per Second 3";
×
NEW
237
        case RemoteId::Location::SpeedAcc::MetersPerSecond1:
×
NEW
238
            return str << "Meters Per Second 1";
×
NEW
239
        case RemoteId::Location::SpeedAcc::MetersPerSecond03:
×
NEW
240
            return str << "Meters Per Second 0 3";
×
NEW
241
        default:
×
NEW
242
            return str << "Unknown";
×
243
    }
244
}
245

NEW
246
std::ostream& operator<<(std::ostream& str, RemoteId::Location::TimeAcc const& time_acc)
×
247
{
NEW
248
    switch (time_acc) {
×
NEW
249
        case RemoteId::Location::TimeAcc::Unknown:
×
NEW
250
            return str << "Unknown";
×
NEW
251
        case RemoteId::Location::TimeAcc::Second01:
×
NEW
252
            return str << "Second 0 1";
×
NEW
253
        case RemoteId::Location::TimeAcc::Second02:
×
NEW
254
            return str << "Second 0 2";
×
NEW
255
        case RemoteId::Location::TimeAcc::Second03:
×
NEW
256
            return str << "Second 0 3";
×
NEW
257
        case RemoteId::Location::TimeAcc::Second04:
×
NEW
258
            return str << "Second 0 4";
×
NEW
259
        case RemoteId::Location::TimeAcc::Second05:
×
NEW
260
            return str << "Second 0 5";
×
NEW
261
        case RemoteId::Location::TimeAcc::Second06:
×
NEW
262
            return str << "Second 0 6";
×
NEW
263
        case RemoteId::Location::TimeAcc::Second07:
×
NEW
264
            return str << "Second 0 7";
×
NEW
265
        case RemoteId::Location::TimeAcc::Second08:
×
NEW
266
            return str << "Second 0 8";
×
NEW
267
        case RemoteId::Location::TimeAcc::Second09:
×
NEW
268
            return str << "Second 0 9";
×
NEW
269
        case RemoteId::Location::TimeAcc::Second10:
×
NEW
270
            return str << "Second 1 0";
×
NEW
271
        case RemoteId::Location::TimeAcc::Second11:
×
NEW
272
            return str << "Second 1 1";
×
NEW
273
        case RemoteId::Location::TimeAcc::Second12:
×
NEW
274
            return str << "Second 1 2";
×
NEW
275
        case RemoteId::Location::TimeAcc::Second13:
×
NEW
276
            return str << "Second 1 3";
×
NEW
277
        case RemoteId::Location::TimeAcc::Second14:
×
NEW
278
            return str << "Second 1 4";
×
NEW
279
        case RemoteId::Location::TimeAcc::Second15:
×
NEW
280
            return str << "Second 1 5";
×
NEW
281
        default:
×
NEW
282
            return str << "Unknown";
×
283
    }
284
}
NEW
285
bool operator==(const RemoteId::Location& lhs, const RemoteId::Location& rhs)
×
286
{
NEW
287
    return (rhs.status == lhs.status) && (rhs.direction_deg == lhs.direction_deg) &&
×
NEW
288
           ((std::isnan(rhs.speed_horizontal_m_s) && std::isnan(lhs.speed_horizontal_m_s)) ||
×
NEW
289
            rhs.speed_horizontal_m_s == lhs.speed_horizontal_m_s) &&
×
NEW
290
           ((std::isnan(rhs.speed_vertical_m_s) && std::isnan(lhs.speed_vertical_m_s)) ||
×
NEW
291
            rhs.speed_vertical_m_s == lhs.speed_vertical_m_s) &&
×
NEW
292
           ((std::isnan(rhs.latitude_deg) && std::isnan(lhs.latitude_deg)) ||
×
NEW
293
            rhs.latitude_deg == lhs.latitude_deg) &&
×
NEW
294
           ((std::isnan(rhs.longitude_deg) && std::isnan(lhs.longitude_deg)) ||
×
NEW
295
            rhs.longitude_deg == lhs.longitude_deg) &&
×
NEW
296
           ((std::isnan(rhs.altitude_barometric_m) && std::isnan(lhs.altitude_barometric_m)) ||
×
NEW
297
            rhs.altitude_barometric_m == lhs.altitude_barometric_m) &&
×
NEW
298
           ((std::isnan(rhs.altitude_geodetic_m) && std::isnan(lhs.altitude_geodetic_m)) ||
×
NEW
299
            rhs.altitude_geodetic_m == lhs.altitude_geodetic_m) &&
×
NEW
300
           (rhs.height_reference == lhs.height_reference) &&
×
NEW
301
           ((std::isnan(rhs.height_m) && std::isnan(lhs.height_m)) ||
×
NEW
302
            rhs.height_m == lhs.height_m) &&
×
NEW
303
           (rhs.time_utc_us == lhs.time_utc_us) &&
×
NEW
304
           (rhs.horizontal_accuracy == lhs.horizontal_accuracy) &&
×
NEW
305
           (rhs.vertical_accuracy == lhs.vertical_accuracy) &&
×
NEW
306
           (rhs.barometer_accuracy == lhs.barometer_accuracy) &&
×
NEW
307
           (rhs.speed_accuracy == lhs.speed_accuracy) &&
×
NEW
308
           (rhs.timestamp_accuracy == lhs.timestamp_accuracy);
×
309
}
310

NEW
311
std::ostream& operator<<(std::ostream& str, RemoteId::Location const& location)
×
312
{
NEW
313
    str << std::setprecision(15);
×
NEW
314
    str << "location:" << '\n' << "{\n";
×
NEW
315
    str << "    status: " << location.status << '\n';
×
NEW
316
    str << "    direction_deg: " << location.direction_deg << '\n';
×
NEW
317
    str << "    speed_horizontal_m_s: " << location.speed_horizontal_m_s << '\n';
×
NEW
318
    str << "    speed_vertical_m_s: " << location.speed_vertical_m_s << '\n';
×
NEW
319
    str << "    latitude_deg: " << location.latitude_deg << '\n';
×
NEW
320
    str << "    longitude_deg: " << location.longitude_deg << '\n';
×
NEW
321
    str << "    altitude_barometric_m: " << location.altitude_barometric_m << '\n';
×
NEW
322
    str << "    altitude_geodetic_m: " << location.altitude_geodetic_m << '\n';
×
NEW
323
    str << "    height_reference: " << location.height_reference << '\n';
×
NEW
324
    str << "    height_m: " << location.height_m << '\n';
×
NEW
325
    str << "    time_utc_us: " << location.time_utc_us << '\n';
×
NEW
326
    str << "    horizontal_accuracy: " << location.horizontal_accuracy << '\n';
×
NEW
327
    str << "    vertical_accuracy: " << location.vertical_accuracy << '\n';
×
NEW
328
    str << "    barometer_accuracy: " << location.barometer_accuracy << '\n';
×
NEW
329
    str << "    speed_accuracy: " << location.speed_accuracy << '\n';
×
NEW
330
    str << "    timestamp_accuracy: " << location.timestamp_accuracy << '\n';
×
NEW
331
    str << '}';
×
NEW
332
    return str;
×
333
}
334

NEW
335
std::ostream& operator<<(
×
336
    std::ostream& str, RemoteId::SystemId::OperatorLocationType const& operator_location_type)
337
{
NEW
338
    switch (operator_location_type) {
×
NEW
339
        case RemoteId::SystemId::OperatorLocationType::Takeoff:
×
NEW
340
            return str << "Takeoff";
×
NEW
341
        case RemoteId::SystemId::OperatorLocationType::LiveGnss:
×
NEW
342
            return str << "Live Gnss";
×
NEW
343
        case RemoteId::SystemId::OperatorLocationType::Fixed:
×
NEW
344
            return str << "Fixed";
×
NEW
345
        default:
×
NEW
346
            return str << "Unknown";
×
347
    }
348
}
349

350
std::ostream&
NEW
351
operator<<(std::ostream& str, RemoteId::SystemId::ClassificationType const& classification_type)
×
352
{
NEW
353
    switch (classification_type) {
×
NEW
354
        case RemoteId::SystemId::ClassificationType::Undeclared:
×
NEW
355
            return str << "Undeclared";
×
NEW
356
        case RemoteId::SystemId::ClassificationType::Eu:
×
NEW
357
            return str << "Eu";
×
NEW
358
        default:
×
NEW
359
            return str << "Unknown";
×
360
    }
361
}
362

NEW
363
std::ostream& operator<<(std::ostream& str, RemoteId::SystemId::CategoryEu const& category_eu)
×
364
{
NEW
365
    switch (category_eu) {
×
NEW
366
        case RemoteId::SystemId::CategoryEu::Undeclared:
×
NEW
367
            return str << "Undeclared";
×
NEW
368
        case RemoteId::SystemId::CategoryEu::Open:
×
NEW
369
            return str << "Open";
×
NEW
370
        case RemoteId::SystemId::CategoryEu::Specific:
×
NEW
371
            return str << "Specific";
×
NEW
372
        case RemoteId::SystemId::CategoryEu::Certified:
×
NEW
373
            return str << "Certified";
×
NEW
374
        default:
×
NEW
375
            return str << "Unknown";
×
376
    }
377
}
378

NEW
379
std::ostream& operator<<(std::ostream& str, RemoteId::SystemId::ClassEu const& class_eu)
×
380
{
NEW
381
    switch (class_eu) {
×
NEW
382
        case RemoteId::SystemId::ClassEu::Undeclared:
×
NEW
383
            return str << "Undeclared";
×
NEW
384
        case RemoteId::SystemId::ClassEu::Class0:
×
NEW
385
            return str << "Class 0";
×
NEW
386
        case RemoteId::SystemId::ClassEu::Class1:
×
NEW
387
            return str << "Class 1";
×
NEW
388
        case RemoteId::SystemId::ClassEu::Class2:
×
NEW
389
            return str << "Class 2";
×
NEW
390
        case RemoteId::SystemId::ClassEu::Class3:
×
NEW
391
            return str << "Class 3";
×
NEW
392
        case RemoteId::SystemId::ClassEu::Class4:
×
NEW
393
            return str << "Class 4";
×
NEW
394
        case RemoteId::SystemId::ClassEu::Class5:
×
NEW
395
            return str << "Class 5";
×
NEW
396
        case RemoteId::SystemId::ClassEu::Class6:
×
NEW
397
            return str << "Class 6";
×
NEW
398
        default:
×
NEW
399
            return str << "Unknown";
×
400
    }
401
}
NEW
402
bool operator==(const RemoteId::SystemId& lhs, const RemoteId::SystemId& rhs)
×
403
{
NEW
404
    return (rhs.operator_location_type == lhs.operator_location_type) &&
×
NEW
405
           (rhs.classification_type == lhs.classification_type) &&
×
NEW
406
           ((std::isnan(rhs.operator_latitude_deg) && std::isnan(lhs.operator_latitude_deg)) ||
×
NEW
407
            rhs.operator_latitude_deg == lhs.operator_latitude_deg) &&
×
NEW
408
           ((std::isnan(rhs.operator_longitude_deg) && std::isnan(lhs.operator_longitude_deg)) ||
×
NEW
409
            rhs.operator_longitude_deg == lhs.operator_longitude_deg) &&
×
NEW
410
           (rhs.area_count == lhs.area_count) && (rhs.area_radius_m == lhs.area_radius_m) &&
×
NEW
411
           ((std::isnan(rhs.area_ceiling_m) && std::isnan(lhs.area_ceiling_m)) ||
×
NEW
412
            rhs.area_ceiling_m == lhs.area_ceiling_m) &&
×
NEW
413
           ((std::isnan(rhs.area_floor_m) && std::isnan(lhs.area_floor_m)) ||
×
NEW
414
            rhs.area_floor_m == lhs.area_floor_m) &&
×
NEW
415
           (rhs.category_eu == lhs.category_eu) && (rhs.class_eu == lhs.class_eu) &&
×
NEW
416
           ((std::isnan(rhs.operator_altitude_geo_m) && std::isnan(lhs.operator_altitude_geo_m)) ||
×
NEW
417
            rhs.operator_altitude_geo_m == lhs.operator_altitude_geo_m) &&
×
NEW
418
           (rhs.time_utc_us == lhs.time_utc_us);
×
419
}
420

NEW
421
std::ostream& operator<<(std::ostream& str, RemoteId::SystemId const& system_id)
×
422
{
NEW
423
    str << std::setprecision(15);
×
NEW
424
    str << "system_id:" << '\n' << "{\n";
×
NEW
425
    str << "    operator_location_type: " << system_id.operator_location_type << '\n';
×
NEW
426
    str << "    classification_type: " << system_id.classification_type << '\n';
×
NEW
427
    str << "    operator_latitude_deg: " << system_id.operator_latitude_deg << '\n';
×
NEW
428
    str << "    operator_longitude_deg: " << system_id.operator_longitude_deg << '\n';
×
NEW
429
    str << "    area_count: " << system_id.area_count << '\n';
×
NEW
430
    str << "    area_radius_m: " << system_id.area_radius_m << '\n';
×
NEW
431
    str << "    area_ceiling_m: " << system_id.area_ceiling_m << '\n';
×
NEW
432
    str << "    area_floor_m: " << system_id.area_floor_m << '\n';
×
NEW
433
    str << "    category_eu: " << system_id.category_eu << '\n';
×
NEW
434
    str << "    class_eu: " << system_id.class_eu << '\n';
×
NEW
435
    str << "    operator_altitude_geo_m: " << system_id.operator_altitude_geo_m << '\n';
×
NEW
436
    str << "    time_utc_us: " << system_id.time_utc_us << '\n';
×
NEW
437
    str << '}';
×
NEW
438
    return str;
×
439
}
440

441
std::ostream&
NEW
442
operator<<(std::ostream& str, RemoteId::OperatorId::OperatorIdType const& operator_id_type)
×
443
{
NEW
444
    switch (operator_id_type) {
×
NEW
445
        case RemoteId::OperatorId::OperatorIdType::Caa:
×
NEW
446
            return str << "Caa";
×
NEW
447
        default:
×
NEW
448
            return str << "Unknown";
×
449
    }
450
}
NEW
451
bool operator==(const RemoteId::OperatorId& lhs, const RemoteId::OperatorId& rhs)
×
452
{
NEW
453
    return (rhs.operator_id_type == lhs.operator_id_type) && (rhs.operator_id == lhs.operator_id);
×
454
}
455

NEW
456
std::ostream& operator<<(std::ostream& str, RemoteId::OperatorId const& operator_id)
×
457
{
NEW
458
    str << std::setprecision(15);
×
NEW
459
    str << "operator_id:" << '\n' << "{\n";
×
NEW
460
    str << "    operator_id_type: " << operator_id.operator_id_type << '\n';
×
NEW
461
    str << "    operator_id: " << operator_id.operator_id << '\n';
×
NEW
462
    str << '}';
×
NEW
463
    return str;
×
464
}
465

NEW
466
std::ostream& operator<<(std::ostream& str, RemoteId::SelfId::DescType const& desc_type)
×
467
{
NEW
468
    switch (desc_type) {
×
NEW
469
        case RemoteId::SelfId::DescType::Text:
×
NEW
470
            return str << "Text";
×
NEW
471
        case RemoteId::SelfId::DescType::Emergency:
×
NEW
472
            return str << "Emergency";
×
NEW
473
        case RemoteId::SelfId::DescType::ExtendedStatus:
×
NEW
474
            return str << "Extended Status";
×
NEW
475
        default:
×
NEW
476
            return str << "Unknown";
×
477
    }
478
}
NEW
479
bool operator==(const RemoteId::SelfId& lhs, const RemoteId::SelfId& rhs)
×
480
{
NEW
481
    return (rhs.description_type == lhs.description_type) && (rhs.description == lhs.description);
×
482
}
483

NEW
484
std::ostream& operator<<(std::ostream& str, RemoteId::SelfId const& self_id)
×
485
{
NEW
486
    str << std::setprecision(15);
×
NEW
487
    str << "self_id:" << '\n' << "{\n";
×
NEW
488
    str << "    description_type: " << self_id.description_type << '\n';
×
NEW
489
    str << "    description: " << self_id.description << '\n';
×
NEW
490
    str << '}';
×
NEW
491
    return str;
×
492
}
493

NEW
494
std::ostream& operator<<(std::ostream& str, RemoteId::ArmStatus::Status const& status)
×
495
{
NEW
496
    switch (status) {
×
NEW
497
        case RemoteId::ArmStatus::Status::GoodToArm:
×
NEW
498
            return str << "Good To Arm";
×
NEW
499
        case RemoteId::ArmStatus::Status::PreArmFailGeneric:
×
NEW
500
            return str << "Pre Arm Fail Generic";
×
NEW
501
        default:
×
NEW
502
            return str << "Unknown";
×
503
    }
504
}
NEW
505
bool operator==(const RemoteId::ArmStatus& lhs, const RemoteId::ArmStatus& rhs)
×
506
{
NEW
507
    return (rhs.status == lhs.status) && (rhs.error == lhs.error);
×
508
}
509

NEW
510
std::ostream& operator<<(std::ostream& str, RemoteId::ArmStatus const& arm_status)
×
511
{
NEW
512
    str << std::setprecision(15);
×
NEW
513
    str << "arm_status:" << '\n' << "{\n";
×
NEW
514
    str << "    status: " << arm_status.status << '\n';
×
NEW
515
    str << "    error: " << arm_status.error << '\n';
×
NEW
516
    str << '}';
×
NEW
517
    return str;
×
518
}
519

NEW
520
std::ostream& operator<<(std::ostream& str, RemoteId::Result const& result)
×
521
{
NEW
522
    switch (result) {
×
NEW
523
        case RemoteId::Result::Unknown:
×
NEW
524
            return str << "Unknown";
×
NEW
525
        case RemoteId::Result::Success:
×
NEW
526
            return str << "Success";
×
NEW
527
        case RemoteId::Result::Error:
×
NEW
528
            return str << "Error";
×
NEW
529
        default:
×
NEW
530
            return str << "Unknown";
×
531
    }
532
}
533

534
} // 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