-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathMessage.m
More file actions
31 lines (29 loc) · 805 Bytes
/
Message.m
File metadata and controls
31 lines (29 loc) · 805 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
classdef Message
% Message sent by a UAV; no larger than 32 bytes
% pos is the perceived [x,y] coordinate of the UAV
% bearing is the perceived bearing of the UAV
% state is the FSM state of the UAV
% pheremoneType indicates whether the message contains a pheremone
% id is the ID of the UAV
properties
% 16 bytes
pos;
% 8 bytes
bearing;
% 1 byte
state;
% 1 byte
pheremoneType;
% 1 byte
id;
end
methods
function message = Message()
message.pos = [0,0];
message.id = uint8(-1);
message.bearing = 0;
message.state = UavState.Inactive;
message.pheremoneType = PheremoneType.None;
end
end
end