epan/dissectors/pidl/ C99 drsuapi
[wireshark-sm.git] / epan / dissectors / packet-llrp.c
blob43e744ecbb9f25a80278e881da4d9768e8817507
1 /* packet-llrp.c
2 * Routines for Low Level Reader Protocol dissection
3 * Copyright 2012, Evan Huus <eapache@gmail.com>
4 * Copyright 2012, Martin Kupec <martin.kupec@kupson.cz>
5 * Copyright 2014, Petr Stetiar <petr.stetiar@gaben.cz>
7 * http://www.gs1.org/gsmp/kc/epcglobal/llrp
9 * Wireshark - Network traffic analyzer
10 * By Gerald Combs <gerald@wireshark.org>
11 * Copyright 1998 Gerald Combs
13 * SPDX-License-Identifier: GPL-2.0-or-later
16 #include "config.h"
18 #include <epan/packet.h>
19 #include <epan/expert.h>
20 #include <epan/tfs.h>
21 #include <wsutil/array.h>
23 #include "packet-tcp.h"
25 void proto_register_llrp(void);
26 void proto_reg_handoff_llrp(void);
28 static dissector_handle_t llrp_handle;
30 #define LLRP_PORT 5084
32 /* Initialize the protocol and registered fields */
33 static int proto_llrp;
34 static int hf_llrp_version;
35 static int hf_llrp_type;
36 static int hf_llrp_length;
37 static int hf_llrp_id;
38 static int hf_llrp_cur_ver;
39 static int hf_llrp_sup_ver;
40 static int hf_llrp_req_cap;
41 static int hf_llrp_req_conf;
42 static int hf_llrp_rospec;
43 static int hf_llrp_antenna_id;
44 static int hf_llrp_gpi_port;
45 static int hf_llrp_gpo_port;
46 static int hf_llrp_rest_fact;
47 static int hf_llrp_accessspec;
48 static int hf_llrp_vendor;
49 static int hf_llrp_impinj_msg_type;
50 static int hf_llrp_tlv_type;
51 static int hf_llrp_tv_type;
52 static int hf_llrp_tlv_len;
53 static int hf_llrp_param;
54 static int hf_llrp_num_gpi;
55 static int hf_llrp_num_gpo;
56 static int hf_llrp_microseconds;
57 static int hf_llrp_max_supported_antenna;
58 static int hf_llrp_can_set_antenna_prop;
59 static int hf_llrp_has_utc_clock;
60 static int hf_llrp_device_manufacturer;
61 static int hf_llrp_model;
62 static int hf_llrp_firmware_version;
63 static int hf_llrp_max_receive_sense;
64 static int hf_llrp_index;
65 static int hf_llrp_receive_sense;
66 static int hf_llrp_receive_sense_index_min;
67 static int hf_llrp_receive_sense_index_max;
68 static int hf_llrp_num_protocols;
69 static int hf_llrp_protocol_id;
70 static int hf_llrp_can_do_survey;
71 static int hf_llrp_can_report_buffer_warning;
72 static int hf_llrp_support_client_opspec;
73 static int hf_llrp_can_stateaware;
74 static int hf_llrp_support_holding;
75 static int hf_llrp_max_priority_supported;
76 static int hf_llrp_client_opspec_timeout;
77 static int hf_llrp_max_num_rospec;
78 static int hf_llrp_max_num_spec_per_rospec;
79 static int hf_llrp_max_num_inventory_per_aispec;
80 static int hf_llrp_max_num_accessspec;
81 static int hf_llrp_max_num_opspec_per_accressspec;
82 static int hf_llrp_country_code;
83 static int hf_llrp_comm_standard;
84 static int hf_llrp_transmit_power;
85 static int hf_llrp_hopping;
86 static int hf_llrp_hop_table_id;
87 static int hf_llrp_rfu;
88 static int hf_llrp_num_hops;
89 static int hf_llrp_frequency;
90 static int hf_llrp_num_freqs;
91 static int hf_llrp_min_freq;
92 static int hf_llrp_max_freq;
93 static int hf_llrp_rospec_id;
94 static int hf_llrp_priority;
95 static int hf_llrp_cur_state;
96 static int hf_llrp_rospec_start_trig_type;
97 static int hf_llrp_offset;
98 static int hf_llrp_period;
99 static int hf_llrp_gpi_event;
100 static int hf_llrp_timeout;
101 static int hf_llrp_rospec_stop_trig_type;
102 static int hf_llrp_duration_trig;
103 static int hf_llrp_antenna_count;
104 static int hf_llrp_antenna;
105 static int hf_llrp_aispec_stop_trig_type;
106 static int hf_llrp_trig_type;
107 static int hf_llrp_number_of_tags;
108 static int hf_llrp_number_of_attempts;
109 static int hf_llrp_t;
110 static int hf_llrp_inventory_spec_id;
111 static int hf_llrp_start_freq;
112 static int hf_llrp_stop_freq;
113 static int hf_llrp_stop_trig_type;
114 static int hf_llrp_n_4;
115 static int hf_llrp_duration;
116 static int hf_llrp_accessspec_id;
117 static int hf_llrp_access_cur_state;
118 static int hf_llrp_access_stop_trig_type;
119 static int hf_llrp_operation_count;
120 static int hf_llrp_opspec_id;
121 static int hf_llrp_conf_value;
122 static int hf_llrp_id_type;
123 static int hf_llrp_reader_id;
124 static int hf_llrp_gpo_data;
125 static int hf_llrp_keepalive_trig_type;
126 static int hf_llrp_time_iterval;
127 static int hf_llrp_antenna_connected;
128 static int hf_llrp_antenna_gain;
129 static int hf_llrp_receiver_sense;
130 static int hf_llrp_channel_idx;
131 static int hf_llrp_gpi_config;
132 static int hf_llrp_gpi_state;
133 static int hf_llrp_hold_events_and_reports;
134 static int hf_llrp_ro_report_trig;
135 static int hf_llrp_n_2;
136 static int hf_llrp_enable_rospec_id;
137 static int hf_llrp_enable_spec_idx;
138 static int hf_llrp_enable_inv_spec_id;
139 static int hf_llrp_enable_antenna_id;
140 static int hf_llrp_enable_channel_idx;
141 static int hf_llrp_enable_peak_rssi;
142 static int hf_llrp_enable_first_seen;
143 static int hf_llrp_enable_last_seen;
144 static int hf_llrp_enable_seen_count;
145 static int hf_llrp_enable_accessspec_id;
146 static int hf_llrp_access_report_trig;
147 static int hf_llrp_length_bits;
148 static int hf_llrp_epc;
149 static int hf_llrp_spec_idx;
150 static int hf_llrp_peak_rssi;
151 static int hf_llrp_tag_count;
152 static int hf_llrp_bandwidth;
153 static int hf_llrp_average_rssi;
154 static int hf_llrp_notif_state;
155 static int hf_llrp_event_type;
156 static int hf_llrp_next_chan_idx;
157 static int hf_llrp_roevent_type;
158 static int hf_llrp_prem_rospec_id;
159 static int hf_llrp_buffer_full_percentage;
160 static int hf_llrp_message;
161 static int hf_llrp_rfevent_type;
162 static int hf_llrp_aievent_type;
163 static int hf_llrp_antenna_event_type;
164 static int hf_llrp_conn_status;
165 static int hf_llrp_loop_count;
166 static int hf_llrp_status_code;
167 static int hf_llrp_error_desc;
168 static int hf_llrp_field_num;
169 static int hf_llrp_error_code;
170 static int hf_llrp_parameter_type;
171 static int hf_llrp_can_support_block_erase;
172 static int hf_llrp_can_support_block_write;
173 static int hf_llrp_can_support_block_permalock;
174 static int hf_llrp_can_support_tag_recomm;
175 static int hf_llrp_can_support_UMI_method2;
176 static int hf_llrp_can_support_XPC;
177 static int hf_llrp_max_num_filter_per_query;
178 static int hf_llrp_mode_ident;
179 static int hf_llrp_DR;
180 static int hf_llrp_hag_conformance;
181 static int hf_llrp_mod;
182 static int hf_llrp_flm;
183 static int hf_llrp_m;
184 static int hf_llrp_bdr;
185 static int hf_llrp_pie;
186 static int hf_llrp_min_tari;
187 static int hf_llrp_max_tari;
188 static int hf_llrp_step_tari;
189 static int hf_llrp_inventory_state_aware;
190 static int hf_llrp_trunc;
191 static int hf_llrp_mb;
192 static int hf_llrp_pointer;
193 static int hf_llrp_tag_mask;
194 static int hf_llrp_aware_filter_target;
195 static int hf_llrp_aware_filter_action;
196 static int hf_llrp_unaware_filter_action;
197 static int hf_llrp_mode_idx;
198 static int hf_llrp_tari;
199 static int hf_llrp_session;
200 static int hf_llrp_tag_population;
201 static int hf_llrp_tag_transit_time;
202 static int hf_llrp_sing_i;
203 static int hf_llrp_sing_s;
204 static int hf_llrp_sing_a;
205 static int hf_llrp_match;
206 static int hf_llrp_tag_data;
207 static int hf_llrp_access_pass;
208 static int hf_llrp_word_pointer;
209 static int hf_llrp_word_count;
210 static int hf_llrp_write_data;
211 static int hf_llrp_kill_pass;
212 static int hf_llrp_kill_3;
213 static int hf_llrp_kill_2;
214 static int hf_llrp_kill_l;
215 static int hf_llrp_privilege;
216 static int hf_llrp_data_field;
217 static int hf_llrp_block_pointer;
218 static int hf_llrp_block_mask;
219 static int hf_llrp_length_words;
220 static int hf_llrp_block_range;
221 static int hf_llrp_enable_crc;
222 static int hf_llrp_enable_pc;
223 static int hf_llrp_enable_xpc;
224 static int hf_llrp_pc_bits;
225 static int hf_llrp_xpc_w1;
226 static int hf_llrp_xpc_w2;
227 static int hf_llrp_crc;
228 static int hf_llrp_num_coll;
229 static int hf_llrp_num_empty;
230 static int hf_llrp_access_result;
231 static int hf_llrp_read_data;
232 static int hf_llrp_num_words_written;
233 static int hf_llrp_permlock_status;
234 static int hf_llrp_vendor_id;
235 static int hf_llrp_vendor_unknown;
236 static int hf_llrp_impinj_param_type;
237 static int hf_llrp_save_config;
238 static int hf_llrp_impinj_req_data;
239 static int hf_llrp_impinj_reg_region;
240 static int hf_llrp_impinj_search_mode;
241 static int hf_llrp_impinj_en_tag_dir;
242 static int hf_llrp_impinj_antenna_conf;
243 static int hf_llrp_decision_time;
244 static int hf_llrp_impinj_tag_dir;
245 static int hf_llrp_confidence;
246 static int hf_llrp_impinj_fix_freq_mode;
247 static int hf_llrp_num_channels;
248 static int hf_llrp_channel;
249 static int hf_llrp_impinj_reduce_power_mode;
250 static int hf_llrp_impinj_low_duty_mode;
251 static int hf_llrp_empty_field_timeout;
252 static int hf_llrp_field_ping_interval;
253 static int hf_llrp_model_name;
254 static int hf_llrp_serial_number;
255 static int hf_llrp_soft_ver;
256 static int hf_llrp_firm_ver;
257 static int hf_llrp_fpga_ver;
258 static int hf_llrp_pcba_ver;
259 static int hf_llrp_height_thresh;
260 static int hf_llrp_zero_motion_thresh;
261 static int hf_llrp_board_manufacturer;
262 static int hf_llrp_fw_ver_hex;
263 static int hf_llrp_hw_ver_hex;
264 static int hf_llrp_gpi_debounce;
265 static int hf_llrp_temperature;
266 static int hf_llrp_impinj_link_monitor_mode;
267 static int hf_llrp_link_down_thresh;
268 static int hf_llrp_impinj_report_buff_mode;
269 static int hf_llrp_permalock_result;
270 static int hf_llrp_block_permalock_result;
271 static int hf_llrp_impinj_data_profile;
272 static int hf_llrp_impinj_access_range;
273 static int hf_llrp_impinj_persistence;
274 static int hf_llrp_set_qt_config_result;
275 static int hf_llrp_get_qt_config_result;
276 static int hf_llrp_impinj_serialized_tid_mode;
277 static int hf_llrp_impinj_rf_phase_mode;
278 static int hf_llrp_impinj_peak_rssi_mode;
279 static int hf_llrp_impinj_gps_coordinates_mode;
280 static int hf_llrp_impinj_tid;
281 static int hf_llrp_phase_angle;
282 static int hf_llrp_rssi;
283 static int hf_llrp_latitude;
284 static int hf_llrp_longitude;
285 static int hf_llrp_gga_sentence;
286 static int hf_llrp_rmc_sentence;
287 static int hf_llrp_impinj_optim_read_mode;
288 static int hf_llrp_impinj_rf_doppler_mode;
289 static int hf_llrp_retry_count;
290 static int hf_llrp_impinj_access_spec_ordering;
291 static int hf_llrp_impinj_gpo_mode;
292 static int hf_llrp_gpo_pulse_dur;
293 static int hf_llrp_impinj_hub_id;
294 static int hf_llrp_impinj_hub_fault_type;
295 static int hf_llrp_impinj_hub_connected_type;
297 /* Initialize the subtree pointers */
298 static int ett_llrp;
299 static int ett_llrp_param;
301 static expert_field ei_llrp_req_conf;
302 static expert_field ei_llrp_invalid_length;
304 /* Message Types */
305 #define LLRP_TYPE_GET_READER_CAPABILITIES 1
306 #define LLRP_TYPE_GET_READER_CONFIG 2
307 #define LLRP_TYPE_SET_READER_CONFIG 3
308 #define LLRP_TYPE_CLOSE_CONNECTION_RESPONSE 4
309 #define LLRP_TYPE_GET_READER_CAPABILITIES_RESPONSE 11
310 #define LLRP_TYPE_GET_READER_CONFIG_RESPONSE 12
311 #define LLRP_TYPE_SET_READER_CONFIG_RESPONSE 13
312 #define LLRP_TYPE_CLOSE_CONNECTION 14
313 #define LLRP_TYPE_ADD_ROSPEC 20
314 #define LLRP_TYPE_DELETE_ROSPEC 21
315 #define LLRP_TYPE_START_ROSPEC 22
316 #define LLRP_TYPE_STOP_ROSPEC 23
317 #define LLRP_TYPE_ENABLE_ROSPEC 24
318 #define LLRP_TYPE_DISABLE_ROSPEC 25
319 #define LLRP_TYPE_GET_ROSPECS 26
320 #define LLRP_TYPE_ADD_ROSPEC_RESPONSE 30
321 #define LLRP_TYPE_DELETE_ROSPEC_RESPONSE 31
322 #define LLRP_TYPE_START_ROSPEC_RESPONSE 32
323 #define LLRP_TYPE_STOP_ROSPEC_RESPONSE 33
324 #define LLRP_TYPE_ENABLE_ROSPEC_RESPONSE 34
325 #define LLRP_TYPE_DISABLE_ROSPEC_RESPONSE 35
326 #define LLRP_TYPE_GET_ROSPECS_RESPONSE 36
327 #define LLRP_TYPE_ADD_ACCESSSPEC 40
328 #define LLRP_TYPE_DELETE_ACCESSSPEC 41
329 #define LLRP_TYPE_ENABLE_ACCESSSPEC 42
330 #define LLRP_TYPE_DISABLE_ACCESSSPEC 43
331 #define LLRP_TYPE_GET_ACCESSSPECS 44
332 #define LLRP_TYPE_CLIENT_REQUEST_OP 45
333 #define LLRP_TYPE_GET_SUPPORTED_VERSION 46
334 #define LLRP_TYPE_SET_PROTOCOL_VERSION 47
335 #define LLRP_TYPE_ADD_ACCESSSPEC_RESPONSE 50
336 #define LLRP_TYPE_DELETE_ACCESSSPEC_RESPONSE 51
337 #define LLRP_TYPE_ENABLE_ACCESSSPEC_RESPONSE 52
338 #define LLRP_TYPE_DISABLE_ACCESSSPEC_RESPONSE 53
339 #define LLRP_TYPE_GET_ACCESSSPECS_RESPONSE 54
340 #define LLRP_TYPE_CLIENT_RESQUEST_OP_RESPONSE 55
341 #define LLRP_TYPE_GET_SUPPORTED_VERSION_RESPONSE 56
342 #define LLRP_TYPE_SET_PROTOCOL_VERSION_RESPONSE 57
343 #define LLRP_TYPE_GET_REPORT 60
344 #define LLRP_TYPE_RO_ACCESS_REPORT 61
345 #define LLRP_TYPE_KEEPALIVE 62
346 #define LLRP_TYPE_READER_EVENT_NOTIFICATION 63
347 #define LLRP_TYPE_ENABLE_EVENTS_AND_REPORTS 64
348 #define LLRP_TYPE_KEEPALIVE_ACK 72
349 #define LLRP_TYPE_ERROR_MESSAGE 100
350 #define LLRP_TYPE_CUSTOM_MESSAGE 1023
352 static const value_string message_types[] = {
353 { LLRP_TYPE_GET_READER_CAPABILITIES, "Get Reader Capabilities" },
354 { LLRP_TYPE_GET_READER_CONFIG, "Get Reader Config" },
355 { LLRP_TYPE_SET_READER_CONFIG, "Set Reader Config" },
356 { LLRP_TYPE_CLOSE_CONNECTION_RESPONSE, "Close Connection Response" },
357 { LLRP_TYPE_GET_READER_CAPABILITIES_RESPONSE,"Get Reader Capabilities Response"},
358 { LLRP_TYPE_GET_READER_CONFIG_RESPONSE, "Get Reader Config Response" },
359 { LLRP_TYPE_SET_READER_CONFIG_RESPONSE, "Set Reader Config Response" },
360 { LLRP_TYPE_CLOSE_CONNECTION, "Close Connection" },
361 { LLRP_TYPE_ADD_ROSPEC, "Add ROSpec" },
362 { LLRP_TYPE_DELETE_ROSPEC, "Delete ROSpec" },
363 { LLRP_TYPE_START_ROSPEC, "Start ROSpec" },
364 { LLRP_TYPE_STOP_ROSPEC, "Stop ROSpec" },
365 { LLRP_TYPE_ENABLE_ROSPEC, "Enable ROSpec" },
366 { LLRP_TYPE_DISABLE_ROSPEC, "Disable ROSpec" },
367 { LLRP_TYPE_GET_ROSPECS, "Get ROSpecs" },
368 { LLRP_TYPE_ADD_ROSPEC_RESPONSE, "Add ROSpec Response" },
369 { LLRP_TYPE_DELETE_ROSPEC_RESPONSE, "Delete ROSpec Response" },
370 { LLRP_TYPE_START_ROSPEC_RESPONSE, "Start ROSpec Response" },
371 { LLRP_TYPE_STOP_ROSPEC_RESPONSE, "Stop ROSpec Response" },
372 { LLRP_TYPE_ENABLE_ROSPEC_RESPONSE, "Enable ROSpec Response" },
373 { LLRP_TYPE_DISABLE_ROSPEC_RESPONSE, "Disable ROSpec Response" },
374 { LLRP_TYPE_GET_ROSPECS_RESPONSE, "Get ROSpecs Response" },
375 { LLRP_TYPE_ADD_ACCESSSPEC, "Add AccessSpec" },
376 { LLRP_TYPE_DELETE_ACCESSSPEC, "Delete AccessSpec" },
377 { LLRP_TYPE_ENABLE_ACCESSSPEC, "Enable AccessSpec" },
378 { LLRP_TYPE_DISABLE_ACCESSSPEC, "Disable AccessSpec" },
379 { LLRP_TYPE_GET_ACCESSSPECS, "Get AccessSpecs" },
380 { LLRP_TYPE_CLIENT_REQUEST_OP, "Client Request OP" },
381 { LLRP_TYPE_GET_SUPPORTED_VERSION, "Get Supported Version" },
382 { LLRP_TYPE_SET_PROTOCOL_VERSION, "Set Protocol Version" },
383 { LLRP_TYPE_ADD_ACCESSSPEC_RESPONSE, "Add AccessSpec Response" },
384 { LLRP_TYPE_DELETE_ACCESSSPEC_RESPONSE, "Delete AccessSpec Response" },
385 { LLRP_TYPE_ENABLE_ACCESSSPEC_RESPONSE, "Enable AccessSpec Response" },
386 { LLRP_TYPE_DISABLE_ACCESSSPEC_RESPONSE, "Disable AccessSpec Response" },
387 { LLRP_TYPE_GET_ACCESSSPECS_RESPONSE, "Get AccessSpecs Response" },
388 { LLRP_TYPE_CLIENT_RESQUEST_OP_RESPONSE, "Client Resquest OP Response" },
389 { LLRP_TYPE_GET_SUPPORTED_VERSION_RESPONSE, "Get Supported Version Response" },
390 { LLRP_TYPE_SET_PROTOCOL_VERSION_RESPONSE, "Set Protocol Version Response" },
391 { LLRP_TYPE_GET_REPORT, "Get Report" },
392 { LLRP_TYPE_RO_ACCESS_REPORT, "RO Access Report" },
393 { LLRP_TYPE_KEEPALIVE, "Keepalive" },
394 { LLRP_TYPE_READER_EVENT_NOTIFICATION, "Reader Event Notification" },
395 { LLRP_TYPE_ENABLE_EVENTS_AND_REPORTS, "Enable Events And Reports" },
396 { LLRP_TYPE_KEEPALIVE_ACK, "Keepalive Ack" },
397 { LLRP_TYPE_ERROR_MESSAGE, "Error Message" },
398 { LLRP_TYPE_CUSTOM_MESSAGE, "Custom Message" },
399 { 0, NULL }
401 static value_string_ext message_types_ext = VALUE_STRING_EXT_INIT(message_types);
403 /* Versions */
404 #define LLRP_VERS_1_0_1 0x01
405 #define LLRP_VERS_1_1 0x02
407 static const value_string llrp_versions[] = {
408 { LLRP_VERS_1_0_1, "1.0.1" },
409 { LLRP_VERS_1_1, "1.1" },
410 { 0, NULL }
413 /* Capabilities */
414 #define LLRP_CAP_ALL 0
415 #define LLRP_CAP_GENERAL_DEVICE 1
416 #define LLRP_CAP_LLRP 2
417 #define LLRP_CAP_REGULATORY 3
418 #define LLRP_CAP_AIR_PROTOCOL 4
420 static const value_string capabilities_request[] = {
421 { LLRP_CAP_ALL, "All" },
422 { LLRP_CAP_GENERAL_DEVICE, "General Device Capabilities" },
423 { LLRP_CAP_LLRP, "LLRP Capabilities" },
424 { LLRP_CAP_REGULATORY, "Regulatory Capabilities" },
425 { LLRP_CAP_AIR_PROTOCOL, "Air Protocol LLRP Capabilities" },
426 { 0, NULL }
429 /* Configurations */
430 #define LLRP_CONF_ALL 0
431 #define LLRP_CONF_IDENTIFICATION 1
432 #define LLRP_CONF_ANTENNA_PROPERTIES 2
433 #define LLRP_CONF_ANTENNA_CONFIGURATION 3
434 #define LLRP_CONF_RO_REPORT_SPEC 4
435 #define LLRP_CONF_READER_EVENT_NOTIFICATION_SPEC 5
436 #define LLRP_CONF_ACCESS_REPORT_SPEC 6
437 #define LLRP_CONF_LLRP_CONFIGURATION_STATE 7
438 #define LLRP_CONF_KEEPALIVE_SPEC 8
439 #define LLRP_CONF_GPI_PORT_CURRENT_STATE 9
440 #define LLRP_CONF_GPO_WRITE_DATA 10
441 #define LLRP_CONF_EVENTS_AND_REPORTS 11
443 static const value_string config_request[] = {
444 { LLRP_CONF_ALL, "All" },
445 { LLRP_CONF_IDENTIFICATION, "Identification" },
446 { LLRP_CONF_ANTENNA_PROPERTIES, "Antenna Properties" },
447 { LLRP_CONF_ANTENNA_CONFIGURATION, "Antenna Configuration" },
448 { LLRP_CONF_RO_REPORT_SPEC, "RO Report Spec" },
449 { LLRP_CONF_READER_EVENT_NOTIFICATION_SPEC, "Reader Event Notification Spec" },
450 { LLRP_CONF_ACCESS_REPORT_SPEC, "Access Report Spec" },
451 { LLRP_CONF_LLRP_CONFIGURATION_STATE, "LLRP Configuration State" },
452 { LLRP_CONF_KEEPALIVE_SPEC, "Keepalive Spec" },
453 { LLRP_CONF_GPI_PORT_CURRENT_STATE, "GPI Port Current State" },
454 { LLRP_CONF_GPO_WRITE_DATA, "GPO Write Data" },
455 { LLRP_CONF_EVENTS_AND_REPORTS, "Events and Reports" },
456 { 0, NULL }
458 static value_string_ext config_request_ext = VALUE_STRING_EXT_INIT(config_request);
460 /* TLV Parameter Types */
461 #define LLRP_TLV_UTC_TIMESTAMP 128
462 #define LLRP_TLV_UPTIME 129
463 #define LLRP_TLV_GENERAL_DEVICE_CAP 137
464 #define LLRP_TLV_RECEIVE_SENSE_ENTRY 139
465 #define LLRP_TLV_ANTENNA_AIR_PROTO 140
466 #define LLRP_TLV_GPIO_CAPABILITIES 141
467 #define LLRP_TLV_LLRP_CAPABILITIES 142
468 #define LLRP_TLV_REGU_CAPABILITIES 143
469 #define LLRP_TLV_UHF_CAPABILITIES 144
470 #define LLRP_TLV_XMIT_POWER_LEVEL_ENTRY 145
471 #define LLRP_TLV_FREQ_INFORMATION 146
472 #define LLRP_TLV_FREQ_HOP_TABLE 147
473 #define LLRP_TLV_FIXED_FREQ_TABLE 148
474 #define LLRP_TLV_ANTENNA_RCV_SENSE_RANGE 149
475 #define LLRP_TLV_RO_SPEC 177
476 #define LLRP_TLV_RO_BOUND_SPEC 178
477 #define LLRP_TLV_RO_SPEC_START_TRIGGER 179
478 #define LLRP_TLV_PER_TRIGGER_VAL 180
479 #define LLRP_TLV_GPI_TRIGGER_VAL 181
480 #define LLRP_TLV_RO_SPEC_STOP_TRIGGER 182
481 #define LLRP_TLV_AI_SPEC 183
482 #define LLRP_TLV_AI_SPEC_STOP 184
483 #define LLRP_TLV_TAG_OBSERV_TRIGGER 185
484 #define LLRP_TLV_INVENTORY_PARAM_SPEC 186
485 #define LLRP_TLV_RF_SURVEY_SPEC 187
486 #define LLRP_TLV_RF_SURVEY_SPEC_STOP_TR 188
487 #define LLRP_TLV_ACCESS_SPEC 207
488 #define LLRP_TLV_ACCESS_SPEC_STOP_TRIG 208
489 #define LLRP_TLV_ACCESS_COMMAND 209
490 #define LLRP_TLV_CLIENT_REQ_OP_SPEC 210
491 #define LLRP_TLV_CLIENT_REQ_RESPONSE 211
492 #define LLRP_TLV_LLRP_CONF_STATE_VAL 217
493 #define LLRP_TLV_IDENT 218
494 #define LLRP_TLV_GPO_WRITE_DATA 219
495 #define LLRP_TLV_KEEPALIVE_SPEC 220
496 #define LLRP_TLV_ANTENNA_PROPS 221
497 #define LLRP_TLV_ANTENNA_CONF 222
498 #define LLRP_TLV_RF_RECEIVER 223
499 #define LLRP_TLV_RF_TRANSMITTER 224
500 #define LLRP_TLV_GPI_PORT_CURRENT_STATE 225
501 #define LLRP_TLV_EVENTS_AND_REPORTS 226
502 #define LLRP_TLV_RO_REPORT_SPEC 237
503 #define LLRP_TLV_TAG_REPORT_CONTENT_SEL 238
504 #define LLRP_TLV_ACCESS_REPORT_SPEC 239
505 #define LLRP_TLV_TAG_REPORT_DATA 240
506 #define LLRP_TLV_EPC_DATA 241
507 #define LLRP_TLV_RF_SURVEY_REPORT_DATA 242
508 #define LLRP_TLV_FREQ_RSSI_LEVEL_ENTRY 243
509 #define LLRP_TLV_READER_EVENT_NOTI_SPEC 244
510 #define LLRP_TLV_EVENT_NOTIF_STATE 245
511 #define LLRP_TLV_READER_EVENT_NOTI_DATA 246
512 #define LLRP_TLV_HOPPING_EVENT 247
513 #define LLRP_TLV_GPI_EVENT 248
514 #define LLRP_TLV_RO_SPEC_EVENT 249
515 #define LLRP_TLV_REPORT_BUF_LEVEL_WARN 250
516 #define LLRP_TLV_REPORT_BUF_OVERFLOW_ERR 251
517 #define LLRP_TLV_READER_EXCEPTION_EVENT 252
518 #define LLRP_TLV_RF_SURVEY_EVENT 253
519 #define LLRP_TLV_AI_SPEC_EVENT 254
520 #define LLRP_TLV_ANTENNA_EVENT 255
521 #define LLRP_TLV_CONN_ATTEMPT_EVENT 256
522 #define LLRP_TLV_CONN_CLOSE_EVENT 257
523 #define LLRP_TLV_LLRP_STATUS 287
524 #define LLRP_TLV_FIELD_ERROR 288
525 #define LLRP_TLV_PARAM_ERROR 289
526 #define LLRP_TLV_C1G2_LLRP_CAP 327
527 #define LLRP_TLV_C1G2_UHF_RF_MD_TBL 328
528 #define LLRP_TLV_C1G2_UHF_RF_MD_TBL_ENT 329
529 #define LLRP_TLV_C1G2_INVENTORY_COMMAND 330
530 #define LLRP_TLV_C1G2_FILTER 331
531 #define LLRP_TLV_C1G2_TAG_INV_MASK 332
532 #define LLRP_TLV_C1G2_TAG_INV_AWARE_FLTR 333
533 #define LLRP_TLV_C1G2_TAG_INV_UNAWR_FLTR 334
534 #define LLRP_TLV_C1G2_RF_CONTROL 335
535 #define LLRP_TLV_C1G2_SINGULATION_CTRL 336
536 #define LLRP_TLV_C1G2_TAG_INV_AWARE_SING 337
537 #define LLRP_TLV_C1G2_TAG_SPEC 338
538 #define LLRP_TLV_C1G2_TARGET_TAG 339
539 #define LLRP_TLV_C1G2_READ 341
540 #define LLRP_TLV_C1G2_WRITE 342
541 #define LLRP_TLV_C1G2_KILL 343
542 #define LLRP_TLV_C1G2_LOCK 344
543 #define LLRP_TLV_C1G2_LOCK_PAYLOAD 345
544 #define LLRP_TLV_C1G2_BLK_ERASE 346
545 #define LLRP_TLV_C1G2_BLK_WRITE 347
546 #define LLRP_TLV_C1G2_EPC_MEMORY_SLCTOR 348
547 #define LLRP_TLV_C1G2_READ_OP_SPEC_RES 349
548 #define LLRP_TLV_C1G2_WRT_OP_SPEC_RES 350
549 #define LLRP_TLV_C1G2_KILL_OP_SPEC_RES 351
550 #define LLRP_TLV_C1G2_LOCK_OP_SPEC_RES 352
551 #define LLRP_TLV_C1G2_BLK_ERS_OP_SPC_RES 353
552 #define LLRP_TLV_C1G2_BLK_WRT_OP_SPC_RES 354
553 #define LLRP_TLV_LOOP_SPEC 355
554 #define LLRP_TLV_SPEC_LOOP_EVENT 356
555 #define LLRP_TLV_C1G2_RECOMMISSION 357
556 #define LLRP_TLV_C1G2_BLK_PERMALOCK 358
557 #define LLRP_TLV_C1G2_GET_BLK_PERMALOCK 359
558 #define LLRP_TLV_C1G2_RECOM_OP_SPEC_RES 360
559 #define LLRP_TLV_C1G2_BLK_PRL_OP_SPC_RES 361
560 #define LLRP_TLV_C1G2_BLK_PRL_STAT_RES 362
561 #define LLRP_TLV_MAX_RECEIVE_SENSE 363
562 #define LLRP_TLV_RF_SURVEY_FREQ_CAP 365
563 #define LLRP_TLV_CUSTOM_PARAMETER 1023
565 static const value_string tlv_type[] = {
566 { LLRP_TLV_UTC_TIMESTAMP, "UTC Timestamp" },
567 { LLRP_TLV_UPTIME, "Uptime" },
568 { LLRP_TLV_GENERAL_DEVICE_CAP, "General Device Capabilities" },
569 { LLRP_TLV_RECEIVE_SENSE_ENTRY, "Receive Sensitivity Entry" },
570 { LLRP_TLV_ANTENNA_AIR_PROTO, "Antenna Air Protocol" },
571 { LLRP_TLV_GPIO_CAPABILITIES, "GPIO Capabilities" },
572 { LLRP_TLV_LLRP_CAPABILITIES, "LLRP Capabilities" },
573 { LLRP_TLV_REGU_CAPABILITIES, "REGU Capabilities" },
574 { LLRP_TLV_UHF_CAPABILITIES, "UHF Capabilities" },
575 { LLRP_TLV_XMIT_POWER_LEVEL_ENTRY, "Transmit Power Level Entry" },
576 { LLRP_TLV_FREQ_INFORMATION, "Frequency Information" },
577 { LLRP_TLV_FREQ_HOP_TABLE, "Frequency Hop Table" },
578 { LLRP_TLV_FIXED_FREQ_TABLE, "Fixed Frequency Table" },
579 { LLRP_TLV_ANTENNA_RCV_SENSE_RANGE, "Antenna RCV Sensitivity Range" },
580 { LLRP_TLV_RO_SPEC, "RO Spec" },
581 { LLRP_TLV_RO_BOUND_SPEC, "RO Bound Spec" },
582 { LLRP_TLV_RO_SPEC_START_TRIGGER, "RO Spec Start Trigger" },
583 { LLRP_TLV_PER_TRIGGER_VAL, "PER Trigger Value" },
584 { LLRP_TLV_GPI_TRIGGER_VAL, "GPI Trigger Value" },
585 { LLRP_TLV_RO_SPEC_STOP_TRIGGER, "RO Spec Stop Trigger" },
586 { LLRP_TLV_AI_SPEC, "AI Spec" },
587 { LLRP_TLV_AI_SPEC_STOP, "AI Spec Stop" },
588 { LLRP_TLV_TAG_OBSERV_TRIGGER, "Tag Observation Trigger" },
589 { LLRP_TLV_INVENTORY_PARAM_SPEC, "Inventory Parameter Spec ID" },
590 { LLRP_TLV_RF_SURVEY_SPEC, "RF Survey Spec" },
591 { LLRP_TLV_RF_SURVEY_SPEC_STOP_TR, "RF Survey Spec Stop Trigger" },
592 { LLRP_TLV_ACCESS_SPEC, "Access Spec" },
593 { LLRP_TLV_ACCESS_SPEC_STOP_TRIG, "Access Spec Stop Trigger" },
594 { LLRP_TLV_ACCESS_COMMAND, "Access Command" },
595 { LLRP_TLV_CLIENT_REQ_OP_SPEC, "Client Request Op Spec" },
596 { LLRP_TLV_CLIENT_REQ_RESPONSE, "Client Request Response" },
597 { LLRP_TLV_LLRP_CONF_STATE_VAL, "LLRP Configuration State Value" },
598 { LLRP_TLV_IDENT, "Identification" },
599 { LLRP_TLV_GPO_WRITE_DATA, "GPO Write Data" },
600 { LLRP_TLV_KEEPALIVE_SPEC, "Keepalive Spec" },
601 { LLRP_TLV_ANTENNA_PROPS, "Antenna Properties" },
602 { LLRP_TLV_ANTENNA_CONF, "Antenna Configuration" },
603 { LLRP_TLV_RF_RECEIVER, "RF Receiver" },
604 { LLRP_TLV_RF_TRANSMITTER, "RF Transmitter" },
605 { LLRP_TLV_GPI_PORT_CURRENT_STATE, "GPI Port Current State" },
606 { LLRP_TLV_EVENTS_AND_REPORTS, "Events And Reports" },
607 { LLRP_TLV_RO_REPORT_SPEC, "RO Report Spec" },
608 { LLRP_TLV_TAG_REPORT_CONTENT_SEL, "Tag Report Content Selector" },
609 { LLRP_TLV_ACCESS_REPORT_SPEC, "Access Report Spec" },
610 { LLRP_TLV_TAG_REPORT_DATA, "Tag Report Data" },
611 { LLRP_TLV_EPC_DATA, "EPC Data" },
612 { LLRP_TLV_RF_SURVEY_REPORT_DATA, "RF Survey Report Data" },
613 { LLRP_TLV_FREQ_RSSI_LEVEL_ENTRY, "Frequency RSSI Level Entry" },
614 { LLRP_TLV_READER_EVENT_NOTI_SPEC, "Reader Event Notification Spec" },
615 { LLRP_TLV_EVENT_NOTIF_STATE, "Event Notification State" },
616 { LLRP_TLV_READER_EVENT_NOTI_DATA, "Reader Event Notification Data" },
617 { LLRP_TLV_HOPPING_EVENT, "Hopping Event" },
618 { LLRP_TLV_GPI_EVENT, "GPI Event" },
619 { LLRP_TLV_RO_SPEC_EVENT, "RO Spec Event" },
620 { LLRP_TLV_REPORT_BUF_LEVEL_WARN, "Report Buffer Level Warning Event" },
621 { LLRP_TLV_REPORT_BUF_OVERFLOW_ERR, "Report Buffer Overflow Error Event" },
622 { LLRP_TLV_READER_EXCEPTION_EVENT, "Reader Exception Event" },
623 { LLRP_TLV_RF_SURVEY_EVENT, "RF Survey Event" },
624 { LLRP_TLV_AI_SPEC_EVENT, "AI Spec Event" },
625 { LLRP_TLV_ANTENNA_EVENT, "ANTENNA Event" },
626 { LLRP_TLV_CONN_ATTEMPT_EVENT, "CONN Attempt Event" },
627 { LLRP_TLV_CONN_CLOSE_EVENT, "CONN Close Event" },
628 { LLRP_TLV_LLRP_STATUS, "LLRP Status" },
629 { LLRP_TLV_FIELD_ERROR, "Field Error" },
630 { LLRP_TLV_PARAM_ERROR, "Param Error" },
631 { LLRP_TLV_C1G2_LLRP_CAP, "C1G2 LLRP Capabilities" },
632 { LLRP_TLV_C1G2_UHF_RF_MD_TBL, "C1G2 UHF RF Mode Table" },
633 { LLRP_TLV_C1G2_UHF_RF_MD_TBL_ENT, "C1G2 UHF RF Mode Table Entry" },
634 { LLRP_TLV_C1G2_INVENTORY_COMMAND, "C1G2 Inventory Command" },
635 { LLRP_TLV_C1G2_FILTER, "C1G2 Filter" },
636 { LLRP_TLV_C1G2_TAG_INV_MASK, "C1G2 Tag Inventory Mask" },
637 { LLRP_TLV_C1G2_TAG_INV_AWARE_FLTR, "C1G2 Tag Inventory State-Aware Filter Action" },
638 { LLRP_TLV_C1G2_TAG_INV_UNAWR_FLTR, "C1G2 Tag Inventory State-Unaware Filter Action" },
639 { LLRP_TLV_C1G2_RF_CONTROL, "C1G2 RF Control" },
640 { LLRP_TLV_C1G2_SINGULATION_CTRL, "C1G2 Singulation Control" },
641 { LLRP_TLV_C1G2_TAG_INV_AWARE_SING, "C1G2 Tag Inventory State-Aware Singulation" },
642 { LLRP_TLV_C1G2_TAG_SPEC, "C1G2 Tag Spec" },
643 { LLRP_TLV_C1G2_TARGET_TAG, "C1G2 Target Tag" },
644 { LLRP_TLV_C1G2_READ, "C1G2 Read" },
645 { LLRP_TLV_C1G2_WRITE, "C1G2 Write" },
646 { LLRP_TLV_C1G2_KILL, "C1G2 Kill" },
647 { LLRP_TLV_C1G2_LOCK, "C1G2 Lock" },
648 { LLRP_TLV_C1G2_LOCK_PAYLOAD, "C1G2 Lock Payload" },
649 { LLRP_TLV_C1G2_BLK_ERASE, "C1G2 Block Erase" },
650 { LLRP_TLV_C1G2_BLK_WRITE, "C1G2 Block Write" },
651 { LLRP_TLV_C1G2_EPC_MEMORY_SLCTOR, "C1G2 EPC Memory Selector" },
652 { LLRP_TLV_C1G2_READ_OP_SPEC_RES, "C1G2 Read Op Spec Result" },
653 { LLRP_TLV_C1G2_WRT_OP_SPEC_RES, "C1G2 Write Op Spec Result" },
654 { LLRP_TLV_C1G2_KILL_OP_SPEC_RES, "C1G2 Kill Op Spec Result" },
655 { LLRP_TLV_C1G2_LOCK_OP_SPEC_RES, "C1G2 Lock Op Spec Result" },
656 { LLRP_TLV_C1G2_BLK_ERS_OP_SPC_RES, "C1G2 Block Erase Op Spec Result" },
657 { LLRP_TLV_C1G2_BLK_WRT_OP_SPC_RES, "C1G2 Block Write Op Spec Result" },
658 { LLRP_TLV_LOOP_SPEC, "Loop Spec" },
659 { LLRP_TLV_SPEC_LOOP_EVENT, "Spec loop event" },
660 { LLRP_TLV_C1G2_RECOMMISSION, "C1G2 Recommission" },
661 { LLRP_TLV_C1G2_BLK_PERMALOCK, "C1G2 Block Permalock" },
662 { LLRP_TLV_C1G2_GET_BLK_PERMALOCK, "C1G2 Get Block Permalock Status" },
663 { LLRP_TLV_C1G2_RECOM_OP_SPEC_RES, "C1G2 Recommission Op Spec Result" },
664 { LLRP_TLV_C1G2_BLK_PRL_OP_SPC_RES, "C1G2 Block Permalock Op Spec Result" },
665 { LLRP_TLV_C1G2_BLK_PRL_STAT_RES, "C1G2 Block Permalock Status Op Spec Result" },
666 { LLRP_TLV_MAX_RECEIVE_SENSE, "Maximum Receive Sensitivity" },
667 { LLRP_TLV_RF_SURVEY_FREQ_CAP, "RF Survey Frequency Capabilities" },
668 { LLRP_TLV_CUSTOM_PARAMETER, "Custom parameter" },
669 { 0, NULL }
671 static value_string_ext tlv_type_ext = VALUE_STRING_EXT_INIT(tlv_type);
673 /* TV Parameter Types */
674 #define LLRP_TV_ANTENNA_ID 1
675 #define LLRP_TV_FIRST_SEEN_TIME_UTC 2
676 #define LLRP_TV_FIRST_SEEN_TIME_UPTIME 3
677 #define LLRP_TV_LAST_SEEN_TIME_UTC 4
678 #define LLRP_TV_LAST_SEEN_TIME_UPTIME 5
679 #define LLRP_TV_PEAK_RSSI 6
680 #define LLRP_TV_CHANNEL_INDEX 7
681 #define LLRP_TV_TAG_SEEN_COUNT 8
682 #define LLRP_TV_RO_SPEC_ID 9
683 #define LLRP_TV_INVENTORY_PARAM_SPEC_ID 10
684 #define LLRP_TV_C1G2_CRC 11
685 #define LLRP_TV_C1G2_PC 12
686 #define LLRP_TV_EPC96 13
687 #define LLRP_TV_SPEC_INDEX 14
688 #define LLRP_TV_CLIENT_REQ_OP_SPEC_RES 15
689 #define LLRP_TV_ACCESS_SPEC_ID 16
690 #define LLRP_TV_OP_SPEC_ID 17
691 #define LLRP_TV_C1G2_SINGULATION_DET 18
692 #define LLRP_TV_C1G2_XPC_W1 19
693 #define LLRP_TV_C1G2_XPC_W2 20
695 /* Since TV's don't have a length field,
696 * use these values instead */
697 #define LLRP_TV_LEN_ANTENNA_ID 2
698 #define LLRP_TV_LEN_FIRST_SEEN_TIME_UTC 8
699 #define LLRP_TV_LEN_FIRST_SEEN_TIME_UPTIME 8
700 #define LLRP_TV_LEN_LAST_SEEN_TIME_UTC 8
701 #define LLRP_TV_LEN_LAST_SEEN_TIME_UPTIME 8
702 #define LLRP_TV_LEN_PEAK_RSSI 1
703 #define LLRP_TV_LEN_CHANNEL_INDEX 2
704 #define LLRP_TV_LEN_TAG_SEEN_COUNT 2
705 #define LLRP_TV_LEN_RO_SPEC_ID 4
706 #define LLRP_TV_LEN_INVENTORY_PARAM_SPEC_ID 2
707 #define LLRP_TV_LEN_C1G2_CRC 2
708 #define LLRP_TV_LEN_C1G2_PC 2
709 #define LLRP_TV_LEN_EPC96 12
710 #define LLRP_TV_LEN_SPEC_INDEX 2
711 #define LLRP_TV_LEN_CLIENT_REQ_OP_SPEC_RES 2
712 #define LLRP_TV_LEN_ACCESS_SPEC_ID 4
713 #define LLRP_TV_LEN_OP_SPEC_ID 2
714 #define LLRP_TV_LEN_C1G2_SINGULATION_DET 4
715 #define LLRP_TV_LEN_C1G2_XPC_W1 2
716 #define LLRP_TV_LEN_C1G2_XPC_W2 2
718 static const value_string tv_type[] = {
719 { LLRP_TV_ANTENNA_ID, "Antenna ID" },
720 { LLRP_TV_FIRST_SEEN_TIME_UTC, "First Seen Timestamp UTC" },
721 { LLRP_TV_FIRST_SEEN_TIME_UPTIME, "First Seen Timestamp Uptime" },
722 { LLRP_TV_LAST_SEEN_TIME_UTC, "Last Seen Timestamp UTC" },
723 { LLRP_TV_LAST_SEEN_TIME_UPTIME, "Last Seen Timestamp Uptime" },
724 { LLRP_TV_PEAK_RSSI, "Peak RSSI" },
725 { LLRP_TV_CHANNEL_INDEX, "Channel Index" },
726 { LLRP_TV_TAG_SEEN_COUNT, "Tag Seen Count" },
727 { LLRP_TV_RO_SPEC_ID, "RO Spec ID" },
728 { LLRP_TV_INVENTORY_PARAM_SPEC_ID, "Inventory Parameter Spec ID" },
729 { LLRP_TV_C1G2_CRC, "C1G2 CRC" },
730 { LLRP_TV_C1G2_PC, "C1G2 PC" },
731 { LLRP_TV_EPC96, "EPC-96" },
732 { LLRP_TV_SPEC_INDEX, "Spec Index" },
733 { LLRP_TV_CLIENT_REQ_OP_SPEC_RES, "Client Request Op Spec Result" },
734 { LLRP_TV_ACCESS_SPEC_ID, "Access Spec ID" },
735 { LLRP_TV_OP_SPEC_ID, "Op Spec ID" },
736 { LLRP_TV_C1G2_SINGULATION_DET, "C1G2 Singulation Details" },
737 { LLRP_TV_C1G2_XPC_W1, "C1G2 XPC W1" },
738 { LLRP_TV_C1G2_XPC_W2, "C1G2 XPC W2" },
739 { 0, NULL }
741 static value_string_ext tv_type_ext = VALUE_STRING_EXT_INIT(tv_type);
743 /* Protocol IDs */
744 #define LLRP_PROT_ID_UNSPECIFIED 0
745 #define LLRP_PROT_ID_EPC_C1G2 1
747 static const range_string protocol_id[] = {
748 { LLRP_PROT_ID_UNSPECIFIED, LLRP_PROT_ID_UNSPECIFIED, "Unspecified protocol" },
749 { LLRP_PROT_ID_EPC_C1G2, LLRP_PROT_ID_EPC_C1G2, "EPCGlobal Class 1 Gen 2" },
750 { LLRP_PROT_ID_EPC_C1G2 + 1, 255, "Reserved for future use" },
751 { 0, 0, NULL }
754 /* Communication standards */
755 #define LLRP_COMM_STANDARD_UNSPECIFIED 0
756 #define LLRP_COMM_STANDARD_US_FCC_PART_15 1
757 #define LLRP_COMM_STANDARD_ETSI_302_208 2
758 #define LLRP_COMM_STANDARD_ETSI_300_220 3
759 #define LLRP_COMM_STANDARD_AUSTRALIA_LIPD_1W 4
760 #define LLRP_COMM_STANDARD_AUSTRALIA_LIPD_4W 5
761 #define LLRP_COMM_STANDARD_JAPAN_ARIB_STD_T89 6
762 #define LLRP_COMM_STANDARD_HONG_KONG_OFTA_1049 7
763 #define LLRP_COMM_STANDARD_TAIWAN_DGT_LP0002 8
764 #define LLRP_COMM_STANDARD_KOREA_MIC_ARTICLE_5_2 9
766 static const value_string comm_standard[] = {
767 { LLRP_COMM_STANDARD_UNSPECIFIED, "Unspecified" },
768 { LLRP_COMM_STANDARD_US_FCC_PART_15, "US FCC Part 15" },
769 { LLRP_COMM_STANDARD_ETSI_302_208, "ETSI 302 208" },
770 { LLRP_COMM_STANDARD_ETSI_300_220, "ETSI 300 220" },
771 { LLRP_COMM_STANDARD_AUSTRALIA_LIPD_1W, "Australia LIPD 1W" },
772 { LLRP_COMM_STANDARD_AUSTRALIA_LIPD_4W, "Australia LIPD 4W" },
773 { LLRP_COMM_STANDARD_JAPAN_ARIB_STD_T89, "Japan_ARIB STD T89" },
774 { LLRP_COMM_STANDARD_HONG_KONG_OFTA_1049, "Hong_Kong OFTA 1049" },
775 { LLRP_COMM_STANDARD_TAIWAN_DGT_LP0002, "Taiwan DGT LP0002" },
776 { LLRP_COMM_STANDARD_KOREA_MIC_ARTICLE_5_2, "Korea MIC Article 5 2" },
777 { 0, NULL }
779 static value_string_ext comm_standard_ext = VALUE_STRING_EXT_INIT(comm_standard);
781 /* ID type */
782 #define LLRP_ID_TYPE_MAC 0
783 #define LLRP_ID_TYPE_EPC 1
785 static const value_string id_type[] = {
786 { LLRP_ID_TYPE_MAC, "MAC" },
787 { LLRP_ID_TYPE_EPC, "EPC" },
788 { 0, NULL }
791 /* KeepAlive type */
792 #define LLRP_KEEPALIVE_TYPE_NULL 0
793 #define LLRP_KEEPALIVE_TYPE_PERIODIC 1
795 static const value_string keepalive_type[] = {
796 { LLRP_KEEPALIVE_TYPE_NULL, "Null" },
797 { LLRP_KEEPALIVE_TYPE_PERIODIC, "Periodic" },
798 { 0, NULL }
801 /* Notification Event type */
802 #define LLRP_NOTIFICATION_EVENT_TYPE_UPON_HOPPING_TO_NEXT_CHANNEL 0
803 #define LLRP_NOTIFICATION_EVENT_TYPE_GPI_EVENT 1
804 #define LLRP_NOTIFICATION_EVENT_TYPE_ROSPEC_EVENT 2
805 #define LLRP_NOTIFICATION_EVENT_TYPE_REPORT_BUFFER_FILL_WARNING 3
806 #define LLRP_NOTIFICATION_EVENT_TYPE_READER_EXCEPTION_EVENT 4
807 #define LLRP_NOTIFICATION_EVENT_TYPE_RFSURVEY_EVENT 5
808 #define LLRP_NOTIFICATION_EVENT_TYPE_AISPEC_EVENT 6
809 #define LLRP_NOTIFICATION_EVENT_TYPE_AISPEC_EVENT_WITH_DETAILS 7
810 #define LLRP_NOTIFICATION_EVENT_TYPE_ANTENNA_EVENT 8
811 #define LLRP_NOTIFICATION_EVENT_TYPE_SPEC_LOOP_EVENT 9
813 static const value_string event_type[] = {
814 { LLRP_NOTIFICATION_EVENT_TYPE_UPON_HOPPING_TO_NEXT_CHANNEL, "Upon hopping to next channel" },
815 { LLRP_NOTIFICATION_EVENT_TYPE_GPI_EVENT, "GPI event" },
816 { LLRP_NOTIFICATION_EVENT_TYPE_ROSPEC_EVENT, "ROSpec event" },
817 { LLRP_NOTIFICATION_EVENT_TYPE_REPORT_BUFFER_FILL_WARNING, "Report buffer fill warning" },
818 { LLRP_NOTIFICATION_EVENT_TYPE_READER_EXCEPTION_EVENT, "Reader exception event" },
819 { LLRP_NOTIFICATION_EVENT_TYPE_RFSURVEY_EVENT, "RFSurvey event" },
820 { LLRP_NOTIFICATION_EVENT_TYPE_AISPEC_EVENT, "AISpec event" },
821 { LLRP_NOTIFICATION_EVENT_TYPE_AISPEC_EVENT_WITH_DETAILS, "AISpec event with details" },
822 { LLRP_NOTIFICATION_EVENT_TYPE_ANTENNA_EVENT, "Antenna event" },
823 { LLRP_NOTIFICATION_EVENT_TYPE_SPEC_LOOP_EVENT, "SpecLoop event" },
824 { 0, NULL }
826 static value_string_ext event_type_ext = VALUE_STRING_EXT_INIT(event_type);
828 /* ROSpec event type */
829 #define LLRP_ROSPEC_EVENT_TYPE_START_OF_ROSPEC 0
830 #define LLRP_ROSPEC_EVENT_TYPE_END_OF_ROSPEC 1
831 #define LLRP_ROSPEC_EVENT_TYPE_PREEMPTION_OF_ROSPEC 2
833 static const value_string roevent_type[] = {
834 { LLRP_ROSPEC_EVENT_TYPE_START_OF_ROSPEC, "Start of ROSpec" },
835 { LLRP_ROSPEC_EVENT_TYPE_END_OF_ROSPEC, "End of ROSpec" },
836 { LLRP_ROSPEC_EVENT_TYPE_PREEMPTION_OF_ROSPEC, "Preemption of ROSpec" },
837 { 0, NULL }
840 /* ROSpec event type */
841 #define LLRP_RF_SURVEY_EVENT_TYPE_START_OF_SURVEY 0
842 #define LLRP_RF_SURVEY_EVENT_TYPE_END_OF_SURVEY 1
844 static const value_string rfevent_type[] = {
845 { LLRP_RF_SURVEY_EVENT_TYPE_START_OF_SURVEY, "Start of survey" },
846 { LLRP_RF_SURVEY_EVENT_TYPE_END_OF_SURVEY, "End of survey" },
847 { 0, NULL }
850 /* AISpec event type */
851 #define LLRP_AISPEC_EVENT_TYPE_END_OF_AISPEC 0
853 static const value_string aievent_type[] = {
854 { LLRP_AISPEC_EVENT_TYPE_END_OF_AISPEC, "End of AISpec" },
855 { 0, NULL }
858 /* Antenna event type */
859 #define LLRP_ANTENNA_EVENT_DISCONNECTED 0
860 #define LLRP_ANTENNA_EVENT_CONNECTED 1
862 static const value_string antenna_event_type[] = {
863 { LLRP_ANTENNA_EVENT_DISCONNECTED, "Antenna disconnected" },
864 { LLRP_ANTENNA_EVENT_CONNECTED, "Antenna connected" },
865 { 0, NULL }
868 /* Connection status */
869 #define LLRP_CONNECTION_SUCCESS 0
870 #define LLRP_CONNECTION_FAILED_READER_INITIATE_ALREADY_EXISTS 1
871 #define LLRP_CONNECTION_FAILED_CLIENT_INITIATE_ALREADY_EXISTS 2
872 #define LLRP_CONNECTION_FAILED_OTHER_REASON_THAN_ALREADY_EXISTS 3
873 #define LLRP_CONNECTION_ANOTHER_CONNECTION_ATTEMPTED 4
875 static const value_string connection_status[] = {
876 { LLRP_CONNECTION_SUCCESS, "Success" },
877 { LLRP_CONNECTION_FAILED_READER_INITIATE_ALREADY_EXISTS, "Failed a reader initiated connection already exists" },
878 { LLRP_CONNECTION_FAILED_CLIENT_INITIATE_ALREADY_EXISTS, "Failed a client initiated connection already exists" },
879 { LLRP_CONNECTION_FAILED_OTHER_REASON_THAN_ALREADY_EXISTS, "Failed reason other than a connection already exists" },
880 { LLRP_CONNECTION_ANOTHER_CONNECTION_ATTEMPTED, "Another connection attempted" },
881 { 0, NULL }
884 /* Status code */
885 #define LLRP_STATUS_CODE_M_SUCCESS 0
886 #define LLRP_STATUS_CODE_M_PARAMETERERROR 100
887 #define LLRP_STATUS_CODE_M_FIELDERROR 101
888 #define LLRP_STATUS_CODE_M_UNEXPECTEDPARAMETER 102
889 #define LLRP_STATUS_CODE_M_MISSINGPARAMETER 103
890 #define LLRP_STATUS_CODE_M_DUPLICATEPARAMETER 104
891 #define LLRP_STATUS_CODE_M_OVERFLOWPARAMETER 105
892 #define LLRP_STATUS_CODE_M_OVERFLOWFIELD 106
893 #define LLRP_STATUS_CODE_M_UNKNOWNPARAMETER 107
894 #define LLRP_STATUS_CODE_M_UNKNOWNFIELD 108
895 #define LLRP_STATUS_CODE_M_UNSUPPORTEDMESSAGE 109
896 #define LLRP_STATUS_CODE_M_UNSUPPORTEDVERSION 110
897 #define LLRP_STATUS_CODE_M_UNSUPPORTEDPARAMETER 111
898 #define LLRP_STATUS_CODE_P_PARAMETERERROR 200
899 #define LLRP_STATUS_CODE_P_FIELDERROR 201
900 #define LLRP_STATUS_CODE_P_UNEXPECTEDPARAMETER 202
901 #define LLRP_STATUS_CODE_P_MISSINGPARAMETER 203
902 #define LLRP_STATUS_CODE_P_DUPLICATEPARAMETER 204
903 #define LLRP_STATUS_CODE_P_OVERFLOWPARAMETER 205
904 #define LLRP_STATUS_CODE_P_OVERFLOWFIELD 206
905 #define LLRP_STATUS_CODE_P_UNKNOWNPARAMETER 207
906 #define LLRP_STATUS_CODE_P_UNKNOWNFIELD 208
907 #define LLRP_STATUS_CODE_P_UNSUPPORTEDPARAMETER 209
908 #define LLRP_STATUS_CODE_A_INVALID 300
909 #define LLRP_STATUS_CODE_A_OUTOFRANGE 301
910 #define LLRP_STATUS_CODE_R_DEVICEERROR 401
912 static const value_string status_code[] = {
913 { LLRP_STATUS_CODE_M_SUCCESS, "M_Success" },
914 { LLRP_STATUS_CODE_M_PARAMETERERROR, "M_ParameterError" },
915 { LLRP_STATUS_CODE_M_FIELDERROR, "M_FieldError" },
916 { LLRP_STATUS_CODE_M_UNEXPECTEDPARAMETER, "M_UnexpectedParameter" },
917 { LLRP_STATUS_CODE_M_MISSINGPARAMETER, "M_MissingParameter" },
918 { LLRP_STATUS_CODE_M_DUPLICATEPARAMETER, "M_DuplicateParameter" },
919 { LLRP_STATUS_CODE_M_OVERFLOWPARAMETER, "M_OverflowParameter" },
920 { LLRP_STATUS_CODE_M_OVERFLOWFIELD, "M_OverflowField" },
921 { LLRP_STATUS_CODE_M_UNKNOWNPARAMETER, "M_UnknownParameter" },
922 { LLRP_STATUS_CODE_M_UNKNOWNFIELD, "M_UnknownField" },
923 { LLRP_STATUS_CODE_M_UNSUPPORTEDMESSAGE, "M_UnsupportedMessage" },
924 { LLRP_STATUS_CODE_M_UNSUPPORTEDVERSION, "M_UnsupportedVersion" },
925 { LLRP_STATUS_CODE_M_UNSUPPORTEDPARAMETER,"M_UnsupportedParameter" },
926 { LLRP_STATUS_CODE_P_PARAMETERERROR, "P_ParameterError" },
927 { LLRP_STATUS_CODE_P_FIELDERROR, "P_FieldError" },
928 { LLRP_STATUS_CODE_P_UNEXPECTEDPARAMETER, "P_UnexpectedParameter" },
929 { LLRP_STATUS_CODE_P_MISSINGPARAMETER, "P_MissingParameter" },
930 { LLRP_STATUS_CODE_P_DUPLICATEPARAMETER, "P_DuplicateParameter" },
931 { LLRP_STATUS_CODE_P_OVERFLOWPARAMETER, "P_OverflowParameter" },
932 { LLRP_STATUS_CODE_P_OVERFLOWFIELD, "P_OverflowField" },
933 { LLRP_STATUS_CODE_P_UNKNOWNPARAMETER, "P_UnknownParameter" },
934 { LLRP_STATUS_CODE_P_UNKNOWNFIELD, "P_UnknownField" },
935 { LLRP_STATUS_CODE_P_UNSUPPORTEDPARAMETER,"P_UnsupportedParameter" },
936 { LLRP_STATUS_CODE_A_INVALID, "A_Invalid" },
937 { LLRP_STATUS_CODE_A_OUTOFRANGE, "A_OutOfRange" },
938 { LLRP_STATUS_CODE_R_DEVICEERROR, "R_DeviceError" },
939 { 0, NULL }
941 static value_string_ext status_code_ext = VALUE_STRING_EXT_INIT(status_code);
943 /* C1G2 tag inventory state aware singulation action */
944 static const true_false_string tfs_state_a_b = { "State B", "State A" };
945 static const true_false_string tfs_sl = { "~SL", "SL" };
946 static const true_false_string tfs_all_no = { "All", "No" };
948 /* Vendors */
949 #define LLRP_VENDOR_IMPINJ 25882
951 static const value_string llrp_vendors[] = {
952 { LLRP_VENDOR_IMPINJ, "Impinj" },
953 { 0, NULL }
956 /* Vendor subtypes */
958 /* Impinj custom message types */
959 #define LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS 21
960 #define LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS_RESPONSE 22
961 #define LLRP_IMPINJ_TYPE_SAVE_SETTINGS 23
962 #define LLRP_IMPINJ_TYPE_SAVE_SETTINGS_RESPONSE 24
964 static const value_string impinj_msg_subtype[] = {
965 { LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS, "Enable extensions" },
966 { LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS_RESPONSE, "Enable extensions response" },
967 { LLRP_IMPINJ_TYPE_SAVE_SETTINGS, "Save settings" },
968 { LLRP_IMPINJ_TYPE_SAVE_SETTINGS_RESPONSE, "Save setting response" },
969 { 0, NULL }
971 static value_string_ext impinj_msg_subtype_ext = VALUE_STRING_EXT_INIT(impinj_msg_subtype);
973 /* Impinj custom parameter types */
974 #define LLRP_IMPINJ_PARAM_REQUESTED_DATA 21
975 #define LLRP_IMPINJ_PARAM_SUBREGULATORY_REGION 22
976 #define LLRP_IMPINJ_PARAM_INVENTORY_SEARCH_MODE 23
977 #define LLRP_IMPINJ_PARAM_TAG_DIRECTION_REPORTING 24
978 #define LLRP_IMPINJ_PARAM_TAG_DIRECTION 25
979 #define LLRP_IMPINJ_PARAM_FIXED_FREQUENCY_LIST 26
980 #define LLRP_IMPINJ_PARAM_REDUCED_POWER_FREQUENCY_LIST 27
981 #define LLRP_IMPINJ_PARAM_LOW_DUTY_CYCLE 28
982 #define LLRP_IMPINJ_PARAM_DETAILED_VERSION 29
983 #define LLRP_IMPINJ_PARAM_FREQUENCY_CAPABILITIES 30
984 #define LLRP_IMPINJ_PARAM_TAG_INFORMATION 31
985 #define LLRP_IMPINJ_PARAM_FORKLIFT_CONFIGURATION 32
986 #define LLRP_IMPINJ_PARAM_FORKLIFT_HEIGHT_THRESHOLD 33
987 #define LLRP_IMPINJ_PARAM_FORKLIFT_ZEROMOTION_TIME_THRESHOLD 34
988 #define LLRP_IMPINJ_PARAM_FORKLIFT_COMPANION_BOARD_INFO 35
989 #define LLRP_IMPINJ_PARAM_GPI_DEBOUNCE_CONFIGURATION 36
990 #define LLRP_IMPINJ_PARAM_READER_TEMPERATURE 37
991 #define LLRP_IMPINJ_PARAM_LINK_MONITOR_CONFIGURATION 38
992 #define LLRP_IMPINJ_PARAM_REPORT_BUFFER_CONFIGURATION 39
993 #define LLRP_IMPINJ_PARAM_ACCESS_SPEC_CONFIGURATION 40
994 #define LLRP_IMPINJ_PARAM_BLOCK_WRITE_WORD_COUNT 41
995 #define LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK 42
996 #define LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK_OPSPEC_RESULT 43
997 #define LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS 44
998 #define LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS_OPSPEC_RESULT 45
999 #define LLRP_IMPINJ_PARAM_SET_QT_CONFIG 46
1000 #define LLRP_IMPINJ_PARAM_SET_QT_CONFIG_OPSPEC_RESULT 47
1001 #define LLRP_IMPINJ_PARAM_GET_QT_CONFIG 48
1002 #define LLRP_IMPINJ_PARAM_GET_QT_CONFIG_OPSPEC_RESULT 49
1003 #define LLRP_IMPINJ_PARAM_TAG_REPORT_CONTENT_SELECTOR 50
1004 #define LLRP_IMPINJ_PARAM_ENABLE_SERIALIZED_TID 51
1005 #define LLRP_IMPINJ_PARAM_ENABLE_RF_PHASE_ANGLE 52
1006 #define LLRP_IMPINJ_PARAM_ENABLE_PEAK_RSSI 53
1007 #define LLRP_IMPINJ_PARAM_ENABLE_GPS_COORDINATES 54
1008 #define LLRP_IMPINJ_PARAM_SERIALIZED_TID 55
1009 #define LLRP_IMPINJ_PARAM_RF_PHASE_ANGLE 56
1010 #define LLRP_IMPINJ_PARAM_PEAK_RSSI 57
1011 #define LLRP_IMPINJ_PARAM_GPS_COORDINATES 58
1012 #define LLRP_IMPINJ_PARAM_LOOP_SPEC 59
1013 #define LLRP_IMPINJ_PARAM_GPS_NMEA_SENTENCES 60
1014 #define LLRP_IMPINJ_PARAM_GGA_SENTENCE 61
1015 #define LLRP_IMPINJ_PARAM_RMC_SENTENCE 62
1016 #define LLRP_IMPINJ_PARAM_OPSPEC_RETRY_COUNT 63
1017 #define LLRP_IMPINJ_PARAM_ADVANCE_GPO_CONFIG 64
1018 #define LLRP_IMPINJ_PARAM_ENABLE_OPTIM_READ 65
1019 #define LLRP_IMPINJ_PARAM_ACCESS_SPEC_ORDERING 66
1020 #define LLRP_IMPINJ_PARAM_ENABLE_RF_DOPPLER_FREQ 67
1021 #define LLRP_IMPINJ_PARAM_ARRAY_VERSION 1520
1022 #define LLRP_IMPINJ_PARAM_HUB_VERSIONS 1537
1023 #define LLRP_IMPINJ_PARAM_HUB_CONFIGURATION 1538
1025 static const value_string impinj_param_type[] = {
1026 { LLRP_IMPINJ_PARAM_REQUESTED_DATA, "Requested Data" },
1027 { LLRP_IMPINJ_PARAM_SUBREGULATORY_REGION, "Sub regulatory region" },
1028 { LLRP_IMPINJ_PARAM_INVENTORY_SEARCH_MODE, "Inventory search mode" },
1029 { LLRP_IMPINJ_PARAM_TAG_DIRECTION_REPORTING, "Tag direction reporting" },
1030 { LLRP_IMPINJ_PARAM_TAG_DIRECTION, "Tag direction" },
1031 { LLRP_IMPINJ_PARAM_FIXED_FREQUENCY_LIST, "Fixed frequency list" },
1032 { LLRP_IMPINJ_PARAM_REDUCED_POWER_FREQUENCY_LIST, "Reduced power frequency list" },
1033 { LLRP_IMPINJ_PARAM_LOW_DUTY_CYCLE, "Low duty cycle" },
1034 { LLRP_IMPINJ_PARAM_DETAILED_VERSION, "Detailed version" },
1035 { LLRP_IMPINJ_PARAM_FREQUENCY_CAPABILITIES, "Frequency capabilities" },
1036 { LLRP_IMPINJ_PARAM_TAG_INFORMATION, "Tag information" },
1037 { LLRP_IMPINJ_PARAM_FORKLIFT_CONFIGURATION, "Forklift configuration" },
1038 { LLRP_IMPINJ_PARAM_FORKLIFT_HEIGHT_THRESHOLD, "Forklift height threshold" },
1039 { LLRP_IMPINJ_PARAM_FORKLIFT_ZEROMOTION_TIME_THRESHOLD, "Forklift zero motion time threshold" },
1040 { LLRP_IMPINJ_PARAM_FORKLIFT_COMPANION_BOARD_INFO, "Forklift companion board info" },
1041 { LLRP_IMPINJ_PARAM_GPI_DEBOUNCE_CONFIGURATION, "Gpi debounce configuration" },
1042 { LLRP_IMPINJ_PARAM_READER_TEMPERATURE, "Reader temperature" },
1043 { LLRP_IMPINJ_PARAM_LINK_MONITOR_CONFIGURATION, "Link monitor configuration" },
1044 { LLRP_IMPINJ_PARAM_REPORT_BUFFER_CONFIGURATION, "Report buffer configuration" },
1045 { LLRP_IMPINJ_PARAM_ACCESS_SPEC_CONFIGURATION, "Access spec configuration" },
1046 { LLRP_IMPINJ_PARAM_BLOCK_WRITE_WORD_COUNT, "Block write word count" },
1047 { LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK, "Block permalock" },
1048 { LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK_OPSPEC_RESULT, "Block permalock OpSpec result" },
1049 { LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS, "Get block permalock status" },
1050 { LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS_OPSPEC_RESULT,"Get block permalock status OpSpec result" },
1051 { LLRP_IMPINJ_PARAM_SET_QT_CONFIG, "Set QT config" },
1052 { LLRP_IMPINJ_PARAM_SET_QT_CONFIG_OPSPEC_RESULT, "Set QT config OpSpec result" },
1053 { LLRP_IMPINJ_PARAM_GET_QT_CONFIG, "Get QT config" },
1054 { LLRP_IMPINJ_PARAM_GET_QT_CONFIG_OPSPEC_RESULT, "Get QT config OpSpec result" },
1055 { LLRP_IMPINJ_PARAM_TAG_REPORT_CONTENT_SELECTOR, "Tag report content selector" },
1056 { LLRP_IMPINJ_PARAM_ENABLE_SERIALIZED_TID, "Enable serialized TID" },
1057 { LLRP_IMPINJ_PARAM_ENABLE_RF_PHASE_ANGLE, "Enable RF phase angle" },
1058 { LLRP_IMPINJ_PARAM_ENABLE_PEAK_RSSI, "Enable peak RSSI" },
1059 { LLRP_IMPINJ_PARAM_ENABLE_GPS_COORDINATES, "Enable GPS coordinates" },
1060 { LLRP_IMPINJ_PARAM_SERIALIZED_TID, "Serialized TID" },
1061 { LLRP_IMPINJ_PARAM_RF_PHASE_ANGLE, "RF phase angle" },
1062 { LLRP_IMPINJ_PARAM_PEAK_RSSI, "Peak RSSI" },
1063 { LLRP_IMPINJ_PARAM_GPS_COORDINATES, "GPS coordinates" },
1064 { LLRP_IMPINJ_PARAM_LOOP_SPEC, "LoopSpec" },
1065 { LLRP_IMPINJ_PARAM_GPS_NMEA_SENTENCES, "GPS NMEA sentences" },
1066 { LLRP_IMPINJ_PARAM_GGA_SENTENCE, "GGA sentence" },
1067 { LLRP_IMPINJ_PARAM_RMC_SENTENCE, "RMC sentence" },
1068 { LLRP_IMPINJ_PARAM_OPSPEC_RETRY_COUNT, "OpSpec retry count" },
1069 { LLRP_IMPINJ_PARAM_ADVANCE_GPO_CONFIG, "Advanced GPO configuration" },
1070 { LLRP_IMPINJ_PARAM_ENABLE_OPTIM_READ, "Enable optimized read" },
1071 { LLRP_IMPINJ_PARAM_ACCESS_SPEC_ORDERING, "AccessSpec ordering" },
1072 { LLRP_IMPINJ_PARAM_ENABLE_RF_DOPPLER_FREQ, "Enable RF doppler frequency" },
1073 { LLRP_IMPINJ_PARAM_ARRAY_VERSION, "Array specific HW and version info" },
1074 { LLRP_IMPINJ_PARAM_HUB_VERSIONS, "Hub specific HW and version info" },
1075 { LLRP_IMPINJ_PARAM_HUB_CONFIGURATION, "Hub connection and fault state" },
1076 { 0, NULL }
1078 static value_string_ext impinj_param_type_ext = VALUE_STRING_EXT_INIT(impinj_param_type);
1080 /* Impinj requested data */
1081 #define LLRP_IMPINJ_REQ_DATA_ALL_CAPABILITIES 1000
1082 #define LLRP_IMPINJ_REQ_DATA_DETAILED_VERSION 1001
1083 #define LLRP_IMPINJ_REQ_DATA_FREQUENCY_CAPABILITIES 1002
1084 #define LLRP_IMPINJ_REQ_DATA_CONFIGURATION 2000
1085 #define LLRP_IMPINJ_REQ_DATA_SUB_REGULATORY_REGION 2001
1086 #define LLRP_IMPINJ_REQ_DATA_FORKLIFT_CONFIGURATION 2002
1087 #define LLRP_IMPINJ_REQ_DATA_GPI_DEBOUNCE_CONFIGURATION 2003
1088 #define LLRP_IMPINJ_REQ_DATA_READER_TEMPERATURE 2004
1089 #define LLRP_IMPINJ_REQ_DATA_LINK_MONITOR_CONFIGURATION 2005
1090 #define LLRP_IMPINJ_REQ_DATA_REPORT_BUFFER_CONFIGURATION 2006
1091 #define LLRP_IMPINJ_REQ_DATA_ACCESS_SPEC_CONFIGURATION 2007
1092 #define LLRP_IMPINJ_REQ_DATA_GPS_NMEA_SENTENCES 2008
1095 static const value_string impinj_req_data[] = {
1096 { LLRP_IMPINJ_REQ_DATA_ALL_CAPABILITIES, "All capabilities" },
1097 { LLRP_IMPINJ_REQ_DATA_DETAILED_VERSION, "Detailed version" },
1098 { LLRP_IMPINJ_REQ_DATA_FREQUENCY_CAPABILITIES, "Frequency capabilities" },
1099 { LLRP_IMPINJ_REQ_DATA_CONFIGURATION, "Configuration" },
1100 { LLRP_IMPINJ_REQ_DATA_SUB_REGULATORY_REGION, "Sub regulatory region" },
1101 { LLRP_IMPINJ_REQ_DATA_FORKLIFT_CONFIGURATION, "Forklift configuration" },
1102 { LLRP_IMPINJ_REQ_DATA_GPI_DEBOUNCE_CONFIGURATION, "GPI debounce configuration" },
1103 { LLRP_IMPINJ_REQ_DATA_READER_TEMPERATURE, "Reader temperature" },
1104 { LLRP_IMPINJ_REQ_DATA_LINK_MONITOR_CONFIGURATION, "Link monitor configuration" },
1105 { LLRP_IMPINJ_REQ_DATA_REPORT_BUFFER_CONFIGURATION, "Report buffer configuration" },
1106 { LLRP_IMPINJ_REQ_DATA_ACCESS_SPEC_CONFIGURATION, "Access spec configuration" },
1107 { LLRP_IMPINJ_REQ_DATA_GPS_NMEA_SENTENCES, "GPS NMEA sentences" },
1108 { 0, NULL }
1110 static value_string_ext impinj_req_data_ext = VALUE_STRING_EXT_INIT(impinj_req_data);
1112 /* Impinj regulatory region */
1113 #define LLRP_IMPINJ_REG_REGION_FCC_PART_15_247 0
1114 #define LLRP_IMPINJ_REG_REGION_ETSI_EN_300_220 1
1115 #define LLRP_IMPINJ_REG_REGION_ETSI_EN_302_208_WITH_LBT 2
1116 #define LLRP_IMPINJ_REG_REGION_HONG_KONG_920_925_MHZ 3
1117 #define LLRP_IMPINJ_REG_REGION_TAIWAN_922_928_MHZ 4
1118 #define LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ 5
1119 #define LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ_LOW_POWER 6
1120 #define LLRP_IMPINJ_REG_REGION_ETSI_EN_302_208_V1_2_1 7
1121 #define LLRP_IMPINJ_REG_REGION_KOREA_910_914_MHZ 8
1122 #define LLRP_IMPINJ_REG_REGION_MALAYSIA_919_923_MHZ 9
1123 #define LLRP_IMPINJ_REG_REGION_CHINA_920_925_MHZ 10
1124 #define LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ_WITHOUT_LBT 11
1125 #define LLRP_IMPINJ_REG_REGION_SOUTH_AFRICA_915_919_MHZ 12
1126 #define LLRP_IMPINJ_REG_REGION_BRAZIL_902_907_AND_915_928_MHZ 13
1127 #define LLRP_IMPINJ_REG_REGION_THAILAND_920_925_MHZ 14
1128 #define LLRP_IMPINJ_REG_REGION_SINGAPORE_920_925_MHZ 15
1129 #define LLRP_IMPINJ_REG_REGION_AUSTRALIA_920_926_MHZ 16
1130 #define LLRP_IMPINJ_REG_REGION_INDIA_865_867_MHZ 17
1131 #define LLRP_IMPINJ_REG_REGION_URUGUAY_916_928_MHZ 18
1132 #define LLRP_IMPINJ_REG_REGION_VIETNAM_920_925_MHZ 19
1133 #define LLRP_IMPINJ_REG_REGION_ISRAEL_915_917_MHZ 20
1135 static const value_string impinj_reg_region[] = {
1136 { LLRP_IMPINJ_REG_REGION_FCC_PART_15_247, "Fcc part 15 247" },
1137 { LLRP_IMPINJ_REG_REGION_ETSI_EN_300_220, "ETSI EN 300 220" },
1138 { LLRP_IMPINJ_REG_REGION_ETSI_EN_302_208_WITH_LBT, "ETSI EN 302 208 with LBT" },
1139 { LLRP_IMPINJ_REG_REGION_HONG_KONG_920_925_MHZ, "Hong kong 920-925 MHz" },
1140 { LLRP_IMPINJ_REG_REGION_TAIWAN_922_928_MHZ, "Taiwan 922-928 MHz" },
1141 { LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ, "Japan 952-954 MHz" },
1142 { LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ_LOW_POWER, "Japan 952-954 MHz low power" },
1143 { LLRP_IMPINJ_REG_REGION_ETSI_EN_302_208_V1_2_1, "ETSI EN 302 208 v1.2.1" },
1144 { LLRP_IMPINJ_REG_REGION_KOREA_910_914_MHZ, "Korea 910-914 MHz" },
1145 { LLRP_IMPINJ_REG_REGION_MALAYSIA_919_923_MHZ, "Malaysia 919-923 MHz" },
1146 { LLRP_IMPINJ_REG_REGION_CHINA_920_925_MHZ, "China 920-925 MHz" },
1147 { LLRP_IMPINJ_REG_REGION_JAPAN_952_954_MHZ_WITHOUT_LBT, "Japan 952-954 MHz without LBT" },
1148 { LLRP_IMPINJ_REG_REGION_SOUTH_AFRICA_915_919_MHZ, "South africa 915-919 MHz" },
1149 { LLRP_IMPINJ_REG_REGION_BRAZIL_902_907_AND_915_928_MHZ, "Brazil 902-907 and 915-928 MHz" },
1150 { LLRP_IMPINJ_REG_REGION_THAILAND_920_925_MHZ, "Thailand 920-925 MHz" },
1151 { LLRP_IMPINJ_REG_REGION_SINGAPORE_920_925_MHZ, "Singapore 920-925 MHz" },
1152 { LLRP_IMPINJ_REG_REGION_AUSTRALIA_920_926_MHZ, "Australia 920-926 MHz" },
1153 { LLRP_IMPINJ_REG_REGION_INDIA_865_867_MHZ, "India 865-867 MHz" },
1154 { LLRP_IMPINJ_REG_REGION_URUGUAY_916_928_MHZ, "Uruguay 916-928 MHz" },
1155 { LLRP_IMPINJ_REG_REGION_VIETNAM_920_925_MHZ, "Vietnam 920-925 MHz" },
1156 { LLRP_IMPINJ_REG_REGION_ISRAEL_915_917_MHZ, "Israel 915-917 MHz" },
1157 { 0, NULL }
1159 static value_string_ext impinj_reg_region_ext = VALUE_STRING_EXT_INIT(impinj_reg_region);
1161 /* Impinj inventory search type */
1162 #define LLRP_IMPINJ_SEARCH_TYPE_READER_SELECTED 0
1163 #define LLRP_IMPINJ_SEARCH_TYPE_SINGLE_TARGET 1
1164 #define LLRP_IMPINJ_SEARCH_TYPE_DUAL_TARGET 2
1165 #define LLRP_IMPINJ_SEARCH_TYPE_SINGLE_TARGET_WITH_SUPP 3
1167 static const value_string impinj_search_mode[] = {
1168 { LLRP_IMPINJ_SEARCH_TYPE_READER_SELECTED, "Reader selected" },
1169 { LLRP_IMPINJ_SEARCH_TYPE_SINGLE_TARGET, "Single target" },
1170 { LLRP_IMPINJ_SEARCH_TYPE_DUAL_TARGET, "Dual target" },
1171 { LLRP_IMPINJ_SEARCH_TYPE_SINGLE_TARGET_WITH_SUPP, "Single target with suppression" },
1172 { 0, NULL }
1175 /* Impinj antenna configuration */
1176 #define LLRP_IMPINJ_ANT_CONF_DUAL 1
1177 #define LLRP_IMPINJ_ANT_CONF_QUAD 2
1179 static const value_string impinj_ant_conf[] = {
1180 { LLRP_IMPINJ_ANT_CONF_DUAL, "Dual antenna" },
1181 { LLRP_IMPINJ_ANT_CONF_QUAD, "Quad antenna" },
1182 { 0, NULL }
1185 /* Impinj tag direction */
1186 #define LLRP_IMPINJ_TAG_DIR_INDETERMINED 0
1187 #define LLRP_IMPINJ_TAG_DIR_FROM_2_TO_1 1
1188 #define LLRP_IMPINJ_TAG_DIR_FROM_1_TO_2 2
1190 static const value_string impinj_tag_dir[] = {
1191 { LLRP_IMPINJ_TAG_DIR_INDETERMINED, "Indeterminate" },
1192 { LLRP_IMPINJ_TAG_DIR_FROM_2_TO_1, "From side2 to side1" },
1193 { LLRP_IMPINJ_TAG_DIR_FROM_1_TO_2, "From side1 to side2" },
1194 { 0, NULL }
1197 /* Impinj fixed frequency mode */
1198 #define LLRP_IMPINJ_FIX_FREQ_MODE_DISABLED 0
1199 #define LLRP_IMPINJ_FIX_FREQ_MODE_AUTO_SELECT 1
1200 #define LLRP_IMPINJ_FIX_FREQ_MODE_CHANNEL_LIST 2
1202 static const value_string impinj_fix_freq_mode[] = {
1203 { LLRP_IMPINJ_FIX_FREQ_MODE_DISABLED, "Disabled" },
1204 { LLRP_IMPINJ_FIX_FREQ_MODE_AUTO_SELECT, "Auto select" },
1205 { LLRP_IMPINJ_FIX_FREQ_MODE_CHANNEL_LIST, "Channel list" },
1206 { 0, NULL }
1209 /* Impinj enabled/disabled */
1210 #define LLRP_IMPINJ_BOOLEAN_DISABLED 0
1211 #define LLRP_IMPINJ_BOOLEAN_ENABLED 1
1213 static const value_string impinj_boolean[] = {
1214 { LLRP_IMPINJ_BOOLEAN_DISABLED, "Disabled" },
1215 { LLRP_IMPINJ_BOOLEAN_ENABLED, "Enabled" },
1216 { 0, NULL }
1219 /* Impinj report buffer mode */
1220 #define LLRP_IMPINJ_REPORT_BUFF_MODE_NORMAL 0
1221 #define LLRP_IMPINJ_REPORT_BUFF_MODE_LOW_LATENCY 1
1223 static const value_string impinj_report_buff_mode[] = {
1224 { LLRP_IMPINJ_REPORT_BUFF_MODE_NORMAL, "Normal" },
1225 { LLRP_IMPINJ_REPORT_BUFF_MODE_LOW_LATENCY, "Low latency" },
1226 { 0, NULL }
1229 /* Impinj permalock operation result */
1230 #define LLRP_IMPINJ_PERMALOCK_SUCCESS 0
1231 #define LLRP_IMPINJ_PERMALOCK_INSUFFICIENT_POWER 1
1232 #define LLRP_IMPINJ_PERMALOCK_NONSPECIFIC_TAG_ERROR 2
1233 #define LLRP_IMPINJ_PERMALOCK_NO_RESPONSE_FROM_TAG 3
1234 #define LLRP_IMPINJ_PERMALOCK_NONSPECIFIC_READER_ERROR 4
1235 #define LLRP_IMPINJ_PERMALOCK_INCORRECT_PASSWORD_ERROR 5
1236 #define LLRP_IMPINJ_PERMALOCK_TAG_MEMORY_OVERRUN_ERROR 6
1238 static const value_string impinj_permalock_result[] = {
1239 { LLRP_IMPINJ_PERMALOCK_SUCCESS, "Success" },
1240 { LLRP_IMPINJ_PERMALOCK_INSUFFICIENT_POWER, "Insufficient power" },
1241 { LLRP_IMPINJ_PERMALOCK_NONSPECIFIC_TAG_ERROR, "Nonspecific tag error" },
1242 { LLRP_IMPINJ_PERMALOCK_NO_RESPONSE_FROM_TAG, "No response from tag" },
1243 { LLRP_IMPINJ_PERMALOCK_NONSPECIFIC_READER_ERROR, "Nonspecific reader error" },
1244 { LLRP_IMPINJ_PERMALOCK_INCORRECT_PASSWORD_ERROR, "Incorrect password error" },
1245 { LLRP_IMPINJ_PERMALOCK_TAG_MEMORY_OVERRUN_ERROR, "Tag memory overrun error" },
1246 { 0, NULL }
1248 static value_string_ext impinj_permalock_result_ext = VALUE_STRING_EXT_INIT(impinj_permalock_result);
1250 /* Impinj get block permalock operation result */
1251 #define LLRP_IMPINJ_BLOCK_PERMALOCK_SUCCESS 0
1252 #define LLRP_IMPINJ_BLOCK_PERMALOCK_NONSPECIFIC_TAG_ERROR 1
1253 #define LLRP_IMPINJ_BLOCK_PERMALOCK_NO_RESPONSE_FROM_TAG 2
1254 #define LLRP_IMPINJ_BLOCK_PERMALOCK_NONSPECIFIC_READER_ERROR 3
1255 #define LLRP_IMPINJ_BLOCK_PERMALOCK_INCORRECT_PASSWORD_ERROR 4
1256 #define LLRP_IMPINJ_BLOCK_PERMALOCK_TAG_MEMORY_OVERRUN_ERROR 5
1258 static const value_string impinj_block_permalock_result[] = {
1259 { LLRP_IMPINJ_BLOCK_PERMALOCK_SUCCESS, "Success" },
1260 { LLRP_IMPINJ_BLOCK_PERMALOCK_NONSPECIFIC_TAG_ERROR, "Nonspecific tag error" },
1261 { LLRP_IMPINJ_BLOCK_PERMALOCK_NO_RESPONSE_FROM_TAG, "No response from tag" },
1262 { LLRP_IMPINJ_BLOCK_PERMALOCK_NONSPECIFIC_READER_ERROR, "Nonspecific reader error" },
1263 { LLRP_IMPINJ_BLOCK_PERMALOCK_INCORRECT_PASSWORD_ERROR, "Incorrect password error" },
1264 { LLRP_IMPINJ_BLOCK_PERMALOCK_TAG_MEMORY_OVERRUN_ERROR, "Tag memory overrun error" },
1265 { 0, NULL }
1267 static value_string_ext impinj_block_permalock_result_ext = VALUE_STRING_EXT_INIT(impinj_block_permalock_result);
1269 /* Impinj data profile parameter */
1270 #define LLRP_IMPINJ_DATA_PROFILE_UNKNOWN 0
1271 #define LLRP_IMPINJ_DATA_PROFILE_PRIVATE 1
1272 #define LLRP_IMPINJ_DATA_PROFILE_PUBLIC 2
1274 static const value_string impinj_data_profile[] = {
1275 { LLRP_IMPINJ_DATA_PROFILE_UNKNOWN, "Unknown" },
1276 { LLRP_IMPINJ_DATA_PROFILE_PRIVATE, "Private" },
1277 { LLRP_IMPINJ_DATA_PROFILE_PUBLIC, "Public" },
1278 { 0, NULL }
1281 /* Impinj access range parameter */
1282 #define LLRP_IMPINJ_ACCESS_RANGE_UNKNOWN 0
1283 #define LLRP_IMPINJ_ACCESS_RANGE_NORMAL_RANGE 1
1284 #define LLRP_IMPINJ_ACCESS_RANGE_SHORT_RANGE 2
1286 static const value_string impinj_access_range[] = {
1287 { LLRP_IMPINJ_ACCESS_RANGE_UNKNOWN, "Unknown" },
1288 { LLRP_IMPINJ_ACCESS_RANGE_NORMAL_RANGE, "Normal range" },
1289 { LLRP_IMPINJ_ACCESS_RANGE_SHORT_RANGE, "Short range" },
1290 { 0, NULL }
1293 /* Impinj persistence parameter */
1294 #define LLRP_IMPINJ_PERSISTENCE_UNKNOWN 0
1295 #define LLRP_IMPINJ_PERSISTENCE_TEMPORARY 1
1296 #define LLRP_IMPINJ_PERSISTENCE_PERMANENT 2
1298 static const value_string impinj_persistence[] = {
1299 { LLRP_IMPINJ_PERSISTENCE_UNKNOWN, "Unknown" },
1300 { LLRP_IMPINJ_PERSISTENCE_TEMPORARY, "Temporary" },
1301 { LLRP_IMPINJ_PERSISTENCE_PERMANENT, "Permanent" },
1302 { 0, NULL }
1305 /* Impinj set QT config result */
1306 #define LLRP_IMPINJ_SET_QT_CONFIG_SUCCESS 0
1307 #define LLRP_IMPINJ_SET_QT_CONFIG_INSUFFICIENT_POWER 1
1308 #define LLRP_IMPINJ_SET_QT_CONFIG_NONSPECIFIC_TAG_ERROR 2
1309 #define LLRP_IMPINJ_SET_QT_CONFIG_NO_RESPONSE_FROM_TAG 3
1310 #define LLRP_IMPINJ_SET_QT_CONFIG_NONSPECIFIC_READER_ERROR 4
1311 #define LLRP_IMPINJ_SET_QT_CONFIG_INCORRECT_PASSWORD_ERROR 5
1313 static const value_string impinj_set_qt_config_result[] = {
1314 { LLRP_IMPINJ_SET_QT_CONFIG_SUCCESS, "Success" },
1315 { LLRP_IMPINJ_SET_QT_CONFIG_INSUFFICIENT_POWER, "Insufficient power" },
1316 { LLRP_IMPINJ_SET_QT_CONFIG_NONSPECIFIC_TAG_ERROR, "Nonspecific tag error" },
1317 { LLRP_IMPINJ_SET_QT_CONFIG_NO_RESPONSE_FROM_TAG, "No response from tag" },
1318 { LLRP_IMPINJ_SET_QT_CONFIG_NONSPECIFIC_READER_ERROR, "Nonspecific reader error" },
1319 { LLRP_IMPINJ_SET_QT_CONFIG_INCORRECT_PASSWORD_ERROR, "Incorrect password error" },
1320 { 0, NULL }
1322 static value_string_ext impinj_set_qt_config_result_ext = VALUE_STRING_EXT_INIT(impinj_set_qt_config_result);
1324 /* Impinj get QT config result */
1325 #define LLRP_IMPINJ_GET_QT_CONFIG_SUCCESS 0
1326 #define LLRP_IMPINJ_GET_QT_CONFIG_NONSPECIFIC_TAG_ERROR 1
1327 #define LLRP_IMPINJ_GET_QT_CONFIG_NO_RESPONSE_FROM_TAG 2
1328 #define LLRP_IMPINJ_GET_QT_CONFIG_NONSPECIFIC_READER_ERROR 3
1329 #define LLRP_IMPINJ_GET_QT_CONFIG_INCORRECT_PASSWORD_ERROR 4
1331 static const value_string impinj_get_qt_config_result[] = {
1332 { LLRP_IMPINJ_GET_QT_CONFIG_SUCCESS, "Success" },
1333 { LLRP_IMPINJ_GET_QT_CONFIG_NONSPECIFIC_TAG_ERROR, "Nonspecific tag error" },
1334 { LLRP_IMPINJ_GET_QT_CONFIG_NO_RESPONSE_FROM_TAG, "No response from tag" },
1335 { LLRP_IMPINJ_GET_QT_CONFIG_NONSPECIFIC_READER_ERROR, "Nonspecific reader error" },
1336 { LLRP_IMPINJ_GET_QT_CONFIG_INCORRECT_PASSWORD_ERROR, "Incorrect password error" },
1337 { 0, NULL }
1339 static value_string_ext impinj_get_qt_config_result_ext = VALUE_STRING_EXT_INIT(impinj_get_qt_config_result);
1341 /* Impinj access spec ordering */
1342 #define LLRP_IMPINJ_ACCESS_SPEC_ORDERING_FIFO 0
1343 #define LLRP_IMPINJ_ACCESS_SPEC_ORDERING_ASCENDING 1
1345 static const value_string impinj_access_spec_ordering[] = {
1346 { LLRP_IMPINJ_ACCESS_SPEC_ORDERING_FIFO, "FIFO" },
1347 { LLRP_IMPINJ_ACCESS_SPEC_ORDERING_ASCENDING, "Ascending" },
1348 { 0, NULL }
1351 /* Impinj GPO mode */
1352 #define LLRP_IMPINJ_GPO_MODE_NORMAL 0
1353 #define LLRP_IMPINJ_GPO_MODE_PULSED 1
1354 #define LLRP_IMPINJ_GPO_MODE_READER_OPERATIONAL_STATUS 2
1355 #define LLRP_IMPINJ_GPO_MODE_LLRP_CONNECTION_STATUS 3
1356 #define LLRP_IMPINJ_GPO_MODE_READER_INVENTORY_STATUS 4
1357 #define LLRP_IMPINJ_GPO_MODE_NETWORK_CONNECTION_STATUS 5
1358 #define LLRP_IMPINJ_GPO_MODE_READER_INVENTORY_TAGS_STATUS 6
1360 static const value_string impinj_gpo_mode[] = {
1361 { LLRP_IMPINJ_GPO_MODE_NORMAL, "Normal" },
1362 { LLRP_IMPINJ_GPO_MODE_PULSED, "Pulsed" },
1363 { LLRP_IMPINJ_GPO_MODE_READER_OPERATIONAL_STATUS, "Reader operational status" },
1364 { LLRP_IMPINJ_GPO_MODE_LLRP_CONNECTION_STATUS, "LLRP connection status" },
1365 { LLRP_IMPINJ_GPO_MODE_READER_INVENTORY_STATUS, "Reader inventory status" },
1366 { LLRP_IMPINJ_GPO_MODE_NETWORK_CONNECTION_STATUS, "Network connection status" },
1367 { LLRP_IMPINJ_GPO_MODE_READER_INVENTORY_TAGS_STATUS, "Reader inventory tags status" },
1368 { 0, NULL }
1370 static value_string_ext impinj_gpo_mode_ext = VALUE_STRING_EXT_INIT(impinj_gpo_mode);
1372 /* Impinj Hub connected type */
1373 #define LLRP_IMPINJ_HUB_CTYPE_UNKNOWN 0
1374 #define LLRP_IMPINJ_HUB_CTYPE_DISCONNECTED 1
1375 #define LLRP_IMPINJ_HUB_CTYPE_CONNECTED 2
1377 static const value_string impinj_hub_connected_type[] = {
1378 { LLRP_IMPINJ_HUB_CTYPE_UNKNOWN, "Unknown" },
1379 { LLRP_IMPINJ_HUB_CTYPE_DISCONNECTED, "Disconnected" },
1380 { LLRP_IMPINJ_HUB_CTYPE_CONNECTED, "Connected" },
1381 { 0, NULL }
1383 static value_string_ext impinj_hub_connected_type_ext = VALUE_STRING_EXT_INIT(impinj_hub_connected_type);
1385 /* Impinj Hub fault type */
1386 #define LLRP_IMPINJ_HUB_FTYPE_NO_FAULT 0
1387 #define LLRP_IMPINJ_HUB_FTYPE_RFPOWER 1
1388 #define LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB1 2
1389 #define LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB2 3
1390 #define LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB3 4
1391 #define LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB4 5
1392 #define LLRP_IMPINJ_HUB_FTYPE_NO_INIT 6
1393 #define LLRP_IMPINJ_HUB_FTYPE_SERIAL_OVERFLOW 7
1394 #define LLRP_IMPINJ_HUB_FTYPE_DISCONNECTED 8
1396 static const value_string impinj_hub_fault_type[] = {
1397 { LLRP_IMPINJ_HUB_FTYPE_NO_FAULT, "No fault" },
1398 { LLRP_IMPINJ_HUB_FTYPE_RFPOWER, "RF power" },
1399 { LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB1, "RF power on hub 1" },
1400 { LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB2, "RF power on hub 2" },
1401 { LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB3, "RF power on hub 3" },
1402 { LLRP_IMPINJ_HUB_FTYPE_RFPOWER_HUB4, "RF power on hub 4" },
1403 { LLRP_IMPINJ_HUB_FTYPE_NO_INIT, "No init" },
1404 { LLRP_IMPINJ_HUB_FTYPE_SERIAL_OVERFLOW, "Serial overflow" },
1405 { LLRP_IMPINJ_HUB_FTYPE_DISCONNECTED, "Disconnected" },
1406 { 0, NULL },
1408 static value_string_ext impinj_hub_fault_type_ext = VALUE_STRING_EXT_INIT(impinj_hub_fault_type);
1410 /* Misc */
1411 #define LLRP_ROSPEC_ALL 0
1412 #define LLRP_ANTENNA_ALL 0
1413 #define LLRP_GPI_PORT_ALL 0
1414 #define LLRP_GPO_PORT_ALL 0
1415 #define LLRP_ACCESSSPEC_ALL 0
1416 #define LLRP_TLV_LEN_MIN 4
1417 #define LLRP_HEADER_LENGTH 10
1418 #define LLRP_NO_LIMIT 0
1420 static const value_string unique_no_limit[] = {
1421 { LLRP_NO_LIMIT, "No Limit" },
1422 { 0, NULL },
1425 static const value_string unique_all_rospecs[] = {
1426 { LLRP_ROSPEC_ALL, "All ROSpecs" },
1427 { 0, NULL },
1430 static const value_string unique_all_access_specs[] = {
1431 { LLRP_ACCESSSPEC_ALL, "All Access Specs" },
1432 { 0, NULL },
1435 static const value_string unique_all_antenna[] = {
1436 { LLRP_ANTENNA_ALL, "All Antenna" },
1437 { 0, NULL },
1440 static const value_string unique_all_gpi_ports[] = {
1441 { LLRP_GPI_PORT_ALL, "All GPI Ports" },
1442 { 0, NULL },
1445 static const value_string unique_all_gpo_ports[] = {
1446 { LLRP_GPO_PORT_ALL, "All GPO Ports" },
1447 { 0, NULL },
1451 static unsigned
1452 dissect_llrp_parameters(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
1453 unsigned offset, const unsigned end, const unsigned depth);
1455 static unsigned dissect_llrp_utf8_parameter(tvbuff_t * const tvb, packet_info *pinfo,
1456 proto_tree * const tree, const unsigned hfindex, const unsigned offset)
1458 int len;
1460 len = tvb_get_ntohs(tvb, offset);
1461 if(tvb_reported_length_remaining(tvb, offset) < len) {
1462 expert_add_info_format(pinfo, tree, &ei_llrp_invalid_length,
1463 "invalid length of string: claimed %u, available %u.",
1464 len, tvb_reported_length_remaining(tvb, offset));
1465 return offset + 2;
1467 proto_tree_add_item(tree, hfindex, tvb,
1468 offset, 2, ENC_BIG_ENDIAN | ENC_UTF_8);
1470 return offset + len + 2;
1473 static unsigned dissect_llrp_bit_field(tvbuff_t * const tvb,
1474 proto_tree * const tree, const unsigned hfindex, const unsigned offset)
1476 unsigned len;
1478 len = tvb_get_ntohs(tvb, offset);
1479 len = (len + 7) / 8;
1480 proto_tree_add_item(tree, hf_llrp_length_bits, tvb,
1481 offset, 2, ENC_BIG_ENDIAN);
1482 proto_tree_add_item(tree, hfindex, tvb,
1483 offset + 2, len, ENC_NA);
1484 return offset + len + 2;
1487 static unsigned dissect_llrp_word_array(tvbuff_t * const tvb,
1488 proto_tree * const tree, const unsigned hfindex, const unsigned offset)
1490 unsigned len;
1492 len = tvb_get_ntohs(tvb, offset);
1493 len *= 2;
1494 proto_tree_add_item(tree, hf_llrp_length_words, tvb,
1495 offset, 2, ENC_BIG_ENDIAN);
1496 proto_tree_add_item(tree, hfindex, tvb,
1497 offset + 2, len, ENC_NA);
1498 return offset + len + 2;
1501 static unsigned dissect_llrp_item_array(tvbuff_t * const tvb, packet_info *pinfo,
1502 proto_tree * const tree, const unsigned hfindex_number,
1503 const unsigned hfindex_item, const unsigned item_size, unsigned offset)
1505 unsigned num;
1507 num = tvb_get_ntohs(tvb, offset);
1508 proto_tree_add_item(tree, hfindex_number, tvb,
1509 offset, 2, ENC_BIG_ENDIAN);
1510 offset += 2;
1511 if(tvb_reported_length_remaining(tvb, offset) < ((int)(num*item_size))) {
1512 expert_add_info_format(pinfo, tree, &ei_llrp_invalid_length,
1513 "Array longer than message");
1514 return offset + tvb_reported_length_remaining(tvb, offset);
1516 while(num--) {
1517 proto_tree_add_item(tree, hfindex_item, tvb,
1518 offset, item_size, ENC_BIG_ENDIAN);
1519 offset += item_size;
1521 return offset;
1524 static unsigned
1525 // NOLINTNEXTLINE(misc-no-recursion)
1526 dissect_llrp_impinj_parameter(tvbuff_t *tvb, packet_info *pinfo, proto_tree *param_tree,
1527 unsigned suboffset, const unsigned param_end)
1529 uint32_t subtype;
1531 subtype = tvb_get_ntohl(tvb, suboffset);
1532 proto_item_append_text(param_tree, " (Impinj - %s)",
1533 val_to_str_ext(subtype, &impinj_param_type_ext, "Unknown Type: %d"));
1534 proto_tree_add_item(param_tree, hf_llrp_impinj_param_type, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1535 suboffset += 4;
1537 switch(subtype) {
1538 case LLRP_IMPINJ_PARAM_TAG_INFORMATION:
1539 case LLRP_IMPINJ_PARAM_FORKLIFT_CONFIGURATION:
1540 case LLRP_IMPINJ_PARAM_ACCESS_SPEC_CONFIGURATION:
1541 case LLRP_IMPINJ_PARAM_TAG_REPORT_CONTENT_SELECTOR:
1542 case LLRP_IMPINJ_PARAM_GPS_NMEA_SENTENCES:
1543 case LLRP_IMPINJ_PARAM_HUB_VERSIONS:
1544 /* Just parameters */
1545 break;
1546 case LLRP_IMPINJ_PARAM_REQUESTED_DATA:
1547 proto_tree_add_item(param_tree, hf_llrp_impinj_req_data, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1548 suboffset += 4;
1549 break;
1550 case LLRP_IMPINJ_PARAM_SUBREGULATORY_REGION:
1551 proto_tree_add_item(param_tree, hf_llrp_impinj_reg_region, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1552 suboffset += 2;
1553 break;
1554 case LLRP_IMPINJ_PARAM_INVENTORY_SEARCH_MODE:
1555 proto_tree_add_item(param_tree, hf_llrp_impinj_search_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1556 suboffset += 2;
1557 break;
1558 case LLRP_IMPINJ_PARAM_TAG_DIRECTION_REPORTING:
1559 proto_tree_add_item(param_tree, hf_llrp_impinj_en_tag_dir, tvb, suboffset, 2, ENC_NA);
1560 suboffset += 2;
1561 proto_tree_add_item(param_tree, hf_llrp_impinj_antenna_conf, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1562 suboffset += 2;
1563 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 4, ENC_NA);
1564 suboffset += 4;
1565 break;
1566 case LLRP_IMPINJ_PARAM_TAG_DIRECTION:
1567 proto_tree_add_item(param_tree, hf_llrp_decision_time, tvb, suboffset, 8, ENC_BIG_ENDIAN);
1568 suboffset += 8;
1569 proto_tree_add_item(param_tree, hf_llrp_impinj_tag_dir, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1570 suboffset += 2;
1571 proto_tree_add_item(param_tree, hf_llrp_confidence, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1572 suboffset += 2;
1573 break;
1574 case LLRP_IMPINJ_PARAM_FIXED_FREQUENCY_LIST:
1575 proto_tree_add_item(param_tree, hf_llrp_impinj_fix_freq_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1576 suboffset += 2;
1577 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 2, ENC_NA);
1578 suboffset += 2;
1579 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1580 hf_llrp_num_channels, hf_llrp_channel, 2, suboffset);
1581 break;
1582 case LLRP_IMPINJ_PARAM_REDUCED_POWER_FREQUENCY_LIST:
1583 proto_tree_add_item(param_tree, hf_llrp_impinj_reduce_power_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1584 suboffset += 2;
1585 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 2, ENC_NA);
1586 suboffset += 2;
1587 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1588 hf_llrp_num_channels, hf_llrp_channel, 2, suboffset);
1589 break;
1590 case LLRP_IMPINJ_PARAM_LOW_DUTY_CYCLE:
1591 proto_tree_add_item(param_tree, hf_llrp_impinj_low_duty_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1592 suboffset += 2;
1593 proto_tree_add_item(param_tree, hf_llrp_empty_field_timeout, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1594 suboffset += 2;
1595 proto_tree_add_item(param_tree, hf_llrp_field_ping_interval, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1596 suboffset += 2;
1597 break;
1598 case LLRP_IMPINJ_PARAM_DETAILED_VERSION:
1599 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_model_name, suboffset);
1600 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_serial_number, suboffset);
1601 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_soft_ver, suboffset);
1602 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_firm_ver, suboffset);
1603 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_fpga_ver, suboffset);
1604 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_pcba_ver, suboffset);
1605 break;
1606 case LLRP_IMPINJ_PARAM_FREQUENCY_CAPABILITIES:
1607 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1608 hf_llrp_num_freqs, hf_llrp_frequency, 4, suboffset);
1609 break;
1610 case LLRP_IMPINJ_PARAM_FORKLIFT_HEIGHT_THRESHOLD:
1611 proto_tree_add_item(param_tree, hf_llrp_height_thresh, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1612 suboffset += 2;
1613 break;
1614 case LLRP_IMPINJ_PARAM_FORKLIFT_ZEROMOTION_TIME_THRESHOLD:
1615 proto_tree_add_item(param_tree, hf_llrp_zero_motion_thresh, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1616 suboffset += 2;
1617 break;
1618 case LLRP_IMPINJ_PARAM_FORKLIFT_COMPANION_BOARD_INFO:
1619 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_board_manufacturer, suboffset);
1620 proto_tree_add_item(param_tree, hf_llrp_fw_ver_hex, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1621 suboffset += 2;
1622 proto_tree_add_item(param_tree, hf_llrp_hw_ver_hex, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1623 suboffset += 2;
1624 break;
1625 case LLRP_IMPINJ_PARAM_GPI_DEBOUNCE_CONFIGURATION:
1626 proto_tree_add_item(param_tree, hf_llrp_gpi_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1627 suboffset += 2;
1628 proto_tree_add_item(param_tree, hf_llrp_gpi_debounce, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1629 suboffset += 4;
1630 break;
1631 case LLRP_IMPINJ_PARAM_READER_TEMPERATURE:
1632 proto_tree_add_item(param_tree, hf_llrp_temperature, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1633 suboffset += 2;
1634 break;
1635 case LLRP_IMPINJ_PARAM_LINK_MONITOR_CONFIGURATION:
1636 proto_tree_add_item(param_tree, hf_llrp_impinj_link_monitor_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1637 suboffset += 2;
1638 proto_tree_add_item(param_tree, hf_llrp_link_down_thresh, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1639 suboffset += 2;
1640 break;
1641 case LLRP_IMPINJ_PARAM_REPORT_BUFFER_CONFIGURATION:
1642 proto_tree_add_item(param_tree, hf_llrp_impinj_report_buff_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1643 suboffset += 2;
1644 break;
1645 case LLRP_IMPINJ_PARAM_BLOCK_WRITE_WORD_COUNT:
1646 proto_tree_add_item(param_tree, hf_llrp_word_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1647 suboffset += 2;
1648 break;
1649 case LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK:
1650 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1651 suboffset += 2;
1652 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1653 suboffset += 4;
1654 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
1655 suboffset += 1;
1656 proto_tree_add_item(param_tree, hf_llrp_block_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1657 suboffset += 2;
1658 proto_tree_add_item(param_tree, hf_llrp_block_mask, tvb, suboffset, 2, ENC_NA);
1659 suboffset += 2;
1660 break;
1661 case LLRP_IMPINJ_PARAM_BLOCK_PERMALOCK_OPSPEC_RESULT:
1662 proto_tree_add_item(param_tree, hf_llrp_permalock_result, tvb, suboffset, 1, ENC_NA);
1663 suboffset += 1;
1664 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1665 suboffset += 2;
1666 break;
1667 case LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS:
1668 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1669 suboffset += 2;
1670 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1671 suboffset += 4;
1672 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
1673 suboffset += 1;
1674 proto_tree_add_item(param_tree, hf_llrp_block_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1675 suboffset += 2;
1676 proto_tree_add_item(param_tree, hf_llrp_block_range, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1677 suboffset += 2;
1678 break;
1679 case LLRP_IMPINJ_PARAM_GET_BLOCK_PERMALOCK_STATUS_OPSPEC_RESULT:
1680 proto_tree_add_item(param_tree, hf_llrp_block_permalock_result, tvb, suboffset, 1, ENC_NA);
1681 suboffset += 1;
1682 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1683 suboffset += 2;
1684 break;
1685 case LLRP_IMPINJ_PARAM_SET_QT_CONFIG:
1686 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1687 suboffset += 2;
1688 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1689 suboffset += 4;
1690 proto_tree_add_item(param_tree, hf_llrp_impinj_data_profile, tvb, suboffset, 1, ENC_NA);
1691 suboffset += 1;
1692 proto_tree_add_item(param_tree, hf_llrp_impinj_access_range, tvb, suboffset, 1, ENC_NA);
1693 suboffset += 1;
1694 proto_tree_add_item(param_tree, hf_llrp_impinj_persistence, tvb, suboffset, 1, ENC_NA);
1695 suboffset += 1;
1696 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 4, ENC_NA);
1697 suboffset += 4;
1698 break;
1699 case LLRP_IMPINJ_PARAM_SET_QT_CONFIG_OPSPEC_RESULT:
1700 proto_tree_add_item(param_tree, hf_llrp_set_qt_config_result, tvb, suboffset, 1, ENC_NA);
1701 suboffset += 1;
1702 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1703 suboffset += 2;
1704 break;
1705 case LLRP_IMPINJ_PARAM_GET_QT_CONFIG:
1706 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1707 suboffset += 2;
1708 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1709 suboffset += 4;
1710 break;
1711 case LLRP_IMPINJ_PARAM_GET_QT_CONFIG_OPSPEC_RESULT:
1712 proto_tree_add_item(param_tree, hf_llrp_get_qt_config_result, tvb, suboffset, 1, ENC_NA);
1713 suboffset += 1;
1714 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1715 suboffset += 2;
1716 proto_tree_add_item(param_tree, hf_llrp_impinj_data_profile, tvb, suboffset, 1, ENC_NA);
1717 suboffset += 1;
1718 proto_tree_add_item(param_tree, hf_llrp_impinj_access_range, tvb, suboffset, 1, ENC_NA);
1719 suboffset += 1;
1720 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 4, ENC_NA);
1721 suboffset += 4;
1722 break;
1723 case LLRP_IMPINJ_PARAM_ENABLE_SERIALIZED_TID:
1724 proto_tree_add_item(param_tree, hf_llrp_impinj_serialized_tid_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1725 suboffset += 2;
1726 break;
1727 case LLRP_IMPINJ_PARAM_ENABLE_RF_PHASE_ANGLE:
1728 proto_tree_add_item(param_tree, hf_llrp_impinj_rf_phase_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1729 suboffset += 2;
1730 break;
1731 case LLRP_IMPINJ_PARAM_ENABLE_PEAK_RSSI:
1732 proto_tree_add_item(param_tree, hf_llrp_impinj_peak_rssi_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1733 suboffset += 2;
1734 break;
1735 case LLRP_IMPINJ_PARAM_ENABLE_GPS_COORDINATES:
1736 proto_tree_add_item(param_tree, hf_llrp_impinj_gps_coordinates_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1737 suboffset += 2;
1738 break;
1739 case LLRP_IMPINJ_PARAM_SERIALIZED_TID:
1740 proto_tree_add_item(param_tree, hf_llrp_impinj_tid, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1741 suboffset += 2;
1742 break;
1743 case LLRP_IMPINJ_PARAM_RF_PHASE_ANGLE:
1744 proto_tree_add_item(param_tree, hf_llrp_phase_angle, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1745 suboffset += 2;
1746 break;
1747 case LLRP_IMPINJ_PARAM_PEAK_RSSI:
1748 proto_tree_add_item(param_tree, hf_llrp_rssi, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1749 suboffset += 2;
1750 break;
1751 case LLRP_IMPINJ_PARAM_GPS_COORDINATES:
1752 proto_tree_add_item(param_tree, hf_llrp_latitude, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1753 suboffset += 4;
1754 proto_tree_add_item(param_tree, hf_llrp_longitude, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1755 suboffset += 4;
1756 break;
1757 case LLRP_IMPINJ_PARAM_LOOP_SPEC:
1758 proto_tree_add_item(param_tree, hf_llrp_loop_count, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1759 suboffset += 4;
1760 break;
1761 case LLRP_IMPINJ_PARAM_GGA_SENTENCE:
1762 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_gga_sentence, suboffset);
1763 break;
1764 case LLRP_IMPINJ_PARAM_RMC_SENTENCE:
1765 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_rmc_sentence, suboffset);
1766 break;
1767 case LLRP_IMPINJ_PARAM_OPSPEC_RETRY_COUNT:
1768 proto_tree_add_item(param_tree, hf_llrp_retry_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1769 suboffset += 2;
1770 break;
1771 case LLRP_IMPINJ_PARAM_ADVANCE_GPO_CONFIG:
1772 proto_tree_add_item(param_tree, hf_llrp_gpo_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1773 suboffset += 2;
1774 proto_tree_add_item(param_tree, hf_llrp_impinj_gpo_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1775 suboffset += 2;
1776 proto_tree_add_item(param_tree, hf_llrp_gpo_pulse_dur, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1777 suboffset += 4;
1778 break;
1779 case LLRP_IMPINJ_PARAM_ENABLE_OPTIM_READ:
1780 proto_tree_add_item(param_tree, hf_llrp_impinj_optim_read_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1781 suboffset += 2;
1782 break;
1783 case LLRP_IMPINJ_PARAM_ACCESS_SPEC_ORDERING:
1784 proto_tree_add_item(param_tree, hf_llrp_impinj_access_spec_ordering, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1785 suboffset += 2;
1786 break;
1787 case LLRP_IMPINJ_PARAM_ENABLE_RF_DOPPLER_FREQ:
1788 proto_tree_add_item(param_tree, hf_llrp_impinj_rf_doppler_mode, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1789 suboffset += 2;
1790 break;
1791 case LLRP_IMPINJ_PARAM_ARRAY_VERSION:
1792 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_serial_number, suboffset);
1793 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_firm_ver, suboffset);
1794 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_pcba_ver, suboffset);
1795 break;
1796 case LLRP_IMPINJ_PARAM_HUB_CONFIGURATION:
1797 proto_tree_add_item(param_tree, hf_llrp_impinj_hub_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1798 suboffset += 2;
1799 proto_tree_add_item(param_tree, hf_llrp_impinj_hub_connected_type, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1800 suboffset += 2;
1801 proto_tree_add_item(param_tree, hf_llrp_impinj_hub_fault_type, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1802 suboffset += 2;
1803 break;
1804 default:
1805 return suboffset;
1807 /* Each custom parameters ends with optional custom parameter, disscect it */
1808 return dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, 0);
1811 static unsigned
1812 // NOLINTNEXTLINE(misc-no-recursion)
1813 dissect_llrp_parameters(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
1814 unsigned offset, const unsigned end, const unsigned depth)
1816 uint8_t has_length;
1817 uint16_t len, type;
1818 unsigned real_len, param_end;
1819 unsigned suboffset;
1820 unsigned num;
1821 proto_item *ti;
1822 proto_tree *param_tree;
1824 while (((int)(end - offset)) > 0)
1826 has_length = !(tvb_get_uint8(tvb, offset) & 0x80);
1828 if (has_length)
1830 type = tvb_get_ntohs(tvb, offset);
1831 len = tvb_get_ntohs(tvb, offset + 2);
1833 if (len < LLRP_TLV_LEN_MIN)
1834 real_len = LLRP_TLV_LEN_MIN;
1835 else if (len > tvb_reported_length_remaining(tvb, offset))
1836 real_len = tvb_reported_length_remaining(tvb, offset);
1837 else
1838 real_len = len;
1840 param_end = offset + real_len;
1842 if (depth > 16) {
1843 return param_end;
1846 ti = proto_tree_add_none_format(tree, hf_llrp_param, tvb,
1847 offset, real_len, "TLV Parameter: %s",
1848 val_to_str_ext(type, &tlv_type_ext, "Unknown Type: %d"));
1849 param_tree = proto_item_add_subtree(ti, ett_llrp_param);
1851 proto_tree_add_item(param_tree, hf_llrp_tlv_type, tvb,
1852 offset, 2, ENC_BIG_ENDIAN);
1853 offset += 2;
1855 ti = proto_tree_add_item(param_tree, hf_llrp_tlv_len, tvb,
1856 offset, 2, ENC_BIG_ENDIAN);
1857 if (len != real_len)
1858 expert_add_info_format(pinfo, ti, &ei_llrp_invalid_length,
1859 "Invalid length field: claimed %u, should be %u.",
1860 len, real_len);
1861 offset += 2;
1863 suboffset = offset;
1864 increment_dissection_depth(pinfo);
1865 switch(type) {
1866 case LLRP_TLV_RO_BOUND_SPEC:
1867 case LLRP_TLV_UHF_CAPABILITIES:
1868 case LLRP_TLV_ACCESS_COMMAND:
1869 case LLRP_TLV_TAG_REPORT_DATA:
1870 case LLRP_TLV_RF_SURVEY_REPORT_DATA:
1871 case LLRP_TLV_READER_EVENT_NOTI_SPEC:
1872 case LLRP_TLV_READER_EVENT_NOTI_DATA:
1873 case LLRP_TLV_C1G2_UHF_RF_MD_TBL:
1874 case LLRP_TLV_C1G2_TAG_SPEC:
1875 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1876 break;
1877 case LLRP_TLV_UTC_TIMESTAMP:
1878 case LLRP_TLV_UPTIME:
1879 proto_tree_add_item(param_tree, hf_llrp_microseconds, tvb, suboffset, 8, ENC_BIG_ENDIAN);
1880 suboffset += 8;
1881 break;
1882 case LLRP_TLV_GENERAL_DEVICE_CAP:
1883 proto_tree_add_item(param_tree, hf_llrp_max_supported_antenna, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1884 proto_tree_add_item(param_tree, hf_llrp_can_set_antenna_prop, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1885 suboffset += 2;
1886 proto_tree_add_item(param_tree, hf_llrp_has_utc_clock, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1887 suboffset += 2;
1888 proto_tree_add_item(param_tree, hf_llrp_device_manufacturer, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1889 suboffset += 4;
1890 proto_tree_add_item(param_tree, hf_llrp_model, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1891 suboffset += 4;
1892 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_firmware_version, suboffset);
1893 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1894 break;
1895 case LLRP_TLV_MAX_RECEIVE_SENSE:
1896 proto_tree_add_item(param_tree, hf_llrp_max_receive_sense, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1897 suboffset += 2;
1898 break;
1899 case LLRP_TLV_RECEIVE_SENSE_ENTRY:
1900 proto_tree_add_item(param_tree, hf_llrp_index, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1901 suboffset += 2;
1902 proto_tree_add_item(param_tree, hf_llrp_receive_sense, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1903 suboffset += 2;
1904 break;
1905 case LLRP_TLV_ANTENNA_RCV_SENSE_RANGE:
1906 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1907 suboffset += 2;
1908 proto_tree_add_item(param_tree, hf_llrp_receive_sense_index_min, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1909 suboffset += 2;
1910 proto_tree_add_item(param_tree, hf_llrp_receive_sense_index_max, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1911 suboffset += 2;
1912 break;
1913 case LLRP_TLV_ANTENNA_AIR_PROTO:
1914 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1915 suboffset += 2;
1916 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1917 hf_llrp_num_protocols, hf_llrp_protocol_id, 1, suboffset);
1918 break;
1919 case LLRP_TLV_GPIO_CAPABILITIES:
1920 proto_tree_add_item(param_tree, hf_llrp_num_gpi, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1921 suboffset += 2;
1922 proto_tree_add_item(param_tree, hf_llrp_num_gpo, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1923 suboffset += 2;
1924 break;
1925 case LLRP_TLV_LLRP_CAPABILITIES:
1926 proto_tree_add_item(param_tree, hf_llrp_can_do_survey, tvb, suboffset, 1, ENC_NA);
1927 proto_tree_add_item(param_tree, hf_llrp_can_report_buffer_warning, tvb, suboffset, 1, ENC_NA);
1928 proto_tree_add_item(param_tree, hf_llrp_support_client_opspec, tvb, suboffset, 1, ENC_NA);
1929 proto_tree_add_item(param_tree, hf_llrp_can_stateaware, tvb, suboffset, 1, ENC_NA);
1930 proto_tree_add_item(param_tree, hf_llrp_support_holding, tvb, suboffset, 1, ENC_NA);
1931 suboffset += 1;
1932 proto_tree_add_item(param_tree, hf_llrp_max_priority_supported, tvb, suboffset, 1, ENC_NA);
1933 suboffset += 1;
1934 proto_tree_add_item(param_tree, hf_llrp_client_opspec_timeout, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1935 suboffset += 2;
1936 proto_tree_add_item(param_tree, hf_llrp_max_num_rospec, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1937 suboffset += 4;
1938 proto_tree_add_item(param_tree, hf_llrp_max_num_spec_per_rospec, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1939 suboffset += 4;
1940 proto_tree_add_item(param_tree, hf_llrp_max_num_inventory_per_aispec, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1941 suboffset += 4;
1942 proto_tree_add_item(param_tree, hf_llrp_max_num_accessspec, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1943 suboffset += 4;
1944 proto_tree_add_item(param_tree, hf_llrp_max_num_opspec_per_accressspec, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1945 suboffset += 4;
1947 break;
1948 case LLRP_TLV_REGU_CAPABILITIES:
1949 proto_tree_add_item(param_tree, hf_llrp_country_code, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1950 suboffset += 2;
1951 proto_tree_add_item(param_tree, hf_llrp_comm_standard, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1952 suboffset += 2;
1953 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1954 break;
1955 case LLRP_TLV_XMIT_POWER_LEVEL_ENTRY:
1956 proto_tree_add_item(param_tree, hf_llrp_index, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1957 suboffset += 2;
1958 proto_tree_add_item(param_tree, hf_llrp_transmit_power, tvb, suboffset, 2, ENC_BIG_ENDIAN);
1959 suboffset += 2;
1960 break;
1961 case LLRP_TLV_FREQ_INFORMATION:
1962 proto_tree_add_item(param_tree, hf_llrp_hopping, tvb, suboffset, 1, ENC_NA);
1963 suboffset += 1;
1964 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1965 break;
1966 case LLRP_TLV_FREQ_HOP_TABLE:
1967 proto_tree_add_item(param_tree, hf_llrp_hop_table_id, tvb, suboffset, 1, ENC_NA);
1968 suboffset += 1;
1969 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 1, ENC_NA);
1970 suboffset += 1;
1971 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1972 hf_llrp_num_hops, hf_llrp_frequency, 4, suboffset);
1973 break;
1974 case LLRP_TLV_FIXED_FREQ_TABLE:
1975 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
1976 hf_llrp_num_freqs, hf_llrp_frequency, 4, suboffset);
1977 break;
1978 case LLRP_TLV_RF_SURVEY_FREQ_CAP:
1979 proto_tree_add_item(param_tree, hf_llrp_min_freq, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1980 suboffset += 4;
1981 proto_tree_add_item(param_tree, hf_llrp_max_freq, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1982 suboffset += 4;
1983 break;
1984 case LLRP_TLV_RO_SPEC:
1985 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
1986 suboffset += 4;
1987 proto_tree_add_item(param_tree, hf_llrp_priority, tvb, suboffset, 1, ENC_NA);
1988 suboffset += 1;
1989 proto_tree_add_item(param_tree, hf_llrp_cur_state, tvb, suboffset, 1, ENC_NA);
1990 suboffset += 1;
1991 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1992 break;
1993 case LLRP_TLV_RO_SPEC_START_TRIGGER:
1994 proto_tree_add_item(param_tree, hf_llrp_rospec_start_trig_type, tvb, suboffset, 1, ENC_NA);
1995 suboffset += 1;
1996 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
1997 break;
1998 case LLRP_TLV_PER_TRIGGER_VAL:
1999 proto_tree_add_item(param_tree, hf_llrp_offset, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2000 suboffset += 4;
2001 proto_tree_add_item(param_tree, hf_llrp_period, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2002 suboffset += 4;
2003 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2004 break;
2005 case LLRP_TLV_GPI_TRIGGER_VAL:
2006 proto_tree_add_item(param_tree, hf_llrp_gpi_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2007 suboffset += 2;
2008 proto_tree_add_item(param_tree, hf_llrp_gpi_event, tvb, suboffset, 1, ENC_NA);
2009 suboffset += 1;
2010 proto_tree_add_item(param_tree, hf_llrp_timeout, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2011 suboffset += 4;
2012 break;
2013 case LLRP_TLV_RO_SPEC_STOP_TRIGGER:
2014 proto_tree_add_item(param_tree, hf_llrp_rospec_stop_trig_type, tvb, suboffset, 1, ENC_NA);
2015 suboffset += 1;
2016 proto_tree_add_item(param_tree, hf_llrp_duration_trig, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2017 suboffset += 4;
2018 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2019 break;
2020 case LLRP_TLV_AI_SPEC:
2021 suboffset = dissect_llrp_item_array(tvb, pinfo, param_tree,
2022 hf_llrp_antenna_count, hf_llrp_antenna, 2, suboffset);
2023 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2024 break;
2025 case LLRP_TLV_AI_SPEC_STOP:
2026 proto_tree_add_item(param_tree, hf_llrp_aispec_stop_trig_type, tvb, suboffset, 1, ENC_NA);
2027 suboffset += 1;
2028 proto_tree_add_item(param_tree, hf_llrp_duration_trig, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2029 suboffset += 4;
2030 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2031 break;
2032 case LLRP_TLV_TAG_OBSERV_TRIGGER:
2033 proto_tree_add_item(param_tree, hf_llrp_trig_type, tvb, suboffset, 1, ENC_NA);
2034 suboffset += 1;
2035 proto_tree_add_item(param_tree, hf_llrp_rfu, tvb, suboffset, 1, ENC_NA);
2036 suboffset += 1;
2037 proto_tree_add_item(param_tree, hf_llrp_number_of_tags, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2038 suboffset += 2;
2039 proto_tree_add_item(param_tree, hf_llrp_number_of_attempts, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2040 suboffset += 2;
2041 proto_tree_add_item(param_tree, hf_llrp_t, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2042 suboffset += 2;
2043 proto_tree_add_item(param_tree, hf_llrp_timeout, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2044 suboffset += 4;
2045 break;
2046 case LLRP_TLV_INVENTORY_PARAM_SPEC:
2047 proto_tree_add_item(param_tree, hf_llrp_inventory_spec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2048 suboffset += 2;
2049 proto_tree_add_item(param_tree, hf_llrp_protocol_id, tvb, suboffset, 1, ENC_NA);
2050 suboffset += 1;
2051 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2052 break;
2053 case LLRP_TLV_RF_SURVEY_SPEC:
2054 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2055 suboffset += 2;
2056 proto_tree_add_item(param_tree, hf_llrp_start_freq, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2057 suboffset += 4;
2058 proto_tree_add_item(param_tree, hf_llrp_stop_freq, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2059 suboffset += 4;
2060 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2061 break;
2062 case LLRP_TLV_RF_SURVEY_SPEC_STOP_TR:
2063 proto_tree_add_item(param_tree, hf_llrp_stop_trig_type, tvb, suboffset, 1, ENC_NA);
2064 suboffset += 1;
2065 proto_tree_add_item(param_tree, hf_llrp_duration, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2066 suboffset += 4;
2067 proto_tree_add_item(param_tree, hf_llrp_n_4, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2068 suboffset += 4;
2069 break;
2070 case LLRP_TLV_LOOP_SPEC:
2071 proto_tree_add_item(param_tree, hf_llrp_loop_count, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2072 suboffset += 4;
2073 break;
2074 case LLRP_TLV_ACCESS_SPEC:
2075 proto_tree_add_item(param_tree, hf_llrp_accessspec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2076 suboffset += 4;
2077 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2078 suboffset += 2;
2079 proto_tree_add_item(param_tree, hf_llrp_protocol_id, tvb, suboffset, 1, ENC_BIG_ENDIAN);
2080 suboffset += 1;
2081 proto_tree_add_item(param_tree, hf_llrp_access_cur_state, tvb, suboffset, 1, ENC_NA);
2082 suboffset += 1;
2083 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2084 suboffset += 4;
2085 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2086 break;
2087 case LLRP_TLV_ACCESS_SPEC_STOP_TRIG:
2088 proto_tree_add_item(param_tree, hf_llrp_access_stop_trig_type, tvb, suboffset, 1, ENC_NA);
2089 suboffset += 1;
2090 proto_tree_add_item(param_tree, hf_llrp_operation_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2091 suboffset += 2;
2092 break;
2093 case LLRP_TLV_CLIENT_REQ_OP_SPEC:
2094 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2095 suboffset += 2;
2096 break;
2097 case LLRP_TLV_CLIENT_REQ_RESPONSE:
2098 proto_tree_add_item(param_tree, hf_llrp_accessspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2099 suboffset += 2;
2100 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2101 break;
2102 case LLRP_TLV_LLRP_CONF_STATE_VAL:
2103 proto_tree_add_item(param_tree, hf_llrp_conf_value, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2104 suboffset += 4;
2105 break;
2106 case LLRP_TLV_IDENT:
2107 proto_tree_add_item(param_tree, hf_llrp_id_type, tvb, suboffset, 1, ENC_NA);
2108 suboffset += 1;
2109 num = tvb_get_ntohs(tvb, suboffset);
2110 proto_tree_add_item(param_tree, hf_llrp_reader_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2111 suboffset += num;
2112 break;
2113 case LLRP_TLV_GPO_WRITE_DATA:
2114 proto_tree_add_item(param_tree, hf_llrp_gpo_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2115 suboffset += 2;
2116 proto_tree_add_item(param_tree, hf_llrp_gpo_data, tvb, suboffset, 1, ENC_NA);
2117 suboffset += 1;
2118 break;
2119 case LLRP_TLV_KEEPALIVE_SPEC:
2120 proto_tree_add_item(param_tree, hf_llrp_keepalive_trig_type, tvb, suboffset, 1, ENC_NA);
2121 suboffset += 1;
2122 proto_tree_add_item(param_tree, hf_llrp_time_iterval, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2123 suboffset += 4;
2124 break;
2125 case LLRP_TLV_ANTENNA_PROPS:
2126 proto_tree_add_item(param_tree, hf_llrp_antenna_connected, tvb, suboffset, 1, ENC_NA);
2127 suboffset += 1;
2128 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2129 suboffset += 2;
2130 proto_tree_add_item(param_tree, hf_llrp_antenna_gain, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2131 suboffset += 2;
2132 break;
2133 case LLRP_TLV_ANTENNA_CONF:
2134 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2135 suboffset += 2;
2136 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2137 break;
2138 case LLRP_TLV_RF_RECEIVER:
2139 proto_tree_add_item(param_tree, hf_llrp_receiver_sense, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2140 suboffset += 2;
2141 break;
2142 case LLRP_TLV_RF_TRANSMITTER:
2143 proto_tree_add_item(param_tree, hf_llrp_hop_table_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2144 suboffset += 2;
2145 proto_tree_add_item(param_tree, hf_llrp_channel_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2146 suboffset += 2;
2147 proto_tree_add_item(param_tree, hf_llrp_transmit_power, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2148 suboffset += 2;
2149 break;
2150 case LLRP_TLV_GPI_PORT_CURRENT_STATE:
2151 proto_tree_add_item(param_tree, hf_llrp_gpi_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2152 suboffset += 2;
2153 proto_tree_add_item(param_tree, hf_llrp_gpi_config, tvb, suboffset, 1, ENC_NA);
2154 suboffset += 1;
2155 proto_tree_add_item(param_tree, hf_llrp_gpi_state, tvb, suboffset, 1, ENC_NA);
2156 suboffset += 1;
2157 break;
2158 case LLRP_TLV_EVENTS_AND_REPORTS:
2159 proto_tree_add_item(param_tree, hf_llrp_hold_events_and_reports, tvb, suboffset, 1, ENC_NA);
2160 suboffset += 1;
2161 break;
2162 case LLRP_TLV_RO_REPORT_SPEC:
2163 proto_tree_add_item(param_tree, hf_llrp_ro_report_trig, tvb, suboffset, 1, ENC_NA);
2164 suboffset += 1;
2165 proto_tree_add_item(param_tree, hf_llrp_n_2, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2166 suboffset += 2;
2167 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2168 break;
2169 case LLRP_TLV_TAG_REPORT_CONTENT_SEL:
2170 proto_tree_add_item(param_tree, hf_llrp_enable_rospec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2171 proto_tree_add_item(param_tree, hf_llrp_enable_spec_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2172 proto_tree_add_item(param_tree, hf_llrp_enable_inv_spec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2173 proto_tree_add_item(param_tree, hf_llrp_enable_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2174 proto_tree_add_item(param_tree, hf_llrp_enable_channel_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2175 proto_tree_add_item(param_tree, hf_llrp_enable_peak_rssi, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2176 proto_tree_add_item(param_tree, hf_llrp_enable_first_seen, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2177 proto_tree_add_item(param_tree, hf_llrp_enable_last_seen, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2178 proto_tree_add_item(param_tree, hf_llrp_enable_seen_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2179 proto_tree_add_item(param_tree, hf_llrp_enable_accessspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2180 suboffset += 2;
2181 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2182 break;
2183 case LLRP_TLV_ACCESS_REPORT_SPEC:
2184 proto_tree_add_item(param_tree, hf_llrp_access_report_trig, tvb, suboffset, 1, ENC_NA);
2185 suboffset += 1;
2186 break;
2187 case LLRP_TLV_EPC_DATA:
2188 suboffset = dissect_llrp_bit_field(tvb, param_tree, hf_llrp_epc, suboffset);
2189 break;
2190 case LLRP_TLV_FREQ_RSSI_LEVEL_ENTRY:
2191 proto_tree_add_item(param_tree, hf_llrp_frequency, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2192 suboffset += 4;
2193 proto_tree_add_item(param_tree, hf_llrp_bandwidth, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2194 suboffset += 4;
2195 proto_tree_add_item(param_tree, hf_llrp_average_rssi, tvb, suboffset, 1, ENC_NA);
2196 suboffset += 1;
2197 proto_tree_add_item(param_tree, hf_llrp_peak_rssi, tvb, suboffset, 1, ENC_NA);
2198 suboffset += 1;
2199 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2200 break;
2201 case LLRP_TLV_EVENT_NOTIF_STATE:
2202 proto_tree_add_item(param_tree, hf_llrp_event_type, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2203 suboffset += 2;
2204 proto_tree_add_item(param_tree, hf_llrp_notif_state, tvb, suboffset, 1, ENC_NA);
2205 suboffset += 1;
2206 break;
2207 case LLRP_TLV_HOPPING_EVENT:
2208 proto_tree_add_item(param_tree, hf_llrp_hop_table_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2209 suboffset += 2;
2210 proto_tree_add_item(param_tree, hf_llrp_next_chan_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2211 suboffset += 2;
2212 break;
2213 case LLRP_TLV_GPI_EVENT:
2214 proto_tree_add_item(param_tree, hf_llrp_gpi_port, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2215 suboffset += 2;
2216 proto_tree_add_item(param_tree, hf_llrp_gpi_event, tvb, suboffset, 1, ENC_NA);
2217 suboffset += 1;
2218 break;
2219 case LLRP_TLV_RO_SPEC_EVENT:
2220 proto_tree_add_item(param_tree, hf_llrp_roevent_type, tvb, suboffset, 1, ENC_NA);
2221 suboffset += 1;
2222 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2223 suboffset += 4;
2224 proto_tree_add_item(param_tree, hf_llrp_prem_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2225 suboffset += 4;
2226 break;
2227 case LLRP_TLV_REPORT_BUF_LEVEL_WARN:
2228 proto_tree_add_item(param_tree, hf_llrp_buffer_full_percentage, tvb, suboffset, 1, ENC_NA);
2229 suboffset += 1;
2230 break;
2231 case LLRP_TLV_REPORT_BUF_OVERFLOW_ERR: break;
2232 case LLRP_TLV_READER_EXCEPTION_EVENT:
2233 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_message, suboffset);
2234 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2235 break;
2236 case LLRP_TLV_RF_SURVEY_EVENT:
2237 proto_tree_add_item(param_tree, hf_llrp_rfevent_type, tvb, suboffset, 1, ENC_NA);
2238 suboffset += 1;
2239 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2240 suboffset += 4;
2241 proto_tree_add_item(param_tree, hf_llrp_spec_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2242 suboffset += 2;
2243 break;
2244 case LLRP_TLV_AI_SPEC_EVENT:
2245 proto_tree_add_item(param_tree, hf_llrp_aievent_type, tvb, suboffset, 1, ENC_NA);
2246 suboffset += 1;
2247 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2248 suboffset += 4;
2249 proto_tree_add_item(param_tree, hf_llrp_spec_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2250 suboffset += 2;
2251 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2252 break;
2253 case LLRP_TLV_ANTENNA_EVENT:
2254 proto_tree_add_item(param_tree, hf_llrp_antenna_event_type, tvb, suboffset, 1, ENC_NA);
2255 suboffset += 1;
2256 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2257 suboffset += 2;
2258 break;
2259 case LLRP_TLV_CONN_ATTEMPT_EVENT:
2260 proto_tree_add_item(param_tree, hf_llrp_conn_status, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2261 suboffset += 2;
2262 break;
2263 case LLRP_TLV_CONN_CLOSE_EVENT:
2264 break;
2265 case LLRP_TLV_SPEC_LOOP_EVENT:
2266 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2267 suboffset += 4;
2268 proto_tree_add_item(param_tree, hf_llrp_loop_count, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2269 suboffset += 4;
2270 break;
2271 case LLRP_TLV_LLRP_STATUS:
2272 proto_tree_add_item(param_tree, hf_llrp_status_code, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2273 suboffset += 2;
2274 suboffset = dissect_llrp_utf8_parameter(tvb, pinfo, param_tree, hf_llrp_error_desc, suboffset);
2275 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2276 break;
2277 case LLRP_TLV_FIELD_ERROR:
2278 proto_tree_add_item(param_tree, hf_llrp_field_num, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2279 suboffset += 2;
2280 proto_tree_add_item(param_tree, hf_llrp_error_code, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2281 suboffset += 2;
2282 break;
2283 case LLRP_TLV_PARAM_ERROR:
2284 proto_tree_add_item(param_tree, hf_llrp_parameter_type, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2285 suboffset += 2;
2286 proto_tree_add_item(param_tree, hf_llrp_error_code, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2287 suboffset += 2;
2288 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2289 break;
2290 case LLRP_TLV_C1G2_LLRP_CAP:
2291 proto_tree_add_item(param_tree, hf_llrp_can_support_block_erase, tvb, suboffset, 1, ENC_NA);
2292 proto_tree_add_item(param_tree, hf_llrp_can_support_block_write, tvb, suboffset, 1, ENC_NA);
2293 proto_tree_add_item(param_tree, hf_llrp_can_support_block_permalock, tvb, suboffset, 1, ENC_NA);
2294 proto_tree_add_item(param_tree, hf_llrp_can_support_tag_recomm, tvb, suboffset, 1, ENC_NA);
2295 proto_tree_add_item(param_tree, hf_llrp_can_support_UMI_method2, tvb, suboffset, 1, ENC_NA);
2296 proto_tree_add_item(param_tree, hf_llrp_can_support_XPC, tvb, suboffset, 1, ENC_NA);
2297 suboffset += 1;
2298 proto_tree_add_item(param_tree, hf_llrp_max_num_filter_per_query, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2299 suboffset += 2;
2300 break;
2301 case LLRP_TLV_C1G2_UHF_RF_MD_TBL_ENT:
2302 proto_tree_add_item(param_tree, hf_llrp_mode_ident, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2303 suboffset += 4;
2304 proto_tree_add_item(param_tree, hf_llrp_DR, tvb, suboffset, 1, ENC_NA);
2305 proto_tree_add_item(param_tree, hf_llrp_hag_conformance, tvb, suboffset, 1, ENC_NA);
2306 suboffset += 1;
2307 proto_tree_add_item(param_tree, hf_llrp_mod, tvb, suboffset, 1, ENC_NA);
2308 suboffset += 1;
2309 proto_tree_add_item(param_tree, hf_llrp_flm, tvb, suboffset, 1, ENC_NA);
2310 suboffset += 1;
2311 proto_tree_add_item(param_tree, hf_llrp_m, tvb, suboffset, 1, ENC_NA);
2312 suboffset += 1;
2313 proto_tree_add_item(param_tree, hf_llrp_bdr, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2314 suboffset += 4;
2315 proto_tree_add_item(param_tree, hf_llrp_pie, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2316 suboffset += 4;
2317 proto_tree_add_item(param_tree, hf_llrp_min_tari, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2318 suboffset += 4;
2319 proto_tree_add_item(param_tree, hf_llrp_max_tari, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2320 suboffset += 4;
2321 proto_tree_add_item(param_tree, hf_llrp_step_tari, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2322 suboffset += 4;
2323 break;
2324 case LLRP_TLV_C1G2_INVENTORY_COMMAND:
2325 proto_tree_add_item(param_tree, hf_llrp_inventory_state_aware, tvb, suboffset, 1, ENC_NA);
2326 suboffset += 1;
2327 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2328 break;
2329 case LLRP_TLV_C1G2_FILTER:
2330 proto_tree_add_item(param_tree, hf_llrp_trunc, tvb, suboffset, 1, ENC_NA);
2331 suboffset += 1;
2332 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2333 break;
2334 case LLRP_TLV_C1G2_TAG_INV_MASK:
2335 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2336 suboffset += 1;
2337 proto_tree_add_item(param_tree, hf_llrp_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2338 suboffset += 2;
2339 suboffset = dissect_llrp_bit_field(tvb, param_tree, hf_llrp_tag_mask, suboffset);
2340 break;
2341 case LLRP_TLV_C1G2_TAG_INV_AWARE_FLTR:
2342 proto_tree_add_item(param_tree, hf_llrp_aware_filter_target, tvb, suboffset, 1, ENC_NA);
2343 suboffset += 1;
2344 proto_tree_add_item(param_tree, hf_llrp_aware_filter_action, tvb, suboffset, 1, ENC_NA);
2345 suboffset += 1;
2346 break;
2347 case LLRP_TLV_C1G2_TAG_INV_UNAWR_FLTR:
2348 proto_tree_add_item(param_tree, hf_llrp_unaware_filter_action, tvb, suboffset, 1, ENC_NA);
2349 suboffset += 1;
2350 break;
2351 case LLRP_TLV_C1G2_RF_CONTROL:
2352 proto_tree_add_item(param_tree, hf_llrp_mode_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2353 suboffset += 2;
2354 proto_tree_add_item(param_tree, hf_llrp_tari, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2355 suboffset += 2;
2356 break;
2357 case LLRP_TLV_C1G2_SINGULATION_CTRL:
2358 proto_tree_add_item(param_tree, hf_llrp_session, tvb, suboffset, 1, ENC_NA);
2359 suboffset += 1;
2360 proto_tree_add_item(param_tree, hf_llrp_tag_population, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2361 suboffset += 2;
2362 proto_tree_add_item(param_tree, hf_llrp_tag_transit_time, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2363 suboffset += 4;
2364 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2365 break;
2366 case LLRP_TLV_C1G2_TAG_INV_AWARE_SING:
2367 proto_tree_add_item(param_tree, hf_llrp_sing_i, tvb, suboffset, 1, ENC_NA);
2368 proto_tree_add_item(param_tree, hf_llrp_sing_s, tvb, suboffset, 1, ENC_NA);
2369 proto_tree_add_item(param_tree, hf_llrp_sing_a, tvb, suboffset, 1, ENC_NA);
2370 suboffset += 1;
2371 break;
2372 case LLRP_TLV_C1G2_TARGET_TAG:
2373 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2374 proto_tree_add_item(param_tree, hf_llrp_match, tvb, suboffset, 1, ENC_NA);
2375 suboffset += 1;
2376 proto_tree_add_item(param_tree, hf_llrp_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2377 suboffset += 2;
2378 suboffset = dissect_llrp_bit_field(tvb, param_tree, hf_llrp_tag_mask, suboffset);
2379 suboffset = dissect_llrp_bit_field(tvb, param_tree, hf_llrp_tag_data, suboffset);
2380 break;
2381 case LLRP_TLV_C1G2_READ:
2382 case LLRP_TLV_C1G2_BLK_ERASE:
2383 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2384 suboffset += 2;
2385 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2386 suboffset += 4;
2387 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2388 suboffset += 1;
2389 proto_tree_add_item(param_tree, hf_llrp_word_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2390 suboffset += 2;
2391 proto_tree_add_item(param_tree, hf_llrp_word_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2392 suboffset += 2;
2393 break;
2394 case LLRP_TLV_C1G2_WRITE:
2395 case LLRP_TLV_C1G2_BLK_WRITE:
2396 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2397 suboffset += 2;
2398 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2399 suboffset += 4;
2400 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2401 suboffset += 1;
2402 proto_tree_add_item(param_tree, hf_llrp_word_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2403 suboffset += 2;
2404 suboffset = dissect_llrp_word_array(tvb, param_tree, hf_llrp_write_data, suboffset);
2405 break;
2406 case LLRP_TLV_C1G2_KILL:
2407 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2408 suboffset += 2;
2409 proto_tree_add_item(param_tree, hf_llrp_kill_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2410 suboffset += 4;
2411 break;
2412 case LLRP_TLV_C1G2_RECOMMISSION:
2413 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2414 suboffset += 2;
2415 proto_tree_add_item(param_tree, hf_llrp_kill_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2416 suboffset += 4;
2417 proto_tree_add_item(param_tree, hf_llrp_kill_3, tvb, suboffset, 1, ENC_NA);
2418 proto_tree_add_item(param_tree, hf_llrp_kill_2, tvb, suboffset, 1, ENC_NA);
2419 proto_tree_add_item(param_tree, hf_llrp_kill_l, tvb, suboffset, 1, ENC_NA);
2420 suboffset += 1;
2421 break;
2422 case LLRP_TLV_C1G2_LOCK:
2423 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2424 suboffset += 2;
2425 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2426 suboffset += 4;
2427 suboffset = dissect_llrp_parameters(tvb, pinfo, param_tree, suboffset, param_end, depth+1);
2428 break;
2429 case LLRP_TLV_C1G2_LOCK_PAYLOAD:
2430 proto_tree_add_item(param_tree, hf_llrp_privilege, tvb, suboffset, 1, ENC_NA);
2431 suboffset += 1;
2432 proto_tree_add_item(param_tree, hf_llrp_data_field, tvb, suboffset, 1, ENC_NA);
2433 suboffset += 1;
2434 break;
2435 case LLRP_TLV_C1G2_BLK_PERMALOCK:
2436 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2437 suboffset += 2;
2438 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2439 suboffset += 4;
2440 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2441 suboffset += 1;
2442 proto_tree_add_item(param_tree, hf_llrp_block_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2443 suboffset += 2;
2444 suboffset = dissect_llrp_word_array(tvb, param_tree, hf_llrp_block_mask, suboffset);
2445 break;
2446 case LLRP_TLV_C1G2_GET_BLK_PERMALOCK:
2447 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2448 suboffset += 2;
2449 proto_tree_add_item(param_tree, hf_llrp_access_pass, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2450 suboffset += 2;
2451 proto_tree_add_item(param_tree, hf_llrp_mb, tvb, suboffset, 1, ENC_NA);
2452 suboffset += 2;
2453 proto_tree_add_item(param_tree, hf_llrp_block_pointer, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2454 suboffset += 2;
2455 proto_tree_add_item(param_tree, hf_llrp_block_range, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2456 suboffset += 2;
2457 break;
2458 case LLRP_TLV_C1G2_EPC_MEMORY_SLCTOR:
2459 proto_tree_add_item(param_tree, hf_llrp_enable_crc, tvb, suboffset, 1, ENC_NA);
2460 proto_tree_add_item(param_tree, hf_llrp_enable_pc, tvb, suboffset, 1, ENC_NA);
2461 proto_tree_add_item(param_tree, hf_llrp_enable_xpc, tvb, suboffset, 1, ENC_NA);
2462 suboffset += 1;
2463 break;
2464 case LLRP_TLV_C1G2_READ_OP_SPEC_RES:
2465 proto_tree_add_item(param_tree, hf_llrp_access_result, tvb, suboffset, 1, ENC_NA);
2466 suboffset += 1;
2467 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2468 suboffset += 2;
2469 suboffset = dissect_llrp_word_array(tvb, param_tree, hf_llrp_read_data, suboffset);
2470 break;
2471 case LLRP_TLV_C1G2_WRT_OP_SPEC_RES:
2472 case LLRP_TLV_C1G2_BLK_WRT_OP_SPC_RES:
2473 proto_tree_add_item(param_tree, hf_llrp_access_result, tvb, suboffset, 1, ENC_NA);
2474 suboffset += 1;
2475 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2476 suboffset += 2;
2477 proto_tree_add_item(param_tree, hf_llrp_num_words_written, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2478 suboffset += 2;
2479 break;
2480 case LLRP_TLV_C1G2_KILL_OP_SPEC_RES:
2481 case LLRP_TLV_C1G2_RECOM_OP_SPEC_RES:
2482 case LLRP_TLV_C1G2_LOCK_OP_SPEC_RES:
2483 case LLRP_TLV_C1G2_BLK_ERS_OP_SPC_RES:
2484 case LLRP_TLV_C1G2_BLK_PRL_OP_SPC_RES:
2485 proto_tree_add_item(param_tree, hf_llrp_access_result, tvb, suboffset, 1, ENC_NA);
2486 suboffset += 1;
2487 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2488 suboffset += 2;
2489 break;
2490 case LLRP_TLV_C1G2_BLK_PRL_STAT_RES:
2491 proto_tree_add_item(param_tree, hf_llrp_access_result, tvb, suboffset, 1, ENC_NA);
2492 suboffset += 1;
2493 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2494 suboffset += 2;
2495 suboffset = dissect_llrp_word_array(tvb, param_tree, hf_llrp_permlock_status, suboffset);
2496 break;
2497 case LLRP_TLV_CUSTOM_PARAMETER:
2498 proto_tree_add_item_ret_uint(param_tree, hf_llrp_vendor_id, tvb, suboffset, 4, ENC_BIG_ENDIAN, &num);
2499 suboffset += 4;
2500 switch(num) {
2501 case LLRP_VENDOR_IMPINJ:
2502 suboffset = dissect_llrp_impinj_parameter(tvb, pinfo, param_tree, suboffset, param_end);
2503 break;
2504 default:
2505 proto_tree_add_item(param_tree, hf_llrp_vendor_unknown, tvb, suboffset, len-4-2-2, ENC_NA);
2506 suboffset += len-4-2-2;
2507 break;
2509 break;
2511 decrement_dissection_depth(pinfo);
2512 /* Have we decoded exactly the number of bytes declared in the parameter? */
2513 if(suboffset != param_end) {
2514 /* Report problem */
2515 expert_add_info_format(pinfo, param_tree, &ei_llrp_invalid_length,
2516 "Incorrect length of parameter: %u bytes decoded, but %u bytes claimed.",
2517 suboffset - offset + 4, real_len);
2519 /* The len field includes the 4-byte parameter header that we've
2520 * already accounted for in offset */
2521 offset += real_len - 4;
2523 else
2525 type = tvb_get_uint8(tvb, offset) & 0x7F;
2527 switch (type)
2529 case LLRP_TV_ANTENNA_ID:
2530 real_len = LLRP_TV_LEN_ANTENNA_ID; break;
2531 case LLRP_TV_FIRST_SEEN_TIME_UTC:
2532 real_len = LLRP_TV_LEN_FIRST_SEEN_TIME_UTC; break;
2533 case LLRP_TV_FIRST_SEEN_TIME_UPTIME:
2534 real_len = LLRP_TV_LEN_FIRST_SEEN_TIME_UPTIME; break;
2535 case LLRP_TV_LAST_SEEN_TIME_UTC:
2536 real_len = LLRP_TV_LEN_LAST_SEEN_TIME_UTC; break;
2537 case LLRP_TV_LAST_SEEN_TIME_UPTIME:
2538 real_len = LLRP_TV_LEN_LAST_SEEN_TIME_UPTIME; break;
2539 case LLRP_TV_PEAK_RSSI:
2540 real_len = LLRP_TV_LEN_PEAK_RSSI; break;
2541 case LLRP_TV_CHANNEL_INDEX:
2542 real_len = LLRP_TV_LEN_CHANNEL_INDEX; break;
2543 case LLRP_TV_TAG_SEEN_COUNT:
2544 real_len = LLRP_TV_LEN_TAG_SEEN_COUNT; break;
2545 case LLRP_TV_RO_SPEC_ID:
2546 real_len = LLRP_TV_LEN_RO_SPEC_ID; break;
2547 case LLRP_TV_INVENTORY_PARAM_SPEC_ID:
2548 real_len = LLRP_TV_LEN_INVENTORY_PARAM_SPEC_ID; break;
2549 case LLRP_TV_C1G2_CRC:
2550 real_len = LLRP_TV_LEN_C1G2_CRC; break;
2551 case LLRP_TV_C1G2_PC:
2552 real_len = LLRP_TV_LEN_C1G2_PC; break;
2553 case LLRP_TV_EPC96:
2554 real_len = LLRP_TV_LEN_EPC96; break;
2555 case LLRP_TV_SPEC_INDEX:
2556 real_len = LLRP_TV_LEN_SPEC_INDEX; break;
2557 case LLRP_TV_CLIENT_REQ_OP_SPEC_RES:
2558 real_len = LLRP_TV_LEN_CLIENT_REQ_OP_SPEC_RES; break;
2559 case LLRP_TV_ACCESS_SPEC_ID:
2560 real_len = LLRP_TV_LEN_ACCESS_SPEC_ID; break;
2561 case LLRP_TV_OP_SPEC_ID:
2562 real_len = LLRP_TV_LEN_OP_SPEC_ID; break;
2563 case LLRP_TV_C1G2_SINGULATION_DET:
2564 real_len = LLRP_TV_LEN_C1G2_SINGULATION_DET; break;
2565 case LLRP_TV_C1G2_XPC_W1:
2566 real_len = LLRP_TV_LEN_C1G2_XPC_W1; break;
2567 case LLRP_TV_C1G2_XPC_W2:
2568 real_len = LLRP_TV_LEN_C1G2_XPC_W2; break;
2569 default:
2570 /* ???
2571 * No need to mark it, since the hf_llrp_tv_type field
2572 * will already show up as 'unknown'. */
2573 real_len = 0;
2574 break;
2577 ti = proto_tree_add_none_format(tree, hf_llrp_param, tvb,
2578 offset, real_len + 1, "TV Parameter : %s",
2579 val_to_str_ext(type, &tv_type_ext, "Unknown Type: %d"));
2580 param_tree = proto_item_add_subtree(ti, ett_llrp_param);
2582 proto_tree_add_item(param_tree, hf_llrp_tv_type, tvb,
2583 offset, 1, ENC_BIG_ENDIAN);
2584 offset++;
2586 suboffset = offset;
2587 switch (type)
2589 case LLRP_TV_ANTENNA_ID:
2590 proto_tree_add_item(param_tree, hf_llrp_antenna_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2591 break;
2592 case LLRP_TV_FIRST_SEEN_TIME_UTC:
2593 case LLRP_TV_FIRST_SEEN_TIME_UPTIME:
2594 case LLRP_TV_LAST_SEEN_TIME_UTC:
2595 case LLRP_TV_LAST_SEEN_TIME_UPTIME:
2596 proto_tree_add_item(param_tree, hf_llrp_microseconds, tvb, suboffset, 8, ENC_BIG_ENDIAN);
2597 break;
2598 case LLRP_TV_PEAK_RSSI:
2599 proto_tree_add_item(param_tree, hf_llrp_peak_rssi, tvb, suboffset, 1, ENC_NA);
2600 break;
2601 case LLRP_TV_CHANNEL_INDEX:
2602 proto_tree_add_item(param_tree, hf_llrp_channel_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2603 break;
2604 case LLRP_TV_TAG_SEEN_COUNT:
2605 proto_tree_add_item(param_tree, hf_llrp_tag_count, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2606 break;
2607 case LLRP_TV_RO_SPEC_ID:
2608 proto_tree_add_item(param_tree, hf_llrp_rospec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2609 break;
2610 case LLRP_TV_INVENTORY_PARAM_SPEC_ID:
2611 proto_tree_add_item(param_tree, hf_llrp_inventory_spec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2612 break;
2613 case LLRP_TV_C1G2_CRC:
2614 proto_tree_add_item(param_tree, hf_llrp_crc, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2615 break;
2616 case LLRP_TV_C1G2_PC:
2617 proto_tree_add_item(param_tree, hf_llrp_pc_bits, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2618 break;
2619 case LLRP_TV_EPC96:
2620 proto_tree_add_item(param_tree, hf_llrp_epc, tvb, suboffset, 96/8, ENC_NA);
2621 break;
2622 case LLRP_TV_SPEC_INDEX:
2623 proto_tree_add_item(param_tree, hf_llrp_spec_idx, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2624 break;
2625 case LLRP_TV_CLIENT_REQ_OP_SPEC_RES:
2626 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2627 break;
2628 case LLRP_TV_ACCESS_SPEC_ID:
2629 proto_tree_add_item(param_tree, hf_llrp_accessspec_id, tvb, suboffset, 4, ENC_BIG_ENDIAN);
2630 break;
2631 case LLRP_TV_OP_SPEC_ID:
2632 proto_tree_add_item(param_tree, hf_llrp_opspec_id, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2633 break;
2634 case LLRP_TV_C1G2_SINGULATION_DET:
2635 proto_tree_add_item(param_tree, hf_llrp_num_coll, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2636 proto_tree_add_item(param_tree, hf_llrp_num_empty, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2637 break;
2638 case LLRP_TV_C1G2_XPC_W1:
2639 proto_tree_add_item(param_tree, hf_llrp_xpc_w1, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2640 break;
2641 case LLRP_TV_C1G2_XPC_W2:
2642 proto_tree_add_item(param_tree, hf_llrp_xpc_w2, tvb, suboffset, 2, ENC_BIG_ENDIAN);
2643 break;
2645 /* Unlike for TLV's, real_len for TV's doesn't include the standard
2646 * header length, so just add it straight to the offset. */
2647 offset += real_len;
2650 return offset;
2653 static unsigned
2654 dissect_llrp_impinj_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned offset)
2656 uint8_t subtype;
2658 subtype = tvb_get_uint8(tvb, offset);
2660 col_append_fstr(pinfo->cinfo, COL_INFO, " (Impinj - %s)",
2661 val_to_str_ext(subtype, &impinj_msg_subtype_ext, "Unknown Type: %d"));
2662 proto_tree_add_item(tree, hf_llrp_impinj_msg_type, tvb, offset, 1, ENC_BIG_ENDIAN);
2663 offset += 1;
2665 switch(subtype) {
2666 case LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS:
2667 proto_tree_add_item(tree, hf_llrp_rfu, tvb, offset, 4, ENC_NA);
2668 offset += 4;
2669 break;
2670 case LLRP_IMPINJ_TYPE_ENABLE_EXTENSIONS_RESPONSE:
2671 /* Just parameters */
2672 break;
2673 case LLRP_IMPINJ_TYPE_SAVE_SETTINGS:
2674 proto_tree_add_item(tree, hf_llrp_save_config, tvb, offset, 1, ENC_NA);
2675 offset += 1;
2676 break;
2677 case LLRP_IMPINJ_TYPE_SAVE_SETTINGS_RESPONSE:
2678 /* Just parameters */
2679 break;
2681 /* Just return offset, parameters will be dissected by our callee */
2682 return offset;
2685 static void
2686 dissect_llrp_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
2687 uint16_t type, unsigned offset)
2689 bool ends_with_parameters;
2690 uint8_t requested_data;
2691 uint32_t vendor;
2692 proto_item *request_item, *antenna_item, *gpi_item, *gpo_item;
2693 unsigned (*dissect_custom_message)(tvbuff_t *tvb,
2694 packet_info *pinfo, proto_tree *tree, unsigned offset) = NULL;
2696 ends_with_parameters = false;
2697 switch (type)
2699 /* Simple cases just have normal TLV or TV parameters */
2700 case LLRP_TYPE_CLOSE_CONNECTION_RESPONSE:
2701 case LLRP_TYPE_GET_READER_CAPABILITIES_RESPONSE:
2702 case LLRP_TYPE_ADD_ROSPEC:
2703 case LLRP_TYPE_ADD_ROSPEC_RESPONSE:
2704 case LLRP_TYPE_DELETE_ROSPEC_RESPONSE:
2705 case LLRP_TYPE_START_ROSPEC_RESPONSE:
2706 case LLRP_TYPE_STOP_ROSPEC_RESPONSE:
2707 case LLRP_TYPE_ENABLE_ROSPEC_RESPONSE:
2708 case LLRP_TYPE_DISABLE_ROSPEC_RESPONSE:
2709 case LLRP_TYPE_GET_ROSPECS_RESPONSE:
2710 case LLRP_TYPE_ADD_ACCESSSPEC:
2711 case LLRP_TYPE_ADD_ACCESSSPEC_RESPONSE:
2712 case LLRP_TYPE_DELETE_ACCESSSPEC_RESPONSE:
2713 case LLRP_TYPE_ENABLE_ACCESSSPEC_RESPONSE:
2714 case LLRP_TYPE_DISABLE_ACCESSSPEC_RESPONSE:
2715 case LLRP_TYPE_GET_ACCESSSPECS:
2716 case LLRP_TYPE_CLIENT_REQUEST_OP:
2717 case LLRP_TYPE_CLIENT_RESQUEST_OP_RESPONSE:
2718 case LLRP_TYPE_RO_ACCESS_REPORT:
2719 case LLRP_TYPE_READER_EVENT_NOTIFICATION:
2720 case LLRP_TYPE_ERROR_MESSAGE:
2721 case LLRP_TYPE_GET_READER_CONFIG_RESPONSE:
2722 case LLRP_TYPE_SET_READER_CONFIG_RESPONSE:
2723 case LLRP_TYPE_SET_PROTOCOL_VERSION_RESPONSE:
2724 case LLRP_TYPE_GET_ACCESSSPECS_RESPONSE:
2725 case LLRP_TYPE_GET_REPORT:
2726 case LLRP_TYPE_ENABLE_EVENTS_AND_REPORTS:
2727 ends_with_parameters = true;
2728 break;
2729 /* Some just have an ROSpec ID */
2730 case LLRP_TYPE_START_ROSPEC:
2731 case LLRP_TYPE_STOP_ROSPEC:
2732 case LLRP_TYPE_ENABLE_ROSPEC:
2733 case LLRP_TYPE_DISABLE_ROSPEC:
2734 case LLRP_TYPE_DELETE_ROSPEC:
2735 proto_tree_add_item(tree, hf_llrp_rospec, tvb, offset, 4, ENC_BIG_ENDIAN);
2736 offset += 4;
2737 break;
2738 /* Some just have an AccessSpec ID */
2739 case LLRP_TYPE_ENABLE_ACCESSSPEC:
2740 case LLRP_TYPE_DELETE_ACCESSSPEC:
2741 case LLRP_TYPE_DISABLE_ACCESSSPEC:
2742 proto_tree_add_item(tree, hf_llrp_accessspec, tvb, offset, 4, ENC_BIG_ENDIAN);
2743 offset += 4;
2744 break;
2745 case LLRP_TYPE_GET_READER_CAPABILITIES:
2746 proto_tree_add_item(tree, hf_llrp_req_cap, tvb, offset, 1, ENC_BIG_ENDIAN);
2747 offset++;
2748 ends_with_parameters = true;
2749 break;
2750 /* GET_READER_CONFIG is more complicated */
2751 case LLRP_TYPE_GET_READER_CONFIG:
2752 antenna_item = proto_tree_add_item(tree, hf_llrp_antenna_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2753 offset += 2;
2755 requested_data = tvb_get_uint8(tvb, offset);
2756 request_item = proto_tree_add_item(tree, hf_llrp_req_conf, tvb,
2757 offset, 1, ENC_BIG_ENDIAN);
2758 offset++;
2760 gpi_item = proto_tree_add_item(tree, hf_llrp_gpi_port, tvb, offset, 2, ENC_BIG_ENDIAN);
2761 offset += 2;
2763 gpo_item = proto_tree_add_item(tree, hf_llrp_gpo_port, tvb, offset, 2, ENC_BIG_ENDIAN);
2764 offset += 2;
2766 switch (requested_data)
2768 case LLRP_CONF_ALL:
2769 break;
2770 case LLRP_CONF_ANTENNA_PROPERTIES:
2771 case LLRP_CONF_ANTENNA_CONFIGURATION:
2772 /* Ignore both GPI and GPO ports */
2773 proto_item_append_text(gpi_item, " (Ignored)");
2774 proto_item_append_text(gpo_item, " (Ignored)");
2775 break;
2776 case LLRP_CONF_IDENTIFICATION:
2777 case LLRP_CONF_RO_REPORT_SPEC:
2778 case LLRP_CONF_READER_EVENT_NOTIFICATION_SPEC:
2779 case LLRP_CONF_ACCESS_REPORT_SPEC:
2780 case LLRP_CONF_LLRP_CONFIGURATION_STATE:
2781 case LLRP_CONF_KEEPALIVE_SPEC:
2782 case LLRP_CONF_EVENTS_AND_REPORTS:
2783 /* Ignore antenna ID */
2784 proto_item_append_text(antenna_item, " (Ignored)");
2785 /* Ignore both GPI and GPO ports */
2786 proto_item_append_text(gpi_item, " (Ignored)");
2787 proto_item_append_text(gpo_item, " (Ignored)");
2788 break;
2789 case LLRP_CONF_GPI_PORT_CURRENT_STATE:
2790 /* Ignore antenna ID */
2791 proto_item_append_text(antenna_item, " (Ignored)");
2792 /* Ignore GPO port */
2793 proto_item_append_text(gpo_item, " (Ignored)");
2794 break;
2795 case LLRP_CONF_GPO_WRITE_DATA:
2796 /* Ignore antenna ID */
2797 proto_item_append_text(antenna_item, " (Ignored)");
2798 /* Ignore GPI port */
2799 proto_item_append_text(gpi_item, " (Ignored)");
2800 break;
2801 default:
2802 /* Ignore antenna ID */
2803 proto_item_append_text(antenna_item, " (Ignored)");
2804 /* Tell the user that we are confused */
2805 expert_add_info_format(pinfo, request_item, &ei_llrp_req_conf,
2806 "Unrecognized configuration request: %u",
2807 requested_data);
2808 /* Ignore both GPI and GPO ports */
2809 proto_item_append_text(gpi_item, " (Ignored)");
2810 proto_item_append_text(gpo_item, " (Ignored)");
2811 break;
2813 ends_with_parameters = true;
2814 break;
2815 /* END GET_READER_CONFIG */
2816 /* Misc */
2817 case LLRP_TYPE_SET_READER_CONFIG:
2818 proto_tree_add_item(tree, hf_llrp_rest_fact, tvb, offset, 1, ENC_NA);
2819 offset++;
2820 ends_with_parameters = true;
2821 break;
2822 case LLRP_TYPE_SET_PROTOCOL_VERSION:
2823 proto_tree_add_item(tree, hf_llrp_version, tvb, offset, 1, ENC_BIG_ENDIAN);
2824 break;
2825 case LLRP_TYPE_GET_SUPPORTED_VERSION_RESPONSE:
2826 proto_tree_add_item(tree, hf_llrp_cur_ver, tvb, offset, 1, ENC_BIG_ENDIAN);
2827 offset++;
2828 proto_tree_add_item(tree, hf_llrp_sup_ver, tvb, offset, 1, ENC_BIG_ENDIAN);
2829 offset++;
2830 ends_with_parameters = true;
2831 break;
2832 case LLRP_TYPE_CUSTOM_MESSAGE:
2833 vendor = tvb_get_ntohl(tvb, offset);
2834 proto_tree_add_item(tree, hf_llrp_vendor, tvb, offset, 4, ENC_BIG_ENDIAN);
2835 offset += 4;
2836 /* Do vendor specific dissection */
2837 switch(vendor) {
2838 case LLRP_VENDOR_IMPINJ:
2839 dissect_custom_message = dissect_llrp_impinj_message;
2840 ends_with_parameters = true;
2841 break;
2843 if (dissect_custom_message)
2844 offset = dissect_custom_message(tvb, pinfo, tree, offset);
2845 break;
2846 /* Some have no extra data expected */
2847 case LLRP_TYPE_KEEPALIVE:
2848 case LLRP_TYPE_KEEPALIVE_ACK:
2849 case LLRP_TYPE_CLOSE_CONNECTION:
2850 case LLRP_TYPE_GET_ROSPECS:
2851 case LLRP_TYPE_GET_SUPPORTED_VERSION:
2852 break;
2853 default:
2854 /* We shouldn't be called if we don't already recognize the value */
2855 DISSECTOR_ASSERT_NOT_REACHED();
2857 if(ends_with_parameters) {
2858 offset = dissect_llrp_parameters(tvb, pinfo, tree, offset, tvb_reported_length(tvb), 0);
2860 if(tvb_reported_length_remaining(tvb, offset) != 0) {
2861 /* Report problem */
2862 expert_add_info_format(pinfo, tree, &ei_llrp_invalid_length,
2863 "Incorrect length of message: %u bytes decoded, but %u bytes available.",
2864 offset, tvb_reported_length(tvb));
2868 /* Code to actually dissect the packets */
2869 static int
2870 dissect_llrp_packet(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
2872 proto_item *ti;
2873 proto_tree *llrp_tree;
2874 uint16_t type;
2875 uint32_t len;
2876 unsigned offset = 0;
2878 /* Check that there's enough data */
2879 if (tvb_reported_length(tvb) < LLRP_HEADER_LENGTH) {
2880 return 0;
2883 /* Make entries in Protocol column and Info column on summary display */
2884 col_set_str(pinfo->cinfo, COL_PROTOCOL, "LLRP");
2886 col_set_str(pinfo->cinfo, COL_INFO, "LLRP Message");
2888 type = tvb_get_ntohs(tvb, offset) & 0x03FF;
2890 col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)",
2891 val_to_str_ext(type, &message_types_ext, "Unknown Type: %d"));
2893 ti = proto_tree_add_item(tree, proto_llrp, tvb, offset, -1, ENC_NA);
2894 llrp_tree = proto_item_add_subtree(ti, ett_llrp);
2896 proto_tree_add_item(llrp_tree, hf_llrp_version, tvb, offset, 1, ENC_BIG_ENDIAN);
2897 proto_tree_add_item(llrp_tree, hf_llrp_type, tvb, offset, 2, ENC_BIG_ENDIAN);
2898 offset += 2;
2900 ti = proto_tree_add_item(llrp_tree, hf_llrp_length, tvb, offset, 4, ENC_BIG_ENDIAN);
2901 len = tvb_get_ntohl(tvb, offset);
2902 if (len != tvb_reported_length(tvb))
2904 expert_add_info_format(pinfo, ti, &ei_llrp_invalid_length,
2905 "Incorrect length field: claimed %u, but have %u.",
2906 len, tvb_reported_length(tvb));
2908 offset += 4;
2910 proto_tree_add_item(llrp_tree, hf_llrp_id, tvb, offset, 4, ENC_BIG_ENDIAN);
2911 offset += 4;
2913 if (try_val_to_str_ext(type, &message_types_ext))
2914 dissect_llrp_message(tvb, pinfo, llrp_tree, type, offset);
2916 return tvb_captured_length(tvb);
2919 /* Determine length of LLRP message */
2920 static unsigned
2921 get_llrp_message_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset, void *data _U_)
2923 /* Peek into the header to determine the total message length */
2924 return (unsigned)tvb_get_ntohl(tvb, offset+2);
2927 /* The main dissecting routine */
2928 static int
2929 dissect_llrp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
2931 tcp_dissect_pdus(tvb, pinfo, tree, true, LLRP_HEADER_LENGTH,
2932 get_llrp_message_len, dissect_llrp_packet, data);
2933 return tvb_captured_length(tvb);
2936 void
2937 proto_register_llrp(void)
2939 /* Setup list of header fields See Section 1.6.1 for details */
2940 static hf_register_info hf[] = {
2941 { &hf_llrp_version,
2942 { "Version", "llrp.version", FT_UINT8, BASE_DEC, VALS(llrp_versions), 0x1C,
2943 NULL, HFILL }},
2945 { &hf_llrp_type,
2946 { "Type", "llrp.type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &message_types_ext, 0x03FF,
2947 NULL, HFILL }},
2949 { &hf_llrp_length,
2950 { "Length", "llrp.length", FT_UINT32, BASE_DEC, NULL, 0,
2951 NULL, HFILL }},
2953 { &hf_llrp_id,
2954 { "ID", "llrp.id", FT_UINT32, BASE_DEC, NULL, 0,
2955 NULL, HFILL }},
2957 { &hf_llrp_cur_ver,
2958 { "Current Version", "llrp.cur_ver", FT_UINT8, BASE_DEC, VALS(llrp_versions), 0,
2959 NULL, HFILL }},
2961 { &hf_llrp_sup_ver,
2962 { "Supported Version", "llrp.sup_ver", FT_UINT8, BASE_DEC, VALS(llrp_versions), 0,
2963 "The max supported protocol version.", HFILL }},
2965 { &hf_llrp_req_cap,
2966 { "Requested Capabilities", "llrp.req_cap", FT_UINT8, BASE_DEC, VALS(capabilities_request), 0,
2967 NULL, HFILL }},
2969 { &hf_llrp_req_conf,
2970 { "Requested Configuration", "llrp.req_conf", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &config_request_ext, 0,
2971 NULL, HFILL }},
2973 { &hf_llrp_rospec,
2974 { "ROSpec ID", "llrp.rospec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_all_rospecs), 0,
2975 NULL, HFILL }},
2977 { &hf_llrp_antenna_id,
2978 { "Antenna ID", "llrp.antenna_id", FT_UINT16, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_all_antenna), 0,
2979 NULL, HFILL }},
2981 { &hf_llrp_gpi_port,
2982 { "GPI Port Number", "llrp.gpi_port", FT_UINT16, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_all_gpi_ports), 0,
2983 NULL, HFILL }},
2985 { &hf_llrp_gpo_port,
2986 { "GPO Port Number", "llrp.gpo_port", FT_UINT16, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_all_gpo_ports), 0,
2987 NULL, HFILL }},
2989 { &hf_llrp_rest_fact,
2990 { "Restore Factory Settings", "llrp.rest_fact", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
2991 NULL, HFILL }},
2993 { &hf_llrp_accessspec,
2994 { "Access Spec ID", "llrp.accessspec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_all_access_specs), 0,
2995 NULL, HFILL }},
2997 { &hf_llrp_vendor,
2998 { "Vendor ID", "llrp.vendor", FT_UINT32, BASE_DEC, VALS(llrp_vendors), 0,
2999 NULL, HFILL }},
3001 { &hf_llrp_impinj_msg_type,
3002 { "Subtype", "llrp.impinj.type", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &impinj_msg_subtype_ext, 0,
3003 "Subtype specified by vendor", HFILL }},
3005 { &hf_llrp_tlv_type,
3006 { "Type", "llrp.tlv_type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &tlv_type_ext, 0x03FF,
3007 "The type of TLV.", HFILL }},
3009 { &hf_llrp_tv_type,
3010 { "Type", "llrp.tv_type", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &tv_type_ext, 0x7F,
3011 "The type of TV.", HFILL }},
3013 { &hf_llrp_tlv_len,
3014 { "Length", "llrp.tlv_len", FT_UINT16, BASE_DEC, NULL, 0,
3015 "The length of this TLV.", HFILL }},
3017 { &hf_llrp_param,
3018 { "Parameter", "llrp.param", FT_NONE, BASE_NONE, NULL, 0,
3019 NULL, HFILL }},
3021 { &hf_llrp_num_gpi,
3022 { "Number of GPI ports", "llrp.param.num_gpi", FT_UINT16, BASE_DEC, NULL, 0,
3023 NULL, HFILL }},
3025 { &hf_llrp_num_gpo,
3026 { "Number of GPO ports", "llrp.param.num_gpo", FT_UINT16, BASE_DEC, NULL, 0,
3027 NULL, HFILL }},
3029 { &hf_llrp_microseconds,
3030 { "Microseconds", "llrp.param.microseconds", FT_UINT64, BASE_DEC, NULL, 0,
3031 NULL, HFILL }},
3033 { &hf_llrp_max_supported_antenna,
3034 { "Max number of antenna supported", "llrp.param.max_supported_antenna", FT_UINT16, BASE_DEC, NULL, 0,
3035 NULL, HFILL }},
3037 { &hf_llrp_can_set_antenna_prop,
3038 { "Can set antenna properties", "llrp.param.can_set_antenna_prop", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x8000,
3039 NULL, HFILL }},
3041 { &hf_llrp_has_utc_clock,
3042 { "Has UTC clock capabilities", "llrp.param.has_utc_clock", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x4000,
3043 NULL, HFILL }},
3045 { &hf_llrp_device_manufacturer,
3046 { "Device manufacturer name", "llrp.param.device_manufacturer", FT_UINT32, BASE_DEC, NULL, 0,
3047 NULL, HFILL }},
3049 { &hf_llrp_model,
3050 { "Model name", "llrp.param.model", FT_UINT32, BASE_DEC, NULL, 0,
3051 NULL, HFILL }},
3053 { &hf_llrp_firmware_version,
3054 { "Reader firmware version", "llrp.param.firmware_version", FT_UINT_STRING, BASE_NONE, NULL, 0,
3055 NULL, HFILL }},
3057 { &hf_llrp_max_receive_sense,
3058 { "Maximum sensitivity value", "llrp.param.max_receive_sense", FT_UINT16, BASE_DEC, NULL, 0,
3059 NULL, HFILL }},
3061 { &hf_llrp_index,
3062 { "Index", "llrp.param.index", FT_UINT16, BASE_DEC, NULL, 0,
3063 NULL, HFILL }},
3065 { &hf_llrp_receive_sense,
3066 { "Receive sensitivity value", "llrp.param.receive_sense", FT_UINT16, BASE_DEC, NULL, 0,
3067 NULL, HFILL }},
3069 { &hf_llrp_receive_sense_index_min,
3070 { "Receive sensitivity index min", "llrp.param.receive_sense_index_min", FT_UINT16, BASE_DEC, NULL, 0,
3071 NULL, HFILL }},
3073 { &hf_llrp_receive_sense_index_max,
3074 { "Receive sensitivity index max", "llrp.param.receive_sense_index_max", FT_UINT16, BASE_DEC, NULL, 0,
3075 NULL, HFILL }},
3077 { &hf_llrp_num_protocols,
3078 { "Number of protocols", "llrp.param.num_protocols", FT_UINT16, BASE_DEC, NULL, 0,
3079 NULL, HFILL }},
3081 { &hf_llrp_protocol_id,
3082 { "Protocol ID", "llrp.param.protocol_id", FT_UINT8, BASE_DEC | BASE_RANGE_STRING, RVALS(protocol_id), 0,
3083 NULL, HFILL }},
3085 { &hf_llrp_can_do_survey,
3086 { "Can do RF survey", "llrp.param.can_do_survey", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3087 NULL, HFILL }},
3089 { &hf_llrp_can_report_buffer_warning,
3090 { "Can report buffer fill warning", "llrp.param.can_report_buffer_warning", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x40,
3091 NULL, HFILL }},
3093 { &hf_llrp_support_client_opspec,
3094 { "Support client request OpSpec", "llrp.param.support_client_opspec", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
3095 NULL, HFILL }},
3097 { &hf_llrp_can_stateaware,
3098 { "Can do tag inventory state aware singulation", "llrp.param.can_stateaware", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
3099 NULL, HFILL }},
3101 { &hf_llrp_support_holding,
3102 { "Support event and report holding", "llrp.param.support_holding", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x08,
3103 NULL, HFILL }},
3105 { &hf_llrp_max_priority_supported,
3106 { "Max priority level supported", "llrp.param.max_priority_supported", FT_UINT8, BASE_DEC, NULL, 0,
3107 NULL, HFILL }},
3109 { &hf_llrp_client_opspec_timeout,
3110 { "Client request OpSpec timeout", "llrp.param.client_opspec_timeout", FT_UINT16, BASE_DEC, NULL, 0,
3111 NULL, HFILL }},
3113 { &hf_llrp_max_num_rospec,
3114 { "Maximum number of ROSpecs", "llrp.param.max_num_rospec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3115 NULL, HFILL }},
3117 { &hf_llrp_max_num_spec_per_rospec,
3118 { "Maximum number of spec per ROSpec", "llrp.param.max_num_spec_per_rospec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3119 NULL, HFILL }},
3121 { &hf_llrp_max_num_inventory_per_aispec,
3122 { "Maximum number of Inventory Spec per AISpec", "llrp.param.max_num_inventory_per_aispec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3123 NULL, HFILL }},
3125 { &hf_llrp_max_num_accessspec,
3126 { "Maximum number of AccessSpec", "llrp.param.max_num_accessspec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3127 NULL, HFILL }},
3129 { &hf_llrp_max_num_opspec_per_accressspec,
3130 { "Maximum number of OpSpec per AccessSpec", "llrp.param.max_num_opspec_per_accressspec", FT_UINT32, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3131 NULL, HFILL }},
3133 /* TODO add translation */
3134 { &hf_llrp_country_code,
3135 { "Country code", "llrp.param.country_code", FT_UINT16, BASE_DEC, NULL, 0,
3136 NULL, HFILL }},
3138 { &hf_llrp_comm_standard,
3139 { "Communication standard", "llrp.param.comm_standard", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &comm_standard_ext, 0,
3140 NULL, HFILL }},
3142 { &hf_llrp_transmit_power,
3143 { "Transmit power value", "llrp.param.transmit_power", FT_UINT16, BASE_DEC, NULL, 0,
3144 NULL, HFILL }},
3146 { &hf_llrp_hopping,
3147 { "Hopping", "llrp.param.hopping", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3148 NULL, HFILL }},
3150 { &hf_llrp_hop_table_id,
3151 { "Hop table ID", "llrp.param.hop_table_id", FT_UINT16, BASE_DEC, NULL, 0,
3152 NULL, HFILL }},
3154 { &hf_llrp_rfu,
3155 { "Reserved for future use", "llrp.param.rfu", FT_BYTES, BASE_NONE, NULL, 0,
3156 NULL, HFILL }},
3158 { &hf_llrp_num_hops,
3159 { "Number of hops", "llrp.param.num_hops", FT_UINT16, BASE_DEC, NULL, 0,
3160 NULL, HFILL }},
3162 { &hf_llrp_frequency,
3163 { "Frequency", "llrp.param.frequency", FT_UINT32, BASE_DEC, NULL, 0,
3164 NULL, HFILL }},
3166 { &hf_llrp_num_freqs,
3167 { "Number of frequencies", "llrp.param.num_freqs", FT_UINT16, BASE_DEC, NULL, 0,
3168 NULL, HFILL }},
3170 { &hf_llrp_min_freq,
3171 { "Minimum frequency", "llrp.param.min_freq", FT_UINT32, BASE_DEC, NULL, 0,
3172 NULL, HFILL }},
3174 { &hf_llrp_max_freq,
3175 { "Maximum frequency", "llrp.param.max_freq", FT_UINT32, BASE_DEC, NULL, 0,
3176 NULL, HFILL }},
3178 { &hf_llrp_rospec_id,
3179 { "ROSpec ID", "llrp.param.rospec_id", FT_UINT32, BASE_DEC, NULL, 0,
3180 NULL, HFILL }},
3182 { &hf_llrp_priority,
3183 { "Priority", "llrp.param.priority", FT_UINT8, BASE_DEC, NULL, 0,
3184 NULL, HFILL }},
3186 { &hf_llrp_cur_state,
3187 { "Current state", "llrp.param.cur_state", FT_UINT8, BASE_DEC, NULL, 0,
3188 NULL, HFILL }},
3190 { &hf_llrp_rospec_start_trig_type,
3191 { "ROSpec start trigger type", "llrp.param.rospec_start_trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3192 NULL, HFILL }},
3194 { &hf_llrp_offset,
3195 { "Offset", "llrp.param.offset", FT_UINT32, BASE_DEC, NULL, 0,
3196 NULL, HFILL }},
3198 { &hf_llrp_period,
3199 { "Period", "llrp.param.period", FT_UINT32, BASE_DEC, NULL, 0,
3200 NULL, HFILL }},
3202 { &hf_llrp_gpi_event,
3203 { "GPI event", "llrp.param.gpi_event", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3204 NULL, HFILL }},
3206 { &hf_llrp_timeout,
3207 { "Timeout", "llrp.param.timeout", FT_UINT32, BASE_DEC, NULL, 0,
3208 NULL, HFILL }},
3210 { &hf_llrp_rospec_stop_trig_type,
3211 { "ROSpec stop trigger type", "llrp.param.rospec_stop_trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3212 NULL, HFILL }},
3214 { &hf_llrp_duration_trig,
3215 { "Duration trigger value", "llrp.param.duration_trig", FT_UINT32, BASE_DEC, NULL, 0,
3216 NULL, HFILL }},
3218 { &hf_llrp_antenna_count,
3219 { "Antenna count", "llrp.param.antenna_count", FT_UINT16, BASE_DEC, NULL, 0,
3220 NULL, HFILL }},
3222 { &hf_llrp_antenna,
3223 { "Antenna ID", "llrp.param.antenna", FT_UINT16, BASE_DEC, NULL, 0,
3224 NULL, HFILL }},
3226 { &hf_llrp_aispec_stop_trig_type,
3227 { "AISpec stop trigger type", "llrp.param.aispec_stop_trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3228 NULL, HFILL }},
3230 { &hf_llrp_trig_type,
3231 { "Trigger type", "llrp.param.trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3232 NULL, HFILL }},
3234 { &hf_llrp_number_of_tags,
3235 { "Number of tags", "llrp.param.number_of_tags", FT_UINT16, BASE_DEC, NULL, 0,
3236 NULL, HFILL }},
3238 { &hf_llrp_number_of_attempts,
3239 { "Number of attempts", "llrp.param.number_of_attempts", FT_UINT16, BASE_DEC, NULL, 0,
3240 NULL, HFILL }},
3242 { &hf_llrp_t,
3243 { "T", "llrp.param.t", FT_UINT16, BASE_DEC, NULL, 0,
3244 NULL, HFILL }},
3246 { &hf_llrp_inventory_spec_id,
3247 { "Inventory parameter spec id", "llrp.param.inventory_spec_id", FT_UINT16, BASE_DEC, NULL, 0,
3248 NULL, HFILL }},
3250 { &hf_llrp_start_freq,
3251 { "Start frequency", "llrp.param.start_freq", FT_UINT32, BASE_DEC, NULL, 0,
3252 NULL, HFILL }},
3254 { &hf_llrp_stop_freq,
3255 { "Stop frequency", "llrp.param.stop_freq", FT_UINT32, BASE_DEC, NULL, 0,
3256 NULL, HFILL }},
3258 { &hf_llrp_stop_trig_type,
3259 { "Stop trigger type", "llrp.param.stop_trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3260 NULL, HFILL }},
3262 { &hf_llrp_n_4,
3263 { "N", "llrp.param.n_4", FT_UINT32, BASE_DEC, NULL, 0,
3264 NULL, HFILL }},
3266 { &hf_llrp_duration,
3267 { "Duration", "llrp.param.duration", FT_UINT32, BASE_DEC, NULL, 0,
3268 NULL, HFILL }},
3270 { &hf_llrp_accessspec_id,
3271 { "AccessSpec ID", "llrp.param.accessspec_id", FT_UINT32, BASE_DEC, NULL, 0,
3272 NULL, HFILL }},
3274 { &hf_llrp_access_cur_state,
3275 { "Current state", "llrp.param.access_cur_state", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3276 NULL, HFILL }},
3278 { &hf_llrp_access_stop_trig_type,
3279 { "AccessSpec Stop trigger", "llrp.param.access_stop_trig_type", FT_UINT8, BASE_DEC, NULL, 0,
3280 NULL, HFILL }},
3282 { &hf_llrp_operation_count,
3283 { "Operation count value", "llrp.param.operation_count", FT_UINT16, BASE_DEC, NULL, 0,
3284 NULL, HFILL }},
3286 { &hf_llrp_opspec_id,
3287 { "OpSpec ID", "llrp.param.opspec_id", FT_UINT16, BASE_DEC, NULL, 0,
3288 NULL, HFILL }},
3290 { &hf_llrp_conf_value,
3291 { "Configuration value", "llrp.param.conf_value", FT_UINT32, BASE_DEC, NULL, 0,
3292 NULL, HFILL }},
3294 { &hf_llrp_id_type,
3295 { "ID type", "llrp.param.id_type", FT_UINT8, BASE_DEC, VALS(id_type), 0,
3296 NULL, HFILL }},
3298 { &hf_llrp_reader_id,
3299 { "Reader ID", "llrp.param.reader_id", FT_UINT_BYTES, BASE_NONE, NULL, 0,
3300 NULL, HFILL }},
3302 { &hf_llrp_gpo_data,
3303 { "GPO data", "llrp.param.gpo_data", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3304 NULL, HFILL }},
3306 { &hf_llrp_keepalive_trig_type,
3307 { "KeepAlive trigger type", "llrp.param.keepalive_trig_type", FT_UINT8, BASE_DEC, VALS(keepalive_type), 0,
3308 NULL, HFILL }},
3310 { &hf_llrp_time_iterval,
3311 { "Time interval", "llrp.param.time_iterval", FT_UINT32, BASE_DEC, NULL, 0,
3312 NULL, HFILL }},
3314 { &hf_llrp_antenna_connected,
3315 { "Antenna connected", "llrp.param.antenna_connected", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3316 NULL, HFILL }},
3318 { &hf_llrp_antenna_gain,
3319 { "Antenna gain", "llrp.param.antenna_gain", FT_UINT16, BASE_DEC, NULL, 0,
3320 NULL, HFILL }},
3322 { &hf_llrp_receiver_sense,
3323 { "Receiver sensitivity", "llrp.param.receiver_sense", FT_UINT16, BASE_DEC, NULL, 0,
3324 NULL, HFILL }},
3326 { &hf_llrp_channel_idx,
3327 { "Channel index", "llrp.param.channel_idx", FT_UINT16, BASE_DEC, NULL, 0,
3328 NULL, HFILL }},
3330 { &hf_llrp_gpi_config,
3331 { "GPI config", "llrp.param.gpi_config", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3332 NULL, HFILL }},
3334 { &hf_llrp_gpi_state,
3335 { "GPI state", "llrp.param.gpi_state", FT_UINT16, BASE_DEC, NULL, 0,
3336 NULL, HFILL }},
3338 { &hf_llrp_hold_events_and_reports,
3339 { "Hold events and reports upon reconnect", "llrp.param.hold_events_and_reports", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3340 NULL, HFILL }},
3342 { &hf_llrp_ro_report_trig,
3343 { "RO report trigger", "llrp.param.ro_report_trig", FT_UINT8, BASE_DEC, NULL, 0,
3344 NULL, HFILL }},
3346 { &hf_llrp_n_2,
3347 { "N", "llrp.param.n_2", FT_UINT16, BASE_DEC, NULL, 0,
3348 NULL, HFILL }},
3350 { &hf_llrp_enable_rospec_id,
3351 { "Enable ROSpec ID", "llrp.param.enable_rospec_id", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x8000,
3352 NULL, HFILL }},
3354 { &hf_llrp_enable_spec_idx,
3355 { "Enable spec index", "llrp.param.enable_spec_idx", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x4000,
3356 NULL, HFILL }},
3358 { &hf_llrp_enable_inv_spec_id,
3359 { "Enable inventory spec ID", "llrp.param.enable_inv_spec_id", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x2000,
3360 NULL, HFILL }},
3362 { &hf_llrp_enable_antenna_id,
3363 { "Enable antenna ID", "llrp.param.enable_antenna_id", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x1000,
3364 NULL, HFILL }},
3366 { &hf_llrp_enable_channel_idx,
3367 { "Enable channel index", "llrp.param.enable_channel_idx", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0800,
3368 NULL, HFILL }},
3370 { &hf_llrp_enable_peak_rssi,
3371 { "Enable peak RSSI", "llrp.param.enable_peak_rssi", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0400,
3372 NULL, HFILL }},
3374 { &hf_llrp_enable_first_seen,
3375 { "Enable first seen timestamp", "llrp.param.enable_first_seen", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0200,
3376 NULL, HFILL }},
3378 { &hf_llrp_enable_last_seen,
3379 { "Enable last seen timestamp", "llrp.param.enable_last_seen", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0100,
3380 NULL, HFILL }},
3382 { &hf_llrp_enable_seen_count,
3383 { "Enable tag seen count", "llrp.param.enable_seen_count", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0080,
3384 NULL, HFILL }},
3386 { &hf_llrp_enable_accessspec_id,
3387 { "Enable AccessSpec ID", "llrp.param.enable_accessspec_id", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x0040,
3388 NULL, HFILL }},
3390 { &hf_llrp_access_report_trig,
3391 { "Access report trigger", "llrp.param.access_report_trig", FT_UINT8, BASE_DEC, NULL, 0,
3392 NULL, HFILL }},
3394 { &hf_llrp_length_bits,
3395 { "Bit field length (bits)", "llrp.param.length_bits", FT_UINT16, BASE_DEC, NULL, 0,
3396 NULL, HFILL }},
3398 { &hf_llrp_epc,
3399 { "EPC", "llrp.param.epc", FT_BYTES, BASE_NONE, NULL, 0,
3400 NULL, HFILL }},
3402 { &hf_llrp_spec_idx,
3403 { "Spec index", "llrp.param.spec_idx", FT_UINT16, BASE_DEC, NULL, 0,
3404 NULL, HFILL }},
3406 { &hf_llrp_peak_rssi,
3407 { "Peak RSSI", "llrp.param.peak_rssi", FT_UINT8, BASE_DEC, NULL, 0,
3408 NULL, HFILL }},
3410 { &hf_llrp_tag_count,
3411 { "Tag count", "llrp.param.tag_count", FT_UINT16, BASE_DEC, NULL, 0,
3412 NULL, HFILL }},
3414 { &hf_llrp_bandwidth,
3415 { "Bandwidth", "llrp.param.bandwidth", FT_UINT32, BASE_DEC, NULL, 0,
3416 NULL, HFILL }},
3418 { &hf_llrp_average_rssi,
3419 { "Average RSSI", "llrp.param.average_rssi", FT_UINT8, BASE_DEC, NULL, 0,
3420 NULL, HFILL }},
3422 { &hf_llrp_notif_state,
3423 { "Notification state", "llrp.param.notif_state", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3424 NULL, HFILL }},
3426 { &hf_llrp_event_type,
3427 { "Event type", "llrp.param.event_type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &event_type_ext, 0,
3428 NULL, HFILL }},
3430 { &hf_llrp_next_chan_idx,
3431 { "Next channel index", "llrp.param.next_chan_idx", FT_UINT16, BASE_DEC, NULL, 0,
3432 NULL, HFILL }},
3434 { &hf_llrp_roevent_type,
3435 { "Event type", "llrp.param.roevent_type", FT_UINT8, BASE_DEC, VALS(roevent_type), 0,
3436 NULL, HFILL }},
3438 { &hf_llrp_prem_rospec_id,
3439 { "Preempting ROSpec ID", "llrp.param.prem_rospec_id", FT_UINT32, BASE_DEC, NULL, 0,
3440 NULL, HFILL }},
3442 { &hf_llrp_buffer_full_percentage,
3443 { "Report Buffer percentage full", "llrp.param.buffer_full_percentage", FT_UINT8, BASE_DEC, NULL, 0,
3444 NULL, HFILL }},
3446 { &hf_llrp_message,
3447 { "Message", "llrp.param.message", FT_UINT_STRING, BASE_NONE, NULL, 0,
3448 NULL, HFILL }},
3450 { &hf_llrp_rfevent_type,
3451 { "Event type", "llrp.param.rfevent_type", FT_UINT8, BASE_DEC, VALS(rfevent_type), 0,
3452 NULL, HFILL }},
3454 { &hf_llrp_aievent_type,
3455 { "Event type", "llrp.param.aievent_type", FT_UINT8, BASE_DEC, VALS(aievent_type), 0,
3456 NULL, HFILL }},
3458 { &hf_llrp_antenna_event_type,
3459 { "Event type", "llrp.param.antenna_event_type", FT_UINT8, BASE_DEC, VALS(antenna_event_type), 0,
3460 NULL, HFILL }},
3462 { &hf_llrp_conn_status,
3463 { "Status", "llrp.param.conn_status", FT_UINT16, BASE_DEC, VALS(connection_status), 0,
3464 NULL, HFILL }},
3466 { &hf_llrp_loop_count,
3467 { "Loop count", "llrp.param.loop_count", FT_UINT32, BASE_DEC, NULL, 0,
3468 NULL, HFILL }},
3470 { &hf_llrp_status_code,
3471 { "Status code", "llrp.param.status_code", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &status_code_ext, 0,
3472 NULL, HFILL }},
3474 { &hf_llrp_error_desc,
3475 { "Error Description", "llrp.param.error_desc", FT_UINT_STRING, BASE_NONE, NULL, 0,
3476 NULL, HFILL }},
3478 { &hf_llrp_field_num,
3479 { "Field number", "llrp.param.field_num", FT_UINT16, BASE_DEC, NULL, 0,
3480 NULL, HFILL }},
3482 { &hf_llrp_error_code,
3483 { "Error code", "llrp.param.error_code", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &status_code_ext, 0,
3484 NULL, HFILL }},
3486 { &hf_llrp_parameter_type,
3487 { "Parameter type", "llrp.param.parameter_type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &tlv_type_ext, 0,
3488 NULL, HFILL }},
3490 { &hf_llrp_can_support_block_erase,
3491 { "Can support block erase", "llrp.param.can_support_block_erase", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3492 NULL, HFILL }},
3494 { &hf_llrp_can_support_block_write,
3495 { "Can support block write", "llrp.param.can_support_block_write", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x40,
3496 NULL, HFILL }},
3498 { &hf_llrp_can_support_block_permalock,
3499 { "Can support block permalock", "llrp.param.can_support_block_permalock", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
3500 NULL, HFILL }},
3502 { &hf_llrp_can_support_tag_recomm,
3503 { "Can support tag recommisioning", "llrp.param.can_support_tag_recomm", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
3504 NULL, HFILL }},
3506 { &hf_llrp_can_support_UMI_method2,
3507 { "Can support UMI method 2", "llrp.param.can_support_UMI_method2", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x08,
3508 NULL, HFILL }},
3510 { &hf_llrp_can_support_XPC,
3511 { "Can support XPC", "llrp.param.can_support_XPC", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
3512 NULL, HFILL }},
3514 { &hf_llrp_max_num_filter_per_query,
3515 { "Maximum number of select filters per query", "llrp.param.max_num_filter_per_query", FT_UINT16, BASE_DEC|BASE_SPECIAL_VALS, VALS(unique_no_limit), 0,
3516 NULL, HFILL }},
3518 { &hf_llrp_mode_ident,
3519 { "Mode identifier", "llrp.param.mode_ident", FT_UINT32, BASE_DEC, NULL, 0,
3520 NULL, HFILL }},
3522 { &hf_llrp_DR,
3523 { "DR", "llrp.param.DR", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3524 NULL, HFILL }},
3526 { &hf_llrp_hag_conformance,
3527 { "EPC HAG T&C Conformance", "llrp.param.hag_conformance", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x40,
3528 NULL, HFILL }},
3530 { &hf_llrp_mod,
3531 { "M", "llrp.param.mod", FT_UINT8, BASE_DEC, NULL, 0,
3532 NULL, HFILL }},
3534 { &hf_llrp_flm,
3535 { "Forward link modulation", "llrp.param.flm", FT_UINT8, BASE_DEC, NULL, 0,
3536 NULL, HFILL }},
3538 { &hf_llrp_m,
3539 { "Spectral mask indicator", "llrp.param.m", FT_UINT8, BASE_DEC, NULL, 0,
3540 NULL, HFILL }},
3542 { &hf_llrp_bdr,
3543 { "BDR", "llrp.param.bdr", FT_UINT32, BASE_DEC, NULL, 0,
3544 NULL, HFILL }},
3546 { &hf_llrp_pie,
3547 { "PIE", "llrp.param.pie", FT_UINT32, BASE_DEC, NULL, 0,
3548 NULL, HFILL }},
3550 { &hf_llrp_min_tari,
3551 { "Minimum tari", "llrp.param.min_tari", FT_UINT32, BASE_DEC, NULL, 0,
3552 NULL, HFILL }},
3554 { &hf_llrp_max_tari,
3555 { "Maximum tari", "llrp.param.max_tari", FT_UINT32, BASE_DEC, NULL, 0,
3556 NULL, HFILL }},
3558 { &hf_llrp_step_tari,
3559 { "Tari step", "llrp.param.step_tari", FT_UINT32, BASE_DEC, NULL, 0,
3560 NULL, HFILL }},
3562 { &hf_llrp_inventory_state_aware,
3563 { "Tag inventory state aware", "llrp.param.inventory_state_aware", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3564 NULL, HFILL }},
3566 { &hf_llrp_trunc,
3567 { "T", "llrp.param.trunc", FT_UINT8, BASE_DEC, NULL, 0xC0,
3568 NULL, HFILL }},
3570 { &hf_llrp_mb,
3571 { "MB", "llrp.param.mb", FT_UINT8, BASE_DEC, NULL, 0xC0,
3572 NULL, HFILL }},
3574 { &hf_llrp_pointer,
3575 { "Pointer", "llrp.param.pointer", FT_UINT16, BASE_DEC_HEX, NULL, 0,
3576 NULL, HFILL }},
3578 { &hf_llrp_tag_mask,
3579 { "Tag mask", "llrp.param.tag_mask", FT_BYTES, BASE_NONE, NULL, 0,
3580 NULL, HFILL }},
3582 { &hf_llrp_aware_filter_target,
3583 { "Target", "llrp.param.aware_filter_target", FT_UINT8, BASE_DEC, NULL, 0,
3584 NULL, HFILL }},
3586 { &hf_llrp_aware_filter_action,
3587 { "Action", "llrp.param.aware_filter_action", FT_UINT8, BASE_DEC, NULL, 0,
3588 NULL, HFILL }},
3590 { &hf_llrp_unaware_filter_action,
3591 { "Action", "llrp.param.unaware_filter_action", FT_UINT8, BASE_DEC, NULL, 0,
3592 NULL, HFILL }},
3594 { &hf_llrp_mode_idx,
3595 { "Mode index", "llrp.param.mode_idx", FT_UINT16, BASE_DEC, NULL, 0,
3596 NULL, HFILL }},
3598 { &hf_llrp_tari,
3599 { "Tari", "llrp.param.tari", FT_UINT16, BASE_DEC, NULL, 0,
3600 NULL, HFILL }},
3602 { &hf_llrp_session,
3603 { "Session", "llrp.param.session", FT_UINT8, BASE_DEC, NULL, 0xC0,
3604 NULL, HFILL }},
3606 { &hf_llrp_tag_population,
3607 { "Tag population", "llrp.param.tag_population", FT_UINT16, BASE_DEC, NULL, 0,
3608 NULL, HFILL }},
3610 { &hf_llrp_tag_transit_time,
3611 { "Tag tranzit time", "llrp.param.tag_transit_time", FT_UINT32, BASE_DEC, NULL, 0,
3612 NULL, HFILL }},
3614 { &hf_llrp_sing_i,
3615 { "I", "llrp.param.sing_i", FT_BOOLEAN, 8, TFS(&tfs_state_a_b), 0x80,
3616 NULL, HFILL }},
3618 { &hf_llrp_sing_s,
3619 { "S", "llrp.param.sing_s", FT_BOOLEAN, 8, TFS(&tfs_sl), 0x40,
3620 NULL, HFILL }},
3622 { &hf_llrp_sing_a,
3623 { "S_All", "llrp.param.sing_a", FT_BOOLEAN, 8, TFS(&tfs_all_no), 0x20,
3624 NULL, HFILL }},
3626 { &hf_llrp_match,
3627 { "Match", "llrp.param.match", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
3628 NULL, HFILL }},
3630 { &hf_llrp_tag_data,
3631 { "Tag data", "llrp.param.tag_data", FT_BYTES, BASE_NONE, NULL, 0,
3632 NULL, HFILL }},
3634 { &hf_llrp_access_pass,
3635 { "Access password", "llrp.param.access_pass", FT_UINT32, BASE_DEC_HEX, NULL, 0,
3636 NULL, HFILL }},
3638 { &hf_llrp_word_pointer,
3639 { "Word pointer", "llrp.param.word_pointer", FT_UINT16, BASE_DEC_HEX, NULL, 0,
3640 NULL, HFILL }},
3642 { &hf_llrp_word_count,
3643 { "Word count", "llrp.param.word_count", FT_UINT16, BASE_DEC, NULL, 0,
3644 NULL, HFILL }},
3646 { &hf_llrp_write_data,
3647 { "Write data", "llrp.param.write_data", FT_BYTES, BASE_NONE, NULL, 0,
3648 NULL, HFILL }},
3650 { &hf_llrp_kill_pass,
3651 { "Killpassword", "llrp.param.kill_pass", FT_UINT32, BASE_DEC_HEX, NULL, 0,
3652 NULL, HFILL }},
3654 { &hf_llrp_kill_3,
3655 { "3", "llrp.param.kill_3", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
3656 NULL, HFILL }},
3658 { &hf_llrp_kill_2,
3659 { "2", "llrp.param.kill_2", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
3660 NULL, HFILL }},
3662 { &hf_llrp_kill_l,
3663 { "L", "llrp.param.kill_l", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x01,
3664 NULL, HFILL }},
3666 { &hf_llrp_privilege,
3667 { "Privilege", "llrp.param.privilege", FT_UINT8, BASE_DEC, NULL, 0,
3668 NULL, HFILL }},
3670 { &hf_llrp_data_field,
3671 { "Data field", "llrp.param.data_field", FT_UINT8, BASE_DEC, NULL, 0,
3672 NULL, HFILL }},
3674 { &hf_llrp_block_pointer,
3675 { "Block pointer", "llrp.param.block_pointer", FT_UINT16, BASE_DEC_HEX, NULL, 0,
3676 NULL, HFILL }},
3678 { &hf_llrp_block_mask,
3679 { "Block mask", "llrp.param.block_mask", FT_BYTES, BASE_NONE, NULL, 0,
3680 NULL, HFILL }},
3682 { &hf_llrp_length_words,
3683 { "Field Length (words)", "llrp.param.length_words", FT_UINT16, BASE_DEC, NULL, 0,
3684 NULL, HFILL }},
3686 { &hf_llrp_block_range,
3687 { "Block range", "llrp.param.block_range", FT_UINT16, BASE_DEC, NULL, 0,
3688 NULL, HFILL }},
3690 { &hf_llrp_enable_crc,
3691 { "Enable CRC", "llrp.param.enable_crc", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3692 NULL, HFILL }},
3694 { &hf_llrp_enable_pc,
3695 { "Enable PC bits", "llrp.param.enable_pc", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x40,
3696 NULL, HFILL }},
3698 { &hf_llrp_enable_xpc,
3699 { "Enable XPC bits", "llrp.param.enable_xpc", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
3700 NULL, HFILL }},
3702 { &hf_llrp_pc_bits,
3703 { "PC bits", "llrp.param.pc_bits", FT_UINT16, BASE_HEX, NULL, 0,
3704 NULL, HFILL }},
3706 { &hf_llrp_xpc_w1,
3707 { "XPC-W1", "llrp.param.xpc_w1", FT_UINT16, BASE_HEX, NULL, 0,
3708 NULL, HFILL }},
3710 { &hf_llrp_xpc_w2,
3711 { "XPC-W2", "llrp.param.xpc_w2", FT_UINT16, BASE_HEX, NULL, 0,
3712 NULL, HFILL }},
3714 { &hf_llrp_crc,
3715 { "CRC", "llrp.param.crc", FT_UINT16, BASE_HEX, NULL, 0,
3716 NULL, HFILL }},
3718 { &hf_llrp_num_coll,
3719 { "Number of collisions", "llrp.param.num_coll", FT_UINT16, BASE_DEC, NULL, 0,
3720 NULL, HFILL }},
3722 { &hf_llrp_num_empty,
3723 { "Number of empty slots", "llrp.param.num_empty", FT_UINT16, BASE_DEC, NULL, 0,
3724 NULL, HFILL }},
3726 { &hf_llrp_access_result,
3727 { "Result", "llrp.param.access_result", FT_UINT8, BASE_DEC, NULL, 0,
3728 NULL, HFILL }},
3730 { &hf_llrp_read_data,
3731 { "Read data", "llrp.param.read_data", FT_BYTES, BASE_NONE, NULL, 0,
3732 NULL, HFILL }},
3734 { &hf_llrp_num_words_written,
3735 { "Number of words written", "llrp.param.num_words_written", FT_UINT16, BASE_DEC, NULL, 0,
3736 NULL, HFILL }},
3738 { &hf_llrp_permlock_status,
3739 { "Read data", "llrp.param.permlock_status", FT_BYTES, BASE_NONE, NULL, 0,
3740 NULL, HFILL }},
3742 { &hf_llrp_vendor_id,
3743 { "Vendor ID", "llrp.param.vendor_id", FT_UINT32, BASE_DEC, VALS(llrp_vendors), 0,
3744 NULL, HFILL }},
3746 { &hf_llrp_vendor_unknown,
3747 { "Vendor Unknown", "llrp.param.vendor_unknown", FT_BYTES, BASE_NONE, NULL, 0,
3748 NULL, HFILL }},
3750 { &hf_llrp_impinj_param_type,
3751 { "Impinj parameter subtype", "llrp.param.impinj_param_type", FT_UINT32, BASE_DEC | BASE_EXT_STRING, &impinj_param_type_ext, 0,
3752 NULL, HFILL }},
3754 { &hf_llrp_save_config,
3755 { "Save configuration", "llrp.param.save_config", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80,
3756 NULL, HFILL }},
3758 { &hf_llrp_impinj_req_data,
3759 { "Requested data", "llrp.param.impinj_req_data", FT_UINT32, BASE_DEC | BASE_EXT_STRING, &impinj_req_data_ext, 0,
3760 NULL, HFILL }},
3762 { &hf_llrp_impinj_reg_region,
3763 { "Regulatory region", "llrp.param.impinj_reg_region", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &impinj_reg_region_ext, 0,
3764 NULL, HFILL }},
3766 { &hf_llrp_impinj_search_mode,
3767 { "Inventory search mode", "llrp.param.impinj_search_mode", FT_UINT16, BASE_DEC, VALS(impinj_search_mode), 0,
3768 NULL, HFILL }},
3770 { &hf_llrp_impinj_en_tag_dir,
3771 { "Enable tag direction", "llrp.param.impinj_en_tag_dir", FT_BOOLEAN, 16, TFS(&tfs_yes_no), 0x8000,
3772 NULL, HFILL }},
3774 { &hf_llrp_impinj_antenna_conf,
3775 { "Antenna configuration", "llrp.param.impinj_antenna_conf", FT_UINT16, BASE_DEC, VALS(impinj_ant_conf), 0,
3776 NULL, HFILL }},
3778 { &hf_llrp_decision_time,
3779 { "Decision timestamp", "llrp.param.decision_time", FT_UINT64, BASE_DEC, NULL, 0,
3780 NULL, HFILL }},
3782 { &hf_llrp_impinj_tag_dir,
3783 { "Tag direction", "llrp.param.impinj_tag_dir", FT_UINT16, BASE_DEC, VALS(impinj_tag_dir), 0,
3784 NULL, HFILL }},
3786 { &hf_llrp_confidence,
3787 { "Confidence", "llrp.param.confidence", FT_UINT16, BASE_DEC, NULL, 0,
3788 NULL, HFILL }},
3790 { &hf_llrp_impinj_fix_freq_mode,
3791 { "Fixed frequency mode", "llrp.param.impinj_fix_freq_mode", FT_UINT16, BASE_DEC, VALS(impinj_fix_freq_mode), 0,
3792 NULL, HFILL }},
3794 { &hf_llrp_num_channels,
3795 { "Number of channels", "llrp.param.num_channels", FT_UINT16, BASE_DEC, NULL, 0,
3796 NULL, HFILL }},
3798 { &hf_llrp_channel,
3799 { "Channel", "llrp.param.channel", FT_UINT16, BASE_DEC, NULL, 0,
3800 NULL, HFILL }},
3802 { &hf_llrp_impinj_reduce_power_mode,
3803 { "Reduced power mode", "llrp.param.impinj_reduce_power_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3804 NULL, HFILL }},
3806 { &hf_llrp_impinj_low_duty_mode,
3807 { "Low duty cycle mode", "llrp.param.impinj_low_duty_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3808 NULL, HFILL }},
3810 { &hf_llrp_empty_field_timeout,
3811 { "Empty field timeout", "llrp.param.empty_field_timeout", FT_UINT16, BASE_DEC, NULL, 0,
3812 NULL, HFILL }},
3814 { &hf_llrp_field_ping_interval,
3815 { "Field ping interval", "llrp.param.field_ping_interval", FT_UINT16, BASE_DEC, NULL, 0,
3816 NULL, HFILL }},
3818 { &hf_llrp_model_name,
3819 { "Model name", "llrp.param.model_name", FT_UINT_STRING, BASE_NONE, NULL, 0,
3820 NULL, HFILL }},
3822 { &hf_llrp_serial_number,
3823 { "Serial number", "llrp.param.serial_number", FT_UINT_STRING, BASE_NONE, NULL, 0,
3824 NULL, HFILL }},
3826 { &hf_llrp_soft_ver,
3827 { "Software version", "llrp.param.soft_ver", FT_UINT_STRING, BASE_NONE, NULL, 0,
3828 NULL, HFILL }},
3830 { &hf_llrp_firm_ver,
3831 { "Firmware version", "llrp.param.firm_ver", FT_UINT_STRING, BASE_NONE, NULL, 0,
3832 NULL, HFILL }},
3834 { &hf_llrp_fpga_ver,
3835 { "FPGA version", "llrp.param.fpga_ver", FT_UINT_STRING, BASE_NONE, NULL, 0,
3836 NULL, HFILL }},
3838 { &hf_llrp_pcba_ver,
3839 { "PCBA version", "llrp.param.pcba_ver", FT_UINT_STRING, BASE_NONE, NULL, 0,
3840 NULL, HFILL }},
3842 { &hf_llrp_height_thresh,
3843 { "Height threshold", "llrp.param.height_thresh", FT_UINT16, BASE_DEC, NULL, 0,
3844 NULL, HFILL }},
3846 { &hf_llrp_zero_motion_thresh,
3847 { "Zero motion threshold", "llrp.param.zero_motion_thresh", FT_UINT16, BASE_DEC, NULL, 0,
3848 NULL, HFILL }},
3850 { &hf_llrp_board_manufacturer,
3851 { "Board manufacturer", "llrp.param.board_manufacturer", FT_UINT_STRING, BASE_NONE, NULL, 0,
3852 NULL, HFILL }},
3854 { &hf_llrp_fw_ver_hex,
3855 { "Firmware version", "llrp.param.fw_ver_hex", FT_UINT_BYTES, BASE_NONE, NULL, 0,
3856 NULL, HFILL }},
3858 { &hf_llrp_hw_ver_hex,
3859 { "Hardware version", "llrp.param.hw_ver_hex", FT_UINT_BYTES, BASE_NONE, NULL, 0,
3860 NULL, HFILL }},
3862 { &hf_llrp_gpi_debounce,
3863 { "GPI debounce timer Msec", "llrp.param.gpi_debounce", FT_UINT32, BASE_DEC, NULL, 0,
3864 NULL, HFILL }},
3866 { &hf_llrp_temperature,
3867 { "Temperature", "llrp.param.temperature", FT_INT16, BASE_DEC, NULL, 0,
3868 NULL, HFILL }},
3870 { &hf_llrp_impinj_link_monitor_mode,
3871 { "Link monitor mode", "llrp.param.impinj_link_monitor_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3872 NULL, HFILL }},
3874 { &hf_llrp_link_down_thresh,
3875 { "Link down threshold", "llrp.param.link_down_thresh", FT_UINT16, BASE_DEC, NULL, 0,
3876 NULL, HFILL }},
3878 { &hf_llrp_impinj_report_buff_mode,
3879 { "Report buffer mode", "llrp.param.impinj_report_buff_mode", FT_UINT16, BASE_DEC, VALS(impinj_report_buff_mode), 0,
3880 NULL, HFILL }},
3882 { &hf_llrp_permalock_result,
3883 { "Result", "llrp.param.permalock_result", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &impinj_permalock_result_ext, 0,
3884 NULL, HFILL }},
3886 { &hf_llrp_block_permalock_result,
3887 { "Result", "llrp.param.block_permalock_result", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &impinj_block_permalock_result_ext, 0,
3888 NULL, HFILL }},
3890 { &hf_llrp_impinj_data_profile,
3891 { "Data profile", "llrp.param.impinj_data_profile", FT_UINT8, BASE_DEC, VALS(impinj_data_profile), 0,
3892 NULL, HFILL }},
3894 { &hf_llrp_impinj_access_range,
3895 { "Access range", "llrp.param.impinj_access_range", FT_UINT8, BASE_DEC, VALS(impinj_access_range), 0,
3896 NULL, HFILL }},
3898 { &hf_llrp_impinj_persistence,
3899 { "Persistence", "llrp.param.impinj_persistence", FT_UINT8, BASE_DEC, VALS(impinj_persistence), 0,
3900 NULL, HFILL }},
3902 { &hf_llrp_set_qt_config_result,
3903 { "Result", "llrp.param.set_qt_config_result", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &impinj_set_qt_config_result_ext, 0,
3904 NULL, HFILL }},
3906 { &hf_llrp_get_qt_config_result,
3907 { "Result", "llrp.param.get_qt_config_result", FT_UINT8, BASE_DEC | BASE_EXT_STRING, &impinj_get_qt_config_result_ext, 0,
3908 NULL, HFILL }},
3910 { &hf_llrp_impinj_serialized_tid_mode,
3911 { "Serialized TID Mode", "llrp.param.impinj_serialized_tid_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3912 NULL, HFILL }},
3914 { &hf_llrp_impinj_rf_phase_mode,
3915 { "RF phase angle mode", "llrp.param.impinj_rf_phase_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3916 NULL, HFILL }},
3918 { &hf_llrp_impinj_peak_rssi_mode,
3919 { "Peak RSSI mode", "llrp.param.impinj_peak_rssi_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3920 NULL, HFILL }},
3922 { &hf_llrp_impinj_gps_coordinates_mode,
3923 { "GPS coordinates mode", "llrp.param.impinj_gps_coordinates_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3924 NULL, HFILL }},
3926 { &hf_llrp_impinj_tid,
3927 { "TID", "llrp.param.impinj_tid", FT_UINT_BYTES, BASE_NONE, NULL, 0,
3928 NULL, HFILL }},
3930 { &hf_llrp_phase_angle,
3931 { "Phase angle", "llrp.param.phase_angle", FT_UINT16, BASE_DEC, NULL, 0,
3932 NULL, HFILL }},
3934 { &hf_llrp_rssi,
3935 { "RSSI", "llrp.param.rssi", FT_INT16, BASE_DEC, NULL, 0,
3936 NULL, HFILL }},
3938 { &hf_llrp_latitude,
3939 { "Latitude", "llrp.param.latitude", FT_INT32, BASE_DEC, NULL, 0,
3940 NULL, HFILL }},
3942 { &hf_llrp_longitude,
3943 { "Longitude", "llrp.param.longitude", FT_INT32, BASE_DEC, NULL, 0,
3944 NULL, HFILL }},
3946 { &hf_llrp_gga_sentence,
3947 { "GGA sentence", "llrp.param.gga_sentence", FT_UINT_STRING, BASE_NONE, NULL, 0,
3948 NULL, HFILL }},
3950 { &hf_llrp_rmc_sentence,
3951 { "RMC sentence", "llrp.param.rmc_sentence", FT_UINT_STRING, BASE_NONE, NULL, 0,
3952 NULL, HFILL }},
3954 { &hf_llrp_impinj_optim_read_mode,
3955 { "Optimized read mode", "llrp.param.impinj_optim_read_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3956 NULL, HFILL }},
3958 { &hf_llrp_impinj_rf_doppler_mode,
3959 { "RF doppler frequency mode", "llrp.param.impinj_rf_doppler_mode", FT_UINT16, BASE_DEC, VALS(impinj_boolean), 0,
3960 NULL, HFILL }},
3962 { &hf_llrp_retry_count,
3963 { "Retry count", "llrp.param.retry_count", FT_UINT16, BASE_DEC, NULL, 0,
3964 NULL, HFILL }},
3966 { &hf_llrp_impinj_access_spec_ordering,
3967 { "AccessSpec ordering", "llrp.param.impinj_access_spec_ordering", FT_UINT16, BASE_DEC, VALS(impinj_access_spec_ordering), 0,
3968 NULL, HFILL }},
3970 { &hf_llrp_impinj_gpo_mode,
3971 { "GPO mode", "llrp.param.impinj_gpo_mode", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &impinj_gpo_mode_ext, 0,
3972 NULL, HFILL }},
3974 { &hf_llrp_gpo_pulse_dur,
3975 { "GPO pulse duration", "llrp.param.gpo_pulse_dur", FT_UINT32, BASE_DEC, NULL, 0,
3976 NULL, HFILL }},
3978 { &hf_llrp_impinj_hub_id,
3979 { "Hub ID", "llrp.impinj_hub_id", FT_UINT16, BASE_DEC, NULL, 0,
3980 NULL, HFILL }},
3982 { &hf_llrp_impinj_hub_fault_type,
3983 { "Hub fault type", "llrp.param.impinj_hub_fault_type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &impinj_hub_fault_type_ext, 0,
3984 NULL, HFILL }},
3986 { &hf_llrp_impinj_hub_connected_type,
3987 { "Hub connected type", "llrp.param.impinj_hub_connected_type", FT_UINT16, BASE_DEC | BASE_EXT_STRING, &impinj_hub_connected_type_ext, 0,
3988 NULL, HFILL }},
3991 /* Setup protocol subtree array */
3992 static int *ett[] = {
3993 &ett_llrp,
3994 &ett_llrp_param
3997 static ei_register_info ei[] = {
3998 { &ei_llrp_invalid_length, { "llrp.invalid_length_of_string_claimed", PI_MALFORMED, PI_ERROR, "Invalid Length", EXPFILL }},
3999 { &ei_llrp_req_conf, { "llrp.req_conf.invalid", PI_PROTOCOL, PI_ERROR, "Unrecognized configuration request", EXPFILL }},
4002 expert_module_t* expert_llrp;
4004 /* Register the protocol name and description */
4005 proto_llrp = proto_register_protocol("Low Level Reader Protocol", "LLRP", "llrp");
4007 /* Required function calls to register the header fields and subtrees used */
4008 proto_register_field_array(proto_llrp, hf, array_length(hf));
4009 proto_register_subtree_array(ett, array_length(ett));
4010 expert_llrp = expert_register_protocol(proto_llrp);
4011 expert_register_field_array(expert_llrp, ei, array_length(ei));
4013 llrp_handle = register_dissector("llrp", dissect_llrp, proto_llrp);
4016 void
4017 proto_reg_handoff_llrp(void)
4019 dissector_add_uint_with_preference("tcp.port", LLRP_PORT, llrp_handle);
4024 * Editor modelines - https://www.wireshark.org/tools/modelines.html
4026 * Local variables:
4027 * c-basic-offset: 4
4028 * tab-width: 8
4029 * indent-tabs-mode: nil
4030 * End:
4032 * vi: set shiftwidth=4 tabstop=8 expandtab:
4033 * :indentSize=4:tabSize=8:noTabs=true: