1- use crate :: FromRpcResponse ;
2- use crate :: RequestError ;
3- use crate :: RequestResult ;
4- use crate :: TonicResult ;
1+ use crate :: { FromRpcResponse , RequestError , RequestResult , TonicResult } ;
52
63mod pb {
74 tonic:: include_proto!( "mavsdk.rpc.mocap" ) ;
@@ -10,7 +7,8 @@ mod pb {
107/// Global position/attitude estimate from a vision source.
118#[ derive( Default , Clone , PartialEq , Debug ) ]
129pub struct VisionPositionEstimate {
13- /// PositionBody frame timestamp UNIX Epoch time (0 to use Backend timestamp)
10+ /// PositionBody frame timestamp UNIX Epoch time (0 to use Backend
11+ /// timestamp)
1412 pub time_usec : u64 ,
1513 /// Global position (m)
1614 pub position_body : PositionBody ,
@@ -34,7 +32,8 @@ impl From<VisionPositionEstimate> for pb::VisionPositionEstimate {
3432/// Motion capture attitude and position
3533#[ derive( Clone , PartialEq , Debug ) ]
3634pub struct AttitudePosition {
37- /// PositionBody frame timestamp UNIX Epoch time (0 to use Backend timestamp)
35+ /// PositionBody frame timestamp UNIX Epoch time (0 to use Backend
36+ /// timestamp)
3837 pub time_usec : u64 ,
3938 /// Attitude quaternion (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
4039 pub q : Quaternion ,
@@ -55,7 +54,8 @@ impl From<AttitudePosition> for pb::AttitudePositionMocap {
5554 }
5655}
5756
58- /// Odometry message to communicate odometry mocaprmation with an external interface.
57+ /// Odometry message to communicate odometry mocaprmation with an external
58+ /// interface.
5959#[ derive( Clone , PartialEq , Debug ) ]
6060pub struct Odometry {
6161 /// Timestamp (0 to use Backend timestamp).
@@ -192,7 +192,6 @@ impl From<Covariance> for pb::Covariance {
192192 }
193193}
194194
195- ///
196195/// Quaternion type.
197196///
198197/// All rotations and axis systems follow the right-hand rule.
@@ -280,9 +279,9 @@ impl FromRpcResponse<pb::SetVisionPositionEstimateResponse> for SetVisionPositio
280279 }
281280}
282281
283- # [ doc = " Motion Capture allow vehicles to navigate when a global" ]
284- # [ doc = " position source is unavailable or unreliable" ]
285- # [ doc = " (e.g. indoors, or when flying under a bridge. etc.)." ]
282+ /// Motion Capture allow vehicles to navigate when a global
283+ /// position source is unavailable or unreliable
284+ /// (e.g. indoors, or when flying under a bridge. etc.).
286285pub struct Mocap {
287286 service_client : pb:: mocap_service_client:: MocapServiceClient < tonic:: transport:: Channel > ,
288287}
0 commit comments