aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rdm.c
blob: 451231efab16a5f7de8ecc6eaaba25bf395b5729 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
/* packet-rdm.c
 * RDM (Remote Device Management) packet disassembly.
 *
 * This dissector is written by
 *
 *  Erwin Rol <erwin@erwinrol.com>
 *  Copyright 2003, 2011, 2012 Erwin Rol
 *
 *  Shaun Jackman <sjackman@gmail.com>
 *  Copyright 2006 Pathway Connectivity
 *
 *  Wireshark - Network traffic analyzer
 *  Gerald Combs <gerald@wireshark.org>
 *  Copyright 1999 Gerald Combs
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor
 * Boston, MA  02110-1301, USA.
 */
/*
 * ANSI E1.20-2006, Entertainment Technology
 * Remote Device Management over USITT DMX512, describes a method of
 * bi-directional communications over a USITT DMX512/1990 data link
 * between an entertainment lighting controller and one or more
 * remotely controlled lighting devices. The protocol also is intended
 * to work with the ANSI E1.11-2004 control protocol. It allows
 * discovery of devices on a DMX512/E1.11 network and the remote
 * setting of DMX starting addresses, as well as status and fault
 * reporting back to the control console.
 */

#include "config.h"

#include <epan/packet.h>
#include <epan/expert.h>
#include "packet-rdm.h"

void proto_register_rdm(void);
void proto_reg_handoff_rdm(void);

#define RDM_SC_RDM				0xCC
#define RDM_SC_SUB_MESSAGE			0x01

#define RDM_CC_COMMAND_RESPONSE_FLAG		0x01

#define RDM_CC_DISCOVERY_COMMAND		0x10
#define RDM_CC_DISCOVERY_COMMAND_RESPONSE	0x11
#define RDM_CC_GET_COMMAND			0x20
#define RDM_CC_GET_COMMAND_RESPONSE		0x21
#define RDM_CC_SET_COMMAND			0x30
#define RDM_CC_SET_COMMAND_RESPONSE		0x31

static const value_string rdm_cc_vals[] = {
	{ RDM_CC_DISCOVERY_COMMAND,		"Discovery Command" },
	{ RDM_CC_DISCOVERY_COMMAND_RESPONSE,	"Discovery Command Response" },
	{ RDM_CC_GET_COMMAND,			"Get Command" },
	{ RDM_CC_GET_COMMAND_RESPONSE,		"Get Command Response" },
	{ RDM_CC_SET_COMMAND,			"Set Command" },
	{ RDM_CC_SET_COMMAND_RESPONSE,		"Set Command Response" },
	{ 0, NULL },
};

#define RDM_RESPONSE_TYPE_ACK			0x00
#define RDM_RESPONSE_TYPE_ACK_TIMER		0x01
#define RDM_RESPONSE_TYPE_NACK_REASON		0x02
#define RDM_RESPONSE_TYPE_ACK_OVERFLOW		0x03

static const value_string rdm_rt_vals[] = {
	{ RDM_RESPONSE_TYPE_ACK,		"Ack" },
	{ RDM_RESPONSE_TYPE_ACK_TIMER,		"Ack Timer" },
	{ RDM_RESPONSE_TYPE_NACK_REASON,	"Nack Reason" },
	{ RDM_RESPONSE_TYPE_ACK_OVERFLOW,	"Ack Overflow" },
	{ 0, NULL },
};

#define RDM_NR_UNKNOWN_PID			0x0000
#define RDM_NR_FORMAT_ERROR			0x0001
#define RDM_NR_HARDWARE_FAULT			0x0002
#define RDM_NR_PROXY_REJECT			0x0003
#define RDM_NR_WRITE_PROTECT			0x0004
#define RDM_NR_UNSUPPORTED_COMMAND_CLASS	0x0005
#define RDM_NR_DATA_OUT_OF_RANGE		0x0006
#define RDM_NR_BUFFER_FULL			0x0007
#define RDM_NR_PACKET_SIZE_UNSUPPORTED		0x0008
#define RDM_NR_SUB_DEVICE_OUT_OF_RANGE		0x0009
#define RDM_NR_PROXY_BUFFER_FULL		0x000A

static const value_string rdm_nr_vals[] = {
	{ RDM_NR_UNKNOWN_PID,			"Unknown PID" },
	{ RDM_NR_FORMAT_ERROR,			"Format Error" },
	{ RDM_NR_HARDWARE_FAULT,		"Hardware Fault" },
	{ RDM_NR_PROXY_REJECT,			"Proxy Reject" },
	{ RDM_NR_WRITE_PROTECT,			"Write Protect" },
	{ RDM_NR_UNSUPPORTED_COMMAND_CLASS,	"Unsupported Command Class" },
	{ RDM_NR_DATA_OUT_OF_RANGE,		"Data Out Of Range" },
	{ RDM_NR_BUFFER_FULL,			"Buffer Full" },
	{ RDM_NR_PACKET_SIZE_UNSUPPORTED,	"Packet Size Unsupported" },
	{ RDM_NR_SUB_DEVICE_OUT_OF_RANGE,	"Sub-Device Out Of Range" },
	{ RDM_NR_PROXY_BUFFER_FULL,		"Proxy Buffer Full" },
	{ 0, NULL },
};

#define RDM_PARAM_ID_DISC_UNIQUE_BRANCH			0x0001
#define RDM_PARAM_ID_DISC_MUTE				0x0002
#define RDM_PARAM_ID_DISC_UN_MUTE			0x0003
#define RDM_PARAM_ID_PROXIED_DEVICES			0x0010
#define RDM_PARAM_ID_PROXIED_DEVICE_COUNT		0x0011
#define RDM_PARAM_ID_COMMS_STATUS			0x0015
#define RDM_PARAM_ID_QUEUED_MESSAGE			0x0020
#define RDM_PARAM_ID_STATUS_MESSAGES			0x0030
#define RDM_PARAM_ID_STATUS_ID_DESCRIPTION		0x0031
#define RDM_PARAM_ID_CLEAR_STATUS_ID			0x0032
#define RDM_PARAM_ID_SUB_DEVICE_STATUS_REPORT_THRESHOLD 0x0033
#define RDM_PARAM_ID_SUPPORTED_PARAMETERS		0x0050
#define RDM_PARAM_ID_PARAMETER_DESCRIPTION		0x0051
#define RDM_PARAM_ID_DEVICE_INFO			0x0060
#define RDM_PARAM_ID_PRODUCT_DETAIL_ID_LIST		0x0070
#define RDM_PARAM_ID_DEVICE_MODEL_DESCRIPTION		0x0080
#define RDM_PARAM_ID_MANUFACTURER_LABEL			0x0081
#define RDM_PARAM_ID_DEVICE_LABEL			0x0082
#define RDM_PARAM_ID_FACTORY_DEFAULTS			0x0090
#define RDM_PARAM_ID_LANGUAGE_CAPABILITIES		0x00A0
#define RDM_PARAM_ID_LANGUAGE				0x00B0
#define RDM_PARAM_ID_SOFTWARE_VERSION_LABEL		0x00C0
#define RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_ID		0x00C1
#define RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_LABEL	0x00C2
#define RDM_PARAM_ID_DMX_PERSONALITY			0x00E0
#define RDM_PARAM_ID_DMX_PERSONALITY_DESCRIPTION	0x00E1
#define RDM_PARAM_ID_DMX_START_ADDRESS			0x00F0
#define RDM_PARAM_ID_SLOT_INFO				0x0120
#define RDM_PARAM_ID_SLOT_DESCRIPTION			0x0121
#define RDM_PARAM_ID_DEFAULT_SLOT_VALUE			0x0122
#define RDM_PARAM_ID_SENSOR_DEFINITION			0x0200
#define RDM_PARAM_ID_SENSOR_VALUE			0x0201
#define RDM_PARAM_ID_RECORD_SENSORS			0x0202
#define RDM_PARAM_ID_DEVICE_HOURS			0x0400
#define RDM_PARAM_ID_LAMP_HOURS				0x0401
#define RDM_PARAM_ID_LAMP_STRIKES			0x0402
#define RDM_PARAM_ID_LAMP_STATE				0x0403
#define RDM_PARAM_ID_LAMP_ON_MODE			0x0404
#define RDM_PARAM_ID_DEVICE_POWER_CYCLES		0x0405
#define RDM_PARAM_ID_DISPLAY_INVERT			0x0500
#define RDM_PARAM_ID_DISPLAY_LEVEL			0x0501
#define RDM_PARAM_ID_PAN_INVERT				0x0600
#define RDM_PARAM_ID_TILT_INVERT			0x0601
#define RDM_PARAM_ID_PAN_TILT_SWAP			0x0602
#define RDM_PARAM_ID_REAL_TIME_CLOCK			0x0603
#define RDM_PARAM_ID_IDENTIFY_DEVICE			0x1000
#define RDM_PARAM_ID_RESET_DEVICE			0x1001
#define RDM_PARAM_ID_POWER_STATE			0x1010
#define RDM_PARAM_ID_PERFORM_SELFTEST			0x1020
#define RDM_PARAM_ID_SELF_TEST_DESCRIPTION		0x1021
#define RDM_PARAM_ID_CAPTURE_PRESET			0x1030
#define RDM_PARAM_ID_PRESET_PLAYBACK			0x1031

const value_string rdm_param_id_vals[] = {
	{ RDM_PARAM_ID_DISC_UNIQUE_BRANCH,		   "DISC_UNIQUE_BRANCH" },
	{ RDM_PARAM_ID_DISC_MUTE,			   "DISC_MUTE" },
	{ RDM_PARAM_ID_DISC_UN_MUTE,			   "DISC_UN_MUTE" },
	{ RDM_PARAM_ID_PROXIED_DEVICES,			   "PROXIED_DEVICES" },
	{ RDM_PARAM_ID_PROXIED_DEVICE_COUNT,		   "PROXIED_DEVICE_COUNT" },
	{ RDM_PARAM_ID_COMMS_STATUS,			   "COMMS_STATUS" },
	{ RDM_PARAM_ID_QUEUED_MESSAGE,			   "QUEUED_MESSAGE" },
	{ RDM_PARAM_ID_STATUS_MESSAGES,			   "STATUS_MESSAGES" },
	{ RDM_PARAM_ID_STATUS_ID_DESCRIPTION,		   "STATUS_ID_DESCRIPTION" },
	{ RDM_PARAM_ID_CLEAR_STATUS_ID,			   "CLEAR_STATUS_ID" },
	{ RDM_PARAM_ID_SUB_DEVICE_STATUS_REPORT_THRESHOLD, "DEVICE_STATUS_REPORT_THRESHOLD" },
	{ RDM_PARAM_ID_SUPPORTED_PARAMETERS,		   "SUPPORTED_PARAMETERS" },
	{ RDM_PARAM_ID_PARAMETER_DESCRIPTION,		   "PARAMETER_DESCRIPTION" },
	{ RDM_PARAM_ID_DEVICE_INFO,			   "DEVICE_INFO" },
	{ RDM_PARAM_ID_PRODUCT_DETAIL_ID_LIST,		   "PRODUCT_DETAIL_ID_LIST" },
	{ RDM_PARAM_ID_DEVICE_MODEL_DESCRIPTION,	   "DEVICE_MODEL_DESCRIPTION" },
	{ RDM_PARAM_ID_MANUFACTURER_LABEL,		   "MANUFACTURER_LABEL" },
	{ RDM_PARAM_ID_DEVICE_LABEL,			   "DEVICE_LABEL" },
	{ RDM_PARAM_ID_FACTORY_DEFAULTS,		   "FACTORY_DEFAULTS" },
	{ RDM_PARAM_ID_LANGUAGE_CAPABILITIES,		   "LANGUAGE_CAPABILITIES" },
	{ RDM_PARAM_ID_LANGUAGE,			   "LANGUAGE" },
	{ RDM_PARAM_ID_SOFTWARE_VERSION_LABEL,		   "SOFTWARE_VERSION_LABEL" },
	{ RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_ID,	   "BOOT_SOFTWARE_VERSION_ID" },
	{ RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_LABEL,	   "BOOT_SOFTWARE_VERSION_LABEL" },
	{ RDM_PARAM_ID_DMX_PERSONALITY,			   "DMX_PERSONALITY" },
	{ RDM_PARAM_ID_DMX_PERSONALITY_DESCRIPTION,	   "DMX_PERSONALITY_DESCRIPTION" },
	{ RDM_PARAM_ID_DMX_START_ADDRESS,		   "DMX_START_ADDRESS" },
	{ RDM_PARAM_ID_SLOT_INFO,			   "SLOT_INFO" },
	{ RDM_PARAM_ID_SLOT_DESCRIPTION,		   "SLOT_DESCRIPTION" },
	{ RDM_PARAM_ID_DEFAULT_SLOT_VALUE,		   "DEFAULT_SLOT_VALUE" },
	{ RDM_PARAM_ID_SENSOR_DEFINITION,		   "SENSOR_DEFINITION" },
	{ RDM_PARAM_ID_SENSOR_VALUE,			   "SENSOR_VALUE" },
	{ RDM_PARAM_ID_RECORD_SENSORS,			   "RECORD_SENSORS" },
	{ RDM_PARAM_ID_DEVICE_HOURS,			   "DEVICE_HOURS" },
	{ RDM_PARAM_ID_LAMP_HOURS,			   "LAMP_HOURS" },
	{ RDM_PARAM_ID_LAMP_STRIKES,			   "LAMP_STRIKES" },
	{ RDM_PARAM_ID_LAMP_STATE,			   "LAMP_STATE" },
	{ RDM_PARAM_ID_LAMP_ON_MODE,			   "LAMP_ON_MODE" },
	{ RDM_PARAM_ID_DEVICE_POWER_CYCLES,		   "DEVICE_POWER_CYCLES" },
	{ RDM_PARAM_ID_DISPLAY_INVERT,			   "DISPLAY_INVERT" },
	{ RDM_PARAM_ID_DISPLAY_LEVEL,			   "DISPLAY_LEVEL" },
	{ RDM_PARAM_ID_PAN_INVERT,			   "PAN_INVERT" },
	{ RDM_PARAM_ID_TILT_INVERT,			   "TILT_INVERT" },
	{ RDM_PARAM_ID_PAN_TILT_SWAP,			   "PAN_TILT_SWAP" },
	{ RDM_PARAM_ID_REAL_TIME_CLOCK,			   "REAL_TIME_CLOCK" },
	{ RDM_PARAM_ID_IDENTIFY_DEVICE,			   "IDENTIFY_DEVICE" },
	{ RDM_PARAM_ID_RESET_DEVICE,			   "RESET_DEVICE" },
	{ RDM_PARAM_ID_POWER_STATE,			   "POWER_STATE" },
	{ RDM_PARAM_ID_PERFORM_SELFTEST,		   "PERFORM_SELFTEST" },
	{ RDM_PARAM_ID_SELF_TEST_DESCRIPTION,		   "SELF_TEST_DESCRIPTION" },
	{ RDM_PARAM_ID_CAPTURE_PRESET,			   "CAPTURE_PRESET" },
	{ RDM_PARAM_ID_PRESET_PLAYBACK,			   "PRESET_PLAYBACK" },
	{ 0, NULL },
};

value_string_ext rdm_param_id_vals_ext = VALUE_STRING_EXT_INIT(rdm_param_id_vals);

#define RDM_STATUS_NONE				0x00
#define RMD_STATUS_GET_LAST_MESSAGE		0x01
#define RDM_STATUS_ADVISORY			0x02
#define RDM_STATUS_WARNING			0x03
#define RDM_STATUS_ERROR			0x04

static const value_string rdm_status_vals[] = {
	{ RDM_STATUS_NONE,		"None" },
	{ RMD_STATUS_GET_LAST_MESSAGE,	"Get Last Message" },
	{ RDM_STATUS_ADVISORY,		"Advisory" },
	{ RDM_STATUS_WARNING,		"Warning" },
	{ RDM_STATUS_ERROR,		"Error" },
	{ 0, NULL },
};

#define RDM_PREFIX_NONE		0x00
#define RDM_PREFIX_DECI		0x01
#define RDM_PREFIX_CENTI	0x02
#define RDM_PREFIX_MILLI	0x03
#define RDM_PREFIX_MICRO	0x04
#define RDM_PREFIX_NANO		0x05
#define RDM_PREFIX_PICO		0x06
#define RDM_PREFIX_FEMPTO	0x07
#define RDM_PREFIX_ATTO		0x08
#define RDM_PREFIX_ZEPTO	0x09
#define RDM_PREFIX_YOCTO	0x0A
#define RDM_PREFIX_DECA		0x11
#define RDM_PREFIX_HECTO	0x12
#define RDM_PREFIX_KILO		0x13
#define RDM_PREFIX_MEGA		0x14
#define RDM_PREFIX_GIGA		0x15
#define RDM_PREFIX_TERRA	0x16
#define RDM_PREFIX_PETA		0x17
#define RDM_PREFIX_EXA		0x18
#define RDM_PREFIX_ZETTA	0x19
#define RDM_PREFIX_YOTTA	0x1A

static const value_string rdm_prefix_vals[] = {
	{ RDM_PREFIX_NONE,	"NONE (x1)" },
	{ RDM_PREFIX_DECI,	"deci (x10^-1)" },
	{ RDM_PREFIX_CENTI,	"centi (x10^-2)" },
	{ RDM_PREFIX_MILLI,	"milli (x10^-3)" },
	{ RDM_PREFIX_MICRO,	"micro (x10^-6)" },
	{ RDM_PREFIX_NANO,	"nano (x10^-9)" },
	{ RDM_PREFIX_PICO,	"pico (x10^-12)" },
	{ RDM_PREFIX_FEMPTO,	"fempto (x10^-15)" },
	{ RDM_PREFIX_ATTO,	"atto (x10^-18)" },
	{ RDM_PREFIX_ZEPTO,	"zepto (x10^-21)" },
	{ RDM_PREFIX_YOCTO,	"yocto (x10^-24)" },
	{ RDM_PREFIX_DECA,	"deca (x10^1)" },
	{ RDM_PREFIX_HECTO,	"hecto (x10^2)" },
	{ RDM_PREFIX_KILO,	"kilo (x10^3)" },
	{ RDM_PREFIX_MEGA,	"mega (x10^6)" },
	{ RDM_PREFIX_GIGA,	"giga (x10^9)" },
	{ RDM_PREFIX_TERRA,	"terra (x10^12)" },
	{ RDM_PREFIX_PETA,	"peta (x10^15)" },
	{ RDM_PREFIX_EXA,	"exa (x10^18)" },
	{ RDM_PREFIX_ZETTA,	"zetta (x10^21)" },
	{ RDM_PREFIX_YOTTA,	"yotta (x10^24)" },
	{ 0, NULL },
};
static value_string_ext rdm_prefix_vals_ext = VALUE_STRING_EXT_INIT(rdm_prefix_vals);

#define RDM_UNITS_NONE			      0x00
#define RDM_UNITS_CENTIGRADE		      0x01
#define RDM_UNITS_VOLTS_DC		      0x02
#define RDM_UNITS_VOLTS_AC_PEAK		      0x03
#define RDM_UNITS_VOLTS_AC_RMS		      0x04
#define RDM_UNITS_AMPERE_DC		      0x05
#define RDM_UNITS_AMPERE_AC_PEAK	      0x06
#define RDM_UNITS_AMPERE_AC_RMS		      0x07
#define RDM_UNITS_HERTZ			      0x08
#define RDM_UNITS_OHM			      0x09
#define RDM_UNITS_WATT			      0x0A
#define RDM_UNITS_KILOGRAM		      0x0B
#define RDM_UNITS_METERS		      0x0C
#define RDM_UNITS_METERS_SQUARED	      0x0D
#define RDM_UNITS_METERS_CUBED		      0x0E
#define RDM_UNITS_KILOGRAMMES_PER_METER_CUBED 0x0F
#define RDM_UNITS_METERS_PER_SECOND	      0x10
#define RDM_UNITS_METERS_PER_SECOND_SQUARED   0x11
#define RDM_UNITS_NEWTON		      0x12
#define RDM_UNITS_JOULE			      0x13
#define RDM_UNITS_PASCAL		      0x14
#define RDM_UNITS_SECOND		      0x15
#define RDM_UNITS_DEGREE		      0x16
#define RDM_UNITS_STERADIAN		      0x17
#define RDM_UNITS_CANDELA		      0x18
#define RDM_UNITS_LUMEN			      0x19
#define RDM_UNITS_LUX			      0x1A
#define RDM_UNITS_IRE			      0x1B
#define RDM_UNITS_BYTE			      0x1C

static const value_string rdm_unit_vals[] = {
	{ RDM_UNITS_NONE,			 "NONE" },
	{ RDM_UNITS_CENTIGRADE,			 "Centigrade" },
	{ RDM_UNITS_VOLTS_DC,			 "Volts DC" },
	{ RDM_UNITS_VOLTS_AC_PEAK,		 "Volts AC Peak" },
	{ RDM_UNITS_VOLTS_AC_RMS,		 "Volts AC RMS" },
	{ RDM_UNITS_AMPERE_DC,			 "Ampere DC" },
	{ RDM_UNITS_AMPERE_AC_PEAK,		 "Ampere AC Peak" },
	{ RDM_UNITS_AMPERE_AC_RMS,		 "Ampere AC RMS" },
	{ RDM_UNITS_HERTZ,			 "Hertz" },
	{ RDM_UNITS_OHM,			 "Ohm" },
	{ RDM_UNITS_WATT,			 "Watt" },
	{ RDM_UNITS_KILOGRAM,			 "Kilogram" },
	{ RDM_UNITS_METERS,			 "Meters" },
	{ RDM_UNITS_METERS_SQUARED,		 "Meters Squared" },
	{ RDM_UNITS_METERS_CUBED,		 "Meters Cubed" },
	{ RDM_UNITS_KILOGRAMMES_PER_METER_CUBED, "Kilogrammes per Meter Cubed" },
	{ RDM_UNITS_METERS_PER_SECOND,		 "Meters per Second" },
	{ RDM_UNITS_METERS_PER_SECOND_SQUARED,	 "Meters per Second Squared" },
	{ RDM_UNITS_NEWTON,			 "Newton" },
	{ RDM_UNITS_JOULE,			 "Joule" },
	{ RDM_UNITS_PASCAL,			 "Pascal" },
	{ RDM_UNITS_SECOND,			 "Second" },
	{ RDM_UNITS_DEGREE,			 "Degree" },
	{ RDM_UNITS_STERADIAN,			 "Steradian" },
	{ RDM_UNITS_CANDELA,			 "Candela" },
	{ RDM_UNITS_LUMEN,			 "Lumen" },
	{ RDM_UNITS_LUX,			 "Lux" },
	{ RDM_UNITS_IRE,			 "Ire" },
	{ RDM_UNITS_BYTE,			 "Byte" },
	{ 0, NULL },
};
static value_string_ext rdm_unit_vals_ext = VALUE_STRING_EXT_INIT(rdm_unit_vals);

#define RDM_SENS_TEMPERATURE	    0x00
#define RDM_SENS_VOLTAGE	    0x01
#define RDM_SENS_CURRENT	    0x02
#define RDM_SENS_FREQUENCY	    0x03
#define RDM_SENS_RESISTANCE	    0x04
#define RDM_SENS_POWER		    0x05
#define RDM_SENS_MASS		    0x06
#define RDM_SENS_LENGTH		    0x07
#define RDM_SENS_AREA		    0x08
#define RDM_SENS_VOLUME		    0x09
#define RDM_SENS_DENSITY	    0x0A
#define RDM_SENS_VELOCITY	    0x0B
#define RDM_SENS_ACCELERATION	    0x0C
#define RDM_SENS_FORCE		    0x0D
#define RDM_SENS_ENERGY		    0x0E
#define RDM_SENS_PRESSURE	    0x0F
#define RDM_SENS_TIME		    0x10
#define RDM_SENS_ANGLE		    0x11
#define RDM_SENS_POSITION_X	    0x12
#define RDM_SENS_POSITION_Y	    0x13
#define RDM_SENS_POSITION_Z	    0x14
#define RDM_SENS_ANGULAR_VELOCITY   0x15
#define RDM_SENS_LUMINOUS_INTENSITY 0x16
#define RDM_SENS_LUMINOUS_FLUX	    0x17
#define RDM_SENS_ILLUMINANCE	    0x18
#define RDM_SENS_CHROMINANCE_RED    0x19
#define RDM_SENS_CHROMINANCE_GREEN  0x1A
#define RDM_SENS_CHROMINANCE_BLUE   0x1B
#define RDM_SENS_CONTACTS	    0x1C
#define RDM_SENS_MEMORY		    0x1D
#define RDM_SENS_ITEMS		    0x1E
#define RDM_SENS_HUMIDITY	    0x1F
#define RDM_SENS_COUNTER_16BIT	    0x20
#define RDM_SENS_OTHER		    0x7F

static const value_string rdm_sensor_type_vals[] = {
	{ RDM_SENS_TEMPERATURE,		"Temperature" },
	{ RDM_SENS_VOLTAGE,		"Voltage" },
	{ RDM_SENS_CURRENT,		"Current" },
	{ RDM_SENS_FREQUENCY,		"Frequency" },
	{ RDM_SENS_RESISTANCE,		"Resistance" },
	{ RDM_SENS_POWER,		"Power" },
	{ RDM_SENS_MASS,		"Mass" },
	{ RDM_SENS_LENGTH,		"Length" },
	{ RDM_SENS_AREA,		"Area" },
	{ RDM_SENS_VOLUME,		"Volume" },
	{ RDM_SENS_DENSITY,		"Density" },
	{ RDM_SENS_VELOCITY,		"Velocity" },
	{ RDM_SENS_ACCELERATION,	"Acceleration" },
	{ RDM_SENS_FORCE,		"Force" },
	{ RDM_SENS_ENERGY,		"Energy" },
	{ RDM_SENS_PRESSURE,		"Pressure" },
	{ RDM_SENS_TIME,		"Time" },
	{ RDM_SENS_ANGLE,		"Angle" },
	{ RDM_SENS_POSITION_X,		"Position X" },
	{ RDM_SENS_POSITION_Y,		"Position Y" },
	{ RDM_SENS_POSITION_Z,		"Position Z" },
	{ RDM_SENS_ANGULAR_VELOCITY,	"Angular Velocity" },
	{ RDM_SENS_LUMINOUS_INTENSITY,	"Luminous Intensity" },
	{ RDM_SENS_LUMINOUS_FLUX,	"Luminous Flux" },
	{ RDM_SENS_ILLUMINANCE,		"Illuminance" },
	{ RDM_SENS_CHROMINANCE_RED,	"Chrominance Red" },
	{ RDM_SENS_CHROMINANCE_GREEN,	"Chrominance Green" },
	{ RDM_SENS_CHROMINANCE_BLUE,	"Chrominance Blue" },
	{ RDM_SENS_CONTACTS,		"Contacts" },
	{ RDM_SENS_MEMORY,		"Memory" },
	{ RDM_SENS_ITEMS,		"Items" },
	{ RDM_SENS_HUMIDITY,		"Humidity" },
	{ RDM_SENS_COUNTER_16BIT,	"Counter 16bit" },
	{ RDM_SENS_OTHER,		"Other" },
	{ 0, NULL} ,
};
static value_string_ext rdm_sensor_type_vals_ext = VALUE_STRING_EXT_INIT(rdm_sensor_type_vals);

#define RDM_PRODUCT_CATEGORY_NOT_DECLARED		0x0000
#define RDM_PRODUCT_CATEGORY_FIXTURE			0x0100
#define RDM_PRODUCT_CATEGORY_FIXTURE_FIXED		0x0101
#define RDM_PRODUCT_CATEGORY_FIXTURE_MOVING_YOKE	0x0102
#define RDM_PRODUCT_CATEGORY_FIXTURE_MOVING_MIRROR	0x0103
#define RDM_PRODUCT_CATEGORY_FIXTURE_OTHER		0x01FF
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY		0x0200
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_COLOR	0x0201
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_YOKE	0x0202
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_MIRROR	0x0203
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_EFFECT	0x0204
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_BEAM	0x0205
#define RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_OTHER	0x02FF
#define RDM_PRODUCT_CATEGORY_PROJECTOR			0x0300
#define RDM_PRODUCT_CATEGORY_PROJECTOR_FIXED		0x0301
#define RDM_PRODUCT_CATEGORY_PROJECTOR_MOVING_YOKE	0x0302
#define RDM_PRODUCT_CATEGORY_PROJECTOR_MOVING_MIRROR	0x0303
#define RDM_PRODUCT_CATEGORY_PROJECTOR_OTHER		0x03FF
#define RDM_PRODUCT_CATEGORY_ATMOSPHERIC		0x0400
#define RDM_PRODUCT_CATEGORY_ATMOSPHERIC_EFFECT		0x0401
#define RDM_PRODUCT_CATEGORY_ATMOSPHERIC_PYRO		0x0402
#define RDM_PRODUCT_CATEGORY_ATMOSPHERIC_OTHER		0x04FF
#define RDM_PRODUCT_CATEGORY_DIMMER			0x0500
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_INCANDESCENT	0x0501
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_FLUORESCENT	0x0502
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_COLDCATHODE	0x0503
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_NONDIM		0x0504
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_ELV		0x0505
#define RDM_PRODUCT_CATEGORY_DIMMER_AC_OTHER		0x0506
#define RDM_PRODUCT_CATEGORY_DIMMER_DC_LEVEL		0x0507
#define RDM_PRODUCT_CATEGORY_DIMMER_DC_PWM		0x0508
#define RDM_PRODUCT_CATEGORY_DIMMER_CS_LED		0x0509
#define RDM_PRODUCT_CATEGORY_DIMMER_OTHER		0x05FF
#define RDM_PRODUCT_CATEGORY_POWER			0x0600
#define RDM_PRODUCT_CATEGORY_POWER_CONTROL		0x0601
#define RDM_PRODUCT_CATEGORY_POWER_SOURCE		0x0602
#define RDM_PRODUCT_CATEGORY_POWER_OTHER		0x06FF
#define RDM_PRODUCT_CATEGORY_SCENIC			0x0700
#define RDM_PRODUCT_CATEGORY_SCENIC_DRIVE		0x0701
#define RDM_PRODUCT_CATEGORY_SCENIC_OTHER		0x07FF
#define RDM_PRODUCT_CATEGORY_DATA			0x0800
#define RDM_PRODUCT_CATEGORY_DATA_DISTRIBUTION		0x0801
#define RDM_PRODUCT_CATEGORY_DATA_CONVERSION		0x0802
#define RDM_PRODUCT_CATEGORY_DATA_OTHER			0x08FF
#define RDM_PRODUCT_CATEGORY_AV				0x0900
#define RDM_PRODUCT_CATEGORY_AV_AUDIO			0x0901
#define RDM_PRODUCT_CATEGORY_AV_VIDEO			0x0902
#define RDM_PRODUCT_CATEGORY_AV_OTHER			0x09FF
#define RDM_PRODUCT_CATEGORY_MONITOR			0x0A00
#define RDM_PRODUCT_CATEGORY_MONITOR_ACLINEPOWER	0x0A01
#define RDM_PRODUCT_CATEGORY_MONITOR_DCPOWER		0x0A02
#define RDM_PRODUCT_CATEGORY_MONITOR_ENVIRONMENTAL	0x0A03
#define RDM_PRODUCT_CATEGORY_MONITOR_OTHER		0x0AFF
#define RDM_PRODUCT_CATEGORY_CONTROL			0x7000
#define RDM_PRODUCT_CATEGORY_CONTROL_CONTROLLER		0x7001
#define RDM_PRODUCT_CATEGORY_CONTROL_BACKUPDEVICE	0x7002
#define RDM_PRODUCT_CATEGORY_CONTROL_OTHER		0x70FF
#define RDM_PRODUCT_CATEGORY_TEST			0x7100
#define RDM_PRODUCT_CATEGORY_TEST_EQUIPMENT		0x7101
#define RDM_PRODUCT_CATEGORY_TEST_EQUIPMENT_OTHER	0x71FF
#define RDM_PRODUCT_CATEGORY_OTHER			0x7FFF

