Skip to content

Commit a69de40

Browse files
gmorphbillbonney
authored andcommitted
Commit new files generated from new message definitions.
1 parent 169e4b7 commit a69de40

37 files changed

Lines changed: 2544 additions & 0 deletions
Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,165 @@
1+
/* AUTO-GENERATED FILE. DO NOT MODIFY.
2+
*
3+
* This class was automatically generated by the
4+
* java mavlink generator tool. It should not be modified by hand.
5+
*/
6+
7+
// MESSAGE DEEPSTALL PACKING
8+
package com.MAVLink.ardupilotmega;
9+
import com.MAVLink.MAVLinkPacket;
10+
import com.MAVLink.Messages.MAVLinkMessage;
11+
import com.MAVLink.Messages.MAVLinkPayload;
12+
13+
/**
14+
* Deepstall path planning
15+
*/
16+
public class msg_deepstall extends MAVLinkMessage{
17+
18+
public static final int MAVLINK_MSG_ID_DEEPSTALL = 195;
19+
public static final int MAVLINK_MSG_LENGTH = 37;
20+
private static final long serialVersionUID = MAVLINK_MSG_ID_DEEPSTALL;
21+
22+
23+
24+
/**
25+
* Landing latitude (deg * 1E7)
26+
*/
27+
public int landing_lat;
28+
29+
/**
30+
* Landing longitude (deg * 1E7)
31+
*/
32+
public int landing_lon;
33+
34+
/**
35+
* Final heading start point, latitude (deg * 1E7)
36+
*/
37+
public int path_lat;
38+
39+
/**
40+
* Final heading start point, longitude (deg * 1E7)
41+
*/
42+
public int path_lon;
43+
44+
/**
45+
* Arc entry point, latitude (deg * 1E7)
46+
*/
47+
public int arc_entry_lat;
48+
49+
/**
50+
* Arc entry point, longitude (deg * 1E7)
51+
*/
52+
public int arc_entry_lon;
53+
54+
/**
55+
* Altitude (meters)
56+
*/
57+
public float altitude;
58+
59+
/**
60+
* Distance the aircraft expects to travel during the deepstall
61+
*/
62+
public float expected_travel_distance;
63+
64+
/**
65+
* Deepstall cross track error in meters (only valid when in DEEPSTALL_STAGE_LAND)
66+
*/
67+
public float cross_track_error;
68+
69+
/**
70+
* Deepstall stage, see enum MAV_DEEPSTALL_STAGE
71+
*/
72+
public short stage;
73+
74+
75+
/**
76+
* Generates the payload for a mavlink message for a message of this type
77+
* @return
78+
*/
79+
public MAVLinkPacket pack(){
80+
MAVLinkPacket packet = new MAVLinkPacket(MAVLINK_MSG_LENGTH);
81+
packet.sysid = 255;
82+
packet.compid = 190;
83+
packet.msgid = MAVLINK_MSG_ID_DEEPSTALL;
84+
85+
packet.payload.putInt(landing_lat);
86+
87+
packet.payload.putInt(landing_lon);
88+
89+
packet.payload.putInt(path_lat);
90+
91+
packet.payload.putInt(path_lon);
92+
93+
packet.payload.putInt(arc_entry_lat);
94+
95+
packet.payload.putInt(arc_entry_lon);
96+
97+
packet.payload.putFloat(altitude);
98+
99+
packet.payload.putFloat(expected_travel_distance);
100+
101+
packet.payload.putFloat(cross_track_error);
102+
103+
packet.payload.putUnsignedByte(stage);
104+
105+
return packet;
106+
}
107+
108+
/**
109+
* Decode a deepstall message into this class fields
110+
*
111+
* @param payload The message to decode
112+
*/
113+
public void unpack(MAVLinkPayload payload) {
114+
payload.resetIndex();
115+
116+
this.landing_lat = payload.getInt();
117+
118+
this.landing_lon = payload.getInt();
119+
120+
this.path_lat = payload.getInt();
121+
122+
this.path_lon = payload.getInt();
123+
124+
this.arc_entry_lat = payload.getInt();
125+
126+
this.arc_entry_lon = payload.getInt();
127+
128+
this.altitude = payload.getFloat();
129+
130+
this.expected_travel_distance = payload.getFloat();
131+
132+
this.cross_track_error = payload.getFloat();
133+
134+
this.stage = payload.getUnsignedByte();
135+
136+
}
137+
138+
/**
139+
* Constructor for a new message, just initializes the msgid
140+
*/
141+
public msg_deepstall(){
142+
msgid = MAVLINK_MSG_ID_DEEPSTALL;
143+
}
144+
145+
/**
146+
* Constructor for a new message, initializes the message with the payload
147+
* from a mavlink packet
148+
*
149+
*/
150+
public msg_deepstall(MAVLinkPacket mavLinkPacket){
151+
this.sysid = mavLinkPacket.sysid;
152+
this.compid = mavLinkPacket.compid;
153+
this.msgid = MAVLINK_MSG_ID_DEEPSTALL;
154+
unpack(mavLinkPacket.payload);
155+
}
156+
157+
158+
/**
159+
* Returns a string with the MSG name and data
160+
*/
161+
public String toString(){
162+
return "MAVLINK_MSG_ID_DEEPSTALL - sysid:"+sysid+" compid:"+compid+" landing_lat:"+landing_lat+" landing_lon:"+landing_lon+" path_lat:"+path_lat+" path_lon:"+path_lon+" arc_entry_lat:"+arc_entry_lat+" arc_entry_lon:"+arc_entry_lon+" altitude:"+altitude+" expected_travel_distance:"+expected_travel_distance+" cross_track_error:"+cross_track_error+" stage:"+stage+"";
163+
}
164+
}
165+
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
/* AUTO-GENERATED FILE. DO NOT MODIFY.
2+
*
3+
* This class was automatically generated by the
4+
* java mavlink generator tool. It should not be modified by hand.
5+
*/
6+
7+
// MESSAGE RPM PACKING
8+
package com.MAVLink.ardupilotmega;
9+
import com.MAVLink.MAVLinkPacket;
10+
import com.MAVLink.Messages.MAVLinkMessage;
11+
import com.MAVLink.Messages.MAVLinkPayload;
12+
13+
/**
14+
* RPM sensor output
15+
*/
16+
public class msg_rpm extends MAVLinkMessage{
17+
18+
public static final int MAVLINK_MSG_ID_RPM = 226;
19+
public static final int MAVLINK_MSG_LENGTH = 8;
20+
private static final long serialVersionUID = MAVLINK_MSG_ID_RPM;
21+
22+
23+
24+
/**
25+
* RPM Sensor1
26+
*/
27+
public float rpm1;
28+
29+
/**
30+
* RPM Sensor2
31+
*/
32+
public float rpm2;
33+
34+
35+
/**
36+
* Generates the payload for a mavlink message for a message of this type
37+
* @return
38+
*/
39+
public MAVLinkPacket pack(){
40+
MAVLinkPacket packet = new MAVLinkPacket(MAVLINK_MSG_LENGTH);
41+
packet.sysid = 255;
42+
packet.compid = 190;
43+
packet.msgid = MAVLINK_MSG_ID_RPM;
44+
45+
packet.payload.putFloat(rpm1);
46+
47+
packet.payload.putFloat(rpm2);
48+
49+
return packet;
50+
}
51+
52+
/**
53+
* Decode a rpm message into this class fields
54+
*
55+
* @param payload The message to decode
56+
*/
57+
public void unpack(MAVLinkPayload payload) {
58+
payload.resetIndex();
59+
60+
this.rpm1 = payload.getFloat();
61+
62+
this.rpm2 = payload.getFloat();
63+
64+
}
65+
66+
/**
67+
* Constructor for a new message, just initializes the msgid
68+
*/
69+
public msg_rpm(){
70+
msgid = MAVLINK_MSG_ID_RPM;
71+
}
72+
73+
/**
74+
* Constructor for a new message, initializes the message with the payload
75+
* from a mavlink packet
76+
*
77+
*/
78+
public msg_rpm(MAVLinkPacket mavLinkPacket){
79+
this.sysid = mavLinkPacket.sysid;
80+
this.compid = mavLinkPacket.compid;
81+
this.msgid = MAVLINK_MSG_ID_RPM;
82+
unpack(mavLinkPacket.payload);
83+
}
84+
85+
86+
/**
87+
* Returns a string with the MSG name and data
88+
*/
89+
public String toString(){
90+
return "MAVLINK_MSG_ID_RPM - sysid:"+sysid+" compid:"+compid+" rpm1:"+rpm1+" rpm2:"+rpm2+"";
91+
}
92+
}
93+

0 commit comments

Comments
 (0)