Skip to content

Commit

Permalink
api: Remove reservation comments for minimal representations
Browse files Browse the repository at this point in the history
  • Loading branch information
adriansmares committed Jul 18, 2022
1 parent b8d1578 commit 4f3c9de
Show file tree
Hide file tree
Showing 2 changed files with 373 additions and 415 deletions.
58 changes: 8 additions & 50 deletions api/end_device.proto
Original file line number Diff line number Diff line change
Expand Up @@ -434,62 +434,29 @@ message MACState {
// A minimal UplinkMessage definition which is binary compatible with the top level UplinkMessage message.
// Used for type safe recent uplink storage.
message UplinkMessage {
reserved 1; // raw_payload
Message payload = 2 [(validate.rules).message.required = true];
reserved 3; // end_device_ids
message TxSettings {
DataRate data_rate = 1 [(validate.rules).message.required = true];
reserved 2; // data_rate_index
reserved 3; // coding_Rate
reserved 4; // frequency
reserved 5; // enable_crc
reserved 6; // timestamp
reserved 7; // time
reserved 8; // downlink
reserved 9; // concentrator_timestamp
reserved 2 to 9;
}
TxSettings settings = 4 [(validate.rules).message.required = true];
message RxMetadata {
GatewayIdentifiers gateway_ids = 1 [(validate.rules).message.required = true];
reserved 2; // antenna_index
reserved 3; // time
reserved 4; // timestamp
reserved 5; // fine_timestamp
reserved 6; // encrypted_fine_timestamp
reserved 7; // encrypted_fine_timestamp_key_id
reserved 8; // rssi
float channel_rssi = 9;
reserved 10; // rssi_standard_deviation
float snr = 11;
reserved 12; // frequency_offset
reserved 13; // location
DownlinkPathConstraint downlink_path_constraint = 14 [(validate.rules).enum.defined_only = true];
bytes uplink_token = 15;
reserved 16; // signal_rssi
reserved 17; // channel_index
message PacketBrokerMetadata {
reserved 1; // message_id
reserved 2; // forwarder_net_id
reserved 3; // forwarder_tenant_id
reserved 4; // forwarder_cluster_id
reserved 5; // forwarder_gateway_eui
reserved 6; // home_network_tenant_id
reserved 7; // hops
reserved 8; // home_network_cluster_id
reserved 9; // forwarder_gateway_eui
reserved 10; // forwarder_gateway_id
reserved 1 to 10;
}
PacketBrokerMetadata packet_broker = 18;
reserved 19; // hopping_width
reserved 20; // frequency_drift
reserved 99; // advanced
reserved 2 to 8, 10, 12, 13, 16, 17, 19, 20, 99;
}
repeated RxMetadata rx_metadata = 5;
google.protobuf.Timestamp received_at = 6;
repeated string correlation_ids = 7 [(validate.rules).repeated.items.string.max_len = 100];
reserved 8; // gateway_channel_index
uint32 device_channel_index = 9 [(validate.rules).uint32 = {lte: 255}];
reserved 10; // consumed_airtime
reserved 1, 3, 8, 10;
}

// A minimal DownlinkMessage definition which is binary compatible with the top level DownlinkMessage message.
Expand All @@ -499,29 +466,20 @@ message MACState {
message Message {
message MHDR {
MType m_type = 1 [(validate.rules).enum.defined_only = true];
reserved 2; // major
reserved 2;
}
MHDR m_hdr = 1 [(validate.rules).message.required = true];
reserved 2; // mic
message MACPayload {
reserved 1; // f_hdr
uint32 f_port = 2 [(validate.rules).uint32.lte = 255];
reserved 3; // frm_payload
reserved 4; // decoded_payload
uint32 full_f_cnt = 5;
reserved 1, 3, 4;
}
MACPayload mac_payload = 3;
reserved 4; // join_request_payload
reserved 5; // join_accept_payload
reserved 6; // rejoin_request_payload
reserved 7;
reserved 2, 4 to 7;
}
Message payload = 2;
reserved 3; // end_device_ids
reserved 4; // request
reserved 5; // scheduled
repeated string correlation_ids = 6 [(validate.rules).repeated.items.string.max_len = 100];
reserved 7; // session_key_id
reserved 3 to 5, 7;
}

// Recent data uplink messages sorted by time.
Expand Down
Loading

0 comments on commit 4f3c9de

Please sign in to comment.