static const value_string rdm_product_cat_vals[] = {
	{ RDM_PRODUCT_CATEGORY_NOT_DECLARED,		 "Not Declared" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE,			 "Fixture" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_FIXED,		 "Fixture Fixed" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_MOVING_YOKE,	 "Fixture Moving Yoke" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_MOVING_MIRROR,	 "Fixture Moving Mirror" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_OTHER,		 "Fixture Other" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY,	 "Fixture Accessory" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_COLOR,	 "Fixture Accessory Color" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_YOKE,	 "Fixture Accessory Yoke" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_MIRROR, "Fixture Accessory Mirror" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_EFFECT, "Fixture Accessory Effect" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_BEAM,	 "Fixture Accessory Beam" },
	{ RDM_PRODUCT_CATEGORY_FIXTURE_ACCESSORY_OTHER,	 "Fixture Accessory Other" },
	{ RDM_PRODUCT_CATEGORY_PROJECTOR,		 "Projector" },
	{ RDM_PRODUCT_CATEGORY_PROJECTOR_FIXED,		 "Projector Fixed" },
	{ RDM_PRODUCT_CATEGORY_PROJECTOR_MOVING_YOKE,	 "Projector Moving Yoke" },
	{ RDM_PRODUCT_CATEGORY_PROJECTOR_MOVING_MIRROR,	 "Projector Moving Mirror" },
	{ RDM_PRODUCT_CATEGORY_PROJECTOR_OTHER,		 "Projector Other" },
	{ RDM_PRODUCT_CATEGORY_ATMOSPHERIC,		 "Atmospheric" },
	{ RDM_PRODUCT_CATEGORY_ATMOSPHERIC_EFFECT,	 "Atmospheric Effect" },
	{ RDM_PRODUCT_CATEGORY_ATMOSPHERIC_PYRO,	 "Atmospheric Pyro" },
	{ RDM_PRODUCT_CATEGORY_ATMOSPHERIC_OTHER,	 "Atmospheric Other" },
	{ RDM_PRODUCT_CATEGORY_DIMMER,			 "Dimmer" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_INCANDESCENT,	 "Dimmer AC Incandescent" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_FLUORESCENT,	 "Dimmer AC Fluorescent" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_COLDCATHODE,	 "Dimmer AC Coldcathode" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_NONDIM,	 "Dimmer AC Nondim" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_ELV,		 "Dimmer AC ELV" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_AC_OTHER,		 "Dimmer AC Other" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_DC_LEVEL,		 "Dimmer DC Level" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_DC_PWM,		 "Dimmer DC PWM" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_CS_LED,		 "Dimmer CS LED" },
	{ RDM_PRODUCT_CATEGORY_DIMMER_OTHER,		 "Dimmer Other" },
	{ RDM_PRODUCT_CATEGORY_POWER,			 "Power" },
	{ RDM_PRODUCT_CATEGORY_POWER_CONTROL,		 "Power Control" },
	{ RDM_PRODUCT_CATEGORY_POWER_SOURCE,		 "Power Source" },
	{ RDM_PRODUCT_CATEGORY_POWER_OTHER,		 "Power Other" },
	{ RDM_PRODUCT_CATEGORY_SCENIC,			 "Scenic" },
	{ RDM_PRODUCT_CATEGORY_SCENIC_DRIVE,		 "Scenic Drive" },
	{ RDM_PRODUCT_CATEGORY_SCENIC_OTHER,		 "Scenic Other" },
	{ RDM_PRODUCT_CATEGORY_DATA,			 "Data" },
	{ RDM_PRODUCT_CATEGORY_DATA_DISTRIBUTION,	 "Data Distribution" },
	{ RDM_PRODUCT_CATEGORY_DATA_CONVERSION,		 "Data Conversion" },
	{ RDM_PRODUCT_CATEGORY_DATA_OTHER,		 "Data Other" },
	{ RDM_PRODUCT_CATEGORY_AV,			 "AV" },
	{ RDM_PRODUCT_CATEGORY_AV_AUDIO,		 "AV Audio" },
	{ RDM_PRODUCT_CATEGORY_AV_VIDEO,		 "AV Video" },
	{ RDM_PRODUCT_CATEGORY_AV_OTHER,		 "AV Other" },
	{ RDM_PRODUCT_CATEGORY_MONITOR,			 "Monitor" },
	{ RDM_PRODUCT_CATEGORY_MONITOR_ACLINEPOWER,	 "Monitor AC Line Power" },
	{ RDM_PRODUCT_CATEGORY_MONITOR_DCPOWER,		 "Monitor DC Power" },
	{ RDM_PRODUCT_CATEGORY_MONITOR_ENVIRONMENTAL,	 "Monitor Environmental" },
	{ RDM_PRODUCT_CATEGORY_MONITOR_OTHER,		 "Monitor Other" },
	{ RDM_PRODUCT_CATEGORY_CONTROL,			 "Control" },
	{ RDM_PRODUCT_CATEGORY_CONTROL_CONTROLLER,	 "Control Controller" },
	{ RDM_PRODUCT_CATEGORY_CONTROL_BACKUPDEVICE,	 "Control Backup Device" },
	{ RDM_PRODUCT_CATEGORY_CONTROL_OTHER,		 "Control Other" },
	{ RDM_PRODUCT_CATEGORY_TEST,			 "Test" },
	{ RDM_PRODUCT_CATEGORY_TEST_EQUIPMENT,		 "Test Equipment" },
	{ RDM_PRODUCT_CATEGORY_TEST_EQUIPMENT_OTHER,	 "Test Equipment Other" },
	{ RDM_PRODUCT_CATEGORY_OTHER,			 "Other" },
	{ 0, NULL },
};
static value_string_ext rdm_product_cat_vals_ext = VALUE_STRING_EXT_INIT(rdm_product_cat_vals);

static int proto_rdm = -1;

static int hf_rdm_sub_start_code = -1;
static int hf_rdm_message_length = -1;
static int hf_rdm_dest_uid = -1;
static int hf_rdm_src_uid = -1;
static int hf_rdm_transaction_number = -1;
static int hf_rdm_port_id = -1;
static int hf_rdm_response_type = -1;
static int hf_rdm_message_count = -1;
static int hf_rdm_sub_device = -1;
static int hf_rdm_mdb = -1;
static int hf_rdm_command_class = -1;
static int hf_rdm_parameter_id = -1;
static int hf_rdm_parameter_data_length = -1;
static int hf_rdm_parameter_data = -1;
static int hf_rdm_parameter_data_raw = -1;
static int hf_rdm_intron = -1;
static int hf_rdm_checksum = -1;
static int hf_rdm_checksum_status = -1;
static int hf_rdm_trailer = -1;

static int hf_rdm_pd_ack_timer_estimated_response_time = -1;
static int hf_rdm_pd_ack_overflow_uid = -1;
static int hf_rdm_pd_nack_reason_code = -1;

static int hf_rdm_pd_device_label = -1;

static int hf_rdm_pd_manu_label = -1;

static int hf_rdm_pd_dmx_start_address = -1;

static int hf_rdm_pd_queued_message_status = -1;

static int hf_rdm_pd_sensor_nr = -1;
static int hf_rdm_pd_sensor_type = -1;
static int hf_rdm_pd_sensor_unit = -1;
static int hf_rdm_pd_sensor_prefix = -1;
static int hf_rdm_pd_sensor_value_pres = -1;
static int hf_rdm_pd_sensor_value_low = -1;
static int hf_rdm_pd_sensor_value_high = -1;
static int hf_rdm_pd_sensor_value_rec = -1;

static int hf_rdm_pd_sensor_range_min_value = -1;
static int hf_rdm_pd_sensor_range_max_value = -1;
static int hf_rdm_pd_sensor_normal_min_value = -1;
static int hf_rdm_pd_sensor_normal_max_value = -1;
static int hf_rdm_pd_sensor_recorded_value_support = -1;
static int hf_rdm_pd_sensor_description = -1;

static int hf_rdm_pd_device_hours = -1;
static int hf_rdm_pd_lamp_hours = -1;
static int hf_rdm_pd_lamp_strikes = -1;


static int hf_rdm_pd_proto_vers = -1;
static int hf_rdm_pd_device_model_id = -1;
static int hf_rdm_pd_product_cat = -1;
static int hf_rdm_pd_software_vers_id = -1;
static int hf_rdm_pd_dmx_footprint = -1;
static int hf_rdm_pd_dmx_pers_current = -1;
static int hf_rdm_pd_dmx_pers_total = -1;
static int hf_rdm_pd_sub_device_count = -1;
static int hf_rdm_pd_sensor_count = -1;

static int hf_rdm_pd_device_model_description = -1;

static int hf_rdm_pd_disc_unique_branch_lb_uid = -1;
static int hf_rdm_pd_disc_unique_branch_ub_uid = -1;
static int hf_rdm_pd_disc_mute_control_field = -1;
static int hf_rdm_pd_disc_mute_binding_uid = -1;
static int hf_rdm_pd_disc_unmute_control_field = -1;
static int hf_rdm_pd_disc_unmute_binding_uid = -1;
static int hf_rdm_pd_proxied_devices_uid = -1;
static int hf_rdm_pd_proxied_device_count = -1;
static int hf_rdm_pd_proxied_device_list_change = -1;
static int hf_rdm_pd_real_time_clock_year = -1;
static int hf_rdm_pd_real_time_clock_month = -1;
static int hf_rdm_pd_real_time_clock_day = -1;
static int hf_rdm_pd_real_time_clock_hour = -1;
static int hf_rdm_pd_real_time_clock_minute = -1;
static int hf_rdm_pd_real_time_clock_second = -1;
static int hf_rdm_pd_lamp_state = -1;
static int hf_rdm_pd_lamp_on_mode = -1;
static int hf_rdm_pd_device_power_cycles = -1;
static int hf_rdm_pd_display_invert = -1;
static int hf_rdm_pd_display_level = -1;
static int hf_rdm_pd_pan_invert = -1;
static int hf_rdm_pd_tilt_invert = -1;
static int hf_rdm_pd_tilt_swap = -1;
static int hf_rdm_pd_selftest_nr = -1;
static int hf_rdm_pd_selftest_state = -1;
static int hf_rdm_pd_selftest_description = -1;
static int hf_rdm_pd_language_code = -1;
static int hf_rdm_pd_identify_device = -1;
static int hf_rdm_pd_identify_device_state = -1;
static int hf_rdm_pd_reset_device = -1;
static int hf_rdm_pd_power_state = -1;
static int hf_rdm_pd_capture_preset_scene_nr = -1;
static int hf_rdm_pd_capture_preset_up_fade_time = -1;
static int hf_rdm_pd_capture_preset_down_fade_time = -1;
static int hf_rdm_pd_capture_preset_wait_time = -1;
static int hf_rdm_pd_preset_playback_mode = -1;
static int hf_rdm_pd_preset_playback_level = -1;
static int hf_rdm_pd_parameter_id = -1;
static int hf_rdm_pd_parameter_pdl_size = -1;
static int hf_rdm_pd_parameter_data_type = -1;
static int hf_rdm_pd_parameter_cmd_class = -1;
static int hf_rdm_pd_parameter_type = -1;
static int hf_rdm_pd_parameter_unit = -1;
static int hf_rdm_pd_parameter_prefix = -1;
static int hf_rdm_pd_parameter_min_value = -1;
static int hf_rdm_pd_parameter_max_value = -1;
static int hf_rdm_pd_parameter_default_value = -1;
static int hf_rdm_pd_parameter_description = -1;
static int hf_rdm_pd_software_version_label = -1;
static int hf_rdm_pd_boot_software_version_id = -1;
static int hf_rdm_pd_boot_software_version_label = -1;
static int hf_rdm_pd_comms_status_short_msg = -1;
static int hf_rdm_pd_comms_status_len_mismatch = -1;
static int hf_rdm_pd_comms_status_csum_fail = -1;
static int hf_rdm_pd_status_messages_type = -1;
static int hf_rdm_pd_status_messages_sub_device_id = -1;
static int hf_rdm_pd_status_messages_id = -1;
static int hf_rdm_pd_status_messages_data_value_1 = -1;
static int hf_rdm_pd_status_messages_data_value_2 = -1;
static int hf_rdm_pd_status_id = -1;
static int hf_rdm_pd_status_id_description = -1;
static int hf_rdm_pd_sub_device_status_report_threshold_status_type = -1;
static int hf_rdm_pd_product_detail_id_list = -1;
static int hf_rdm_pd_factory_defaults = -1;
static int hf_rdm_pd_dmx_pers_nr = -1;
static int hf_rdm_pd_dmx_pers_count = -1;
static int hf_rdm_pd_dmx_pers_requested = -1;
static int hf_rdm_pd_dmx_pers_slots = -1;
static int hf_rdm_pd_dmx_pers_text = -1;
static int hf_rdm_pd_slot_offset = -1;
static int hf_rdm_pd_slot_type = -1;
static int hf_rdm_pd_slot_label_id = -1;
static int hf_rdm_pd_slot_nr = -1;
static int hf_rdm_pd_slot_description = -1;
static int hf_rdm_pd_slot_value = -1;
static int hf_rdm_pd_rec_value_support = -1;

static int ett_rdm = -1;

static expert_field ei_rdm_checksum = EI_INIT;

static guint16
rdm_checksum(tvbuff_t *tvb, guint length)
{
	guint16 sum = RDM_SC_RDM;
	guint	i;
	for (i = 0; i < length; i++)
		sum += tvb_get_guint8(tvb, i);
	return sum;
}

static guint
dissect_rdm_pd_queued_message(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_queued_message_status, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_dmx_start_address(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_dmx_start_address, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_device_info(tvbuff_t *tvb _U_, guint offset, proto_tree *tree _U_, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_proto_vers, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_device_model_id, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_product_cat, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_software_vers_id, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset +=  4;

		proto_tree_add_item(tree, hf_rdm_pd_dmx_footprint, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_current, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_total, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_dmx_start_address, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sub_device_count, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_count, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_device_model_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_device_model_description, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset +=  len;
		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_device_label(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_device_label, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset +=  len;
		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_device_hours(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_device_hours, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset +=  4;
		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_lamp_hours(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_lamp_hours, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset +=  4;
		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_lamp_strikes(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_lamp_strikes, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset +=  4;
		break;
	}

	return offset;
}


static guint
dissect_rdm_pd_sensor_definition(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_unit, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_prefix, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_range_min_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_range_max_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_normal_min_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_normal_max_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_recorded_value_support, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		proto_tree_add_item(tree, hf_rdm_pd_sensor_description, tvb,
			offset, len - 13, ENC_ASCII|ENC_NA);
		offset += (len - 13);
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_sensor_value(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
	case RDM_CC_SET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_value_pres, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset +=  2;

		if (len == 7 || len == 9) {
			proto_tree_add_item(tree, hf_rdm_pd_sensor_value_low, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset +=  2;
			proto_tree_add_item(tree, hf_rdm_pd_sensor_value_high, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset +=  2;
		}

		if (len == 5 || len == 9) {
			proto_tree_add_item(tree, hf_rdm_pd_sensor_value_rec, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset +=  2;
		}

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_manufacturer_label(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_manu_label, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset +=  len;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_disc_unique_branch(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_DISCOVERY_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_disc_unique_branch_lb_uid, tvb,
			offset, 6, ENC_NA);
		offset += 6;

		proto_tree_add_item(tree, hf_rdm_pd_disc_unique_branch_ub_uid, tvb,
			offset, 6, ENC_NA);
		offset += 6;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_disc_mute(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_DISCOVERY_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_disc_mute_control_field, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		if (len > 2) {
			proto_tree_add_item(tree, hf_rdm_pd_disc_mute_binding_uid, tvb,
				offset, 6, ENC_NA);
			offset += 6;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_disc_un_mute(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_DISCOVERY_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_disc_unmute_control_field, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		if (len > 2) {
			proto_tree_add_item(tree, hf_rdm_pd_disc_unmute_binding_uid, tvb,
				offset, 6, ENC_NA);
			offset += 6;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_proxied_devices(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 6) {
			proto_tree_add_item(tree, hf_rdm_pd_proxied_devices_uid, tvb,
				offset, 6, ENC_NA);
			offset += 6;
			len    -= 6;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_proxied_device_count(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_proxied_device_count, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_proxied_device_list_change, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_comms_status(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_comms_status_short_msg, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_comms_status_len_mismatch, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_comms_status_csum_fail, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_status_messages(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_status_messages_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 9) {
			proto_tree_add_item(tree, hf_rdm_pd_status_messages_sub_device_id, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
			proto_tree_add_item(tree, hf_rdm_pd_status_messages_type, tvb,
				offset, 1, ENC_BIG_ENDIAN);
			offset += 1;
			len    -= 1;
			proto_tree_add_item(tree, hf_rdm_pd_status_messages_id, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
			proto_tree_add_item(tree, hf_rdm_pd_status_messages_data_value_1, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
			proto_tree_add_item(tree, hf_rdm_pd_status_messages_data_value_2, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_status_id_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_status_id, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_status_id_description, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset += len;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_clear_status_id(tvbuff_t *tvb _U_, guint offset, proto_tree *tree _U_, guint8 cc _U_, guint8 len _U_)
{
	return offset;
}

static guint
dissect_rdm_pd_sub_device_status_report_threshold(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_sub_device_status_report_threshold_status_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_supported_parameters(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 2) {
			proto_tree_add_item(tree, hf_rdm_pd_parameter_id, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_parameter_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_parameter_id, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_parameter_id, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_pdl_size, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_data_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_cmd_class, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_unit, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_prefix, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_min_value, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset += 4;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_max_value, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset += 4;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_default_value, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset += 4;
		proto_tree_add_item(tree, hf_rdm_pd_parameter_description, tvb,
			offset, len - 0x14, ENC_ASCII|ENC_NA);
		offset += (len - 0x14);
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_product_detail_id_list(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 2) {
			proto_tree_add_item(tree, hf_rdm_pd_product_detail_id_list, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_factory_defaults(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_factory_defaults, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_language_capabilities(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 2) {
			proto_tree_add_item(tree, hf_rdm_pd_language_code, tvb,
				offset, 2, ENC_ASCII|ENC_NA);
			offset += 2;
			len    -= 2;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_language(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_language_code, tvb,
			offset, 2, ENC_ASCII|ENC_NA);
		offset += 2;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_software_version_label(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_software_version_label, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset += len;

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_boot_software_version_id(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_boot_software_version_id, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset += 4;

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_boot_software_version_label(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_boot_software_version_label, tvb,
			offset, len, ENC_ASCII|ENC_NA);
		offset += len;

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_dmx_personality(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_current, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_count, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_dmx_personality_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_requested, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_requested, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_slots, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_dmx_pers_text, tvb,
			offset, (len - 3), ENC_ASCII|ENC_NA);
		offset += (len - 3);
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_slot_info(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 5) {
			proto_tree_add_item(tree, hf_rdm_pd_slot_offset, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
			proto_tree_add_item(tree, hf_rdm_pd_slot_type, tvb,
				offset, 1, ENC_BIG_ENDIAN);
			offset += 1;
			len    -= 1;
			proto_tree_add_item(tree, hf_rdm_pd_slot_label_id, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_slot_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_slot_nr, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_slot_nr, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_slot_description, tvb,
			offset, (len - 2), ENC_ASCII|ENC_NA);
		offset += (len - 2);
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_slot_value(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND_RESPONSE:
		while (len >= 3) {
			proto_tree_add_item(tree, hf_rdm_pd_slot_offset, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			len    -= 2;
			proto_tree_add_item(tree, hf_rdm_pd_slot_value, tvb,
				offset, 1, ENC_BIG_ENDIAN);
			offset += 1;
			len    -= 1;
		}
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_record_sensors(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_sensor_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_type, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_unit, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_prefix, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_range_min_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_range_max_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_normal_min_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_normal_max_value, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_rec_value_support, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_sensor_description, tvb,
			offset, (len - 13), ENC_ASCII|ENC_NA);
		offset += (len - 13);

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_lamp_state(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_lamp_state, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_lamp_on_mode(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_lamp_on_mode, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_device_power_cycles(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_device_power_cycles, tvb,
			offset, 4, ENC_BIG_ENDIAN);
		offset += 4;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_display_invert(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_display_invert, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_display_level(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_display_level, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_pan_invert(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_pan_invert, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_tilt_invert(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_tilt_invert, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_pan_tilt_swap(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_tilt_swap, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_real_time_clock(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_year, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_month, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_day, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_hour, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_minute, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_real_time_clock_second, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_identify_device(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_identify_device, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_identify_device_state, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_reset_device(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_reset_device, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_power_state(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_power_state, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_perform_selftest(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_selftest_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_selftest_state, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_self_test_description(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len)
{
	switch(cc) {
	case RDM_CC_GET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_selftest_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;

	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_selftest_nr, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		proto_tree_add_item(tree, hf_rdm_pd_selftest_description, tvb,
			offset, (len - 1), ENC_ASCII|ENC_NA);
		offset += (len - 1);
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_capture_preset(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
		proto_tree_add_item(tree, hf_rdm_pd_capture_preset_scene_nr, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_capture_preset_up_fade_time, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_capture_preset_down_fade_time, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_capture_preset_wait_time, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;

		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_preset_playback(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint8 len _U_)
{
	switch(cc) {
	case RDM_CC_SET_COMMAND:
	case RDM_CC_GET_COMMAND_RESPONSE:
		proto_tree_add_item(tree, hf_rdm_pd_preset_playback_mode, tvb,
			offset, 2, ENC_BIG_ENDIAN);
		offset += 2;
		proto_tree_add_item(tree, hf_rdm_pd_preset_playback_level, tvb,
			offset, 1, ENC_BIG_ENDIAN);
		offset += 1;
		break;
	}

	return offset;
}

static guint
dissect_rdm_mdb_param_data(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint16 param_id, guint8 pdl)
{
	switch(param_id) {
	case RDM_PARAM_ID_SENSOR_VALUE:
		offset = dissect_rdm_pd_sensor_value(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_QUEUED_MESSAGE:
		offset = dissect_rdm_pd_queued_message(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DMX_START_ADDRESS:
		offset = dissect_rdm_pd_dmx_start_address(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEVICE_INFO:
		offset = dissect_rdm_pd_device_info(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEVICE_MODEL_DESCRIPTION:
		offset = dissect_rdm_pd_device_model_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEVICE_LABEL:
		offset = dissect_rdm_pd_device_label(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEVICE_HOURS:
		offset = dissect_rdm_pd_device_hours(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LAMP_HOURS:
		offset = dissect_rdm_pd_lamp_hours(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LAMP_STRIKES:
		offset = dissect_rdm_pd_lamp_strikes(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SENSOR_DEFINITION:
		offset = dissect_rdm_pd_sensor_definition(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_MANUFACTURER_LABEL:
		offset = dissect_rdm_pd_manufacturer_label(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DISC_UNIQUE_BRANCH:
		offset = dissect_rdm_pd_disc_unique_branch(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DISC_MUTE:
		offset = dissect_rdm_pd_disc_mute(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DISC_UN_MUTE:
		offset = dissect_rdm_pd_disc_un_mute(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PROXIED_DEVICES:
		offset = dissect_rdm_pd_proxied_devices(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PROXIED_DEVICE_COUNT:
		offset = dissect_rdm_pd_proxied_device_count(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_COMMS_STATUS:
		offset = dissect_rdm_pd_comms_status(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_STATUS_MESSAGES:
		offset = dissect_rdm_pd_status_messages(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_STATUS_ID_DESCRIPTION:
		offset = dissect_rdm_pd_status_id_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_CLEAR_STATUS_ID:
		offset = dissect_rdm_pd_clear_status_id(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SUB_DEVICE_STATUS_REPORT_THRESHOLD:
		offset = dissect_rdm_pd_sub_device_status_report_threshold(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SUPPORTED_PARAMETERS:
		offset = dissect_rdm_pd_supported_parameters(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PARAMETER_DESCRIPTION:
		offset = dissect_rdm_pd_parameter_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PRODUCT_DETAIL_ID_LIST:
		offset = dissect_rdm_pd_product_detail_id_list(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_FACTORY_DEFAULTS:
		offset = dissect_rdm_pd_factory_defaults(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LANGUAGE_CAPABILITIES:
		offset = dissect_rdm_pd_language_capabilities(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LANGUAGE:
		offset = dissect_rdm_pd_language(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SOFTWARE_VERSION_LABEL:
		offset = dissect_rdm_pd_software_version_label(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_ID:
		offset = dissect_rdm_pd_boot_software_version_id(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_BOOT_SOFTWARE_VERSION_LABEL:
		offset = dissect_rdm_pd_boot_software_version_label(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DMX_PERSONALITY:
		offset = dissect_rdm_pd_dmx_personality(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DMX_PERSONALITY_DESCRIPTION:
		offset = dissect_rdm_pd_dmx_personality_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SLOT_INFO:
		offset = dissect_rdm_pd_slot_info(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SLOT_DESCRIPTION:
		offset = dissect_rdm_pd_slot_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEFAULT_SLOT_VALUE:
		offset = dissect_rdm_pd_slot_value(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_RECORD_SENSORS:
		offset = dissect_rdm_pd_record_sensors(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LAMP_STATE:
		offset = dissect_rdm_pd_lamp_state(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_LAMP_ON_MODE:
		offset = dissect_rdm_pd_lamp_on_mode(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DEVICE_POWER_CYCLES:
		offset = dissect_rdm_pd_device_power_cycles(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DISPLAY_INVERT:
		offset = dissect_rdm_pd_display_invert(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_DISPLAY_LEVEL:
		offset = dissect_rdm_pd_display_level(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PAN_INVERT:
		offset = dissect_rdm_pd_pan_invert(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_TILT_INVERT:
		offset = dissect_rdm_pd_tilt_invert(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PAN_TILT_SWAP:
		offset = dissect_rdm_pd_pan_tilt_swap(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_REAL_TIME_CLOCK:
		offset = dissect_rdm_pd_real_time_clock(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_IDENTIFY_DEVICE:
		offset = dissect_rdm_pd_identify_device(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_RESET_DEVICE:
		offset = dissect_rdm_pd_reset_device(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_POWER_STATE:
		offset = dissect_rdm_pd_power_state(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PERFORM_SELFTEST:
		offset = dissect_rdm_pd_perform_selftest(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_SELF_TEST_DESCRIPTION:
		offset = dissect_rdm_pd_self_test_description(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_CAPTURE_PRESET:
		offset = dissect_rdm_pd_capture_preset(tvb, offset, tree, cc, pdl);
		break;

	case RDM_PARAM_ID_PRESET_PLAYBACK:
		offset = dissect_rdm_pd_preset_playback(tvb, offset, tree, cc, pdl);
		break;

	default:
		proto_tree_add_item(tree, hf_rdm_parameter_data_raw, tvb,
			offset, pdl, ENC_NA);
		offset += pdl;
		break;
	}

	return offset;
}

static guint
dissect_rdm_pd_ack_overflow(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint16 param_id _U_, guint8 pdl)
{
	if (pdl > 0) {
		int i;

		switch(cc) {
		case RDM_CC_GET_COMMAND_RESPONSE:
		case RDM_CC_SET_COMMAND_RESPONSE:
			for (i = 0; i < (pdl / 6); i++) {
				proto_tree_add_item(tree, hf_rdm_pd_ack_overflow_uid, tvb,
						offset, 6, ENC_NA);
				offset += 6;
			}
			break;
		}
	}

	return offset;
}

static guint
dissect_rdm_pd_ack_timer(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint16 param_id _U_, guint8 pdl)
{
	if (pdl == 2) {
		switch(cc) {
		case RDM_CC_GET_COMMAND_RESPONSE:
		case RDM_CC_SET_COMMAND_RESPONSE:
			proto_tree_add_item(tree, hf_rdm_pd_ack_timer_estimated_response_time, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			break;
		}
	}
	return offset;
}

static guint
dissect_rdm_pd_nack_reason(tvbuff_t *tvb, guint offset, proto_tree *tree, guint8 cc, guint16 param_id _U_, guint8 pdl _U_)
{
	if (pdl == 2) {
		switch(cc) {
		case RDM_CC_GET_COMMAND_RESPONSE:
		case RDM_CC_SET_COMMAND_RESPONSE:
			proto_tree_add_item(tree, hf_rdm_pd_nack_reason_code, tvb,
				offset, 2, ENC_BIG_ENDIAN);
			offset += 2;
			break;
		}
	}

	return offset;
}

static guint
dissect_rdm_mdb(tvbuff_t *tvb, guint offset, proto_tree *tree)
{
	guint8      cc;
	guint8      rt;
	guint16	    param_id;
	guint8	    parameter_data_length;
	proto_tree *hi,*si, *mdb_tree;

	rt = tvb_get_guint8(tvb, offset);
	cc = tvb_get_guint8(tvb, offset + 4);

	if ((cc & RDM_CC_COMMAND_RESPONSE_FLAG) == RDM_CC_COMMAND_RESPONSE_FLAG) {
		proto_tree_add_item(tree, hf_rdm_response_type, tvb,
				offset, 1, ENC_BIG_ENDIAN);
	        offset += 1;

	} else {
		proto_tree_add_item(tree, hf_rdm_port_id, tvb,
		                offset, 1, ENC_BIG_ENDIAN);
	        offset += 1;
	}

	proto_tree_add_item(tree, hf_rdm_message_count, tvb,
			offset, 1, ENC_BIG_ENDIAN);
	offset += 1;

	proto_tree_add_item(tree, hf_rdm_sub_device, tvb,
			offset, 2, ENC_BIG_ENDIAN);
	offset += 2;

	hi = proto_tree_add_item(tree, hf_rdm_mdb, tvb,
			offset, -1, ENC_NA);
	mdb_tree = proto_item_add_subtree(hi,ett_rdm);

	proto_tree_add_item(mdb_tree, hf_rdm_command_class, tvb,
			offset, 1, ENC_BIG_ENDIAN);
	offset += 1;

	param_id = tvb_get_ntohs(tvb, offset);
	proto_tree_add_item(mdb_tree, hf_rdm_parameter_id, tvb,
			offset, 2, ENC_BIG_ENDIAN);
	offset += 2;

	parameter_data_length = tvb_get_guint8(tvb, offset);
	proto_tree_add_item(mdb_tree, hf_rdm_parameter_data_length, tvb,
			offset, 1, ENC_BIG_ENDIAN);
	offset += 1;
	proto_item_set_len( mdb_tree,  parameter_data_length + 4);

	if (parameter_data_length > 0) {

		hi = proto_tree_add_item(mdb_tree, hf_rdm_parameter_data, tvb,
				offset, parameter_data_length, ENC_NA);
		si = proto_item_add_subtree(hi,ett_rdm);

		if ((cc & RDM_CC_COMMAND_RESPONSE_FLAG) == RDM_CC_COMMAND_RESPONSE_FLAG) {

			switch(rt) {
			case RDM_RESPONSE_TYPE_ACK:
				offset = dissect_rdm_mdb_param_data(tvb, offset, si, cc, param_id, parameter_data_length);
				break;
			case RDM_RESPONSE_TYPE_ACK_TIMER:
				offset = dissect_rdm_pd_ack_timer(tvb, offset, si, cc, param_id, parameter_data_length);
				break;
			case RDM_RESPONSE_TYPE_NACK_REASON:
				offset = dissect_rdm_pd_nack_reason(tvb, offset, si, cc, param_id, parameter_data_length);
				break;
			case RDM_RESPONSE_TYPE_ACK_OVERFLOW:
				offset = dissect_rdm_pd_ack_overflow(tvb, offset, si, cc, param_id, parameter_data_length);
				break;
			}

		} else {
			offset = dissect_rdm_mdb_param_data(tvb, offset, si, cc, param_id, parameter_data_length);
		}
	}

	return offset;
}

static int
dissect_rdm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
	col_set_str(pinfo->cinfo, COL_PROTOCOL, "RDM");
	col_clear(pinfo->cinfo, COL_INFO);

	if (tree) {
		gint	    padding_size;
		guint16	    man_id;
		guint32	    dev_id;
		guint       message_length, offset = 0;

		proto_tree *ti = proto_tree_add_item(tree, proto_rdm, tvb,
				offset, -1, ENC_NA);
		proto_tree *rdm_tree = proto_item_add_subtree(ti, ett_rdm);

		proto_tree_add_item(rdm_tree, hf_rdm_sub_start_code, tvb,
				offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		message_length = tvb_get_guint8(tvb, offset);
		proto_tree_add_item(rdm_tree, hf_rdm_message_length, tvb,
				offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		man_id = tvb_get_ntohs(tvb, offset);
		dev_id = tvb_get_ntohl(tvb, offset + 2);
		proto_item_append_text(ti, ", Dst UID: %04x:%08x", man_id, dev_id);
		proto_tree_add_item(rdm_tree, hf_rdm_dest_uid, tvb,
				offset, 6, ENC_NA);
		offset += 6;


		man_id = tvb_get_ntohs(tvb, offset);
		dev_id = tvb_get_ntohl(tvb, offset + 2);
		proto_item_append_text(ti, ", Src UID: %04x:%08x", man_id, dev_id);
		proto_tree_add_item(rdm_tree, hf_rdm_src_uid, tvb,
				offset, 6, ENC_NA);
		offset += 6;

		proto_tree_add_item(rdm_tree, hf_rdm_transaction_number, tvb,
				offset, 1, ENC_BIG_ENDIAN);
		offset += 1;

		offset = dissect_rdm_mdb(tvb, offset, rdm_tree);

		padding_size = offset - (message_length - 1);
		if (padding_size > 0) {
			proto_tree_add_item(rdm_tree, hf_rdm_intron, tvb,
					offset, padding_size, ENC_NA);
			offset += padding_size;
		}

		proto_tree_add_checksum(rdm_tree, tvb, offset, hf_rdm_checksum, hf_rdm_checksum_status, &ei_rdm_checksum, pinfo, rdm_checksum(tvb, offset),
							ENC_BIG_ENDIAN, PROTO_CHECKSUM_VERIFY);
		offset += 2;

		if (offset < tvb_reported_length(tvb))
			proto_tree_add_item(rdm_tree, hf_rdm_trailer, tvb,
					offset, -1, ENC_NA);
	}
	return tvb_captured_length(tvb);
}

void
proto_register_rdm(void)
{
	static hf_register_info hf[] = {
		{ &hf_rdm_sub_start_code,
			{ "Sub-start code", "rdm.ssc",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_message_length,
			{ "Message length", "rdm.len",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_dest_uid,
			{ "Destination UID", "rdm.dst",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_src_uid,
			{ "Source UID", "rdm.src",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_transaction_number,
			{ "Transaction number", "rdm.tn",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_port_id,
			{ "Port ID", "rdm.port_id",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_response_type,
			{ "Response type", "rdm.rt",
				FT_UINT8, BASE_HEX, VALS(rdm_rt_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_message_count,
			{ "Message count", "rdm.mc",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_sub_device,
			{ "Sub-device", "rdm.sd",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_mdb,
			{ "Message Data Block", "rdm.mdb",
				FT_NONE, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_command_class,
			{ "Command class", "rdm.cc",
				FT_UINT8, BASE_HEX, VALS(rdm_cc_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_parameter_id,
			{ "Parameter ID", "rdm.pid",
				FT_UINT16, BASE_HEX | BASE_EXT_STRING, &rdm_param_id_vals_ext, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_parameter_data_length,
			{ "Parameter data length", "rdm.pdl",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_parameter_data,
			{ "Parameter data", "rdm.pd",
				FT_NONE, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_parameter_data_raw,
			{ "Raw Data", "rdm.pd.raw",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_intron,
			{ "Intron", "rdm.intron",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_checksum,
			{ "Checksum", "rdm.checksum",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_checksum_status,
			{ "Checksum Status", "rdm.checksum.status",
				FT_UINT8, BASE_NONE, VALS(proto_checksum_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_trailer,
			{ "Trailer", "rdm.trailer",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_ack_overflow_uid,
			{ "UID", "rdm.pd.ack_overflow.uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_ack_timer_estimated_response_time,
			{ "Estimated Response Time", "rdm.pd.ack_timer.estimated_response_time",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_nack_reason_code,
			{ "NACK Reason Code", "rdm.pd.nack_reason.code",
				FT_UINT16, BASE_HEX, VALS(rdm_nr_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_queued_message_status,
			{ "Status", "rdm.pd.queued_message.status",
				FT_UINT8, BASE_HEX, VALS(rdm_status_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_nr,
			{ "Sensor Nr.", "rdm.pd.sensor.nr",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_value_pres,
			{ "Sensor Present Value", "rdm.pd.sensor.value.present",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_value_low,
			{ "Sensor Lowest Value", "rdm.pd.sensor.value.lowest",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_value_high,
			{ "Sensor Highest Value", "rdm.pd.sensor.value.highest",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_value_rec,
			{ "Sensor Recorded Value", "rdm.pd.sensor.value.recorded",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_range_min_value,
			{ "Sensor Range Min. Value", "rdm.pd.sensor.range.min_value",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_range_max_value,
			{ "Sensor Range Max. Value", "rdm.pd.sensor.range.max_value",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_normal_min_value,
			{ "Sensor Normal Min. Value", "rdm.pd.sensor.normal.min_value",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_normal_max_value,
			{ "Sensor Normal Max. Value", "rdm.pd.sensor.normal.max_value",
				FT_INT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_recorded_value_support,
			{ "Sensor Recorded Value Support", "rdm.pd.sensor.recorded_value_support",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_type,
			{ "Sensor Type", "rdm.pd.sensor_type",
				FT_UINT8, BASE_HEX | BASE_EXT_STRING, &rdm_sensor_type_vals_ext, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_unit,
			{ "Sensor Unit", "rdm.pd.sensor_unit",
				FT_UINT8, BASE_HEX | BASE_EXT_STRING, &rdm_unit_vals_ext, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_prefix,
			{ "Sensor Prefix", "rdm.pd.sensor_prefix",
				FT_UINT8, BASE_HEX | BASE_EXT_STRING, &rdm_prefix_vals_ext, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_description,
			{ "Sensor Description", "rdm.pd.sensor.description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_manu_label,
			{ "Manufacturer Label", "rdm.pd.manu_label",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},


		{ &hf_rdm_pd_device_label,
			{ "Device Label", "rdm.pd.device_label",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_start_address,
			{ "DMX Start Address", "rdm.pd.dmx_start_address",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_device_hours,
			{ "Device Hours", "rdm.pd.device_hours",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_lamp_hours,
			{ "Lamp Hours", "rdm.pd.lamp_hours",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_lamp_strikes,
			{ "Lamp Strikes", "rdm.pd.lamp_strikes",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_proto_vers,
			{ "RDM Protocol Version", "rdm.pd.proto_vers",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_device_model_id,
			{ "Device Model ID", "rdm.pd.device_model_id",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_product_cat,
			{ "Product Category", "rdm.pd.product_cat",
				FT_UINT16, BASE_HEX | BASE_EXT_STRING, &rdm_product_cat_vals_ext, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_software_vers_id,
			{ "Software Version ID", "rdm.pd.software_version_id",
				FT_UINT32, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_footprint,
			{ "DMX Footprint", "rdm.pd.dmx_footprint",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_current,
			{ "Current DMX Personality", "rdm.pd.dmx_pers_current",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_total,
			{ "Total nr. DMX Personalities", "rdm.pd.dmx_pers_total",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sub_device_count,
			{ "Sub-Device Count", "rdm.pd.sub_device_count",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sensor_count,
			{ "Sensor Count", "rdm.pd.sensor_count",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_device_model_description,
			{ "Device Model Description", "rdm.pd.device_model_description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_unique_branch_lb_uid,
			{ "Lower Bound UID", "rdm.pd.disc_unique_branch.lb_uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_unique_branch_ub_uid,
			{ "Upper Bound UID", "rdm.pd.disc_unique_branch.ub_uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_mute_control_field,
			{ "Control Field", "rdm.pd.disc_mute.control_field",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_mute_binding_uid,
			{ "Binding UID", "rdm.pd.disc_mute.binding_uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_unmute_control_field,
			{ "Control Field", "rdm.pd.disc_unmute.control_field",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_disc_unmute_binding_uid,
			{ "Binding UID", "rdm.pd.disc_unmute.binding_uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_proxied_devices_uid,
			{ "UID", "rdm.pd.proxied_devices.uid",
				FT_BYTES, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_proxied_device_count,
			{ "Device Count", "rdm.pd.device_count",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_proxied_device_list_change,
			{ "List Change", "rdm.pd.list_change",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_year,
			{ "Year", "rdm.pd.real_time_clock.year",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_month,
			{ "Month", "rdm.pd.real_time_clock.month",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_day,
			{ "Day", "rdm.pd.real_time_clock.day",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_hour,
			{ "Hour", "rdm.pd.real_time_clock.hour",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_minute,
			{ "Minute", "rdm.pd.real_time_clock.minute",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_real_time_clock_second,
			{ "Second", "rdm.pd.real_time_clock.second",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_lamp_state,
			{ "Lamp State", "rdm.pd.lamp_state",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_lamp_on_mode,
			{ "Lamp On Mode", "rdm.pd.lamp_on_mode",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_device_power_cycles,
			{ "Device Power Cycles", "rdm.pd.device_power_cycles",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_display_invert,
			{ "Display Invert", "rdm.pd.display_invert",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_display_level,
			{ "Display Level", "rdm.pd.display_level",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_pan_invert,
			{ "Pan Invert", "rdm.pd.pan_invert",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_tilt_invert,
			{ "Tilt Invert", "rdm.pd.tilt_invert",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_tilt_swap,
			{ "Tilt Swap", "rdm.pd.tilt_swap",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_selftest_nr,
			{ "Selftest Nr.", "rdm.pd.selftest.nr",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_selftest_state,
			{ "Selftest State", "rdm.pd.selftest.state",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_selftest_description,
			{ "Selftest Description", "rdm.pd.selftest.description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_language_code,
			{ "Language Code", "rdm.pd.language_code",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_identify_device,
			{ "Identify Device", "rdm.pd.identify_device",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_identify_device_state,
			{ "Identify Device State", "rdm.pd.identify_device.state",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_reset_device,
			{ "Reset Device", "rdm.pd.reset_device",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_power_state,
			{ "Power State", "rdm.pd.power_state",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_capture_preset_scene_nr,
			{ "Scene Nr.", "rdm.pd.capture_preset.scene_nr",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_capture_preset_up_fade_time,
			{ "Up Fade Time", "rdm.pd.capture_preset.up_fade_time",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_capture_preset_down_fade_time,
			{ "Down Fade Time", "rdm.pd.capture_preset.down_fade_time",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_capture_preset_wait_time,
			{ "Wait Time", "rdm.pd.capture_preset.wait_time",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_preset_playback_mode,
			{ "Mode", "rdm.pd.preset_playback.mode",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_preset_playback_level,
			{ "Level", "rdm.pd.preset_playback.level",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_id,
			{ "ID", "rdm.pd.parameter.id",
				FT_UINT16, BASE_HEX, VALS(rdm_param_id_vals), 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_pdl_size,
			{ "PDL Size", "rdm.pd.parameter.pdl_size",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_data_type,
			{ "Data Type", "rdm.pd.parameter.data_type",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_cmd_class,
			{ "Command Class", "rdm.pd.parameter.cmd_class",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_type,
			{ "Type", "rdm.pd.parameter.type",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_unit,
			{ "Unit", "rdm.pd.parameter.unit",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_prefix,
			{ "Prefix", "rdm.pd.parameter.prefix",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_min_value,
			{ "Min. Value", "rdm.pd.parameter.min_value",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_max_value,
			{ "Max. Value", "rdm.pd.parameter.max_value",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_default_value,
			{ "Default Value", "rdm.pd.parameter.default_value",
				FT_UINT32, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_parameter_description,
			{ "Description", "rdm.pd.parameter.description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_software_version_label,
			{ "Version Label", "rdm.pd.software_version.label",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_boot_software_version_id,
			{ "Version ID", "rdm.pd.boot_software_version.id",
				FT_UINT32, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_boot_software_version_label,
			{ "Version Label", "rdm.pd.boot_software_version.label",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_comms_status_short_msg,
			{ "Short Msg", "rdm.pd.comms_status.short_msg",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_comms_status_len_mismatch,
			{ "Len Mismatch", "rdm.pd.comms_status.len_mismatch",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_comms_status_csum_fail,
			{ "Checksum Fail", "rdm.pd.comms_status.csum_fail",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_messages_type,
			{ "Type", "rdm.pd.status_messages.type",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_messages_sub_device_id,
			{ "Sub. Device ID", "rdm.pd.status_messages.sub_devices_id",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_messages_id,
			{ "ID", "rdm.pd.status_messages.id",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_messages_data_value_1,
			{ "Data Value 1", "rdm.pd.status_messages.data_value_1",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_messages_data_value_2,
			{ "Data Value 2", "rdm.pd.status_messages.data_value_2",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_id,
			{ "ID", "rdm.pd.status_id",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_status_id_description,
			{ "Description", "rdm.pd.status_id.description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_sub_device_status_report_threshold_status_type,
			{ "Status Type", "rdm.pd.sub_device_status_report_threshold.status_type",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_product_detail_id_list,
			{ "Sensor Count", "rdm.pd.product_detail_id_list",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_factory_defaults,
			{ "Factory Defaults", "rdm.pd.factory_defaults",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_nr,
			{ "DMX Pers. Nr.", "rdm.pd.dmx_pers.nr",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_count,
			{ "DMX Pers. Count", "rdm.pd.dmx_pers.count",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_requested,
			{ "DMX Pers. Requested", "rdm.pd.dmx_pers.requested",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_slots,
			{ "DMX Pers. Slots", "rdm.pd.dmx_pers.slots",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_dmx_pers_text,
			{ "DMX Pers. Text", "rdm.pd.dmx_pers.text",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_offset,
			{ "Slot Offset", "rdm.pd.slot_offset",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_type,
			{ "Slot Type", "rdm.pd.slot_type",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_label_id,
			{ "Slot Label ID", "rdm.pd.slot_label_id",
				FT_UINT16, BASE_HEX, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_nr,
			{ "Slot Nr.", "rdm.pd.slot_nr",
				FT_UINT16, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_description,
			{ "Slot Description", "rdm.pd.slot_description",
				FT_STRING, BASE_NONE, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_slot_value,
			{ "Slot Value", "rdm.pd.slot_value",
				FT_UINT8, BASE_DEC, NULL, 0x0,
				NULL, HFILL }},

		{ &hf_rdm_pd_rec_value_support,
			{ "Rec. Value Support", "rdm.pd.rec_value_support",
				FT_UINT8, BASE_HEX, NULL, 0x0,
				NULL, HFILL }}
	};

	static gint *ett[] = {
		&ett_rdm
	};

	static ei_register_info ei[] = {
		{ &ei_rdm_checksum, { "rdm.bad_checksum", PI_CHECKSUM, PI_ERROR, "Bad checksum", EXPFILL }},
	};

	expert_module_t* expert_rdm;

	proto_rdm = proto_register_protocol("Remote Device Management", "RDM", "rdm");
	proto_register_field_array(proto_rdm, hf, array_length(hf));
	proto_register_subtree_array(ett, array_length(ett));
	register_dissector("rdm", dissect_rdm, proto_rdm);
	expert_rdm = expert_register_protocol(proto_rdm);
	expert_register_field_array(expert_rdm, ei, array_length(ei));
}

void
proto_reg_handoff_rdm(void) {
	dissector_add_uint("dmx", 0xCC, create_dissector_handle(dissect_rdm, proto_rdm));
}

/*
 * Editor modelines  -  http://www.wireshark.org/tools/modelines.html
 *
 * Local variables:
 * c-basic-offset: 8
 * tab-width: 8
 * indent-tabs-mode: t
 * End:
 *
 * vi: set shiftwidth=8 tabstop=8 noexpandtab:
 * :indentSize=8:tabSize=8:noTabs=false:
 */