在好例子网,分享、交流、成长!
您当前所在位置:首页C# 开发实例C#语言基础 → C#连接发那科数控机床

C#连接发那科数控机床

C#语言基础

下载此实例
  • 开发语言:C#
  • 实例大小:25.68M
  • 下载次数:202
  • 浏览次数:7966
  • 发布时间:2018-03-07
  • 实例类别:C#语言基础
  • 发 布 人:caorong
  • 文件格式:.zip
  • 所需积分:1
 相关标签: C# c

实例介绍

【实例简介】

【实例截图】

from clipboard

【核心代码】

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
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
5321
5322
5323
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
5339
5340
5341
5342
5343
5344
5345
5346
5347
5348
5349
5350
5351
5352
5353
5354
5355
5356
5357
5358
5359
5360
5361
5362
5363
5364
5365
5366
5367
5368
5369
5370
5371
5372
5373
5374
5375
5376
5377
5378
5379
5380
5381
5382
5383
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414
5415
5416
5417
5418
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457
5458
5459
5460
5461
5462
5463
5464
5465
5466
5467
5468
5469
5470
5471
5472
5473
5474
5475
5476
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528
5529
5530
5531
5532
5533
5534
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544
5545
5546
5547
5548
5549
5550
5551
5552
5553
5554
5555
5556
5557
5558
5559
5560
5561
5562
5563
5564
5565
5566
5567
5568
5569
5570
5571
5572
5573
5574
5575
5576
5577
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597
5598
5599
5600
5601
5602
5603
5604
5605
5606
5607
5608
5609
5610
5611
5612
5613
5614
5615
5616
5617
5618
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628
5629
5630
5631
5632
5633
5634
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644
5645
5646
5647
5648
5649
5650
5651
5652
5653
5654
5655
5656
5657
5658
5659
5660
5661
5662
5663
5664
5665
5666
5667
5668
5669
5670
5671
5672
5673
5674
5675
5676
5677
5678
5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
5691
5692
5693
5694
5695
5696
5697
5698
5699
5700
5701
5702
5703
5704
5705
5706
5707
5708
5709
5710
5711
5712
5713
5714
5715
5716
5717
5718
5719
5720
5721
5722
5723
5724
5725
5726
5727
5728
5729
5730
5731
5732
5733
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793
5794
5795
5796
5797
5798
5799
5800
5801
5802
5803
5804
5805
5806
5807
5808
5809
5810
5811
5812
5813
5814
5815
5816
5817
5818
5819
5820
5821
5822
5823
5824
5825
5826
5827
5828
5829
5830
5831
5832
5833
5834
5835
5836
5837
5838
5839
5840
5841
5842
5843
5844
5845
5846
5847
5848
5849
5850
5851
5852
5853
5854
5855
5856
5857
5858
5859
5860
5861
5862
5863
5864
5865
5866
5867
5868
5869
5870
5871
5872
5873
5874
5875
5876
5877
5878
5879
5880
5881
5882
5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946
5947
5948
5949
5950
5951
5952
5953
5954
5955
5956
5957
5958
5959
5960
5961
5962
5963
5964
5965
5966
5967
5968
5969
5970
5971
5972
5973
5974
5975
5976
5977
5978
5979
5980
5981
5982
5983
5984
5985
5986
5987
5988
5989
5990
5991
5992
5993
5994
5995
5996
5997
5998
5999
6000
6001
6002
6003
6004
6005
6006
6007
6008
6009
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019
6020
6021
6022
6023
6024
6025
6026
6027
6028
6029
6030
6031
6032
6033
6034
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044
6045
6046
6047
6048
6049
6050
6051
6052
6053
6054
6055
6056
6057
6058
6059
6060
6061
6062
6063
6064
6065
6066
6067
6068
6069
6070
6071
6072
6073
6074
6075
6076
6077
6078
6079
6080
6081
6082
6083
6084
6085
6086
6087
6088
6089
6090
6091
6092
6093
6094
6095
6096
6097
6098
6099
6100
6101
6102
6103
6104
6105
6106
6107
6108
6109
6110
6111
6112
6113
6114
6115
6116
6117
6118
6119
6120
6121
6122
6123
6124
6125
6126
6127
6128
6129
6130
6131
6132
6133
6134
6135
6136
6137
6138
6139
6140
6141
6142
6143
6144
6145
6146
6147
6148
6149
6150
6151
6152
6153
6154
6155
6156
6157
6158
6159
6160
6161
6162
6163
6164
6165
6166
6167
6168
6169
6170
6171
6172
6173
6174
6175
6176
6177
6178
6179
6180
6181
6182
6183
6184
6185
6186
6187
6188
6189
6190
6191
6192
6193
6194
6195
6196
6197
6198
6199
6200
6201
6202
6203
6204
6205
6206
6207
6208
6209
6210
6211
6212
6213
6214
6215
6216
6217
6218
6219
6220
6221
6222
6223
6224
6225
6226
6227
6228
6229
6230
6231
6232
6233
6234
6235
6236
6237
6238
6239
6240
6241
6242
6243
6244
6245
6246
6247
6248
6249
6250
6251
6252
6253
6254
6255
6256
6257
6258
6259
6260
6261
6262
6263
6264
6265
6266
6267
6268
6269
6270
6271
6272
6273
6274
6275
6276
6277
6278
6279
6280
6281
6282
6283
6284
6285
6286
6287
6288
6289
6290
6291
6292
6293
6294
6295
6296
6297
6298
6299
6300
6301
6302
6303
6304
6305
6306
6307
6308
6309
6310
6311
6312
6313
6314
6315
6316
6317
6318
6319
6320
6321
6322
6323
6324
6325
6326
6327
6328
6329
6330
6331
6332
6333
6334
6335
6336
6337
6338
6339
6340
6341
6342
6343
6344
6345
6346
6347
6348
6349
6350
6351
6352
6353
6354
6355
6356
6357
6358
6359
6360
6361
6362
6363
6364
6365
6366
6367
6368
6369
6370
6371
6372
6373
6374
6375
6376
6377
6378
6379
6380
6381
6382
6383
6384
6385
6386
6387
6388
6389
6390
6391
6392
6393
6394
6395
6396
6397
6398
6399
6400
6401
6402
6403
6404
6405
6406
6407
6408
6409
6410
6411
6412
6413
6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
6429
6430
6431
6432
6433
6434
6435
6436
6437
6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
6453
6454
6455
6456
6457
6458
6459
6460
6461
6462
6463
6464
6465
6466
6467
6468
6469
6470
6471
6472
6473
6474
6475
6476
6477
6478
6479
6480
6481
6482
6483
6484
6485
6486
6487
6488
6489
6490
6491
6492
6493
6494
6495
6496
6497
6498
6499
6500
6501
6502
6503
6504
6505
6506
6507
6508
6509
6510
6511
6512
6513
6514
6515
6516
6517
6518
6519
6520
6521
6522
6523
6524
6525
6526
6527
6528
6529
6530
6531
6532
6533
6534
6535
6536
6537
6538
6539
6540
6541
6542
6543
6544
6545
6546
6547
6548
6549
6550
6551
6552
6553
6554
6555
6556
6557
6558
6559
6560
6561
6562
6563
6564
6565
6566
6567
6568
6569
6570
6571
6572
6573
6574
6575
6576
6577
6578
6579
6580
6581
6582
6583
6584
6585
6586
6587
6588
6589
6590
6591
6592
6593
6594
6595
6596
6597
6598
6599
6600
6601
6602
6603
6604
6605
6606
6607
6608
6609
6610
6611
6612
6613
6614
6615
6616
6617
6618
6619
6620
6621
6622
6623
6624
6625
6626
6627
6628
6629
6630
6631
6632
6633
6634
6635
6636
6637
6638
6639
6640
6641
6642
6643
6644
6645
6646
6647
6648
6649
6650
6651
6652
6653
6654
6655
6656
6657
6658
6659
6660
6661
6662
6663
6664
6665
6666
6667
6668
6669
6670
6671
6672
6673
6674
6675
6676
6677
6678
6679
6680
6681
6682
6683
6684
6685
6686
6687
6688
6689
6690
6691
6692
6693
6694
6695
6696
6697
6698
6699
6700
6701
6702
6703
6704
6705
6706
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
6746
6747
6748
6749
6750
6751
6752
6753
6754
6755
6756
6757
6758
6759
6760
6761
6762
6763
6764
6765
6766
6767
6768
6769
6770
6771
6772
6773
6774
6775
6776
6777
6778
6779
6780
6781
6782
6783
6784
6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797
6798
6799
6800
6801
6802
6803
6804
6805
6806
6807
6808
6809
6810
6811
6812
6813
6814
6815
6816
6817
6818
6819
6820
6821
6822
6823
6824
6825
6826
6827
6828
6829
6830
6831
6832
6833
6834
6835
6836
6837
6838
6839
6840
6841
6842
6843
6844
6845
6846
6847
6848
6849
6850
6851
6852
6853
6854
6855
6856
6857
6858
6859
6860
6861
6862
6863
6864
6865
6866
6867
6868
6869
6870
6871
6872
6873
6874
6875
6876
6877
6878
6879
6880
6881
6882
6883
6884
6885
6886
6887
6888
6889
6890
6891
6892
6893
6894
6895
6896
6897
6898
6899
6900
6901
6902
6903
6904
6905
6906
6907
6908
6909
6910
6911
6912
6913
6914
6915
6916
6917
6918
6919
6920
6921
6922
6923
6924
6925
6926
6927
6928
6929
6930
6931
6932
6933
6934
6935
6936
6937
6938
6939
6940
6941
6942
6943
6944
6945
6946
6947
6948
6949
6950
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960
6961
6962
6963
6964
6965
6966
6967
6968
6969
6970
6971
6972
6973
6974
6975
6976
6977
6978
6979
6980
6981
6982
6983
6984
6985
6986
6987
6988
6989
6990
6991
6992
6993
6994
6995
6996
6997
6998
6999
7000
7001
7002
7003
7004
7005
7006
7007
7008
7009
7010
7011
7012
7013
7014
7015
7016
7017
7018
7019
7020
7021
7022
7023
7024
7025
7026
7027
7028
7029
7030
7031
7032
7033
7034
7035
7036
7037
7038
7039
7040
7041
7042
7043
7044
7045
7046
7047
7048
7049
7050
7051
7052
7053
7054
7055
7056
7057
7058
7059
7060
7061
7062
7063
7064
7065
7066
7067
7068
7069
7070
7071
7072
7073
7074
7075
7076
7077
7078
7079
7080
7081
7082
7083
7084
7085
7086
7087
7088
7089
7090
7091
7092
7093
7094
7095
7096
7097
7098
7099
7100
7101
7102
7103
7104
7105
7106
7107
7108
7109
7110
7111
7112
7113
7114
7115
7116
7117
7118
7119
7120
7121
7122
7123
7124
7125
7126
7127
7128
7129
7130
7131
7132
7133
7134
7135
7136
7137
7138
7139
7140
7141
7142
7143
7144
7145
7146
7147
7148
7149
7150
7151
7152
7153
7154
7155
7156
7157
7158
7159
7160
7161
7162
7163
7164
7165
7166
7167
7168
7169
7170
7171
7172
7173
7174
7175
7176
7177
7178
7179
7180
7181
7182
7183
7184
7185
7186
7187
7188
7189
7190
7191
7192
7193
7194
7195
7196
7197
7198
7199
7200
7201
7202
7203
7204
7205
7206
7207
7208
7209
7210
7211
7212
7213
7214
7215
7216
7217
7218
7219
7220
7221
7222
7223
7224
7225
7226
7227
7228
7229
7230
7231
7232
7233
7234
7235
7236
7237
7238
7239
7240
7241
7242
7243
7244
7245
7246
7247
7248
7249
7250
7251
7252
7253
7254
7255
7256
7257
7258
7259
7260
7261
7262
7263
7264
7265
7266
7267
7268
7269
7270
7271
7272
7273
7274
7275
7276
7277
7278
7279
7280
7281
7282
7283
7284
7285
7286
7287
7288
7289
7290
7291
7292
7293
7294
7295
7296
7297
7298
7299
7300
7301
7302
7303
7304
7305
7306
7307
7308
7309
7310
7311
7312
7313
7314
7315
7316
7317
7318
7319
7320
7321
7322
7323
7324
7325
7326
7327
7328
7329
7330
7331
7332
7333
7334
7335
7336
7337
7338
7339
7340
7341
7342
7343
7344
7345
7346
7347
7348
7349
7350
7351
7352
7353
7354
7355
7356
7357
7358
7359
7360
7361
7362
7363
7364
7365
7366
7367
7368
7369
7370
7371
7372
7373
7374
7375
7376
7377
7378
7379
7380
7381
7382
7383
7384
7385
7386
7387
7388
7389
7390
7391
7392
7393
7394
7395
7396
7397
7398
7399
7400
7401
7402
7403
7404
7405
7406
7407
7408
7409
7410
7411
7412
7413
7414
7415
7416
7417
7418
7419
7420
7421
7422
7423
7424
7425
7426
7427
7428
7429
7430
7431
7432
7433
7434
7435
7436
7437
7438
7439
7440
7441
7442
7443
7444
7445
7446
7447
7448
7449
7450
7451
7452
7453
7454
7455
7456
7457
7458
7459
7460
7461
7462
7463
7464
7465
7466
7467
7468
7469
7470
7471
7472
7473
7474
7475
7476
7477
7478
7479
7480
7481
7482
7483
7484
7485
7486
7487
7488
7489
7490
7491
7492
7493
7494
7495
7496
7497
7498
7499
7500
7501
7502
7503
7504
7505
7506
7507
7508
7509
7510
7511
7512
7513
7514
7515
7516
7517
7518
7519
7520
7521
7522
7523
7524
7525
7526
7527
7528
7529
7530
7531
7532
7533
7534
7535
7536
7537
7538
7539
7540
7541
7542
7543
7544
7545
7546
7547
7548
7549
7550
7551
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579
7580
7581
7582
7583
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595
7596
7597
7598
7599
7600
7601
7602
7603
7604
7605
7606
7607
7608
7609
7610
7611
7612
7613
7614
7615
7616
7617
7618
7619
7620
7621
7622
7623
7624
7625
7626
7627
7628
7629
7630
7631
7632
7633
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643
7644
7645
7646
7647
7648
7649
7650
7651
7652
7653
7654
7655
7656
7657
7658
7659
7660
7661
7662
7663
7664
7665
7666
7667
7668
7669
7670
7671
7672
7673
7674
7675
7676
7677
7678
7679
7680
7681
7682
7683
7684
7685
7686
7687
7688
7689
7690
7691
7692
7693
7694
7695
7696
7697
7698
7699
7700
7701
7702
7703
7704
7705
7706
7707
7708
7709
7710
7711
7712
7713
7714
7715
7716
7717
7718
7719
7720
7721
7722
7723
7724
7725
7726
7727
7728
7729
7730
7731
7732
7733
7734
7735
7736
7737
7738
7739
7740
7741
7742
7743
7744
7745
7746
7747
7748
7749
7750
7751
7752
7753
7754
7755
7756
7757
7758
7759
7760
7761
7762
7763
7764
7765
7766
7767
7768
7769
7770
7771
7772
7773
7774
7775
7776
7777
7778
7779
7780
7781
7782
7783
7784
7785
7786
7787
7788
7789
7790
7791
7792
7793
7794
7795
7796
7797
7798
7799
7800
7801
7802
7803
7804
7805
7806
7807
7808
7809
7810
7811
7812
7813
7814
7815
7816
7817
7818
7819
7820
7821
7822
7823
7824
7825
7826
7827
7828
7829
7830
7831
7832
7833
7834
7835
7836
7837
7838
7839
7840
7841
7842
7843
7844
7845
7846
7847
7848
7849
7850
7851
7852
7853
7854
7855
7856
7857
7858
7859
7860
7861
7862
7863
7864
7865
7866
7867
7868
7869
7870
7871
7872
7873
7874
7875
7876
7877
7878
7879
7880
7881
7882
7883
7884
7885
7886
7887
7888
7889
7890
7891
7892
7893
7894
7895
7896
7897
7898
7899
7900
7901
7902
7903
7904
7905
7906
7907
7908
7909
7910
7911
7912
7913
7914
7915
7916
7917
7918
7919
7920
7921
7922
7923
7924
7925
7926
7927
7928
7929
7930
7931
7932
7933
7934
7935
7936
7937
7938
7939
7940
7941
7942
7943
7944
7945
7946
7947
7948
7949
7950
7951
7952
7953
7954
7955
7956
7957
7958
7959
7960
7961
7962
7963
7964
7965
7966
7967
7968
7969
7970
7971
7972
7973
7974
7975
7976
7977
7978
7979
7980
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990
7991
7992
7993
7994
7995
7996
7997
7998
7999
8000
8001
8002
8003
8004
8005
8006
8007
8008
8009
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021
8022
8023
8024
8025
8026
8027
8028
8029
8030
8031
8032
8033
8034
8035
8036
8037
8038
8039
8040
8041
8042
8043
8044
8045
8046
8047
8048
8049
8050
8051
8052
8053
8054
8055
8056
8057
8058
8059
8060
8061
8062
8063
8064
8065
8066
8067
8068
8069
8070
8071
8072
8073
8074
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085
8086
8087
8088
8089
8090
8091
8092
8093
8094
8095
8096
8097
8098
8099
8100
8101
8102
8103
8104
8105
8106
8107
8108
8109
8110
8111
8112
8113
8114
8115
8116
8117
8118
8119
8120
8121
8122
8123
8124
8125
8126
8127
8128
8129
8130
8131
8132
8133
8134
8135
8136
8137
8138
8139
8140
8141
8142
8143
8144
8145
8146
8147
8148
8149
8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
8166
8167
8168
8169
8170
8171
8172
8173
8174
8175
8176
8177
8178
8179
8180
8181
8182
8183
8184
8185
8186
8187
8188
8189
8190
8191
8192
8193
8194
8195
8196
8197
8198
8199
8200
8201
8202
8203
8204
8205
8206
8207
8208
8209
8210
8211
8212
8213
8214
8215
8216
8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232
8233
8234
8235
8236
8237
8238
8239
8240
8241
8242
8243
8244
8245
8246
8247
8248
8249
8250
8251
8252
8253
8254
8255
8256
8257
8258
8259
8260
8261
8262
8263
8264
8265
8266
8267
8268
8269
8270
8271
8272
8273
8274
8275
8276
8277
8278
8279
8280
8281
8282
8283
8284
8285
8286
8287
8288
8289
8290
8291
8292
8293
8294
8295
8296
8297
8298
8299
8300
8301
8302
8303
8304
8305
8306
8307
8308
8309
8310
8311
8312
8313
8314
8315
8316
8317
8318
8319
8320
8321
8322
8323
8324
8325
8326
8327
8328
8329
8330
8331
8332
8333
8334
8335
8336
8337
8338
8339
8340
8341
8342
8343
8344
8345
8346
8347
8348
8349
8350
8351
8352
8353
8354
8355
8356
8357
8358
8359
8360
8361
8362
8363
8364
8365
8366
8367
8368
8369
8370
8371
8372
8373
8374
8375
8376
8377
8378
8379
8380
8381
8382
8383
8384
8385
8386
8387
8388
8389
8390
8391
8392
8393
8394
8395
8396
8397
8398
8399
8400
8401
8402
8403
8404
8405
8406
8407
8408
8409
8410
8411
8412
8413
8414
8415
8416
8417
8418
8419
8420
8421
8422
8423
8424
8425
8426
8427
8428
8429
8430
8431
8432
8433
8434
8435
8436
8437
8438
8439
8440
8441
8442
8443
8444
8445
8446
8447
8448
8449
8450
8451
8452
8453
8454
8455
8456
8457
8458
8459
8460
8461
8462
8463
8464
8465
8466
8467
8468
8469
8470
8471
8472
8473
8474
8475
8476
8477
8478
8479
8480
8481
8482
8483
8484
8485
8486
8487
8488
8489
8490
8491
8492
8493
8494
8495
8496
8497
8498
8499
8500
8501
8502
8503
8504
8505
8506
8507
8508
8509
8510
8511
8512
8513
8514
8515
8516
8517
8518
8519
8520
8521
8522
8523
8524
8525
8526
8527
8528
8529
8530
8531
8532
8533
8534
8535
8536
8537
8538
8539
8540
8541
8542
8543
8544
8545
8546
8547
8548
8549
8550
8551
8552
8553
8554
8555
8556
8557
8558
8559
8560
8561
8562
8563
8564
8565
8566
8567
8568
8569
8570
8571
8572
8573
8574
8575
8576
8577
8578
8579
8580
8581
8582
8583
8584
8585
8586
8587
8588
8589
8590
8591
8592
8593
8594
8595
8596
8597
8598
8599
8600
8601
8602
8603
8604
8605
8606
8607
8608
8609
8610
8611
8612
8613
8614
8615
8616
8617
8618
8619
8620
8621
8622
8623
8624
8625
8626
8627
8628
8629
8630
8631
8632
8633
8634
8635
8636
8637
8638
8639
8640
8641
8642
8643
8644
8645
8646
8647
8648
8649
8650
8651
8652
8653
8654
8655
8656
8657
8658
8659
8660
8661
8662
8663
8664
8665
8666
8667
8668
8669
8670
8671
8672
8673
8674
8675
8676
8677
8678
8679
8680
8681
8682
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695
8696
8697
8698
8699
8700
8701
8702
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712
8713
8714
8715
8716
8717
8718
8719
8720
8721
8722
8723
8724
8725
8726
8727
8728
8729
8730
8731
8732
8733
8734
8735
8736
8737
8738
8739
8740
8741
8742
8743
8744
8745
8746
8747
8748
8749
8750
8751
8752
8753
8754
8755
8756
8757
8758
8759
8760
8761
8762
8763
8764
8765
8766
8767
8768
8769
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798
8799
8800
8801
8802
8803
8804
8805
8806
8807
8808
8809
8810
8811
8812
8813
8814
8815
8816
8817
8818
8819
8820
8821
8822
8823
8824
8825
8826
8827
8828
8829
8830
8831
8832
8833
8834
8835
8836
8837
8838
8839
8840
8841
8842
8843
8844
8845
8846
8847
8848
8849
8850
8851
8852
8853
8854
8855
8856
8857
8858
8859
8860
8861
8862
8863
8864
8865
8866
8867
8868
8869
8870
8871
8872
8873
8874
8875
8876
8877
8878
8879
8880
8881
8882
8883
8884
8885
8886
8887
8888
8889
8890
8891
8892
8893
8894
8895
8896
8897
8898
8899
8900
8901
8902
8903
8904
8905
8906
8907
8908
8909
8910
8911
8912
8913
8914
8915
8916
8917
8918
8919
8920
8921
8922
8923
8924
8925
8926
8927
8928
8929
8930
8931
8932
8933
8934
8935
8936
8937
8938
8939
8940
8941
8942
8943
8944
8945
8946
8947
8948
8949
8950
8951
8952
8953
8954
8955
8956
8957
8958
8959
8960
8961
8962
8963
8964
8965
8966
8967
8968
8969
8970
8971
8972
8973
8974
8975
8976
8977
8978
8979
8980
8981
8982
8983
8984
8985
8986
8987
8988
8989
8990
8991
8992
8993
8994
8995
8996
8997
8998
8999
9000
9001
9002
9003
9004
9005
9006
9007
9008
9009
9010
9011
9012
9013
9014
9015
9016
9017
9018
9019
9020
9021
9022
9023
9024
9025
9026
9027
9028
9029
9030
9031
9032
9033
9034
9035
9036
9037
9038
9039
9040
9041
9042
9043
9044
9045
9046
9047
9048
9049
9050
9051
9052
9053
9054
9055
9056
9057
9058
9059
9060
9061
9062
9063
9064
9065
9066
9067
9068
9069
9070
9071
9072
9073
9074
9075
9076
9077
9078
9079
9080
9081
9082
9083
9084
9085
9086
9087
9088
9089
9090
9091
9092
9093
9094
9095
9096
9097
9098
9099
9100
9101
9102
9103
9104
9105
9106
9107
9108
9109
9110
9111
9112
9113
9114
9115
9116
9117
9118
9119
9120
9121
9122
9123
9124
9125
9126
9127
9128
9129
9130
9131
9132
9133
9134
9135
9136
9137
9138
9139
9140
9141
9142
9143
9144
9145
9146
9147
9148
9149
9150
9151
9152
9153
9154
9155
9156
9157
9158
9159
9160
9161
9162
9163
9164
9165
9166
9167
9168
9169
9170
9171
9172
9173
9174
9175
9176
9177
9178
9179
9180
9181
9182
9183
9184
9185
9186
9187
9188
9189
9190
9191
9192
9193
9194
9195
9196
9197
9198
9199
9200
9201
9202
9203
9204
9205
9206
9207
9208
9209
9210
9211
9212
9213
9214
9215
9216
9217
9218
9219
9220
9221
9222
9223
9224
9225
9226
9227
9228
9229
9230
9231
9232
9233
9234
9235
9236
9237
9238
9239
9240
9241
9242
9243
9244
9245
9246
9247
9248
9249
9250
9251
9252
9253
9254
9255
9256
9257
9258
9259
9260
9261
9262
9263
9264
9265
9266
9267
9268
9269
9270
9271
9272
9273
9274
9275
9276
9277
9278
9279
9280
9281
9282
9283
9284
9285
9286
9287
9288
9289
9290
9291
9292
9293
9294
9295
9296
9297
9298
9299
9300
9301
9302
9303
9304
9305
9306
9307
9308
9309
9310
9311
9312
9313
9314
9315
9316
9317
9318
9319
9320
9321
9322
9323
9324
9325
9326
9327
9328
9329
9330
9331
9332
9333
9334
9335
9336
9337
9338
9339
9340
9341
9342
9343
9344
9345
9346
9347
9348
9349
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360
9361
9362
9363
9364
9365
9366
9367
9368
9369
9370
9371
9372
9373
9374
9375
9376
9377
9378
9379
9380
9381
9382
9383
9384
9385
9386
9387
9388
9389
9390
9391
9392
9393
9394
9395
9396
9397
9398
9399
9400
9401
9402
9403
9404
9405
9406
9407
9408
9409
9410
9411
9412
9413
9414
9415
9416
9417
9418
9419
9420
9421
9422
9423
9424
9425
9426
9427
9428
9429
9430
9431
9432
9433
9434
9435
9436
9437
9438
9439
9440
9441
9442
9443
9444
9445
9446
9447
9448
9449
9450
9451
9452
9453
9454
9455
9456
9457
9458
9459
9460
9461
9462
9463
9464
9465
9466
9467
9468
9469
9470
9471
9472
9473
9474
9475
9476
9477
9478
9479
9480
9481
9482
9483
9484
9485
9486
9487
9488
9489
9490
9491
9492
9493
9494
9495
9496
9497
9498
9499
9500
9501
9502
9503
9504
9505
9506
9507
9508
9509
9510
9511
9512
9513
9514
9515
9516
9517
9518
9519
9520
9521
9522
9523
9524
9525
9526
9527
9528
9529
9530
9531
9532
9533
9534
9535
9536
9537
9538
9539
9540
9541
9542
9543
9544
9545
9546
9547
9548
9549
9550
9551
9552
9553
9554
9555
9556
9557
9558
9559
9560
9561
9562
9563
9564
9565
9566
9567
9568
9569
9570
9571
9572
9573
9574
9575
9576
9577
9578
9579
9580
9581
9582
9583
9584
9585
9586
9587
9588
9589
9590
9591
9592
9593
9594
9595
9596
9597
9598
9599
9600
9601
9602
9603
9604
9605
9606
9607
9608
9609
9610
9611
9612
9613
9614
9615
9616
9617
9618
9619
9620
9621
9622
9623
9624
9625
9626
9627
9628
9629
9630
9631
9632
9633
9634
9635
9636
9637
9638
9639
9640
9641
9642
9643
9644
9645
9646
9647
9648
9649
9650
9651
9652
9653
9654
9655
9656
9657
9658
9659
9660
9661
9662
9663
9664
9665
9666
9667
9668
9669
9670
9671
9672
9673
9674
9675
9676
9677
9678
9679
9680
9681
9682
9683
9684
9685
9686
9687
9688
9689
9690
9691
9692
9693
9694
9695
9696
9697
9698
9699
9700
9701
9702
9703
9704
9705
9706
9707
9708
9709
9710
9711
9712
9713
9714
9715
9716
9717
9718
9719
9720
9721
9722
9723
9724
9725
9726
9727
9728
9729
9730
9731
9732
9733
9734
9735
9736
9737
9738
9739
9740
9741
9742
9743
9744
9745
9746
9747
9748
9749
9750
9751
9752
9753
9754
9755
9756
9757
9758
9759
9760
9761
9762
9763
9764
9765
9766
9767
9768
9769
9770
9771
9772
9773
9774
9775
9776
9777
9778
9779
9780
9781
9782
9783
9784
9785
9786
9787
9788
9789
9790
9791
9792
9793
9794
9795
9796
9797
9798
9799
9800
9801
9802
9803
9804
9805
9806
9807
9808
9809
9810
9811
9812
9813
9814
9815
9816
9817
9818
9819
9820
9821
9822
9823
9824
9825
9826
9827
9828
9829
9830
9831
9832
9833
9834
9835
9836
9837
9838
9839
9840
9841
9842
9843
9844
9845
9846
9847
9848
9849
9850
9851
9852
9853
9854
9855
9856
9857
9858
9859
9860
9861
9862
9863
9864
9865
9866
9867
9868
9869
9870
9871
9872
9873
9874
9875
9876
9877
9878
9879
9880
9881
9882
9883
9884
9885
9886
9887
9888
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905
9906
9907
9908
9909
9910
9911
9912
9913
9914
9915
9916
9917
9918
9919
9920
9921
9922
9923
9924
9925
9926
9927
9928
9929
9930
9931
9932
9933
9934
9935
9936
9937
9938
9939
9940
9941
9942
9943
9944
9945
9946
9947
9948
9949
9950
9951
9952
9953
9954
9955
9956
9957
9958
9959
9960
9961
9962
9963
9964
9965
9966
9967
9968
9969
9970
9971
9972
9973
9974
9975
9976
9977
9978
9979
9980
9981
9982
9983
9984
9985
9986
9987
9988
9989
9990
9991
9992
9993
9994
9995
9996
9997
9998
9999
10000
10001
10002
10003
10004
10005
10006
10007
10008
10009
10010
10011
10012
10013
10014
10015
10016
10017
10018
10019
10020
10021
10022
10023
10024
10025
10026
10027
10028
10029
10030
10031
10032
10033
10034
10035
10036
10037
10038
10039
10040
10041
10042
10043
10044
10045
10046
10047
10048
10049
10050
10051
10052
10053
10054
10055
10056
10057
10058
10059
10060
10061
10062
10063
10064
10065
10066
10067
10068
10069
10070
10071
10072
10073
10074
10075
10076
10077
10078
10079
10080
10081
10082
10083
10084
10085
10086
10087
10088
10089
10090
10091
10092
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
10111
10112
10113
10114
10115
10116
10117
10118
10119
10120
10121
10122
10123
10124
10125
10126
10127
10128
10129
10130
10131
10132
10133
10134
10135
10136
10137
10138
10139
10140
10141
10142
10143
10144
10145
10146
10147
10148
10149
10150
10151
10152
10153
10154
10155
10156
10157
10158
10159
10160
10161
10162
10163
10164
10165
10166
10167
10168
10169
10170
10171
10172
10173
10174
10175
10176
10177
10178
10179
10180
10181
10182
10183
10184
10185
10186
10187
10188
10189
10190
10191
10192
10193
10194
10195
10196
10197
10198
10199
10200
10201
10202
10203
10204
10205
10206
10207
10208
10209
10210
10211
10212
10213
10214
10215
10216
10217
10218
10219
10220
10221
10222
10223
10224
10225
10226
10227
10228
10229
10230
10231
10232
10233
10234
10235
10236
10237
10238
10239
10240
10241
10242
10243
10244
10245
10246
10247
10248
10249
10250
10251
10252
10253
10254
10255
10256
10257
10258
10259
10260
10261
10262
10263
10264
10265
10266
10267
10268
10269
10270
10271
10272
10273
10274
10275
10276
10277
10278
10279
10280
10281
10282
10283
10284
10285
10286
10287
10288
10289
10290
10291
10292
10293
10294
10295
10296
10297
10298
10299
10300
10301
10302
10303
10304
10305
10306
10307
10308
10309
10310
10311
10312
10313
10314
10315
10316
10317
10318
10319
10320
10321
10322
10323
10324
10325
10326
10327
10328
10329
10330
10331
10332
10333
10334
10335
10336
10337
10338
10339
10340
10341
10342
10343
10344
10345
10346
10347
10348
10349
10350
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361
10362
10363
10364
10365
10366
10367
10368
10369
10370
10371
10372
10373
10374
10375
10376
10377
10378
10379
10380
10381
10382
10383
10384
10385
10386
10387
10388
10389
10390
10391
10392
10393
10394
10395
10396
10397
10398
10399
10400
10401
10402
10403
10404
10405
10406
10407
10408
10409
10410
10411
10412
10413
10414
10415
10416
10417
10418
10419
10420
10421
10422
10423
10424
10425
10426
10427
10428
10429
10430
10431
10432
10433
10434
10435
10436
10437
10438
10439
10440
10441
10442
10443
10444
10445
10446
10447
10448
10449
10450
10451
10452
10453
10454
10455
10456
10457
10458
10459
10460
10461
10462
10463
10464
10465
10466
10467
10468
10469
10470
10471
10472
10473
10474
10475
10476
10477
10478
10479
10480
10481
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491
10492
10493
10494
10495
10496
10497
10498
10499
10500
10501
10502
10503
10504
10505
10506
10507
10508
10509
10510
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521
10522
10523
10524
10525
10526
10527
10528
10529
10530
10531
10532
10533
10534
10535
10536
10537
10538
10539
10540
10541
10542
10543
10544
10545
10546
10547
10548
10549
10550
10551
10552
10553
10554
10555
10556
10557
10558
10559
10560
10561
10562
10563
10564
10565
10566
10567
10568
10569
10570
10571
10572
10573
10574
10575
10576
10577
10578
10579
10580
10581
10582
10583
10584
10585
10586
10587
10588
10589
10590
10591
10592
10593
10594
10595
10596
10597
10598
10599
10600
10601
10602
10603
10604
10605
10606
10607
10608
10609
10610
10611
10612
10613
10614
10615
10616
10617
10618
10619
10620
10621
10622
10623
10624
10625
10626
10627
10628
10629
10630
10631
10632
10633
10634
10635
10636
10637
10638
10639
10640
10641
10642
10643
10644
10645
10646
10647
10648
10649
10650
10651
10652
10653
10654
10655
10656
10657
10658
10659
10660
10661
10662
10663
10664
10665
10666
10667
10668
10669
10670
10671
10672
10673
10674
10675
10676
10677
10678
10679
10680
10681
10682
10683
10684
10685
10686
10687
10688
10689
10690
10691
10692
10693
10694
10695
10696
10697
10698
10699
10700
10701
10702
10703
10704
10705
10706
10707
10708
10709
10710
10711
10712
10713
10714
10715
10716
10717
10718
10719
10720
10721
10722
10723
10724
10725
10726
10727
10728
10729
10730
10731
10732
10733
10734
10735
10736
10737
10738
10739
10740
10741
10742
10743
10744
10745
10746
10747
10748
10749
10750
10751
10752
10753
10754
10755
10756
10757
10758
10759
10760
10761
10762
10763
10764
10765
10766
10767
10768
10769
10770
10771
10772
10773
10774
10775
10776
10777
10778
10779
10780
10781
10782
10783
10784
10785
10786
10787
10788
10789
10790
10791
10792
10793
10794
10795
10796
10797
10798
10799
10800
10801
10802
10803
10804
10805
10806
10807
10808
10809
10810
10811
10812
10813
10814
10815
10816
10817
10818
10819
10820
10821
10822
10823
10824
10825
10826
10827
10828
10829
10830
10831
10832
10833
10834
10835
10836
10837
10838
10839
10840
10841
10842
10843
10844
10845
10846
10847
10848
10849
10850
10851
10852
10853
10854
10855
10856
10857
10858
10859
10860
10861
10862
10863
10864
10865
10866
10867
10868
10869
10870
10871
10872
10873
10874
10875
10876
10877
10878
10879
10880
10881
10882
10883
10884
10885
10886
10887
10888
10889
10890
10891
10892
10893
10894
10895
10896
10897
10898
10899
10900
10901
10902
10903
10904
10905
10906
10907
10908
10909
10910
10911
10912
10913
10914
10915
10916
10917
10918
10919
10920
10921
10922
10923
10924
10925
10926
10927
10928
10929
10930
10931
10932
10933
10934
10935
10936
10937
10938
10939
10940
10941
10942
10943
10944
10945
10946
10947
10948
10949
10950
10951
10952
10953
10954
10955
10956
10957
10958
10959
10960
10961
10962
10963
10964
10965
10966
10967
10968
10969
10970
10971
10972
10973
10974
10975
10976
10977
10978
10979
10980
10981
10982
10983
10984
10985
10986
10987
10988
10989
10990
10991
10992
10993
10994
10995
10996
10997
10998
10999
11000
11001
11002
11003
11004
11005
11006
11007
11008
11009
11010
11011
11012
11013
11014
11015
11016
11017
11018
11019
11020
11021
11022
11023
11024
11025
11026
11027
11028
11029
11030
11031
11032
11033
11034
11035
11036
11037
11038
11039
11040
11041
11042
11043
11044
11045
11046
11047
11048
11049
11050
11051
11052
11053
11054
11055
11056
11057
11058
11059
11060
11061
11062
11063
11064
11065
11066
11067
11068
11069
11070
11071
11072
11073
11074
11075
11076
11077
11078
11079
11080
11081
11082
11083
11084
11085
11086
11087
11088
11089
11090
11091
11092
11093
11094
11095
11096
11097
11098
11099
11100
11101
11102
11103
11104
11105
11106
11107
11108
11109
11110
11111
11112
11113
11114
11115
11116
11117
11118
11119
11120
11121
11122
11123
11124
11125
11126
11127
11128
11129
11130
11131
11132
11133
11134
11135
11136
11137
11138
11139
11140
11141
11142
11143
11144
11145
11146
11147
11148
11149
11150
11151
11152
11153
11154
11155
11156
11157
11158
11159
11160
11161
11162
11163
11164
11165
11166
11167
11168
11169
11170
11171
11172
11173
11174
11175
11176
11177
11178
11179
11180
11181
11182
11183
11184
11185
11186
11187
11188
11189
11190
11191
11192
11193
11194
11195
11196
11197
11198
11199
11200
11201
11202
11203
11204
11205
11206
11207
11208
11209
11210
11211
11212
11213
11214
11215
11216
11217
11218
11219
11220
11221
11222
11223
11224
11225
11226
11227
11228
11229
11230
11231
11232
11233
11234
11235
11236
11237
11238
11239
11240
11241
11242
11243
11244
11245
11246
11247
11248
11249
11250
11251
11252
11253
11254
11255
11256
11257
11258
11259
11260
11261
11262
11263
11264
11265
11266
11267
11268
11269
11270
11271
11272
11273
11274
11275
11276
11277
11278
11279
11280
11281
11282
11283
11284
11285
11286
11287
11288
11289
11290
11291
11292
11293
11294
11295
11296
11297
11298
/*-------------------------------------------------------------------*/
/* fwlib32.cs                                                        */
/*                                                                   */
/* CNC/PMC Data Window Library for FOCAS1/Ethernet                   */
/*                                                                   */
/* Copyright (C) 2002-2011 by FANUC CORPORATION All rights reserved. */
/*                                                                   */
/*-------------------------------------------------------------------*/
using System;
using System.Runtime.InteropServices;
 
 
    public class Focas1
    {
        /* Axis define */
#if FS30D
    public const short MAX_AXIS = 32;
#elif M_AXIS2
    public const short MAX_AXIS = 24;
#elif FS15D
    public const short MAX_AXIS = 10;
#else
        public const short MAX_AXIS = 8;
#endif
 
        public const short ALL_AXES = (-1);
        public const short ALL_SPINDLES = (-1);
        public const short EW_OK = (short)focas_ret.EW_OK;
 
        /* Error Codes */
        public enum focas_ret
        {
            EW_PROTOCOL = (-17),           /* protocol error */
            EW_SOCKET = (-16),           /* Windows socket error */
            EW_NODLL = (-15),           /* DLL not exist error */
            EW_BUS = (-11),           /* bus error */
            EW_SYSTEM2 = (-10),           /* system error */
            EW_HSSB = (-9),           /* hssb communication error */
            EW_HANDLE = (-8),           /* Windows library handle error */
            EW_VERSION = (-7),           /* CNC/PMC version missmatch */
            EW_UNEXP = (-6),           /* abnormal error */
            EW_SYSTEM = (-5),           /* system error */
            EW_PARITY = (-4),           /* shared RAM parity error */
            EW_MMCSYS = (-3),           /* emm386 or mmcsys install error */
            EW_RESET = (-2),           /* reset or stop occured error */
            EW_BUSY = (-1),           /* busy error */
            EW_OK = 0,           /* no problem */
            EW_FUNC = 1,           /* command prepare error */
            EW_NOPMC = 1,           /* pmc not exist */
            EW_LENGTH = 2,           /* data block length error */
            EW_NUMBER = 3,           /* data number error */
            EW_RANGE = 3,           /* address range error */
            EW_ATTRIB = 4,           /* data attribute error */
            EW_TYPE = 4,           /* data type error */
            EW_DATA = 5,           /* data error */
            EW_NOOPT = 6,           /* no option error */
            EW_PROT = 7,           /* write protect error */
            EW_OVRFLOW = 8,           /* memory overflow error */
            EW_PARAM = 9,           /* cnc parameter not correct error */
            EW_BUFFER = 10,           /* buffer error */
            EW_PATH = 11,           /* path error */
            EW_MODE = 12,           /* cnc mode error */
            EW_REJECT = 13,           /* execution rejected error */
            EW_DTSRVR = 14,           /* data server error */
            EW_ALARM = 15,           /* alarm has been occurred */
            EW_STOP = 16,           /* CNC is not running */
            EW_PASSWD = 17,           /* protection data error */
            /*
                Result codes of DNC operation
            */
            DNC_NORMAL = (-1),           /* normal completed */
            DNC_CANCEL = (-32768),           /* DNC operation was canceled by CNC */
            DNC_OPENERR = (-514),           /* file open error */
            DNC_NOFILE = (-516),           /* file not found */
            DNC_READERR = (-517)              /* read error */
        };
 
        /*--------------------*/
        /*                    */
        /* Structure Template */
        /*                    */
        /*--------------------*/
        /*-------------------------------------*/
        /* CNC: Control axis / spindle related */
        /*-------------------------------------*/
 
        /* cnc_actf:read actual axis feedrate(F) */
        /* cnc_acts:read actual spindle speed(S) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBACT
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;      /* dummy */
            public int data;      /* actual feed / actual spindle */
        }
 
        /* cnc_acts2:read actual spindle speed(S) */
        /* (All or specified ) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBACT2
        {
            public short datano;     /* spindle number */
            public short type;       /* dummy */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public int[] data;       /* spindle data */
        }
 
        /* cnc_absolute:read absolute axis position */
        /* cnc_machine:read machine axis position */
        /* cnc_relative:read relative axis position */
        /* cnc_distance:read distance to go */
        /* cnc_skip:read skip position */
        /* cnc_srvdelay:read servo delay value */
        /* cnc_accdecdly:read acceleration/deceleration delay value */
        /* cnc_absolute2:read absolute axis position 2 */
        /* cnc_relative2:read relative axis position 2 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAXIS
        {
            public short dummy;  /* dummy */
            public short type;   /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] data;      /* data value */
        }
 
        /* cnc_rddynamic:read all dynamic data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class FAXIS
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] absolute;    /* absolute position */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] machine;     /* machine position */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] relative;    /* relative position */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] distance;    /* distance to go */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OAXIS
        {
            public int absolute;  /* absolute position */
            public int machine;   /* machine position */
            public int relative;  /* relative position */
            public int distance;  /* distance to go */
        }
#if (!ONO8D)
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDY_1
        {
            public short dummy;
            public short axis;      /* axis number */
            public short alarm;     /* alarm status */
            public short prgnum;    /* current program number */
            public short prgmnum;   /* main program number */
            public int seqnum;    /* current sequence number */
            public int actf;      /* actual feedrate */
            public int acts;      /* actual spindle speed */
            public FAXIS pos = new FAXIS();
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDY_2
        {
            public short dummy;
            public short axis;      /* axis number */
            public short alarm;     /* alarm status */
            public short prgnum;    /* current program number */
            public short prgmnum;   /* main program number */
            public int seqnum;    /* current sequence number */
            public int actf;      /* actual feedrate */
            public int acts;      /* actual spindle speed */
            public OAXIS pos = new OAXIS();
        }
#else
    [StructLayout(LayoutKind.Sequential, Pack=4)]
    public class ODBDY_1
    {
        public short  dummy ;
        public short  axis ;      /* axis number */
        public short  alarm ;     /* alarm status */
        public int    prgnum ;    /* current program number */
        public int    prgmnum ;   /* main program number */
        public int    seqnum ;    /* current sequence number */
        public int    actf ;      /* actual feedrate */
        public int    acts ;      /* actual spindle speed */
        public FAXIS  pos = new FAXIS();
    }
    [StructLayout(LayoutKind.Sequential, Pack=4)]
    public class ODBDY_2
    {
        public short  dummy ;
        public short  axis ;      /* axis number */
        public short  alarm ;     /* alarm status */
        public int    prgnum ;    /* current program number */
        public int    prgmnum ;   /* main program number */
        public int    seqnum ;    /* current sequence number */
        public int    actf ;      /* actual feedrate */
        public int    acts ;      /* actual spindle speed */
        public OAXIS  pos = new OAXIS();
    }
#endif
 
        /* cnc_rddynamic2:read all dynamic data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDY2_1
        {
            public short dummy;
            public short axis;      /* axis number */
            public int alarm;     /* alarm status */
            public int prgnum;    /* current program number */
            public int prgmnum;   /* main program number */
            public int seqnum;    /* current sequence number */
            public int actf;      /* actual feedrate */
            public int acts;      /* actual spindle speed */
            public FAXIS pos = new FAXIS();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDY2_2
        {
            public short dummy;
            public short axis;       /* axis number */
            public int alarm;      /* alarm status */
            public int prgnum;     /* current program number */
            public int prgmnum;    /* main program number */
            public int seqnum;     /* current sequence number */
            public int actf;       /* actual feedrate */
            public int acts;       /* actual spindle speed */
            public OAXIS pos = new OAXIS(); /* In case of 1 axis  */
        }
 
        /* cnc_wrrelpos:set origin / preset relative axis position */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBWRR
        {
            public short datano; /* dummy */
            public short type;   /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] data = new int[MAX_AXIS];   /* preset data */
        }
 
        /* cnc_prstwkcd:preset work coordinate */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBWRA
        {
            public short datano; /* dummy */
            public short type;   /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] data = new int[MAX_AXIS];   /* preset data */
        }
 
        /* cnc_rdmovrlap:read manual overlapped motion value */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBOVL
        {
            public short datano; /* dummy */
            public short type;   /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2 * MAX_AXIS)]
            public int[] data;   /* data value:[2][MAX_AXIS] */
        }
 
        /* cnc_rdspload:read load information of serial spindle */
        /* cnc_rdspmaxrpm:read maximum r.p.m. ratio of serial spindle */
        /* cnc_rdspgear:read gear ratio of serial spindle */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPN
        {
            public short datano; /* dummy */
            public short type;   /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public short[] data;   /* preset data */
        }
 
        /* cnc_rdposition:read tool position */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class POSELM
        {
            public int data;         /* position data */
            public short dec;        /* place of decimal point of position data */
            public short unit;       /* unit of position data */
            public short disp;       /* status of display */
            public char name;        /* axis name */
            public char suff;        /* axis name preffix */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class POSELMALL
        {
            public POSELM abs = new POSELM();
            public POSELM mach = new POSELM();
            public POSELM rel = new POSELM();
            public POSELM dist = new POSELM();
        }
 
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBPOS
    {
        public POSELMALL p1=new POSELMALL();
        public POSELMALL p2=new POSELMALL();
        public POSELMALL p3=new POSELMALL();
        public POSELMALL p4=new POSELMALL();
        public POSELMALL p5=new POSELMALL();
        public POSELMALL p6=new POSELMALL();
        public POSELMALL p7=new POSELMALL();
        public POSELMALL p8=new POSELMALL();
        public POSELMALL p9=new POSELMALL();
        public POSELMALL p10=new POSELMALL();
        public POSELMALL p11=new POSELMALL();
        public POSELMALL p12=new POSELMALL();
        public POSELMALL p13=new POSELMALL();
        public POSELMALL p14=new POSELMALL();
        public POSELMALL p15=new POSELMALL();
        public POSELMALL p16=new POSELMALL();
        public POSELMALL p17=new POSELMALL();
        public POSELMALL p18=new POSELMALL();
        public POSELMALL p19=new POSELMALL();
        public POSELMALL p20=new POSELMALL();
        public POSELMALL p21=new POSELMALL();
        public POSELMALL p22=new POSELMALL();
        public POSELMALL p23=new POSELMALL();
        public POSELMALL p24=new POSELMALL();
        // In case of 24 axes.
        // if you need the more information, you must be add the member.
    }
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBPOS
    {
        public POSELMALL p1=new POSELMALL();
        public POSELMALL p2=new POSELMALL();
        public POSELMALL p3=new POSELMALL();
        public POSELMALL p4=new POSELMALL();
        public POSELMALL p5=new POSELMALL();
        public POSELMALL p6=new POSELMALL();
        public POSELMALL p7=new POSELMALL();
        public POSELMALL p8=new POSELMALL();
        public POSELMALL p9=new POSELMALL();
        public POSELMALL p10=new POSELMALL();
        // In case of 10 axes.
        // if you need the more information, you must be add the member.
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPOS
        {
            public POSELMALL p1 = new POSELMALL();
            public POSELMALL p2 = new POSELMALL();
            public POSELMALL p3 = new POSELMALL();
            public POSELMALL p4 = new POSELMALL();
            public POSELMALL p5 = new POSELMALL();
            public POSELMALL p6 = new POSELMALL();
            public POSELMALL p7 = new POSELMALL();
            public POSELMALL p8 = new POSELMALL();
            // In case of 8 axes.
            // if you need the more information, you must be add the member.
        }
#endif
 
        /* cnc_rdhndintrpt:read handle interruption */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHND_data
        {
            public POSELM input = new POSELM();   /* input unit */
            public POSELM output = new POSELM();  /* output unit */
        }
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBHND
    {
        public ODBHND_data p1=new ODBHND_data();
        public ODBHND_data p2=new ODBHND_data();
        public ODBHND_data p3=new ODBHND_data();
        public ODBHND_data p4=new ODBHND_data();
        public ODBHND_data p5=new ODBHND_data();
        public ODBHND_data p6=new ODBHND_data();
        public ODBHND_data p7=new ODBHND_data();
        public ODBHND_data p8=new ODBHND_data();
        public ODBHND_data p9=new ODBHND_data();
        public ODBHND_data p10=new ODBHND_data();
        public ODBHND_data p11=new ODBHND_data();
        public ODBHND_data p12=new ODBHND_data();
        public ODBHND_data p13=new ODBHND_data();
        public ODBHND_data p14=new ODBHND_data();
        public ODBHND_data p15=new ODBHND_data();
        public ODBHND_data p16=new ODBHND_data();
        public ODBHND_data p17=new ODBHND_data();
        public ODBHND_data p18=new ODBHND_data();
        public ODBHND_data p19=new ODBHND_data();
        public ODBHND_data p20=new ODBHND_data();
        public ODBHND_data p21=new ODBHND_data();
        public ODBHND_data p22=new ODBHND_data();
        public ODBHND_data p23=new ODBHND_data();
        public ODBHND_data p24=new ODBHND_data();
        // In case of 24 axes.
        // if you need the more information, you must be add the member.
    }
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBHND
    {
        public ODBHND_data p1=new ODBHND_data();
        public ODBHND_data p2=new ODBHND_data();
        public ODBHND_data p3=new ODBHND_data();
        public ODBHND_data p4=new ODBHND_data();
        public ODBHND_data p5=new ODBHND_data();
        public ODBHND_data p6=new ODBHND_data();
        public ODBHND_data p7=new ODBHND_data();
        public ODBHND_data p8=new ODBHND_data();
        public ODBHND_data p9=new ODBHND_data();
        public ODBHND_data p10=new ODBHND_data();
        // In case of 10 axes.
        // if you need the more information, you must be add the member.
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHND
        {
            public ODBHND_data p1 = new ODBHND_data();
            public ODBHND_data p2 = new ODBHND_data();
            public ODBHND_data p3 = new ODBHND_data();
            public ODBHND_data p4 = new ODBHND_data();
            public ODBHND_data p5 = new ODBHND_data();
            public ODBHND_data p6 = new ODBHND_data();
            public ODBHND_data p7 = new ODBHND_data();
            public ODBHND_data p8 = new ODBHND_data();
            // In case of 8 axes.
            // if you need the more information, you must be add the member.
        }
#endif
 
        /* cnc_rdspeed:read current speed */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class SPEEDELM
        {
            public int data;       /* speed data */
            public short dec;        /* decimal position */
            public short unit;       /* data unit */
            public short disp;       /* display flag */
            public byte name;       /* name of data */
            public byte suff;       /* suffix */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPEED
        {
            public SPEEDELM actf = new SPEEDELM();   /* actual feed rate */
            public SPEEDELM acts = new SPEEDELM();   /* actual spindle speed */
        }
 
        /* cnc_rdsvmeter:read servo load meter */
        /* cnc_rdspmeter:read spindle load meter */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class LOADELM
        {
            public int data;       /* load meter */
            public short dec;        /* decimal position */
            public short unit;       /* unit */
            public byte name;       /* name of data */
            public byte suff1;      /* suffix */
            public byte suff2;      /* suffix */
            public byte reserve;    /* reserve */
        }
 
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBSVLOAD
    {
        public LOADELM svload1 = new LOADELM();     /* servo load meter */
        public LOADELM svload2 = new LOADELM();     /* servo load meter */
        public LOADELM svload3 = new LOADELM();     /* servo load meter */
        public LOADELM svload4 = new LOADELM();     /* servo load meter */
        public LOADELM svload5 = new LOADELM();     /* servo load meter */
        public LOADELM svload6 = new LOADELM();     /* servo load meter */
        public LOADELM svload7 = new LOADELM();     /* servo load meter */
        public LOADELM svload8 = new LOADELM();     /* servo load meter */
        public LOADELM svload9 = new LOADELM();     /* servo load meter */
        public LOADELM svload10= new LOADELM();     /* servo load meter */
        public LOADELM svload11= new LOADELM();     /* servo load meter */
        public LOADELM svload12= new LOADELM();     /* servo load meter */
        public LOADELM svload13= new LOADELM();     /* servo load meter */
        public LOADELM svload14= new LOADELM();     /* servo load meter */
        public LOADELM svload15= new LOADELM();     /* servo load meter */
        public LOADELM svload16= new LOADELM();     /* servo load meter */
        public LOADELM svload17= new LOADELM();     /* servo load meter */
        public LOADELM svload18= new LOADELM();     /* servo load meter */
        public LOADELM svload19= new LOADELM();     /* servo load meter */
        public LOADELM svload20= new LOADELM();     /* servo load meter */
        public LOADELM svload21= new LOADELM();     /* servo load meter */
        public LOADELM svload22= new LOADELM();     /* servo load meter */
        public LOADELM svload23= new LOADELM();     /* servo load meter */
        public LOADELM svload24= new LOADELM();     /* servo load meter */
    }
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBSVLOAD
    {
        public LOADELM svload1 = new LOADELM();     /* servo load meter */
        public LOADELM svload2 = new LOADELM();     /* servo load meter */
        public LOADELM svload3 = new LOADELM();     /* servo load meter */
        public LOADELM svload4 = new LOADELM();     /* servo load meter */
        public LOADELM svload5 = new LOADELM();     /* servo load meter */
        public LOADELM svload6 = new LOADELM();     /* servo load meter */
        public LOADELM svload7 = new LOADELM();     /* servo load meter */
        public LOADELM svload8 = new LOADELM();     /* servo load meter */
        public LOADELM svload9 = new LOADELM();     /* servo load meter */
        public LOADELM svload10= new LOADELM();     /* servo load meter */
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSVLOAD
        {
            public LOADELM svload1 = new LOADELM();     /* servo load meter */
            public LOADELM svload2 = new LOADELM();     /* servo load meter */
            public LOADELM svload3 = new LOADELM();     /* servo load meter */
            public LOADELM svload4 = new LOADELM();     /* servo load meter */
            public LOADELM svload5 = new LOADELM();     /* servo load meter */
            public LOADELM svload6 = new LOADELM();     /* servo load meter */
            public LOADELM svload7 = new LOADELM();     /* servo load meter */
            public LOADELM svload8 = new LOADELM();     /* servo load meter */
        }
#endif
 
        /* cnc_rdexecpt:read execution program pointer */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class PRGPNT
        {
            public int prog_no;                      /* program number */
            public int blk_no;                       /* block number */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPLOAD_data
        {
            public LOADELM spload = new LOADELM();     /* spindle load meter */
            public LOADELM spspeed = new LOADELM();    /* spindle speed */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPLOAD
        {
            public ODBSPLOAD_data spload1 = new ODBSPLOAD_data();     /* spindle load */
            public ODBSPLOAD_data spload2 = new ODBSPLOAD_data();     /* spindle load */
            public ODBSPLOAD_data spload3 = new ODBSPLOAD_data();     /* spindle load */
            public ODBSPLOAD_data spload4 = new ODBSPLOAD_data();     /* spindle load */
        }
 
        /* cnc_rd5axmandt:read manual feed for 5-axis machining */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB5AXMAN
        {
            public short type1;
            public short type2;
            public short type3;
            public int data1;
            public int data2;
            public int data3;
            public int c1;
            public int c2;
            public int dummy;
            public int td;
            public int r1;
            public int r2;
            public int vr;
            public int h1;
            public int h2;
        }
 
        /*----------------------*/
        /* CNC: Program related */
        /*----------------------*/
 
        /* cnc_rddncdgndt:read the diagnosis data of DNC operation */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDNCDGN
        {
            public short ctrl_word;
            public short can_word;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public char[] nc_file;
            public ushort read_ptr;
            public ushort write_ptr;
            public ushort empty_cnt;
            public uint total_size;
        }
 
        /* cnc_upload:upload NC program */
        /* cnc_cupload:upload NC program(conditional) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBUP
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;  /* dummy */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 256)]
            public char[] data; /* data */
        } /* In case that the number of data is 256 */
 
        /* cnc_buff:read buffer status for downloading/verification NC program */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBBUF
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;  /* dummy */
            public short data;  /* buffer status */
        }
 
        /* cnc_rdprogdir:read program directory */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class PRGDIR
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 256)]
            public char[] prg_data; /* directory data */
        } /* In case that the number of data is 256 */
 
        /* cnc_rdproginfo:read program information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBNC_1
        {
            public short reg_prg;       /* registered program number */
            public short unreg_prg;     /* unregistered program number */
            public int used_mem;      /* used memory area */
            public int unused_mem;    /* unused memory area */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBNC_2
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 31)]
            public char[] asc; /* ASCII string type */
        }
 
        /* cnc_rdprgnum:read program number under execution */
#if (!ONO8D)
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPRO
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;     /* dummy */
            public short data;      /* running program number */
            public short mdata;     /* main program number */
        }
#else
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBPRO
    {
        [MarshalAs(UnmanagedType.ByValArray,SizeConst=2)]
        public short[] dummy ;     /* dummy */
        public int     data ;      /* running program number */
        public int     mdata ;     /* main program number */
    }
#endif
 
        /* cnc_exeprgname:read program name under execution */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXEPRG
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 36)]
            public char[] name;       /* running program name */
            public int o_num;        /* running program number */
        }
 
        /* cnc_rdseqnum:read sequence number under execution */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSEQ
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;      /* dummy */
            public int data;       /* sequence number */
        }
 
        /* cnc_rdmdipntr:read execution pointer for MDI operation */
#if (!ONO8D)
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMDIP
        {
            public short mdiprog;    /* exec. program number */
            public int mdipntr;    /* exec. pointer */
            public short crntprog;   /* prepare program number */
            public int crntpntr;   /* prepare pointer */
        }
#else
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBMDIP
    {
        public int     mdiprog;    /* exec. program number */
        public int     mdipntr;    /* exec. pointer */
        public int     crntprog;   /* prepare program number */
        public int     crntpntr;   /* prepare pointer */
    }
#endif
 
        /* cnc_rdaxisdata:read various axis data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAXDT_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string name = new string(' ', 4);   /* axis name */
            public int data;                       /* position data */
            public short dec;                        /* decimal position */
            public short unit;                       /* data unit */
            public short flag;                       /* flags */
            public short reserve;                    /* reserve */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAXDT
        {
            public ODBAXDT_data data1 = new ODBAXDT_data();
            public ODBAXDT_data data2 = new ODBAXDT_data();
            public ODBAXDT_data data3 = new ODBAXDT_data();
            public ODBAXDT_data data4 = new ODBAXDT_data();
            public ODBAXDT_data data5 = new ODBAXDT_data();
            public ODBAXDT_data data6 = new ODBAXDT_data();
            public ODBAXDT_data data7 = new ODBAXDT_data();
            public ODBAXDT_data data8 = new ODBAXDT_data();
            public ODBAXDT_data data9 = new ODBAXDT_data();
            public ODBAXDT_data data10 = new ODBAXDT_data();
            public ODBAXDT_data data11 = new ODBAXDT_data();
            public ODBAXDT_data data12 = new ODBAXDT_data();
            public ODBAXDT_data data13 = new ODBAXDT_data();
            public ODBAXDT_data data14 = new ODBAXDT_data();
            public ODBAXDT_data data15 = new ODBAXDT_data();
            public ODBAXDT_data data16 = new ODBAXDT_data();
            public ODBAXDT_data data17 = new ODBAXDT_data();
            public ODBAXDT_data data18 = new ODBAXDT_data();
            public ODBAXDT_data data19 = new ODBAXDT_data();
            public ODBAXDT_data data20 = new ODBAXDT_data();
            public ODBAXDT_data data21 = new ODBAXDT_data();
            public ODBAXDT_data data22 = new ODBAXDT_data();
            public ODBAXDT_data data23 = new ODBAXDT_data();
            public ODBAXDT_data data24 = new ODBAXDT_data();
            public ODBAXDT_data data25 = new ODBAXDT_data();
            public ODBAXDT_data data26 = new ODBAXDT_data();
            public ODBAXDT_data data27 = new ODBAXDT_data();
            public ODBAXDT_data data28 = new ODBAXDT_data();
            public ODBAXDT_data data29 = new ODBAXDT_data();
            public ODBAXDT_data data30 = new ODBAXDT_data();
            public ODBAXDT_data data31 = new ODBAXDT_data();
            public ODBAXDT_data data32 = new ODBAXDT_data();
            public ODBAXDT_data data33 = new ODBAXDT_data();
            public ODBAXDT_data data34 = new ODBAXDT_data();
            public ODBAXDT_data data35 = new ODBAXDT_data();
            public ODBAXDT_data data36 = new ODBAXDT_data();
            public ODBAXDT_data data37 = new ODBAXDT_data();
            public ODBAXDT_data data38 = new ODBAXDT_data();
            public ODBAXDT_data data39 = new ODBAXDT_data();
            public ODBAXDT_data data40 = new ODBAXDT_data();
            public ODBAXDT_data data41 = new ODBAXDT_data();
            public ODBAXDT_data data42 = new ODBAXDT_data();
            public ODBAXDT_data data43 = new ODBAXDT_data();
            public ODBAXDT_data data44 = new ODBAXDT_data();
            public ODBAXDT_data data45 = new ODBAXDT_data();
            public ODBAXDT_data data46 = new ODBAXDT_data();
            public ODBAXDT_data data47 = new ODBAXDT_data();
            public ODBAXDT_data data48 = new ODBAXDT_data();
            public ODBAXDT_data data49 = new ODBAXDT_data();
            public ODBAXDT_data data50 = new ODBAXDT_data();
            public ODBAXDT_data data51 = new ODBAXDT_data();
            public ODBAXDT_data data52 = new ODBAXDT_data();
            public ODBAXDT_data data53 = new ODBAXDT_data();
            public ODBAXDT_data data54 = new ODBAXDT_data();
            public ODBAXDT_data data55 = new ODBAXDT_data();
            public ODBAXDT_data data56 = new ODBAXDT_data();
            public ODBAXDT_data data57 = new ODBAXDT_data();
            public ODBAXDT_data data58 = new ODBAXDT_data();
            public ODBAXDT_data data59 = new ODBAXDT_data();
            public ODBAXDT_data data60 = new ODBAXDT_data();
            public ODBAXDT_data data61 = new ODBAXDT_data();
            public ODBAXDT_data data62 = new ODBAXDT_data();
            public ODBAXDT_data data63 = new ODBAXDT_data();
            public ODBAXDT_data data64 = new ODBAXDT_data();
            public ODBAXDT_data data65 = new ODBAXDT_data();
            public ODBAXDT_data data66 = new ODBAXDT_data();
            public ODBAXDT_data data67 = new ODBAXDT_data();
            public ODBAXDT_data data68 = new ODBAXDT_data();
            public ODBAXDT_data data69 = new ODBAXDT_data();
            public ODBAXDT_data data70 = new ODBAXDT_data();
            public ODBAXDT_data data71 = new ODBAXDT_data();
            public ODBAXDT_data data72 = new ODBAXDT_data();
            public ODBAXDT_data data73 = new ODBAXDT_data();
            public ODBAXDT_data data74 = new ODBAXDT_data();
            public ODBAXDT_data data75 = new ODBAXDT_data();
            public ODBAXDT_data data76 = new ODBAXDT_data();
            public ODBAXDT_data data77 = new ODBAXDT_data();
            public ODBAXDT_data data78 = new ODBAXDT_data();
            public ODBAXDT_data data79 = new ODBAXDT_data();
            public ODBAXDT_data data80 = new ODBAXDT_data();
            public ODBAXDT_data data81 = new ODBAXDT_data();
            public ODBAXDT_data data82 = new ODBAXDT_data();
            public ODBAXDT_data data83 = new ODBAXDT_data();
            public ODBAXDT_data data84 = new ODBAXDT_data();
            public ODBAXDT_data data85 = new ODBAXDT_data();
            public ODBAXDT_data data86 = new ODBAXDT_data();
            public ODBAXDT_data data87 = new ODBAXDT_data();
            public ODBAXDT_data data88 = new ODBAXDT_data();
            public ODBAXDT_data data89 = new ODBAXDT_data();
            public ODBAXDT_data data90 = new ODBAXDT_data();
            public ODBAXDT_data data91 = new ODBAXDT_data();
            public ODBAXDT_data data92 = new ODBAXDT_data();
            public ODBAXDT_data data93 = new ODBAXDT_data();
            public ODBAXDT_data data94 = new ODBAXDT_data();
            public ODBAXDT_data data95 = new ODBAXDT_data();
            public ODBAXDT_data data96 = new ODBAXDT_data();
            public ODBAXDT_data data97 = new ODBAXDT_data();
            public ODBAXDT_data data98 = new ODBAXDT_data();
            public ODBAXDT_data data99 = new ODBAXDT_data();
            public ODBAXDT_data data100 = new ODBAXDT_data();
            public ODBAXDT_data data101 = new ODBAXDT_data();
            public ODBAXDT_data data102 = new ODBAXDT_data();
            public ODBAXDT_data data103 = new ODBAXDT_data();
            public ODBAXDT_data data104 = new ODBAXDT_data();
            public ODBAXDT_data data105 = new ODBAXDT_data();
            public ODBAXDT_data data106 = new ODBAXDT_data();
            public ODBAXDT_data data107 = new ODBAXDT_data();
            public ODBAXDT_data data108 = new ODBAXDT_data();
            public ODBAXDT_data data109 = new ODBAXDT_data();
            public ODBAXDT_data data110 = new ODBAXDT_data();
            public ODBAXDT_data data111 = new ODBAXDT_data();
            public ODBAXDT_data data112 = new ODBAXDT_data();
            public ODBAXDT_data data113 = new ODBAXDT_data();
            public ODBAXDT_data data114 = new ODBAXDT_data();
            public ODBAXDT_data data115 = new ODBAXDT_data();
            public ODBAXDT_data data116 = new ODBAXDT_data();
            public ODBAXDT_data data117 = new ODBAXDT_data();
            public ODBAXDT_data data118 = new ODBAXDT_data();
            public ODBAXDT_data data119 = new ODBAXDT_data();
            public ODBAXDT_data data120 = new ODBAXDT_data();
            public ODBAXDT_data data121 = new ODBAXDT_data();
            public ODBAXDT_data data122 = new ODBAXDT_data();
            public ODBAXDT_data data123 = new ODBAXDT_data();
            public ODBAXDT_data data124 = new ODBAXDT_data();
            public ODBAXDT_data data125 = new ODBAXDT_data();
            public ODBAXDT_data data126 = new ODBAXDT_data();
            public ODBAXDT_data data127 = new ODBAXDT_data();
            public ODBAXDT_data data128 = new ODBAXDT_data();
        }
 
        /* cnc_rdspcss:read constant surface speed data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBCSS
        {
            public int srpm;       /* order spindle speed */
            public int sspm;       /* order constant spindle speed */
            public int smax;       /* order maximum spindle speed */
        }
 
        /* cnc_rdpdf_drive:read program drive directory */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPDFDRV
        {
            public short max_num;    /* maximum drive number */
            public short dummy;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive1 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive2 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive3 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive4 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive5 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive6 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive7 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive8 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive9 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive10 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive11 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive12 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive13 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive14 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive15 = new string(' ', 12);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string drive16 = new string(' ', 12);
        }
 
        /* cnc_rdpdf_inf:read program drive information */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPDFINF
        {
            public int used_page;  /* used capacity */
            public int all_page;   /* all capacity */
            public int used_dir;   /* used directory number */
            public int all_dir;    /* all directory number */
        }
 
        /* cnc_rdpdf_subdir:read directory (sub directories) */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IDBPDFSDIR
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 212)]
            public string path = new string(' ', 212);  /* path name */
            public short req_num;    /* entry number */
            public short dummy;
        }
 
        /* cnc_rdpdf_subdir:read directory (sub directories) */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPDFSDIR
        {
            public short sub_exist;    /* existence of sub directory */
            public short dummy;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 36)]
            public string d_f = new string(' ', 36);  /* path name */
        }
 
        /* cnc_rdpdf_alldir:read directory (all files) */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IDBPDFADIR
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 212)]
            public string path = new string(' ', 212);  /* path name */
            public short req_num;    /* entry number */
            public short size_kind;  /* kind of size */
            public short type;       /* kind of format */
            public short dummy;
        }
 
        /* cnc_rdpdf_alldir:read directory (all files) */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPDFADIR
        {
            public short data_kind;  /* kinf of data */
            public short year;       /* last date and time */
            public short mon;        /* last date and time */
            public short day;        /* last date and time */
            public short hour;       /* last date and time */
            public short min;        /* last date and time */
            public short sec;        /* last date and time */
            public short dummy;
            public int dummy2;
            public int size;       /* size */
            public int attr;       /* attribute */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 36)]
            public string d_f = new string(' ', 36);      /* path name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 52)]
            public string comment = new string(' ', 52);  /* comment */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string o_time = new string(' ', 12);   /* machining time stamp */
        }
 
        /* cnc_rdpdf_subdirn:read file count the directory has */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPDFNFIL
        {
            public short dir_num;    /* directory */
            public short file_num;   /* file */
        }
 
        /* cnc_wrpdf_attr:change attribute of program file and directory */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBPDFTDIR
        {
            public uint slct;       /* selection */
            public uint attr;       /* data */
        }
 
        /*---------------------------*/
        /* CNC: NC file data related */
        /*---------------------------*/
 
        /* cnc_rdtofs:read tool offset value */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTOFS
        {
            public short datano; /* data number */
            public short type;   /* data type */
            public int data;   /* data */
        }
 
        /* cnc_rdtofsr:read tool offset value(area specified) */
        /* cnc_wrtofsr:write tool offset value(area specified) */
        [StructLayout(LayoutKind.Explicit)]
        public class OFS_1
        {
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] m_ofs = new int[5];     /* M Each */
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] m_ofs_a = new int[5];   /* M-A All */
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] t_tip = new short[5];   /* T Each, 2-byte */
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] t_ofs = new int[5];     /* T Each, 4-byte */
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OFS_2
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2 * 5)]
            public int[] m_ofs_b = new int[10];  /* M-B All */
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OFS_3
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4 * 5)]
            public int[] m_ofs_c = new int[20];   /* M-C All */
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class T_OFS_A
        {
            public short tip;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public int[] data;
        } /* T-A All */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class T_OFS_A_data
        {
            public T_OFS_A data1 = new T_OFS_A();
            public T_OFS_A data2 = new T_OFS_A();
            public T_OFS_A data3 = new T_OFS_A();
            public T_OFS_A data4 = new T_OFS_A();
            public T_OFS_A data5 = new T_OFS_A();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class T_OFS_B
        {
            public short tip;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] data;
        } /* T-B All */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class T_OFS_B_data
        {
            public T_OFS_B data1 = new T_OFS_B();
            public T_OFS_B data2 = new T_OFS_B();
            public T_OFS_B data3 = new T_OFS_B();
            public T_OFS_B data4 = new T_OFS_B();
            public T_OFS_B data5 = new T_OFS_B();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTO_1_1
        {
            public short datano_s;  /* start offset number */
            public short type;      /* offset type */
            public short datano_e;  /* end offset number */
            public OFS_1 ofs = new OFS_1();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTO_1_2
        {
            public short datano_s;  /* start offset number */
            public short type;      /* offset type */
            public short datano_e;  /* end offset number */
            public OFS_2 ofs = new OFS_2();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTO_1_3
        {
            public short datano_s;  /* start offset number */
            public short type;      /* offset type */
            public short datano_e;  /* end offset number */
            public OFS_3 ofs = new OFS_3();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTO_2
        {
            public short datano_s;  /* start offset number */
            public short type;      /* offset type */
            public short datano_e;  /* end offset number */
            public T_OFS_A_data tofsa = new T_OFS_A_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTO_3
        {
            public short datano_s;  /* start offset number */
            public short type;      /* offset type */
            public short datano_e;  /* end offset number */
            public T_OFS_B_data tofsb = new T_OFS_B_data();
        }
 
        /* cnc_rdzofs:read work zero offset value */
        /* cnc_wrzofs:write work zero offset value */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBZOFS
        {
            public short datano;    /* offset NO. */
            public short type;      /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] data = new int[MAX_AXIS];       /* data value */
        }
 
        /* cnc_rdzofsr:read work zero offset value(area specified) */
        /* cnc_wrzofsr:write work zero offset value(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBZOR
        {
            public short datano_s;  /* start offset number */
            public short type;      /* axis number */
            public short datano_e;  /* end offset number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7 * MAX_AXIS)]
            public int[] data = new int[7 * MAX_AXIS];      /* offset value */
        } /* In case that the number of axes is MAX_AXIS, the number of data is 7 */
 
        /* cnc_rdmsptype:read mesured point value */
        /* cnc_wrmsptype:write mesured point value */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMSTP
        {
            public short datano_s;  /* start offset number */
            public short dummy;     /* dummy */
            public short datano_e;  /* end offset number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)]
            public sbyte[] data = new sbyte[7];      /* mesured point value */
        }
 
        /* cnc_rdparam:read parameter */
        /* cnc_wrparam:write parameter */
        /* cnc_rdset:read setting data */
        /* cnc_wrset:write setting data */
        /* cnc_rdparar:read parameter(area specified) */
        /* cnc_wrparas:write parameter(plural specified) */
        /* cnc_rdsetr:read setting data(area specified) */
        /* cnc_wrsets:write setting data(plural specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REALPRM
        {
            public int prm_val;     /* data of real parameter */
            public int dec_val;     /* decimal point of real parameter */
        }
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class REALPRMS
    {
        public REALPRM rdata1=new REALPRM();
        public REALPRM rdata2=new REALPRM();
        public REALPRM rdata3=new REALPRM();
        public REALPRM rdata4=new REALPRM();
        public REALPRM rdata5=new REALPRM();
        public REALPRM rdata6=new REALPRM();
        public REALPRM rdata7=new REALPRM();
        public REALPRM rdata8=new REALPRM();
        public REALPRM rdata9=new REALPRM();
        public REALPRM rdata10=new REALPRM();
        public REALPRM rdata11=new REALPRM();
        public REALPRM rdata12=new REALPRM();
        public REALPRM rdata13=new REALPRM();
        public REALPRM rdata14=new REALPRM();
        public REALPRM rdata15=new REALPRM();
        public REALPRM rdata16=new REALPRM();
        public REALPRM rdata17=new REALPRM();
        public REALPRM rdata18=new REALPRM();
        public REALPRM rdata19=new REALPRM();
        public REALPRM rdata20=new REALPRM();
        public REALPRM rdata21=new REALPRM();
        public REALPRM rdata22=new REALPRM();
        public REALPRM rdata23=new REALPRM();
        public REALPRM rdata24=new REALPRM();
    } /* In case that the number of alarm is 24 */
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class REALPRMS
    {
        public REALPRM rdata1=new REALPRM();
        public REALPRM rdata2=new REALPRM();
        public REALPRM rdata3=new REALPRM();
        public REALPRM rdata4=new REALPRM();
        public REALPRM rdata5=new REALPRM();
        public REALPRM rdata6=new REALPRM();
        public REALPRM rdata7=new REALPRM();
        public REALPRM rdata8=new REALPRM();
        public REALPRM rdata9=new REALPRM();
        public REALPRM rdata10=new REALPRM();
    } /* In case that the number of alarm is 10 */
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REALPRMS
        {
            public REALPRM rdata1 = new REALPRM();
            public REALPRM rdata2 = new REALPRM();
            public REALPRM rdata3 = new REALPRM();
            public REALPRM rdata4 = new REALPRM();
            public REALPRM rdata5 = new REALPRM();
            public REALPRM rdata6 = new REALPRM();
            public REALPRM rdata7 = new REALPRM();
            public REALPRM rdata8 = new REALPRM();
        } /* In case that the number of alarm is 8 */
#endif
 
        [StructLayout(LayoutKind.Explicit)]
        public class IODBPSD_1
        {
            [FieldOffset(0)]
            public short datano;    /* data number */
            [FieldOffset(2)]
            public short type;      /* axis number */
            [FieldOffset(4)]
            public byte cdata;     /* parameter / setting data */
            [FieldOffset(4)]
            public short idata;
            [FieldOffset(4)]
            public int ldata;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_2
        {
            public short datano;    /* data number */
            public short type;      /* axis number */
            public REALPRM rdata = new REALPRM();
        }
        [StructLayout(LayoutKind.Explicit)]
        public class IODBPSD_3
        {
            [FieldOffset(0)]
            public short datano;    /* data number */
            [FieldOffset(2)]
            public short type;      /* axis number */
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas = new byte[MAX_AXIS];
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas = new short[MAX_AXIS];
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas = new int[MAX_AXIS];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_4
        {
            public short datano;    /* data number */
            public short type;      /* axis number */
            public REALPRMS rdatas = new REALPRMS();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_A
        {
            public IODBPSD_1 data1 = new IODBPSD_1();
            public IODBPSD_1 data2 = new IODBPSD_1();
            public IODBPSD_1 data3 = new IODBPSD_1();
            public IODBPSD_1 data4 = new IODBPSD_1();
            public IODBPSD_1 data5 = new IODBPSD_1();
            public IODBPSD_1 data6 = new IODBPSD_1();
            public IODBPSD_1 data7 = new IODBPSD_1();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_B
        {
            public IODBPSD_2 data1 = new IODBPSD_2();
            public IODBPSD_2 data2 = new IODBPSD_2();
            public IODBPSD_2 data3 = new IODBPSD_2();
            public IODBPSD_2 data4 = new IODBPSD_2();
            public IODBPSD_2 data5 = new IODBPSD_2();
            public IODBPSD_2 data6 = new IODBPSD_2();
            public IODBPSD_2 data7 = new IODBPSD_2();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_C
        {
            public IODBPSD_3 data1 = new IODBPSD_3();
            public IODBPSD_3 data2 = new IODBPSD_3();
            public IODBPSD_3 data3 = new IODBPSD_3();
            public IODBPSD_3 data4 = new IODBPSD_3();
            public IODBPSD_3 data5 = new IODBPSD_3();
            public IODBPSD_3 data6 = new IODBPSD_3();
            public IODBPSD_3 data7 = new IODBPSD_3();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSD_D
        {
            public IODBPSD_4 data1 = new IODBPSD_4();
            public IODBPSD_4 data2 = new IODBPSD_4();
            public IODBPSD_4 data3 = new IODBPSD_4();
            public IODBPSD_4 data4 = new IODBPSD_4();
            public IODBPSD_4 data5 = new IODBPSD_4();
            public IODBPSD_4 data6 = new IODBPSD_4();
            public IODBPSD_4 data7 = new IODBPSD_4();
        } /* (sample) must be modified */
 
        /* cnc_rdparam_ext:read parameters */
        /* cnc_rddiag_ext:read diagnosis data */
        /* cnc_start_async_wrparam:async parameter write start */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRMNO
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] prm = new int[10];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRM_data
        {
            public int prm_val;   /* parameter / setting data */
            public int dec_val;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRM1
        {
            public IODBPRM_data data1 = new IODBPRM_data();
            public IODBPRM_data data2 = new IODBPRM_data();
            public IODBPRM_data data3 = new IODBPRM_data();
            public IODBPRM_data data4 = new IODBPRM_data();
            public IODBPRM_data data5 = new IODBPRM_data();
            public IODBPRM_data data6 = new IODBPRM_data();
            public IODBPRM_data data7 = new IODBPRM_data();
            public IODBPRM_data data8 = new IODBPRM_data();
            public IODBPRM_data data9 = new IODBPRM_data();
            public IODBPRM_data data10 = new IODBPRM_data();
            public IODBPRM_data data11 = new IODBPRM_data();
            public IODBPRM_data data12 = new IODBPRM_data();
            public IODBPRM_data data13 = new IODBPRM_data();
            public IODBPRM_data data14 = new IODBPRM_data();
            public IODBPRM_data data15 = new IODBPRM_data();
            public IODBPRM_data data16 = new IODBPRM_data();
            public IODBPRM_data data17 = new IODBPRM_data();
            public IODBPRM_data data18 = new IODBPRM_data();
            public IODBPRM_data data19 = new IODBPRM_data();
            public IODBPRM_data data20 = new IODBPRM_data();
            public IODBPRM_data data21 = new IODBPRM_data();
            public IODBPRM_data data22 = new IODBPRM_data();
            public IODBPRM_data data23 = new IODBPRM_data();
            public IODBPRM_data data24 = new IODBPRM_data();
            public IODBPRM_data data25 = new IODBPRM_data();
            public IODBPRM_data data26 = new IODBPRM_data();
            public IODBPRM_data data27 = new IODBPRM_data();
            public IODBPRM_data data28 = new IODBPRM_data();
            public IODBPRM_data data29 = new IODBPRM_data();
            public IODBPRM_data data30 = new IODBPRM_data();
            public IODBPRM_data data31 = new IODBPRM_data();
            public IODBPRM_data data32 = new IODBPRM_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRM2
        {
            public int datano;    /* data number */
            public short type;      /* data type */
            public short axis;      /* axis information */
            public short info;      /* misc information */
            public short unit;      /* unit information */
            public IODBPRM1 data = new IODBPRM1();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRM
        {
            public IODBPRM2 prm1 = new IODBPRM2();
            public IODBPRM2 prm2 = new IODBPRM2();
            public IODBPRM2 prm3 = new IODBPRM2();
            public IODBPRM2 prm4 = new IODBPRM2();
            public IODBPRM2 prm5 = new IODBPRM2();
            public IODBPRM2 prm6 = new IODBPRM2();
            public IODBPRM2 prm7 = new IODBPRM2();
            public IODBPRM2 prm8 = new IODBPRM2();
            public IODBPRM2 prm9 = new IODBPRM2();
            public IODBPRM2 prm10 = new IODBPRM2();
        } /* In case that the number of alarm is 10 */
 
        /* cnc_rdpitchr:read pitch error compensation data(area specified) */
        /* cnc_wrpitchr:write pitch error compensation data(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPI
        {
            public short datano_s;  /* start pitch number */
            public short dummy;     /* dummy */
            public short datano_e;  /* end pitch number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public sbyte[] data = new sbyte[5];    /* offset value */
        } /* In case that the number of data is 5 */
 
        /* cnc_rdmacro:read custom macro variable */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBM
        {
            public short datano;    /* variable number */
            public short dummy;     /* dummy */
            public int mcr_val;   /* macro variable */
            public short dec_val;   /* decimal point */
        }
 
        /* cnc_rdmacror:read custom macro variables(area specified) */
        /* cnc_wrmacror:write custom macro variables(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMR_data
        {
            public int mcr_val;   /* macro variable */
            public short dec_val;   /* decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMR1
        {
            public IODBMR_data data1 = new IODBMR_data();
            public IODBMR_data data2 = new IODBMR_data();
            public IODBMR_data data3 = new IODBMR_data();
            public IODBMR_data data4 = new IODBMR_data();
            public IODBMR_data data5 = new IODBMR_data();
        /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMR
        {
            public short datano_s;  /* start macro number */
            public short dummy;     /* dummy */
            public short datano_e;  /* end macro number */
            public IODBMR1 data = new IODBMR1();
        }
 
        /* cnc_rdpmacro:read P code macro variable */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPM
        {
            public int datano;    /* variable number */
            public short dummy;     /* dummy */
            public int mcr_val;   /* macro variable */
            public short dec_val;   /* decimal point */
        }
 
        /* cnc_rdpmacror:read P code macro variables(area specified) */
        /* cnc_wrpmacror:write P code macro variables(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPR_data
        {
            public int mcr_val;   /* macro variable */
            public short dec_val;   /* decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPR1
        {
            public IODBPR_data data1 = new IODBPR_data();
            public IODBPR_data data2 = new IODBPR_data();
            public IODBPR_data data3 = new IODBPR_data();
            public IODBPR_data data4 = new IODBPR_data();
            public IODBPR_data data5 = new IODBPR_data();
        /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPR
        {
            public int datano_s;  /* start macro number */
            public short dummy;     /* dummy */
            public int datano_e;  /* end macro number */
            public IODBPR1 data = new IODBPR1();
        }
 
        /* cnc_rdtofsinfo:read tool offset information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLINF
        {
            public short ofs_type;
            public short use_no;
        }
 
        /* cnc_rdtofsinfo2:read tool offset information(2) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLINF2
        {
            public short ofs_type;
            public short use_no;
            public short ofs_enable;
        }
 
        /* cnc_rdmacroinfo:read custom macro variable information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMVINF
        {
            public short use_no1;
            public short use_no2;
        }
 
        /* cnc_rdpmacroinfo:read P code macro variable information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMINF
        {
            public short use_no1;
#if PCD_UWORD
        public ushort  use_no2;
#else
            public short use_no2;
#endif
            public short v2_type;
        }
 
        /* cnc_tofs_rnge:read validity of tool offset */
        /* cnc_zofs_rnge:read validity of work zero offset */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDATRNG
        {
            public int data_min;   /* lower limit */
            public int data_max;   /* upper limit */
            public int status;     /* status of setting */
        }
 
        /* cnc_rdhsprminfo:read the information for function cnc_rdhsparam() */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class HSPINFO_data
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data1 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data2 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data3 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data4 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data5 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data6 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data7 = new byte[16];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] data8 = new byte[16];
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class HSPINFO
        {
            public HSPINFO_data prminfo1 = new HSPINFO_data();
            public HSPINFO_data prminfo2 = new HSPINFO_data();
            public HSPINFO_data prminfo3 = new HSPINFO_data();
            public HSPINFO_data prminfo4 = new HSPINFO_data();
            public HSPINFO_data prminfo5 = new HSPINFO_data();
            public HSPINFO_data prminfo6 = new HSPINFO_data();
            public HSPINFO_data prminfo7 = new HSPINFO_data();
            public HSPINFO_data prminfo8 = new HSPINFO_data();
            public HSPINFO_data prminfo9 = new HSPINFO_data();
            public HSPINFO_data prminfo10 = new HSPINFO_data();
        }
 
        /* cnc_rdhsparam:read parameters at the high speed */
        [StructLayout(LayoutKind.Explicit)]
        public class HSPDATA_1
        {
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas1 = new byte[MAX_AXIS];
            [FieldOffset(4 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas2 = new byte[MAX_AXIS];
            [FieldOffset(4 * 2 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas3 = new byte[MAX_AXIS];
            [FieldOffset(4 * 3 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas4 = new byte[MAX_AXIS];
            [FieldOffset(4 * 4 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas5 = new byte[MAX_AXIS];
            [FieldOffset(4 * 5 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas6 = new byte[MAX_AXIS];
            [FieldOffset(4 * 6 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas7 = new byte[MAX_AXIS];
            [FieldOffset(4 * 7 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas8 = new byte[MAX_AXIS];
            [FieldOffset(4 * 8 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas9 = new byte[MAX_AXIS];
            [FieldOffset(4 * 9 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas10 = new byte[MAX_AXIS];
        }
 
        [StructLayout(LayoutKind.Explicit)]
        public class HSPDATA_2
        {
            [FieldOffset(0),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas1 = new short[MAX_AXIS];
            [FieldOffset(2 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas2 = new short[MAX_AXIS];
            [FieldOffset(2 * 2 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas3 = new short[MAX_AXIS];
            [FieldOffset(2 * 3 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas4 = new short[MAX_AXIS];
            [FieldOffset(2 * 4 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas5 = new short[MAX_AXIS];
            [FieldOffset(2 * 5 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas6 = new short[MAX_AXIS];
            [FieldOffset(2 * 6 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas7 = new short[MAX_AXIS];
            [FieldOffset(2 * 7 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas8 = new short[MAX_AXIS];
            [FieldOffset(2 * 8 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas9 = new short[MAX_AXIS];
            [FieldOffset(2 * 9 * MAX_AXIS),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas10 = new short[MAX_AXIS];
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class HSPDATA_3
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas1 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas2 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas3 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas4 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas5 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas6 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas7 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas8 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas9 = new int[MAX_AXIS];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas10 = new int[MAX_AXIS];
        }
 
        /*----------------------------------------*/
        /* CNC: Tool life management data related */
        /*----------------------------------------*/
 
        /* cnc_rdgrpid:read tool life management data(tool group number) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLIFE1
        {
            public short dummy; /* dummy */
            public short type;  /* data type */
            public int data;  /* data */
        }
 
        /* cnc_rdngrp:read tool life management data(number of tool groups) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLIFE2
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;  /* dummy */
            public int data;   /* data */
        }
 
        /* cnc_rdntool:read tool life management data(number of tools) */
        /* cnc_rdlife:read tool life management data(tool life) */
        /* cnc_rdcount:read tool life management data(tool lift counter) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLIFE3
        {
            public short datano;    /* data number */
            public short dummy;     /* dummy */
            public int data;      /* data */
        }
 
        /* cnc_rd1length:read tool life management data(tool length number-1) */
        /* cnc_rd2length:read tool life management data(tool length number-2) */
        /* cnc_rd1radius:read tool life management data(cutter compensation no.-1) */
        /* cnc_rd2radius:read tool life management data(cutter compensation no.-2) */
        /* cnc_t1info:read tool life management data(tool information-1) */
        /* cnc_t2info:read tool life management data(tool information-2) */
        /* cnc_toolnum:read tool life management data(tool number) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLIFE4
        {
            public short datano;    /* data number */
            public short type;      /* data type */
            public int data;      /* data */
        }
 
        /* cnc_rdgrpid2:read tool life management data(tool group number) 2 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLIFE5
        {
            public int dummy; /* dummy */
            public int type;  /* data type */
            public int data;  /* data */
        }
 
        /* cnc_rdtoolrng:read tool life management data(tool number, tool life, tool life counter)(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTR_data
        {
            public int ntool;     /* tool number */
            public int life;      /* tool life */
            public int count;     /* tool life counter */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTR1
        {
            public IODBTR_data data1 = new IODBTR_data();
            public IODBTR_data data2 = new IODBTR_data();
            public IODBTR_data data3 = new IODBTR_data();
            public IODBTR_data data4 = new IODBTR_data();
            public IODBTR_data data5 = new IODBTR_data();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTR
        {
            public short datano_s;  /* start group number */
            public short dummy;     /* dummy */
            public short datano_e;  /* end group number */
            public IODBTR1 data = new IODBTR1();
        }
 
        /* cnc_rdtoolgrp:read tool life management data(all data within group) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTG_data
        {
            public int tuse_num;      /* tool number */
            public int tool_num;      /* tool life */
            public int length_num;    /* tool life counter */
            public int radius_num;    /* tool life counter */
            public int tinfo;         /* tool life counter */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTG1
        {
            public ODBTG_data data1 = new ODBTG_data();
            public ODBTG_data data2 = new ODBTG_data();
            public ODBTG_data data3 = new ODBTG_data();
            public ODBTG_data data4 = new ODBTG_data();
            public ODBTG_data data5 = new ODBTG_data();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTG
        {
            public short grp_num;   /* start group number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy;  /* dummy */
            public int ntool;     /* tool number */
            public int life;      /* tool life */
            public int count;     /* tool life counter */
            public ODBTG1 data = new ODBTG1();
        }
 
        /* cnc_wrcountr:write tool life management data(tool life counter) (area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBWRC_data
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] dummy;     /* dummy */
            public int count;     /* tool life counter */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBWRC1
        {
            public IDBWRC_data data1 = new IDBWRC_data();
            public IDBWRC_data data2 = new IDBWRC_data();
            public IDBWRC_data data3 = new IDBWRC_data();
            public IDBWRC_data data4 = new IDBWRC_data();
            public IDBWRC_data data5 = new IDBWRC_data();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBWRC
        {
            public short datano_s;  /* start group number */
            public short dummy;     /* dummy */
            public short datano_e;  /* end group number */
            public IDBWRC1 data = new IDBWRC1();
        }
 
        /* cnc_rdusegrpid:read tool life management data(used tool group number) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBUSEGR
        {
            public short datano; /* dummy */
            public short type;   /* dummy */
            public int next;   /* next use group number */
            public int use;    /* using group number */
            public int slct;   /* selecting group number */
        }
 
        /* cnc_rdmaxgrp:read tool life management data(max. number of tool groups) */
        /* cnc_rdmaxtool:read tool life management data(maximum number of tool within group) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBLFNO
        {
            public short datano; /* dummy */
            public short type;   /* dummy */
            public short data;   /* number of data */
        }
 
        /* cnc_rdusetlno:read tool life management data(used tool no within group) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLUSE
        {
            public short s_grp;  /* start group number */
            public short dummy;  /* dummy */
            public short e_grp;  /* end group number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] data;   /* tool using number */
        } /* In case that the number of group is 5 */
 
        /* cnc_rd1tlifedata:read tool life management data(tool data1) */
        /* cnc_rd2tlifedata:read tool life management data(tool data2) */
        /* cnc_wr1tlifedata:write tool life management data(tool data1) */
        /* cnc_wr2tlifedata:write tool life management data(tool data2) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTD
        {
            public short datano;     /* tool group number */
            public short type;       /* tool using number */
            public int tool_num;   /* tool number */
            public int h_code;     /* H code */
            public int d_code;     /* D code */
            public int tool_inf;   /* tool information */
        }
 
        /* cnc_rd1tlifedat2:read tool life management data(tool data1) 2 */
        /* cnc_wr1tlifedat2:write tool life management data(tool data1) 2 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTD2
        {
            public short datano;     /* tool group number */
            public short dummy;      /* dummy */
            public int type;       /* tool using number */
            public int tool_num;   /* tool number */
            public int h_code;     /* H code */
            public int d_code;     /* D code */
            public int tool_inf;   /* tool information */
        }
 
        /* cnc_rdgrpinfo:read tool life management data(tool group information) */
        /* cnc_wrgrpinfo:write tool life management data(tool group information) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI_data
        {
            public int n_tool;         /* number of tool */
            public int count_value;    /* tool life */
            public int counter;        /* tool life counter */
            public int count_type;     /* tool life counter type */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI1
        {
            public IODBTGI_data data1 = new IODBTGI_data();
            public IODBTGI_data data2 = new IODBTGI_data();
            public IODBTGI_data data3 = new IODBTGI_data();
            public IODBTGI_data data4 = new IODBTGI_data();
            public IODBTGI_data data5 = new IODBTGI_data();
        } /* In case that the number of data is 5 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI
        {
            public short s_grp;  /* start group number */
            public short dummy;  /* dummy */
            public short e_grp;  /* end group number */
            public IODBTGI1 data = new IODBTGI1();
        }
 
        /* cnc_rdgrpinfo2:read tool life management data(tool group information 2) */
        /* cnc_wrgrpinfo2:write tool life management data(tool group information 2) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI2
        {
            public short s_grp;      /* start group number */
            public short dummy;      /* dummy */
            public short e_grp;      /* end group number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] opt_grpno = new int[5];  /* optional group number of tool */
        } /* In case that the number of group is 5 */
 
        /* cnc_rdgrpinfo3:read tool life management data(tool group information 3) */
        /* cnc_wrgrpinfo3:write tool life management data(tool group information 3) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI3
        {
            public short s_grp;      /* start group number */
            public short dummy;      /* dummy */
            public short e_grp;      /* end group number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] life_rest = new int[5];  /* tool life rest count */
        } /* In case that the number of group is 5 */
 
        /* cnc_rdgrpinfo4:read tool life management data(tool group information 4) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTGI4
        {
            public short grp_no;
            public int n_tool;
            public int count_value;
            public int counter;
            public int count_type;
            public int opt_grpno;
            public int life_rest;
        }
 
        /* cnc_instlifedt:insert tool life management data(tool data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBITD
        {
            public short datano; /* tool group number */
            public short type;   /* tool using number */
            public int data;   /* tool number */
        }
 
        /* cnc_rdtlinfo:read tool life management data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBTLINFO
        {
            public int max_group;  /* maximum number of tool groups */
            public int max_tool;   /* maximum number of tool within group */
            public int max_minute; /* maximum number of life count (minutes) */
            public int max_cycle;  /* maximum number of life count (cycles) */
        }
 
        /* cnc_rdtlusegrp:read tool life management data(used tool group number) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBUSEGRP
        {
            public int next;       /* next use group number */
            public int use;        /* using group number */
            public int slct;       /* selecting group number */
            public int opt_next;   /* next use optional group number */
            public int opt_use;    /* using optional group number */
            public int opt_slct;   /* selecting optional group number */
        }
 
        /* cnc_rdtlgrp:read tool life management data(tool group information 2) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLGRP_data
        {
            public int ntool;      /* number of all tool */
            public int nfree;      /* number of free tool */
            public int life;       /* tool life */
            public int count;      /* tool life counter */
            public int use_tool;   /* using tool number */
            public int opt_grpno;  /* optional group number */
            public int life_rest;  /* tool life rest count */
            public short rest_sig;   /* tool life rest signal */
            public short count_type; /* tool life counter type */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLGRP
        {
            public IODBTLGRP_data data1 = new IODBTLGRP_data();
            public IODBTLGRP_data data2 = new IODBTLGRP_data();
            public IODBTLGRP_data data3 = new IODBTLGRP_data();
            public IODBTLGRP_data data4 = new IODBTLGRP_data();
            public IODBTLGRP_data data5 = new IODBTLGRP_data();
        } /* In case that the number of group is 5 */
 
        /* cnc_rdtltool:read tool life management data (tool data1) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLTOOL_data
        {
            public int tool_num;   /* tool number */
            public int h_code;     /* H code */
            public int d_code;     /* D code */
            public int tool_inf;   /* tool information */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLTOOL
        {
            public IODBTLTOOL_data data1 = new IODBTLTOOL_data();
            public IODBTLTOOL_data data2 = new IODBTLTOOL_data();
            public IODBTLTOOL_data data3 = new IODBTLTOOL_data();
            public IODBTLTOOL_data data4 = new IODBTLTOOL_data();
            public IODBTLTOOL_data data5 = new IODBTLTOOL_data();
        } /* In case that the number of group is 5 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXGP_data
        {
            public int grp_no;     /* group number */
            public int opt_grpno;  /* optional group number */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXGP
        {
            public ODBEXGP_data data1 = new ODBEXGP_data();
            public ODBEXGP_data data2 = new ODBEXGP_data();
            public ODBEXGP_data data3 = new ODBEXGP_data();
            public ODBEXGP_data data4 = new ODBEXGP_data();
            public ODBEXGP_data data5 = new ODBEXGP_data();
            public ODBEXGP_data data6 = new ODBEXGP_data();
            public ODBEXGP_data data7 = new ODBEXGP_data();
            public ODBEXGP_data data8 = new ODBEXGP_data();
            public ODBEXGP_data data9 = new ODBEXGP_data();
            public ODBEXGP_data data10 = new ODBEXGP_data();
            public ODBEXGP_data data11 = new ODBEXGP_data();
            public ODBEXGP_data data12 = new ODBEXGP_data();
            public ODBEXGP_data data13 = new ODBEXGP_data();
            public ODBEXGP_data data14 = new ODBEXGP_data();
            public ODBEXGP_data data15 = new ODBEXGP_data();
            public ODBEXGP_data data16 = new ODBEXGP_data();
            public ODBEXGP_data data17 = new ODBEXGP_data();
            public ODBEXGP_data data18 = new ODBEXGP_data();
            public ODBEXGP_data data19 = new ODBEXGP_data();
            public ODBEXGP_data data20 = new ODBEXGP_data();
            public ODBEXGP_data data21 = new ODBEXGP_data();
            public ODBEXGP_data data22 = new ODBEXGP_data();
            public ODBEXGP_data data23 = new ODBEXGP_data();
            public ODBEXGP_data data24 = new ODBEXGP_data();
            public ODBEXGP_data data25 = new ODBEXGP_data();
            public ODBEXGP_data data26 = new ODBEXGP_data();
            public ODBEXGP_data data27 = new ODBEXGP_data();
            public ODBEXGP_data data28 = new ODBEXGP_data();
            public ODBEXGP_data data29 = new ODBEXGP_data();
            public ODBEXGP_data data30 = new ODBEXGP_data();
            public ODBEXGP_data data31 = new ODBEXGP_data();
            public ODBEXGP_data data32 = new ODBEXGP_data();
        }
 
        /*-----------------------------------*/
        /* CNC: Tool management data related */
        /*-----------------------------------*/
 
        /* cnc_regtool:new registration of tool management data */
        /* cnc_rdtool:lead of tool management data */
        /* cnc_wrtool:write of tool management data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMNG_data
        {
            public int T_code;
            public int life_count;
            public int max_life;
            public int rest_life;
            public byte life_stat;
            public byte cust_bits;
            public ushort tool_info;
            public short H_code;
            public short D_code;
            public int spindle_speed;
            public int feedrate;
            public short magazine;
            public short pot;
            public short gno;
            public short m_ofs;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public int[] reserved = new int[4];
            public int custom1;
            public int custom2;
            public int custom3;
            public int custom4;
            public int custom5;
            public int custom6;
            public int custom7;
            public int custom8;
            public int custom9;
            public int custom10;
            public int custom11;
            public int custom12;
            public int custom13;
            public int custom14;
            public int custom15;
            public int custom16;
            public int custom17;
            public int custom18;
            public int custom19;
            public int custom20;
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMNG
        {
            public IODBTLMNG_data data1 = new IODBTLMNG_data();
            public IODBTLMNG_data data2 = new IODBTLMNG_data();
            public IODBTLMNG_data data3 = new IODBTLMNG_data();
            public IODBTLMNG_data data4 = new IODBTLMNG_data();
            public IODBTLMNG_data data5 = new IODBTLMNG_data();
        } /* In case that the number of group is 5 */
 
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMNG_F2_data
        {
            public int T_code;
            public int life_count;
            public int max_life;
            public int rest_life;
            public byte life_stat;
            public byte cust_bits;
            public ushort tool_info;
            public short H_code;
            public short D_code;
            public int spindle_speed;
            public int feedrate;
            public short magazine;
            public short pot;
            public short G_code;
            public short W_code;
            public short gno;
            public short m_ofs;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public int[] reserved;
            public int custom1;
            public int custom2;
            public int custom3;
            public int custom4;
            public int custom5;
            public int custom6;
            public int custom7;
            public int custom8;
            public int custom9;
            public int custom10;
            public int custom11;
            public int custom12;
            public int custom13;
            public int custom14;
            public int custom15;
            public int custom16;
            public int custom17;
            public int custom18;
            public int custom19;
            public int custom20;
            public int custom21;
            public int custom22;
            public int custom23;
            public int custom24;
            public int custom25;
            public int custom26;
            public int custom27;
            public int custom28;
            public int custom29;
            public int custom30;
            public int custom31;
            public int custom32;
            public int custom33;
            public int custom34;
            public int custom35;
            public int custom36;
            public int custom37;
            public int custom38;
            public int custom39;
            public int custom40;
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMNG_F2
        {
            public IODBTLMNG_F2_data data1 = new IODBTLMNG_F2_data();
            public IODBTLMNG_F2_data data2 = new IODBTLMNG_F2_data();
            public IODBTLMNG_F2_data data3 = new IODBTLMNG_F2_data();
            public IODBTLMNG_F2_data data4 = new IODBTLMNG_F2_data();
            public IODBTLMNG_F2_data data5 = new IODBTLMNG_F2_data();
        } /* In case that the number of group is 5 */
 
        /* cnc_wrtool2:write of individual data of tool management data */
        [StructLayout(LayoutKind.Explicit)]
        public class IDBTLM_item
        {
            [FieldOffset(0)]
            public sbyte data1;
            [FieldOffset(0)]
            public short data2;
            [FieldOffset(0)]
            public int data4;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBTLM
        {
            public short data_id;
            public IDBTLM_item item = new IDBTLM_item();
        }
 
        /* cnc_regmagazine:new registration of magazine management data */
        /* cnc_rdmagazine:lead of magazine management data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMAG_data
        {
            public short magazine;
            public short pot;
            public short tool_index;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMAG
        {
            public IODBTLMAG_data data1 = new IODBTLMAG_data();
            public IODBTLMAG_data data2 = new IODBTLMAG_data();
            public IODBTLMAG_data data3 = new IODBTLMAG_data();
            public IODBTLMAG_data data4 = new IODBTLMAG_data();
            public IODBTLMAG_data data5 = new IODBTLMAG_data();
        } /* In case that the number of group is 5 */
 
        /* cnc_delmagazine:deletion of magazine management data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMAG2_data
        {
            public short magazine;
            public short pot;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLMAG2
        {
            public IODBTLMAG2_data data1 = new IODBTLMAG2_data();
            public IODBTLMAG2_data data2 = new IODBTLMAG2_data();
            public IODBTLMAG2_data data3 = new IODBTLMAG2_data();
            public IODBTLMAG2_data data4 = new IODBTLMAG2_data();
            public IODBTLMAG2_data data5 = new IODBTLMAG2_data();
        } /* In case that the number of group is 5 */
 
 
        /*-------------------------------------*/
        /* CNC: Operation history data related */
        /*-------------------------------------*/
 
        /* cnc_rdophistry:read operation history data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_ALM
        {
            public short rec_type;   /* record type */
            public short alm_grp;    /* alarm group */
            public short alm_no;     /* alarm number */
            public sbyte axis_no;    /* axis number */
            public sbyte dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MDI
        {
            public short rec_type;   /* record type */
            public byte key_code;   /* key code */
            public byte pw_flag;    /* power on flag */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public sbyte[] dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_SGN
        {
            public short rec_type;   /* record type */
            public sbyte sig_name;   /* signal name */
            public byte sig_old;    /* old signal bit pattern */
            public byte sig_new;    /* new signal bit pattern */
            public sbyte dummy;
            public short sig_no;     /* signal number */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_DATE
        {
            public short rec_type;   /* record type */
            public sbyte year;       /* year */
            public sbyte month;      /* month */
            public sbyte day;        /* day */
            public sbyte pw_flag;    /* power on flag */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public sbyte[] dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_TIME
        {
            public short rec_type;   /* record flag */
            public sbyte hour;       /* hour */
            public sbyte minute;     /* minute */
            public sbyte second;     /* second */
            public sbyte pw_flag;    /* power on flag */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public sbyte[] dummy;
        }
        [StructLayout(LayoutKind.Explicit, Size = 8)]
        public class ODBHIS_data
        {
            // record type
            [FieldOffset(0)]
            public short rec_type;   /* record type */
 
            // alarm record
            [FieldOffset(0)]
            public short alm_rec_type;   /* record type */
            [FieldOffset(2)]
            public short alm_alm_grp;    /* alarm group */
            [FieldOffset(4)]
            public short alm_alm_no;     /* alarm number */
            [FieldOffset(6)]
            public sbyte alm_axis_no;    /* axis number */
            [FieldOffset(7)]
            public sbyte alm_dummy;
 
            // mdi record
            [FieldOffset(0)]
            public short mdi_rec_type;   /* record type */
            [FieldOffset(2)]
            public byte mdi_key_code;   /* key code */
            [FieldOffset(3)]
            public byte mdi_pw_flag;    /* power on flag */
            [FieldOffset(4)]
            public sbyte mdi_dummy1;
            [FieldOffset(5)]
            public sbyte mdi_dummy2;
            [FieldOffset(6)]
            public sbyte mdi_dummy3;
            [FieldOffset(7)]
            public sbyte mdi_dummy4;
 
            // sign record
            [FieldOffset(0)]
            public short sgn_rec_type;   /* record type */
            [FieldOffset(2)]
            public sbyte sgn_sig_name;   /* signal name */
            [FieldOffset(3)]
            public byte sgn_sig_old;    /* old signal bit pattern */
            [FieldOffset(4)]
            public byte sgn_sig_new;    /* new signal bit pattern */
            [FieldOffset(5)]
            public sbyte sgn_dummy;
            [FieldOffset(6)]
            public short sgn_sig_no;     /* signal number */
 
            // date record
            [FieldOffset(0)]
            public short date_rec_type;   /* record type */
            [FieldOffset(2)]
            public sbyte date_year;       /* year */
            [FieldOffset(3)]
            public sbyte date_month;      /* month */
            [FieldOffset(4)]
            public sbyte date_day;        /* day */
            [FieldOffset(5)]
            public sbyte date_pw_flag;    /* power on flag */
            [FieldOffset(6)]
            public sbyte date_dummy1;
            [FieldOffset(7)]
            public sbyte date_dummy2;
 
            // time record
            [FieldOffset(0)]
            public short time_rec_type;   /* record flag */
            [FieldOffset(2)]
            public sbyte time_hour;       /* hour */
            [FieldOffset(3)]
            public sbyte time_minute;     /* minute */
            [FieldOffset(4)]
            public sbyte time_second;     /* second */
            [FieldOffset(5)]
            public sbyte time_pw_flag;    /* power on flag */
            [FieldOffset(6)]
            public sbyte time_dummy1;
            [FieldOffset(7)]
            public sbyte time_dummy2;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHIS1
        {
            public ODBHIS_data data1 = new ODBHIS_data();
            public ODBHIS_data data2 = new ODBHIS_data();
            public ODBHIS_data data3 = new ODBHIS_data();
            public ODBHIS_data data4 = new ODBHIS_data();
            public ODBHIS_data data5 = new ODBHIS_data();
            public ODBHIS_data data6 = new ODBHIS_data();
            public ODBHIS_data data7 = new ODBHIS_data();
            public ODBHIS_data data8 = new ODBHIS_data();
            public ODBHIS_data data9 = new ODBHIS_data();
            public ODBHIS_data data10 = new ODBHIS_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHIS
        {
            public ushort s_no;   /* start number */
            public short type;   /* dummy */
            public ushort e_no;   /* end number */
            public ODBHIS1 data = new ODBHIS1();
        }
 
        /* cnc_rdophistry2:read operation history data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MDI2
        {
            public byte key_code;   /* key code */
            public byte pw_flag;    /* power on flag */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MDI2_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_MDI2 data = new REC_MDI2();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_SGN2
        {
            public short sig_name;   /* signal name */
            public short sig_no;     /* signal number */
            public byte sig_old;    /* old signal bit pattern */
            public byte sig_new;    /* new signal bit pattern */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_SGN2_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_SGN2 data = new REC_SGN2();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_ALM2
        {
            public short alm_grp;    /* alarm group */
            public short alm_no;     /* alarm number */
            public short axis_no;    /* axis number */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_ALM2_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_ALM2 data = new REC_ALM2();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_DATE2
        {
            public short evnt_type;  /* event type */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_DATE2_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_DATE2 data = new REC_DATE2();
        }
        [StructLayout(LayoutKind.Explicit)]
        public class ODBOPHIS
        {
            [FieldOffset(0)]
            public REC_MDI2_data rec_mdi = new REC_MDI2_data();
            [FieldOffset(0)]
            public REC_SGN2_data rec_sgn = new REC_SGN2_data();
            [FieldOffset(0)]
            public REC_ALM2_data rec_alm = new REC_ALM2_data();
            [FieldOffset(0)]
            public REC_DATE2_data rec_date = new REC_DATE2_data();
        }
 
        /* cnc_rdophistry4:read operation history data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MDI4
        {
            public char key_code;   /* key code */
            public char pw_flag;    /* power on flag */
            public short pth_no;     /* path index */
            public short ex_flag;    /* kxternal key flag */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MDI4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_MDI4 data = new REC_MDI4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_SGN4
        {
            public short sig_name;   /* signal name */
            public short sig_no;     /* signal number */
            public char sig_old;    /* old signal bit pattern */
            public char sig_new;    /* new signal bit pattern */
            public short pmc_no;     /* pmc index */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_SGN4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_SGN4 data = new REC_SGN4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_ALM4
        {
            public short alm_grp;    /* alarm group */
            public short alm_no;     /* alarm number */
            public short axis_no;    /* axis number */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_ALM4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_ALM4 data = new REC_ALM4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_DATE4
        {
            public short evnt_type;  /* event type */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_DATE4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_DATE4 data = new REC_DATE4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_IAL4
        {
            public short alm_grp;    /* alarm group */
            public short alm_no;     /* alarm number */
            public short axis_no;    /* axis number */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
            public short sys_alm;    /* sys alarm */
            public short dsp_flg;    /* message dsp flag */
            public short axis_num;   /* axis num */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] g_modal;    /* G code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public char[] g_dp;       /* #7:1 Block */
            /* #6乣#0 dp*/
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] a_modal;    /* B,D,E,F,H,M,N,O,S,T code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public char[] a_dp;       /* #7:1 Block */
            /* 6乣#0 dp*/
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] abs_pos;    /* Abs pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public char[] abs_dp;     /* Abs dp  */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] mcn_pos;    /* Mcn pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public char[] mcn_dp;     /* Mcn dp  */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_IAL4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_IAL4 data = new REC_IAL4();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class REC_MAL4
        {
            public short alm_grp;    /* alarm group */
            public short alm_no;     /* alarm number */
            public short axis_no;    /* axis number */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
            public short sys_alm;    /* sys alarm */
            public short dsp_flg;    /* message dsp flag */
            public short axis_num;   /* axis num */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string alm_msg = new string(' ', 64);  /* alarm message */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] g_modal;    /* G code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public char[] g_dp;       /* #7:1 Block */
            /* #6乣#0 dp*/
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] a_modal;    /* B,D,E,F,H,M,N,O,S,T code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public char[] a_dp;       /* #7:1 Block */
            /* 6乣#0 dp*/
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] abs_pos;    /* Abs pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public char[] abs_dp;     /* Abs dp  */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] mcn_pos;    /* Mcn pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public char[] mcn_dp;     /* Mcn dp  */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MAL4_data
        {
            public short rec_len;     /* length */
            public short rec_type;    /* record type */
            public REC_MAL4 data = new REC_MAL4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_OPM4
        {
            public short dsp_flg;     /* Dysplay flag(ON/OFF) */
            public short om_no;       /* message number */
            public short year;        /* year */
            public short month;       /* month */
            public short day;         /* day */
            public short hour;        /* Hour */
            public short minute;      /* Minute */
            public short second;      /* Second */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 256)]
            public string ope_msg = new string(' ', 256);  /* Messege */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_OPM4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_OPM4 data = new REC_OPM4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_OFS4
        {
            public short ofs_grp;    /* Tool offset group */
            public short ofs_no;     /* Tool offset number */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
            public int ofs_old;    /* old data */
            public int ofs_new;    /* new data */
            public short old_dp;     /* old data decimal point */
            public short new_dp;     /* new data decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_OFS4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_OFS4 data = new REC_OFS4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_PRM4
        {
            public short prm_grp;    /* paramater group */
            public short prm_num;    /* paramater number */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short prm_len;    /* paramater data length */
            public int prm_no;     /* paramater no */
            public int prm_old;    /* old data */
            public int prm_new;    /* new data */
            public short old_dp;     /* old data decimal point */
            public short new_dp;     /* new data decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_PRM4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_PRM4 data = new REC_PRM4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_WOF4
        {
            public short ofs_grp;    /* Work offset group */
            public short ofs_no;     /* Work offset number */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
            public short axis_no;    /* path axis num $*/
            public short dummy;
            public int ofs_old;    /* old data */
            public int ofs_new;    /* new data */
            public short old_dp;     /* old data decimal point */
            public short new_dp;     /* new data decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_WOF4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_WOF4 data = new REC_WOF4();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MAC4
        {
            public short mac_no;     /* macro val number */
            public short hour;       /* hour */
            public short minute;     /* minute */
            public short second;     /* second */
            public short pth_no;     /* path index */
            public int mac_old;    /* old data */
            public int mac_new;    /* new data */
            public short old_dp;     /* old data decimal point */
            public short new_dp;     /* old data decimal point */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REC_MAC4_data
        {
            public short rec_len;    /* length */
            public short rec_type;   /* record type */
            public REC_MAC4 data = new REC_MAC4();
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_1
        {
            public REC_MDI4_data rec_mdi1 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi2 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi3 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi4 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi5 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi6 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi7 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi8 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi9 = new REC_MDI4_data();
            public REC_MDI4_data rec_mdi10 = new REC_MDI4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_2
        {
            public REC_SGN4_data rec_sgn1 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn2 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn3 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn4 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn5 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn6 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn7 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn8 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn9 = new REC_SGN4_data();
            public REC_SGN4_data rec_sgn10 = new REC_SGN4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_3
        {
            public REC_ALM4_data rec_alm1 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm2 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm3 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm4 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm5 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm6 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm7 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm8 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm9 = new REC_ALM4_data();
            public REC_ALM4_data rec_alm10 = new REC_ALM4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_4
        {
            public REC_DATE4_data rec_date1 = new REC_DATE4_data();
            public REC_DATE4_data rec_date2 = new REC_DATE4_data();
            public REC_DATE4_data rec_date3 = new REC_DATE4_data();
            public REC_DATE4_data rec_date4 = new REC_DATE4_data();
            public REC_DATE4_data rec_date5 = new REC_DATE4_data();
            public REC_DATE4_data rec_date6 = new REC_DATE4_data();
            public REC_DATE4_data rec_date7 = new REC_DATE4_data();
            public REC_DATE4_data rec_date8 = new REC_DATE4_data();
            public REC_DATE4_data rec_date9 = new REC_DATE4_data();
            public REC_DATE4_data rec_date10 = new REC_DATE4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_5
        {
            public REC_IAL4_data rec_ial1 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial2 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial3 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial4 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial5 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial6 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial7 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial8 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial9 = new REC_IAL4_data();
            public REC_IAL4_data rec_ial10 = new REC_IAL4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_6
        {
            public REC_MAL4_data rec_mal1 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal2 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal3 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal4 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal5 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal6 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal7 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal8 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal9 = new REC_MAL4_data();
            public REC_MAL4_data rec_mal10 = new REC_MAL4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_7
        {
            public REC_OPM4_data rec_opm1 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm2 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm3 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm4 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm5 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm6 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm7 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm8 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm9 = new REC_OPM4_data();
            public REC_OPM4_data rec_opm10 = new REC_OPM4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_8
        {
            public REC_OFS4_data rec_ofs1 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs2 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs3 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs4 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs5 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs6 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs7 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs8 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs9 = new REC_OFS4_data();
            public REC_OFS4_data rec_ofs10 = new REC_OFS4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_9
        {
            public REC_PRM4_data rec_prm1 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm2 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm3 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm4 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm5 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm6 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm7 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm8 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm9 = new REC_PRM4_data();
            public REC_PRM4_data rec_prm10 = new REC_PRM4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_10
        {
            public REC_WOF4_data rec_wof1 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof2 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof3 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof4 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof5 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof6 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof7 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof8 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof9 = new REC_WOF4_data();
            public REC_WOF4_data rec_wof10 = new REC_WOF4_data();
        } /* In case that the number of data is 10 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOPHIS4_11
        {
            public REC_MAC4_data rec_mac1 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac2 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac3 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac4 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac5 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac6 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac7 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac8 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac9 = new REC_MAC4_data();
            public REC_MAC4_data rec_mac10 = new REC_MAC4_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdalmhistry:read alarm history data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ALM_HIS_data
        {
            public short dummy;
            public short alm_grp;        /* alarm group */
            public short alm_no;         /* alarm number */
            public byte axis_no;        /* axis number */
            public byte year;           /* year */
            public byte month;          /* month */
            public byte day;            /* day */
            public byte hour;           /* hour */
            public byte minute;         /* minute */
            public byte second;         /* second */
            public byte dummy2;
            public short len_msg;        /* alarm message length */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string alm_msg = new string(' ', 32);  /* alarm message */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALM_HIS1
        {
            public ALM_HIS_data data1 = new ALM_HIS_data();
            public ALM_HIS_data data2 = new ALM_HIS_data();
            public ALM_HIS_data data3 = new ALM_HIS_data();
            public ALM_HIS_data data4 = new ALM_HIS_data();
            public ALM_HIS_data data5 = new ALM_HIS_data();
            public ALM_HIS_data data6 = new ALM_HIS_data();
            public ALM_HIS_data data7 = new ALM_HIS_data();
            public ALM_HIS_data data8 = new ALM_HIS_data();
            public ALM_HIS_data data9 = new ALM_HIS_data();
            public ALM_HIS_data data10 = new ALM_HIS_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAHIS
        {
            public ushort s_no;   /* start number */
            public short type;   /* dummy */
            public ushort e_no;   /* end number */
            public ALM_HIS1 alm_his = new ALM_HIS1();
        }
 
        /* cnc_rdalmhistry2:read alarm history data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ALM_HIS2_data
        {
            public short alm_grp;        /* alarm group */
            public short alm_no;         /* alarm number */
            public short axis_no;        /* axis number */
            public short year;           /* year */
            public short month;          /* month */
            public short day;            /* day */
            public short hour;           /* hour */
            public short minute;         /* minute */
            public short second;         /* second */
            public short len_msg;        /* alarm message length */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string alm_msg = new string(' ', 32);  /* alarm message */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALM_HIS2
        {
            public ALM_HIS2_data data1 = new ALM_HIS2_data();
            public ALM_HIS2_data data2 = new ALM_HIS2_data();
            public ALM_HIS2_data data3 = new ALM_HIS2_data();
            public ALM_HIS2_data data4 = new ALM_HIS2_data();
            public ALM_HIS2_data data5 = new ALM_HIS2_data();
            public ALM_HIS2_data data6 = new ALM_HIS2_data();
            public ALM_HIS2_data data7 = new ALM_HIS2_data();
            public ALM_HIS2_data data8 = new ALM_HIS2_data();
            public ALM_HIS2_data data9 = new ALM_HIS2_data();
            public ALM_HIS2_data data10 = new ALM_HIS2_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAHIS2
        {
            public ushort s_no;   /* start number */
            public ushort e_no;   /* end number */
            public ALM_HIS2 alm_his = new ALM_HIS2();
        }
 
        /* cnc_rdalmhistry3:read alarm history data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ALM_HIS3_data
        {
            public short alm_grp;        /* alarm group */
            public short alm_no;         /* alarm number */
            public short axis_no;        /* axis number */
            public short year;           /* year */
            public short month;          /* month */
            public short day;            /* day */
            public short hour;           /* hour */
            public short minute;         /* minute */
            public short second;         /* second */
            public short len_msg;        /* alarm message length */
            public short pth_no;         /* path index */
            public short dummy;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string alm_msg = new string(' ', 32);  /* alarm message */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALM_HIS3
        {
            public ALM_HIS3_data data1 = new ALM_HIS3_data();
            public ALM_HIS3_data data2 = new ALM_HIS3_data();
            public ALM_HIS3_data data3 = new ALM_HIS3_data();
            public ALM_HIS3_data data4 = new ALM_HIS3_data();
            public ALM_HIS3_data data5 = new ALM_HIS3_data();
            public ALM_HIS3_data data6 = new ALM_HIS3_data();
            public ALM_HIS3_data data7 = new ALM_HIS3_data();
            public ALM_HIS3_data data8 = new ALM_HIS3_data();
            public ALM_HIS3_data data9 = new ALM_HIS3_data();
            public ALM_HIS3_data data10 = new ALM_HIS3_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAHIS3
        {
            public ushort s_no;   /* start number */
            public ushort e_no;   /* end number */
            public ALM_HIS3 alm_his = new ALM_HIS3();
        }
 
        /* cnc_rdalmhistry5:read alarm history data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ALM_HIS5_data
        {
            public short alm_grp;        /* alarm group */
            public short alm_no;         /* alarm number */
            public short axis_no;        /* axis number */
            public short year;           /* year */
            public short month;          /* month */
            public short day;            /* day */
            public short hour;           /* hour */
            public short minute;         /* minute */
            public short second;         /* second */
            public short len_msg;        /* alarm message length */
            public short pth_no;         /* path index */
            public short dummy;          /* dummy */
            public short dsp_flg;        /* Flag for displaying  */
            public short axis_num;       /* Total axis number */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string alm_msg = new string(' ', 64);  /* alarm message */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] g_modal;        /* G code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public byte[] g_dp;           /* #7:1 Block  #6乣#0 dp */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public int[] a_modal;        /* B,D,E,F,H,M,N,O,S,T code Modal */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public byte[] a_dp;           /* #7:1 Block  #6乣#0 dp */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] abs_pos;        /* Abs pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public byte[] abs_dp;         /* Abs dp */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public int[] mcn_pos;        /* Mcn pos */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public byte[] mcn_dp;         /* Mcn dp */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALM_HIS5
        {
            public ALM_HIS5_data data1 = new ALM_HIS5_data();
            public ALM_HIS5_data data2 = new ALM_HIS5_data();
            public ALM_HIS5_data data3 = new ALM_HIS5_data();
            public ALM_HIS5_data data4 = new ALM_HIS5_data();
            public ALM_HIS5_data data5 = new ALM_HIS5_data();
            public ALM_HIS5_data data6 = new ALM_HIS5_data();
            public ALM_HIS5_data data7 = new ALM_HIS5_data();
            public ALM_HIS5_data data8 = new ALM_HIS5_data();
            public ALM_HIS5_data data9 = new ALM_HIS5_data();
            public ALM_HIS5_data data10 = new ALM_HIS5_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAHIS5
        {
            public ushort s_no;   /* start number */
            public ushort e_no;   /* end number */
            public ALM_HIS5 alm_his = new ALM_HIS5();
        }
 
        /* cnc_rdomhistry2:read operater message history data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBOMHIS2_data
        {
            public short dsp_flg;     /* Dysplay flag(ON/OFF) */
            public short om_no;       /* operater message number */
            public short year;        /* year */
            public short month;       /* month */
            public short day;         /* day */
            public short hour;        /* Hour */
            public short minute;      /* Minute */
            public short second;      /* Second */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 256)]
            public string alm_msg = new string(' ', 256);  /* alarm message */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OPM_HIS
        {
            public ODBOMHIS2_data data1 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data2 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data3 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data4 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data5 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data6 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data7 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data8 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data9 = new ODBOMHIS2_data();
            public ODBOMHIS2_data data10 = new ODBOMHIS2_data();
        /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOMHIS2
        {
            public ushort s_no;   /* start number */
            public ushort e_no;   /* end number */
            public OPM_HIS opm_his = new OPM_HIS();
        }
 
        /* cnc_rdhissgnl:read signals related operation history */
        /* cnc_wrhissgnl:write signals related operation history */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBSIG_data
        {
            public short ent_no;     /* entry number */
            public short sig_no;     /* signal number */
            public byte sig_name;   /* signal name */
            public byte mask_pat;   /* signal mask pattern */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG1
        {
            public IODBSIG_data data1 = new IODBSIG_data();
            public IODBSIG_data data2 = new IODBSIG_data();
            public IODBSIG_data data3 = new IODBSIG_data();
            public IODBSIG_data data4 = new IODBSIG_data();
            public IODBSIG_data data5 = new IODBSIG_data();
            public IODBSIG_data data6 = new IODBSIG_data();
            public IODBSIG_data data7 = new IODBSIG_data();
            public IODBSIG_data data8 = new IODBSIG_data();
            public IODBSIG_data data9 = new IODBSIG_data();
            public IODBSIG_data data10 = new IODBSIG_data();
            public IODBSIG_data data11 = new IODBSIG_data();
            public IODBSIG_data data12 = new IODBSIG_data();
            public IODBSIG_data data13 = new IODBSIG_data();
            public IODBSIG_data data14 = new IODBSIG_data();
            public IODBSIG_data data15 = new IODBSIG_data();
            public IODBSIG_data data16 = new IODBSIG_data();
            public IODBSIG_data data17 = new IODBSIG_data();
            public IODBSIG_data data18 = new IODBSIG_data();
            public IODBSIG_data data19 = new IODBSIG_data();
            public IODBSIG_data data20 = new IODBSIG_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG
        {
            public short datano; /* dummy */
            public short type;   /* dummy */
            public IODBSIG1 data = new IODBSIG1();
        }
 
        /* cnc_rdhissgnl2:read signals related operation history 2 */
        /* cnc_wrhissgnl2:write signals related operation history 2 */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class _IODBSIG2_data
        {
            public short ent_no;     /* entry number */
            public short sig_no;     /* signal number */
            public byte sig_name;   /* signal name */
            public byte mask_pat;   /* signal mask pattern */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG2_data
        {
            public _IODBSIG2_data data1 = new _IODBSIG2_data();
            public _IODBSIG2_data data2 = new _IODBSIG2_data();
            public _IODBSIG2_data data3 = new _IODBSIG2_data();
            public _IODBSIG2_data data4 = new _IODBSIG2_data();
            public _IODBSIG2_data data5 = new _IODBSIG2_data();
            public _IODBSIG2_data data6 = new _IODBSIG2_data();
            public _IODBSIG2_data data7 = new _IODBSIG2_data();
            public _IODBSIG2_data data8 = new _IODBSIG2_data();
            public _IODBSIG2_data data9 = new _IODBSIG2_data();
            public _IODBSIG2_data data10 = new _IODBSIG2_data();
            public _IODBSIG2_data data11 = new _IODBSIG2_data();
            public _IODBSIG2_data data12 = new _IODBSIG2_data();
            public _IODBSIG2_data data13 = new _IODBSIG2_data();
            public _IODBSIG2_data data14 = new _IODBSIG2_data();
            public _IODBSIG2_data data15 = new _IODBSIG2_data();
            public _IODBSIG2_data data16 = new _IODBSIG2_data();
            public _IODBSIG2_data data17 = new _IODBSIG2_data();
            public _IODBSIG2_data data18 = new _IODBSIG2_data();
            public _IODBSIG2_data data19 = new _IODBSIG2_data();
            public _IODBSIG2_data data20 = new _IODBSIG2_data();
            public _IODBSIG2_data data31 = new _IODBSIG2_data();
            public _IODBSIG2_data data32 = new _IODBSIG2_data();
            public _IODBSIG2_data data33 = new _IODBSIG2_data();
            public _IODBSIG2_data data34 = new _IODBSIG2_data();
            public _IODBSIG2_data data35 = new _IODBSIG2_data();
            public _IODBSIG2_data data36 = new _IODBSIG2_data();
            public _IODBSIG2_data data37 = new _IODBSIG2_data();
            public _IODBSIG2_data data38 = new _IODBSIG2_data();
            public _IODBSIG2_data data39 = new _IODBSIG2_data();
            public _IODBSIG2_data data40 = new _IODBSIG2_data();
            public _IODBSIG2_data data41 = new _IODBSIG2_data();
            public _IODBSIG2_data data42 = new _IODBSIG2_data();
            public _IODBSIG2_data data43 = new _IODBSIG2_data();
            public _IODBSIG2_data data44 = new _IODBSIG2_data();
            public _IODBSIG2_data data45 = new _IODBSIG2_data();
 
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG2
        {
            public short datano; /* dummy */
            public short type;   /* dummy */
            public IODBSIG2_data data = new IODBSIG2_data();
        }
 
        /* cnc_rdhissgnl3:read signals related operation history */
        /* cnc_wrhissgnl3:write signals related operation history */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class _IODBSIG3_data
        {
            public short ent_no;     /* entry number */
            public short pmc_no;     /* pmc number */
            public short sig_no;     /* signal number */
            public byte sig_name;   /* signal name */
            public byte mask_pat;   /* signal mask pattern */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG3_data
        {
            public _IODBSIG3_data data1 = new _IODBSIG3_data();
            public _IODBSIG3_data data2 = new _IODBSIG3_data();
            public _IODBSIG3_data data3 = new _IODBSIG3_data();
            public _IODBSIG3_data data4 = new _IODBSIG3_data();
            public _IODBSIG3_data data5 = new _IODBSIG3_data();
            public _IODBSIG3_data data6 = new _IODBSIG3_data();
            public _IODBSIG3_data data7 = new _IODBSIG3_data();
            public _IODBSIG3_data data8 = new _IODBSIG3_data();
            public _IODBSIG3_data data9 = new _IODBSIG3_data();
            public _IODBSIG3_data data10 = new _IODBSIG3_data();
            public _IODBSIG3_data data11 = new _IODBSIG3_data();
            public _IODBSIG3_data data12 = new _IODBSIG3_data();
            public _IODBSIG3_data data13 = new _IODBSIG3_data();
            public _IODBSIG3_data data14 = new _IODBSIG3_data();
            public _IODBSIG3_data data15 = new _IODBSIG3_data();
            public _IODBSIG3_data data16 = new _IODBSIG3_data();
            public _IODBSIG3_data data17 = new _IODBSIG3_data();
            public _IODBSIG3_data data18 = new _IODBSIG3_data();
            public _IODBSIG3_data data19 = new _IODBSIG3_data();
            public _IODBSIG3_data data20 = new _IODBSIG3_data();
            public _IODBSIG3_data data21 = new _IODBSIG3_data();
            public _IODBSIG3_data data22 = new _IODBSIG3_data();
            public _IODBSIG3_data data23 = new _IODBSIG3_data();
            public _IODBSIG3_data data24 = new _IODBSIG3_data();
            public _IODBSIG3_data data25 = new _IODBSIG3_data();
            public _IODBSIG3_data data26 = new _IODBSIG3_data();
            public _IODBSIG3_data data27 = new _IODBSIG3_data();
            public _IODBSIG3_data data28 = new _IODBSIG3_data();
            public _IODBSIG3_data data29 = new _IODBSIG3_data();
            public _IODBSIG3_data data30 = new _IODBSIG3_data();
            public _IODBSIG3_data data31 = new _IODBSIG3_data();
            public _IODBSIG3_data data32 = new _IODBSIG3_data();
            public _IODBSIG3_data data33 = new _IODBSIG3_data();
            public _IODBSIG3_data data34 = new _IODBSIG3_data();
            public _IODBSIG3_data data35 = new _IODBSIG3_data();
            public _IODBSIG3_data data36 = new _IODBSIG3_data();
            public _IODBSIG3_data data37 = new _IODBSIG3_data();
            public _IODBSIG3_data data38 = new _IODBSIG3_data();
            public _IODBSIG3_data data39 = new _IODBSIG3_data();
            public _IODBSIG3_data data40 = new _IODBSIG3_data();
            public _IODBSIG3_data data41 = new _IODBSIG3_data();
            public _IODBSIG3_data data42 = new _IODBSIG3_data();
            public _IODBSIG3_data data43 = new _IODBSIG3_data();
            public _IODBSIG3_data data44 = new _IODBSIG3_data();
            public _IODBSIG3_data data45 = new _IODBSIG3_data();
            public _IODBSIG3_data data46 = new _IODBSIG3_data();
            public _IODBSIG3_data data47 = new _IODBSIG3_data();
            public _IODBSIG3_data data48 = new _IODBSIG3_data();
            public _IODBSIG3_data data49 = new _IODBSIG3_data();
            public _IODBSIG3_data data50 = new _IODBSIG3_data();
            public _IODBSIG3_data data51 = new _IODBSIG3_data();
            public _IODBSIG3_data data52 = new _IODBSIG3_data();
            public _IODBSIG3_data data53 = new _IODBSIG3_data();
            public _IODBSIG3_data data54 = new _IODBSIG3_data();
            public _IODBSIG3_data data55 = new _IODBSIG3_data();
            public _IODBSIG3_data data56 = new _IODBSIG3_data();
            public _IODBSIG3_data data57 = new _IODBSIG3_data();
            public _IODBSIG3_data data58 = new _IODBSIG3_data();
            public _IODBSIG3_data data59 = new _IODBSIG3_data();
            public _IODBSIG3_data data60 = new _IODBSIG3_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIG3
        {
            public short datano; /* dummy */
            public short type;   /* dummy */
            public IODBSIG3_data data = new IODBSIG3_data();
        }
 
        /*-------------*/
        /* CNC: Others */
        /*-------------*/
 
        /* cnc_sysinfo:read CNC system information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYS
        {
            public short addinfo;
            public short max_axis;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public char[] cnc_type;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public char[] mt_type;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public char[] series;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public char[] version;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public char[] axes;
        }
 
#if FS15D
    /* cnc_statinfo:read CNC status information */
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBST
    {
        [MarshalAs(UnmanagedType.ByValArray,SizeConst=2)]
        public short[] dummy;      /* dummy                    */
        public short   aut;        /* selected automatic mode  */
        public short   manual;     /* selected manual mode     */
        public short   run;        /* running status           */
        public short   edit;       /* editting status          */
        public short   motion;     /* axis, dwell status       */
        public short   mstb;       /* m, s, t, b status        */
        public short   emergency;  /* emergency stop status    */
        public short   write;      /* writting status          */
        public short   labelskip;  /* label skip status        */
        public short   alarm;      /* alarm status             */
        public short   warning;    /* warning status           */
        public short   battery;    /* battery status           */
    }
#else
        /* cnc_statinfo:read CNC status information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBST
        {
            public short dummy;     /* dummy */
            public short tmmode;    /* T/M mode */
            public short aut;       /* selected automatic mode */
            public short run;       /* running status */
            public short motion;    /* axis, dwell status */
            public short mstb;      /* m, s, t, b status */
            public short emergency; /* emergency stop status */
            public short alarm;     /* alarm status */
            public short edit;      /* editting status */
        }
#endif
 
        /* cnc_alarm:read alarm status */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBALM
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] dummy = { 0, 0 };
            public ushort data = 0;
        }
 
        /* cnc_rdalminfo:read alarm information */
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ALMINFO1_data
    {
        public int     axis;
        public short   alm_no;
    }
     
    [StructLayout(LayoutKind.Sequential,CharSet=CharSet.Ansi,Pack=4)]
    public class ALMINFO2_data
    {
        public int     axis=0 ;
        public short   alm_no=0 ;
        public short   msg_len=0 ;
        [MarshalAs(UnmanagedType.ByValTStr,SizeConst=32)]
        public string  alm_msg= new string(' ',32) ;
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALMINFO1_data
        {
            public short axis;
            public short alm_no;
        }
 
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ALMINFO2_data
        {
            public short axis = 0;
            public short alm_no = 0;
            public short msg_len = 0;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string alm_msg = new string(' ', 32);
        }
#endif
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALMINFO_1
        {
            public ALMINFO1_data msg1 = new ALMINFO1_data();
            public ALMINFO1_data msg2 = new ALMINFO1_data();
            public ALMINFO1_data msg3 = new ALMINFO1_data();
            public ALMINFO1_data msg4 = new ALMINFO1_data();
            public ALMINFO1_data msg5 = new ALMINFO1_data();
            public short data_end;
        } /* In case that the number of alarm is 5 */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ALMINFO_2
        {
            public ALMINFO2_data msg1 = new ALMINFO2_data();
            public ALMINFO2_data msg2 = new ALMINFO2_data();
            public ALMINFO2_data msg3 = new ALMINFO2_data();
            public ALMINFO2_data msg4 = new ALMINFO2_data();
            public ALMINFO2_data msg5 = new ALMINFO2_data();
            public short dataend = 0;
        } /* In case that the number of alarm is 5 */
 
        /* cnc_rdalmmsg:read alarm messages */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBALMMSG_data
        {
            public int alm_no;
            public short type;
            public short axis;
            public short dummy;
            public short msg_len;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string alm_msg = new string(' ', 32);
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBALMMSG
        {
            public ODBALMMSG_data msg1 = new ODBALMMSG_data();
            public ODBALMMSG_data msg2 = new ODBALMMSG_data();
            public ODBALMMSG_data msg3 = new ODBALMMSG_data();
            public ODBALMMSG_data msg4 = new ODBALMMSG_data();
            public ODBALMMSG_data msg5 = new ODBALMMSG_data();
            public ODBALMMSG_data msg6 = new ODBALMMSG_data();
            public ODBALMMSG_data msg7 = new ODBALMMSG_data();
            public ODBALMMSG_data msg8 = new ODBALMMSG_data();
            public ODBALMMSG_data msg9 = new ODBALMMSG_data();
            public ODBALMMSG_data msg10 = new ODBALMMSG_data();
        } /* In case that the number of alarm is 10 */
 
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBALMMSG2_data
        {
            public int alm_no;
            public short type;
            public short axis;
            public short dummy;
            public short msg_len;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string alm_msg = new string(' ', 64);
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBALMMSG2
        {
            public ODBALMMSG2_data msg1 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg2 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg3 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg4 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg5 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg6 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg7 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg8 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg9 = new ODBALMMSG2_data();
            public ODBALMMSG2_data msg10 = new ODBALMMSG2_data();
        } /* In case that the number of alarm is 10 */
 
        /* cnc_modal:read modal data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class MODAL_AUX_data
        {
            public int aux_data;
            public byte flag1;
            public byte flag2;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class MODAL_RAUX1_data
        {
            public MODAL_AUX_data data1 = new MODAL_AUX_data();
            public MODAL_AUX_data data2 = new MODAL_AUX_data();
            public MODAL_AUX_data data3 = new MODAL_AUX_data();
            public MODAL_AUX_data data4 = new MODAL_AUX_data();
            public MODAL_AUX_data data5 = new MODAL_AUX_data();
            public MODAL_AUX_data data6 = new MODAL_AUX_data();
            public MODAL_AUX_data data7 = new MODAL_AUX_data();
            public MODAL_AUX_data data8 = new MODAL_AUX_data();
            public MODAL_AUX_data data9 = new MODAL_AUX_data();
            public MODAL_AUX_data data10 = new MODAL_AUX_data();
            public MODAL_AUX_data data11 = new MODAL_AUX_data();
            public MODAL_AUX_data data12 = new MODAL_AUX_data();
            public MODAL_AUX_data data13 = new MODAL_AUX_data();
            public MODAL_AUX_data data14 = new MODAL_AUX_data();
            public MODAL_AUX_data data15 = new MODAL_AUX_data();
            public MODAL_AUX_data data16 = new MODAL_AUX_data();
            public MODAL_AUX_data data17 = new MODAL_AUX_data();
            public MODAL_AUX_data data18 = new MODAL_AUX_data();
            public MODAL_AUX_data data19 = new MODAL_AUX_data();
            public MODAL_AUX_data data20 = new MODAL_AUX_data();
            public MODAL_AUX_data data21 = new MODAL_AUX_data();
            public MODAL_AUX_data data22 = new MODAL_AUX_data();
            public MODAL_AUX_data data23 = new MODAL_AUX_data();
            public MODAL_AUX_data data24 = new MODAL_AUX_data();
            public MODAL_AUX_data data25 = new MODAL_AUX_data();
            public MODAL_AUX_data data26 = new MODAL_AUX_data();
            public MODAL_AUX_data data27 = new MODAL_AUX_data();
        }
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class MODAL_RAUX2_data
    {
        public MODAL_AUX_data data1 = new MODAL_AUX_data();
        public MODAL_AUX_data data2 = new MODAL_AUX_data();
        public MODAL_AUX_data data3 = new MODAL_AUX_data();
        public MODAL_AUX_data data4 = new MODAL_AUX_data();
        public MODAL_AUX_data data5 = new MODAL_AUX_data();
        public MODAL_AUX_data data6 = new MODAL_AUX_data();
        public MODAL_AUX_data data7 = new MODAL_AUX_data();
        public MODAL_AUX_data data8 = new MODAL_AUX_data();
        public MODAL_AUX_data data9 = new MODAL_AUX_data();
        public MODAL_AUX_data data10= new MODAL_AUX_data();
        public MODAL_AUX_data data11= new MODAL_AUX_data();
        public MODAL_AUX_data data12= new MODAL_AUX_data();
        public MODAL_AUX_data data13= new MODAL_AUX_data();
        public MODAL_AUX_data data14= new MODAL_AUX_data();
        public MODAL_AUX_data data15= new MODAL_AUX_data();
        public MODAL_AUX_data data16= new MODAL_AUX_data();
        public MODAL_AUX_data data17= new MODAL_AUX_data();
        public MODAL_AUX_data data18= new MODAL_AUX_data();
        public MODAL_AUX_data data19= new MODAL_AUX_data();
        public MODAL_AUX_data data20= new MODAL_AUX_data();
        public MODAL_AUX_data data21= new MODAL_AUX_data();
        public MODAL_AUX_data data22= new MODAL_AUX_data();
        public MODAL_AUX_data data23= new MODAL_AUX_data();
        public MODAL_AUX_data data24= new MODAL_AUX_data();
    }
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class MODAL_RAUX2_data
    {
        public MODAL_AUX_data data1 = new MODAL_AUX_data();
        public MODAL_AUX_data data2 = new MODAL_AUX_data();
        public MODAL_AUX_data data3 = new MODAL_AUX_data();
        public MODAL_AUX_data data4 = new MODAL_AUX_data();
        public MODAL_AUX_data data5 = new MODAL_AUX_data();
        public MODAL_AUX_data data6 = new MODAL_AUX_data();
        public MODAL_AUX_data data7 = new MODAL_AUX_data();
        public MODAL_AUX_data data8 = new MODAL_AUX_data();
        public MODAL_AUX_data data9 = new MODAL_AUX_data();
        public MODAL_AUX_data data10= new MODAL_AUX_data();
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class MODAL_RAUX2_data
        {
            public MODAL_AUX_data data1 = new MODAL_AUX_data();
            public MODAL_AUX_data data2 = new MODAL_AUX_data();
            public MODAL_AUX_data data3 = new MODAL_AUX_data();
            public MODAL_AUX_data data4 = new MODAL_AUX_data();
            public MODAL_AUX_data data5 = new MODAL_AUX_data();
            public MODAL_AUX_data data6 = new MODAL_AUX_data();
            public MODAL_AUX_data data7 = new MODAL_AUX_data();
            public MODAL_AUX_data data8 = new MODAL_AUX_data();
        }
#endif
 
        [StructLayout(LayoutKind.Explicit)]
        public class ODBMDL_1
        {
            [FieldOffset(0)]
            public short datano;
            [FieldOffset(2)]
            public short type;
            [FieldOffset(4)]
            public byte g_data;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class ODBMDL_2
        {
            [FieldOffset(0)]
            public short datano;
            [FieldOffset(2)]
            public short type;
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public byte[] g_1shot = new byte[4];
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 35)]
            public byte[] g_rdata = new byte[35];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMDL_3
        {
            public short datano;
            public short type;
            public MODAL_AUX_data aux = new MODAL_AUX_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMDL_4
        {
            public short datano;
            public short type;
            public MODAL_RAUX1_data raux1 = new MODAL_RAUX1_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMDL_5
        {
            public short datano;
            public short type;
            public MODAL_RAUX2_data raux2 = new MODAL_RAUX2_data();
        }
 
        /* cnc_rdgcode: read G code */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBGCD_data
        {
            public short group;
            public short flag;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 8)]
            public string code = new string(' ', 8);
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBGCD
        {
            public ODBGCD_data gcd0 = new ODBGCD_data();
            public ODBGCD_data gcd1 = new ODBGCD_data();
            public ODBGCD_data gcd2 = new ODBGCD_data();
            public ODBGCD_data gcd3 = new ODBGCD_data();
            public ODBGCD_data gcd4 = new ODBGCD_data();
            public ODBGCD_data gcd5 = new ODBGCD_data();
            public ODBGCD_data gcd6 = new ODBGCD_data();
            public ODBGCD_data gcd7 = new ODBGCD_data();
            public ODBGCD_data gcd8 = new ODBGCD_data();
            public ODBGCD_data gcd9 = new ODBGCD_data();
            public ODBGCD_data gcd10 = new ODBGCD_data();
            public ODBGCD_data gcd11 = new ODBGCD_data();
            public ODBGCD_data gcd12 = new ODBGCD_data();
            public ODBGCD_data gcd13 = new ODBGCD_data();
            public ODBGCD_data gcd14 = new ODBGCD_data();
            public ODBGCD_data gcd15 = new ODBGCD_data();
            public ODBGCD_data gcd16 = new ODBGCD_data();
            public ODBGCD_data gcd17 = new ODBGCD_data();
            public ODBGCD_data gcd18 = new ODBGCD_data();
            public ODBGCD_data gcd19 = new ODBGCD_data();
            public ODBGCD_data gcd20 = new ODBGCD_data();
            public ODBGCD_data gcd21 = new ODBGCD_data();
            public ODBGCD_data gcd22 = new ODBGCD_data();
            public ODBGCD_data gcd23 = new ODBGCD_data();
            public ODBGCD_data gcd24 = new ODBGCD_data();
            public ODBGCD_data gcd25 = new ODBGCD_data();
            public ODBGCD_data gcd26 = new ODBGCD_data();
            public ODBGCD_data gcd27 = new ODBGCD_data();
        }
 
        /* cnc_rdcommand: read command value */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBCMD_data
        {
            public byte adrs;
            public byte num;
            public short flag;
            public int cmd_val;
            public int dec_val;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBCMD
        {
            public ODBCMD_data cmd0 = new ODBCMD_data();
            public ODBCMD_data cmd1 = new ODBCMD_data();
            public ODBCMD_data cmd2 = new ODBCMD_data();
            public ODBCMD_data cmd3 = new ODBCMD_data();
            public ODBCMD_data cmd4 = new ODBCMD_data();
            public ODBCMD_data cmd5 = new ODBCMD_data();
            public ODBCMD_data cmd6 = new ODBCMD_data();
            public ODBCMD_data cmd7 = new ODBCMD_data();
            public ODBCMD_data cmd8 = new ODBCMD_data();
            public ODBCMD_data cmd9 = new ODBCMD_data();
            public ODBCMD_data cmd10 = new ODBCMD_data();
            public ODBCMD_data cmd11 = new ODBCMD_data();
            public ODBCMD_data cmd12 = new ODBCMD_data();
            public ODBCMD_data cmd13 = new ODBCMD_data();
            public ODBCMD_data cmd14 = new ODBCMD_data();
            public ODBCMD_data cmd15 = new ODBCMD_data();
            public ODBCMD_data cmd16 = new ODBCMD_data();
            public ODBCMD_data cmd17 = new ODBCMD_data();
            public ODBCMD_data cmd18 = new ODBCMD_data();
            public ODBCMD_data cmd19 = new ODBCMD_data();
            public ODBCMD_data cmd20 = new ODBCMD_data();
            public ODBCMD_data cmd21 = new ODBCMD_data();
            public ODBCMD_data cmd22 = new ODBCMD_data();
            public ODBCMD_data cmd23 = new ODBCMD_data();
            public ODBCMD_data cmd24 = new ODBCMD_data();
            public ODBCMD_data cmd25 = new ODBCMD_data();
            public ODBCMD_data cmd26 = new ODBCMD_data();
            public ODBCMD_data cmd27 = new ODBCMD_data();
            public ODBCMD_data cmd28 = new ODBCMD_data();
            public ODBCMD_data cmd29 = new ODBCMD_data();
        }
 
        /* cnc_diagnoss:read diagnosis data */
        /* cnc_diagnosr:read diagnosis data(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REALDGN
        {
            public int dgn_val;     /* data of real diagnoss */
            public int dec_val;     /* decimal point of real diagnoss */
        }
 
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class REALDGNS
    {
        public REALDGN rdata1=new REALDGN();
        public REALDGN rdata2=new REALDGN();
        public REALDGN rdata3=new REALDGN();
        public REALDGN rdata4=new REALDGN();
        public REALDGN rdata5=new REALDGN();
        public REALDGN rdata6=new REALDGN();
        public REALDGN rdata7=new REALDGN();
        public REALDGN rdata8=new REALDGN();
        public REALDGN rdata9=new REALDGN();
        public REALDGN rdata10=new REALDGN();
        public REALDGN rdata11=new REALDGN();
        public REALDGN rdata12=new REALDGN();
        public REALDGN rdata13=new REALDGN();
        public REALDGN rdata14=new REALDGN();
        public REALDGN rdata15=new REALDGN();
        public REALDGN rdata16=new REALDGN();
        public REALDGN rdata17=new REALDGN();
        public REALDGN rdata18=new REALDGN();
        public REALDGN rdata19=new REALDGN();
        public REALDGN rdata20=new REALDGN();
        public REALDGN rdata21=new REALDGN();
        public REALDGN rdata22=new REALDGN();
        public REALDGN rdata23=new REALDGN();
        public REALDGN rdata24=new REALDGN();
    } /* In case that the number of alarm is 24 */
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class REALDGNS
    {
        public REALDGN rdata1=new REALDGN();
        public REALDGN rdata2=new REALDGN();
        public REALDGN rdata3=new REALDGN();
        public REALDGN rdata4=new REALDGN();
        public REALDGN rdata5=new REALDGN();
        public REALDGN rdata6=new REALDGN();
        public REALDGN rdata7=new REALDGN();
        public REALDGN rdata8=new REALDGN();
        public REALDGN rdata9=new REALDGN();
        public REALDGN rdata10=new REALDGN();
    } /* In case that the number of alarm is 10 */
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class REALDGNS
        {
            public REALDGN rdata1 = new REALDGN();
            public REALDGN rdata2 = new REALDGN();
            public REALDGN rdata3 = new REALDGN();
            public REALDGN rdata4 = new REALDGN();
            public REALDGN rdata5 = new REALDGN();
            public REALDGN rdata6 = new REALDGN();
            public REALDGN rdata7 = new REALDGN();
            public REALDGN rdata8 = new REALDGN();
        } /* In case that the number of alarm is 8 */
#endif
 
        [StructLayout(LayoutKind.Explicit)]
        public class ODBDGN_1
        {
            [FieldOffset(0)]
            public short datano;    /* data number */
            [FieldOffset(2)]
            public short type;      /* axis number */
            [FieldOffset(4)]
            public byte cdata;     /* parameter / setting data */
            [FieldOffset(4)]
            public short idata;
            [FieldOffset(4)]
            public int ldata;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_2
        {
            public short datano;    /* data number */
            public short type;      /* axis number */
            public REALDGN rdata = new REALDGN();
        }
        [StructLayout(LayoutKind.Explicit)]
        public class ODBDGN_3
        {
            [FieldOffset(0)]
            public short datano;    /* data number */
            [FieldOffset(2)]
            public short type;      /* axis number */
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public byte[] cdatas;
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public short[] idatas;
            [FieldOffset(4),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ldatas;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_4
        {
            public short datano;    /* data number */
            public short type;      /* axis number */
            public REALDGNS rdatas = new REALDGNS();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_A
        {
            public ODBDGN_1 data1 = new ODBDGN_1();
            public ODBDGN_1 data2 = new ODBDGN_1();
            public ODBDGN_1 data3 = new ODBDGN_1();
            public ODBDGN_1 data4 = new ODBDGN_1();
            public ODBDGN_1 data5 = new ODBDGN_1();
            public ODBDGN_1 data6 = new ODBDGN_1();
            public ODBDGN_1 data7 = new ODBDGN_1();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_B
        {
            public ODBDGN_2 data1 = new ODBDGN_2();
            public ODBDGN_2 data2 = new ODBDGN_2();
            public ODBDGN_2 data3 = new ODBDGN_2();
            public ODBDGN_2 data4 = new ODBDGN_2();
            public ODBDGN_2 data5 = new ODBDGN_2();
            public ODBDGN_2 data6 = new ODBDGN_2();
            public ODBDGN_2 data7 = new ODBDGN_2();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_C
        {
            public ODBDGN_3 data1 = new ODBDGN_3();
            public ODBDGN_3 data2 = new ODBDGN_3();
            public ODBDGN_3 data3 = new ODBDGN_3();
            public ODBDGN_3 data4 = new ODBDGN_3();
            public ODBDGN_3 data5 = new ODBDGN_3();
            public ODBDGN_3 data6 = new ODBDGN_3();
            public ODBDGN_3 data7 = new ODBDGN_3();
        } /* (sample) must be modified */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDGN_D
        {
            public ODBDGN_4 data1 = new ODBDGN_4();
            public ODBDGN_4 data2 = new ODBDGN_4();
            public ODBDGN_4 data3 = new ODBDGN_4();
            public ODBDGN_4 data4 = new ODBDGN_4();
            public ODBDGN_4 data5 = new ODBDGN_4();
            public ODBDGN_4 data6 = new ODBDGN_4();
            public ODBDGN_4 data7 = new ODBDGN_4();
        } /* (sample) must be modified */
 
        /* cnc_adcnv:read A/D conversion data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAD
        {
            public short datano;    /* input analog voltage type */
            public short type;      /* analog voltage type */
            public short data;      /* digital voltage data */
        }
 
#if FS15D
    /* cnc_rdopmsg:read operator's message */
    [StructLayout(LayoutKind.Sequential,CharSet=CharSet.Ansi,Pack=4)]
    public class OPMSG_data
    {
        public short datano ;     /* operator's message number */
        public short type ;       /* operator's message type   */
        public short char_num ;   /* message string length   */
        [MarshalAs(UnmanagedType.ByValTStr,SizeConst=129)]
        public string  data= new string(' ',129) ;  /* operator's message string */
    } /* In case that the data length is 129 */
#else
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class OPMSG_data
        {
            public short datano;     /* operator's message number */
            public short type;       /* operator's message type   */
            public short char_num;   /* message string length   */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 256)]
            public string data = new string(' ', 256);  /* operator's message string */
        } /* In case that the data length is 256 */
#endif
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OPMSG
        {
            public OPMSG_data msg1 = new OPMSG_data();
            public OPMSG_data msg2 = new OPMSG_data();
            public OPMSG_data msg3 = new OPMSG_data();
            public OPMSG_data msg4 = new OPMSG_data();
            public OPMSG_data msg5 = new OPMSG_data();
        }
 
        /* cnc_rdopmsg2:read operator's message */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class OPMSG2_data
        {
            public short datano;    /* operator's message number */
            public short type;      /* operator's message type */
            public short char_num;  /* message string length */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string data = new string(' ', 64);  /* operator's message string */
        } /* In case that the data length is 64 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OPMSG2
        {
            public OPMSG2_data msg1 = new OPMSG2_data();
            public OPMSG2_data msg2 = new OPMSG2_data();
            public OPMSG2_data msg3 = new OPMSG2_data();
            public OPMSG2_data msg4 = new OPMSG2_data();
            public OPMSG2_data msg5 = new OPMSG2_data();
        }
 
        /* cnc_rdopmsg3:read operator's message */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class OPMSG3_data
        {
            public short datano;    /* operator's message number */
            public short type;      /* operator's message type */
            public short char_num;  /* message string length */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 256)]
            public string data = new string(' ', 256);  /* operator's message string */
        } /* In case that the data length is 256 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class OPMSG3
        {
            public OPMSG3_data msg1 = new OPMSG3_data();
            public OPMSG3_data msg2 = new OPMSG3_data();
            public OPMSG3_data msg3 = new OPMSG3_data();
            public OPMSG3_data msg4 = new OPMSG3_data();
            public OPMSG3_data msg5 = new OPMSG3_data();
        }
 
        /* cnc_sysconfig:read CNC configuration information */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBSYSC
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_p;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_l;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] mod_id;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] soft_id;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_series16 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string s_version16 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] dummy;
            public short m_rom;
            public short s_rom;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public char[] svo_soft;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public char[] pmc_soft;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public char[] lad_soft;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public char[] mcr_soft;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public char[] spl1_soft;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public char[] spl2_soft;
            public short frmmin;
            public short drmmin;
            public short srmmin;
            public short pmcmin;
            public short crtmin;
            public short sv1min;
            public short sv3min;
            public short sicmin;
            public short posmin;
            public short drmmrc;
            public short drmarc;
            public short pmcmrc;
            public short dmaarc;
            public short iopt;
            public short hdiio;
            public short frmsub;
            public short drmsub;
            public short srmsub;
            public short sv5sub;
            public short sv7sub;
            public short sicsub;
            public short possub;
            public short hamsub;
            public short gm2gr1;
            public short crtgr2;
            public short gm1gr2;
            public short gm2gr2;
            public short cmmrb;
            public short sv5axs;
            public short sv7axs;
            public short sicaxs;
            public short posaxs;
            public short hanaxs;
            public short romr64;
            public short srmr64;
            public short dr1r64;
            public short dr2r64;
            public short iopio2;
            public short hdiio2;
            public short cmmrb2;
            public short romfap;
            public short srmfap;
            public short drmfap;
        }
 
        /* cnc_rdprstrinfo:read program restart information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPRS
        {
            public short datano;         /* dummy */
            public short type;           /* dummy */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] data_info;      /* data setting information */
            public int rstr_bc;        /* block counter */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 35)]
            public int[] rstr_m;         /* M code value */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] rstr_t;         /* T code value */
            public int rstr_s;         /* S code value */
            public int rstr_b;         /* B code value */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] dest;           /* program re-start position */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] dist;           /* program re-start distance */
        }
 
#if FS15D
    /* cnc_rdopnlsgnl:read output signal image of software operator's panel */
    /* cnc_wropnlsgnl:write output signal of software operator's panel */
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class IODBSGNL
    {
        public short   datano;     /* dummy */
        public short   type;       /* data select flag */
        public short   mode;       /* mode signal */
        public short   hndl_ax;    /* Manual handle feed axis selection signal */
        public short   hndl_mv;    /* Manual handle feed travel distance selection signal */
        public short   rpd_ovrd;   /* rapid traverse override signal */
        public short   jog_ovrd;   /* manual feedrate override signal */
        public short   feed_ovrd;  /* feedrate override signal */
        public short   spdl_ovrd;  /* spindle override signal */
        public short   blck_del;   /* optional block skip signal */
        public short   sngl_blck;  /* single block signal */
        public short   machn_lock; /* machine lock signal */
        public short   dry_run;    /* dry run signal */
        public short   mem_prtct;  /* memory protection signal */
        public short   feed_hold;  /* automatic operation halt signal */
        public short   manual_rpd; /* (not used) */
        [MarshalAs(UnmanagedType.ByValArray,SizeConst=2)]
        public short[] dummy;      /* (not used) */
    }
#else
        /* cnc_rdopnlsgnl:read output signal image of software operator's panel */
        /* cnc_wropnlsgnl:write output signal of software operator's panel */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSGNL
        {
            public short datano;     /* dummy */
            public short type;       /* data select flag */
            public short mode;       /* mode signal */
            public short hndl_ax;    /* Manual handle feed axis selection signal */
            public short hndl_mv;    /* Manual handle feed travel distance selection signal */
            public short rpd_ovrd;   /* rapid traverse override signal */
            public short jog_ovrd;   /* manual feedrate override signal */
            public short feed_ovrd;  /* feedrate override signal */
            public short spdl_ovrd;  /* (not used) */
            public short blck_del;   /* optional block skip signal */
            public short sngl_blck;  /* single block signal */
            public short machn_lock; /* machine lock signal */
            public short dry_run;    /* dry run signal */
            public short mem_prtct;  /* memory protection signal */
            public short feed_hold;  /* automatic operation halt signal */
        }
#endif
 
        /* cnc_rdopnlgnrl:read general signal image of software operator's panel */
        /* cnc_wropnlgnrl:write general signal image of software operator's panel */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBGNRL
        {
            public short datano; /* dummy */
            public short type;   /* data select flag */
            public byte sgnal;  /* general signal */
        }
 
        /* cnc_rdopnlgsname:read general signal name of software operator's panel */
        /* cnc_wropnlgsname:write general signal name of software operator's panel*/
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBRDNA
        {
            public short datano;         /* dummy */
            public short type;           /* data select flag */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl1_name = new string(' ', 9);  /* general signal 1 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl2_name = new string(' ', 9);  /* general signal 2 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl3_name = new string(' ', 9);  /* general signal 3 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl4_name = new string(' ', 9);  /* general signal 4 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl5_name = new string(' ', 9);  /* general signal 5 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl6_name = new string(' ', 9);  /* general signal 6 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl7_name = new string(' ', 9);  /* general signal 7 name */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 9)]
            public string sgnl8_name = new string(' ', 9);  /* general signal 8 name */
        }
 
        /* cnc_getdtailerr:get detail error */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBERR
        {
            public short err_no;
            public short err_dtno;
        }
 
 
        /* cnc_rdparainfo:read informations of CNC parameter */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPARAIF_info
        {
            public short prm_no;
            public short prm_type;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPARAIF1
        {
            public ODBPARAIF_info info1 = new ODBPARAIF_info();
            public ODBPARAIF_info info2 = new ODBPARAIF_info();
            public ODBPARAIF_info info3 = new ODBPARAIF_info();
            public ODBPARAIF_info info4 = new ODBPARAIF_info();
            public ODBPARAIF_info info5 = new ODBPARAIF_info();
            public ODBPARAIF_info info6 = new ODBPARAIF_info();
            public ODBPARAIF_info info7 = new ODBPARAIF_info();
            public ODBPARAIF_info info8 = new ODBPARAIF_info();
            public ODBPARAIF_info info9 = new ODBPARAIF_info();
            public ODBPARAIF_info info10 = new ODBPARAIF_info();
        /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPARAIF
        {
            public ushort info_no;
            public short prev_no;
            public short next_no;
            public ODBPARAIF1 info = new ODBPARAIF1();
        }
 
        /* cnc_rdsetinfo:read informations of CNC setting data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSETIF_info
        {
            public short set_no;
            public short set_type;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSETIF1
        {
            public ODBSETIF_info info1 = new ODBSETIF_info();
            public ODBSETIF_info info2 = new ODBSETIF_info();
            public ODBSETIF_info info3 = new ODBSETIF_info();
            public ODBSETIF_info info4 = new ODBSETIF_info();
            public ODBSETIF_info info5 = new ODBSETIF_info();
            public ODBSETIF_info info6 = new ODBSETIF_info();
            public ODBSETIF_info info7 = new ODBSETIF_info();
            public ODBSETIF_info info8 = new ODBSETIF_info();
            public ODBSETIF_info info9 = new ODBSETIF_info();
            public ODBSETIF_info info10 = new ODBSETIF_info();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSETIF
        {
            public ushort info_no;
            public short prev_no;
            public short next_no;
            public ODBSETIF1 info = new ODBSETIF1();
        }
 
        /* cnc_rddiaginfo:read informations of CNC diagnose data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDIAGIF_info
        {
            public short diag_no;
            public short diag_type;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDIAGIF1
        {
            public ODBDIAGIF_info info1 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info2 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info3 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info4 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info5 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info6 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info7 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info8 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info9 = new ODBDIAGIF_info();
            public ODBDIAGIF_info info10 = new ODBDIAGIF_info();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDIAGIF
        {
            public ushort info_no;
            public short prev_no;
            public short next_no;
            public ODBDIAGIF1 info = new ODBDIAGIF1();
        }
 
        /* cnc_rdparanum:read maximum, minimum and total number of CNC parameter */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPARANUM
        {
            public ushort para_min;
            public ushort para_max;
            public ushort total_no;
        }
 
        /* cnc_rdsetnum:read maximum, minimum and total number of CNC setting data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSETNUM
        {
            public ushort set_min;
            public ushort set_max;
            public ushort total_no;
        }
 
        /* cnc_rddiagnum:read maximum, minimum and total number of CNC diagnose data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDIAGNUM
        {
            public ushort diag_min;
            public ushort diag_max;
            public ushort total_no;
        }
 
        /* cnc_rdfrominfo:read F-ROM information on CNC  */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBFINFO_info
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string sysname = new string(' ', 12);  /* F-ROM SYSTEM data Name */
            public int fromsize;      /* F-ROM Size */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBFINFO1
        {
            public ODBFINFO_info info1 = new ODBFINFO_info();
            public ODBFINFO_info info2 = new ODBFINFO_info();
            public ODBFINFO_info info3 = new ODBFINFO_info();
            public ODBFINFO_info info4 = new ODBFINFO_info();
            public ODBFINFO_info info5 = new ODBFINFO_info();
            public ODBFINFO_info info6 = new ODBFINFO_info();
            public ODBFINFO_info info7 = new ODBFINFO_info();
            public ODBFINFO_info info8 = new ODBFINFO_info();
            public ODBFINFO_info info9 = new ODBFINFO_info();
            public ODBFINFO_info info10 = new ODBFINFO_info();
            public ODBFINFO_info info11 = new ODBFINFO_info();
            public ODBFINFO_info info12 = new ODBFINFO_info();
            public ODBFINFO_info info13 = new ODBFINFO_info();
            public ODBFINFO_info info14 = new ODBFINFO_info();
            public ODBFINFO_info info15 = new ODBFINFO_info();
            public ODBFINFO_info info16 = new ODBFINFO_info();
            public ODBFINFO_info info17 = new ODBFINFO_info();
            public ODBFINFO_info info18 = new ODBFINFO_info();
            public ODBFINFO_info info19 = new ODBFINFO_info();
            public ODBFINFO_info info20 = new ODBFINFO_info();
            public ODBFINFO_info info21 = new ODBFINFO_info();
            public ODBFINFO_info info22 = new ODBFINFO_info();
            public ODBFINFO_info info23 = new ODBFINFO_info();
            public ODBFINFO_info info24 = new ODBFINFO_info();
            public ODBFINFO_info info25 = new ODBFINFO_info();
            public ODBFINFO_info info26 = new ODBFINFO_info();
            public ODBFINFO_info info27 = new ODBFINFO_info();
            public ODBFINFO_info info28 = new ODBFINFO_info();
            public ODBFINFO_info info29 = new ODBFINFO_info();
            public ODBFINFO_info info30 = new ODBFINFO_info();
            public ODBFINFO_info info31 = new ODBFINFO_info();
            public ODBFINFO_info info32 = new ODBFINFO_info();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBFINFO
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string slotname = new string(' ', 12);  /* Slot Name */
            public int fromnum;           /* Number of F-ROM SYSTEM data */
            public ODBFINFO1 info = new ODBFINFO1();
        }
 
        /* cnc_getfrominfo:read F-ROM information on CNC  */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBFINFORM_info
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string sysname = new string(' ', 12);  /* F-ROM SYSTEM data Name */
            public int fromsize;      /* F-ROM Size */
            public int fromattrib;    /* F-ROM data attribute */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBFINFORM1
        {
            public ODBFINFORM_info info1 = new ODBFINFORM_info();
            public ODBFINFORM_info info2 = new ODBFINFORM_info();
            public ODBFINFORM_info info3 = new ODBFINFORM_info();
            public ODBFINFORM_info info4 = new ODBFINFORM_info();
            public ODBFINFORM_info info5 = new ODBFINFORM_info();
            public ODBFINFORM_info info6 = new ODBFINFORM_info();
            public ODBFINFORM_info info7 = new ODBFINFORM_info();
            public ODBFINFORM_info info8 = new ODBFINFORM_info();
            public ODBFINFORM_info info9 = new ODBFINFORM_info();
            public ODBFINFORM_info info10 = new ODBFINFORM_info();
            public ODBFINFORM_info info11 = new ODBFINFORM_info();
            public ODBFINFORM_info info12 = new ODBFINFORM_info();
            public ODBFINFORM_info info13 = new ODBFINFORM_info();
            public ODBFINFORM_info info14 = new ODBFINFORM_info();
            public ODBFINFORM_info info15 = new ODBFINFORM_info();
            public ODBFINFORM_info info16 = new ODBFINFORM_info();
            public ODBFINFORM_info info17 = new ODBFINFORM_info();
            public ODBFINFORM_info info18 = new ODBFINFORM_info();
            public ODBFINFORM_info info19 = new ODBFINFORM_info();
            public ODBFINFORM_info info20 = new ODBFINFORM_info();
            public ODBFINFORM_info info21 = new ODBFINFORM_info();
            public ODBFINFORM_info info22 = new ODBFINFORM_info();
            public ODBFINFORM_info info23 = new ODBFINFORM_info();
            public ODBFINFORM_info info24 = new ODBFINFORM_info();
            public ODBFINFORM_info info25 = new ODBFINFORM_info();
            public ODBFINFORM_info info26 = new ODBFINFORM_info();
            public ODBFINFORM_info info27 = new ODBFINFORM_info();
            public ODBFINFORM_info info28 = new ODBFINFORM_info();
            public ODBFINFORM_info info29 = new ODBFINFORM_info();
            public ODBFINFORM_info info30 = new ODBFINFORM_info();
            public ODBFINFORM_info info31 = new ODBFINFORM_info();
            public ODBFINFORM_info info32 = new ODBFINFORM_info();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBFINFORM
        {
            public int slotno;            /* Slot Number */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string slotname = new string(' ', 12);  /* Slot Name */
            public int fromnum;           /* Number of F-ROM SYSTEM data */
            public ODBFINFORM1 info = new ODBFINFORM1();
        }
 
        /* cnc_rdsraminfo:read S-RAM information on CNC */
        /* cnc_getsraminfo:read S-RAM information on CNC */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBSINFO_info
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string sramname = new string(' ', 12); /* S-RAM data Name */
            public int sramsize;     /* S-RAM data Size */
            public short divnumber;    /* Division number of S-RAM file */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname1 = new string(' ', 16);    /* S-RAM data Name1 */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname2 = new string(' ', 16);    /* S-RAM data Name2 */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname3 = new string(' ', 16);    /* S-RAM data Name3 */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname4 = new string(' ', 16);    /* S-RAM data Name4 */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname5 = new string(' ', 16);    /* S-RAM data Name5 */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string fname6 = new string(' ', 16);    /* S-RAM data Name6 */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSINFO1
        {
            public ODBSINFO_info info1 = new ODBSINFO_info();
            public ODBSINFO_info info2 = new ODBSINFO_info();
            public ODBSINFO_info info3 = new ODBSINFO_info();
            public ODBSINFO_info info4 = new ODBSINFO_info();
            public ODBSINFO_info info5 = new ODBSINFO_info();
            public ODBSINFO_info info6 = new ODBSINFO_info();
            public ODBSINFO_info info7 = new ODBSINFO_info();
            public ODBSINFO_info info8 = new ODBSINFO_info();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSINFO
        {
            public int sramnum;          /* Number of S-RAM data */
            public ODBSINFO1 info = new ODBSINFO1();
        }
 
        /* cnc_rdsramaddr:read S-RAM address on CNC */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class SRAMADDR
        {
            public short type;          /* SRAM data type */
            public int size;          /* SRAM data size */
            public int offset;        /* offset from top address of SRAM */
        }
 
        /* cnc_dtsvrdpgdir:read file directory in Data Server */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBDSDIR_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string file_name = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string comment = new string(' ', 64);
            public int size;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string date = new string(' ', 16);
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDSDIR1
        {
            public ODBDSDIR_data data1 = new ODBDSDIR_data();
            public ODBDSDIR_data data2 = new ODBDSDIR_data();
            public ODBDSDIR_data data3 = new ODBDSDIR_data();
            public ODBDSDIR_data data4 = new ODBDSDIR_data();
            public ODBDSDIR_data data5 = new ODBDSDIR_data();
            public ODBDSDIR_data data6 = new ODBDSDIR_data();
            public ODBDSDIR_data data7 = new ODBDSDIR_data();
            public ODBDSDIR_data data8 = new ODBDSDIR_data();
            public ODBDSDIR_data data9 = new ODBDSDIR_data();
            public ODBDSDIR_data data10 = new ODBDSDIR_data();
            public ODBDSDIR_data data11 = new ODBDSDIR_data();
            public ODBDSDIR_data data12 = new ODBDSDIR_data();
            public ODBDSDIR_data data13 = new ODBDSDIR_data();
            public ODBDSDIR_data data14 = new ODBDSDIR_data();
            public ODBDSDIR_data data15 = new ODBDSDIR_data();
            public ODBDSDIR_data data16 = new ODBDSDIR_data();
            public ODBDSDIR_data data17 = new ODBDSDIR_data();
            public ODBDSDIR_data data18 = new ODBDSDIR_data();
            public ODBDSDIR_data data19 = new ODBDSDIR_data();
            public ODBDSDIR_data data20 = new ODBDSDIR_data();
            public ODBDSDIR_data data21 = new ODBDSDIR_data();
            public ODBDSDIR_data data22 = new ODBDSDIR_data();
            public ODBDSDIR_data data23 = new ODBDSDIR_data();
            public ODBDSDIR_data data24 = new ODBDSDIR_data();
            public ODBDSDIR_data data25 = new ODBDSDIR_data();
            public ODBDSDIR_data data26 = new ODBDSDIR_data();
            public ODBDSDIR_data data27 = new ODBDSDIR_data();
            public ODBDSDIR_data data28 = new ODBDSDIR_data();
            public ODBDSDIR_data data29 = new ODBDSDIR_data();
            public ODBDSDIR_data data30 = new ODBDSDIR_data();
            public ODBDSDIR_data data31 = new ODBDSDIR_data();
            public ODBDSDIR_data data32 = new ODBDSDIR_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDSDIR
        {
            public int file_num;
            public int remainder;
            public short data_num;
            public ODBDSDIR1 data = new ODBDSDIR1();
        }
 
        /* cnc_dtsvrdset:read setting data for Data Server */
        /* cnc_dtsvwrset:write setting data for Data Server */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBDSSET
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string host_ip = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string host_uname = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string host_passwd = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 128)]
            public string host_dir = new string(' ', 128);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 13)]
            public string dtsv_mac = new string(' ', 13);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string dtsv_ip = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string dtsv_mask = new string(' ', 16);
        }
 
        /* cnc_dtsvmntinfo:read maintenance information for Data Server */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDSMNT
        {
            public int empty_cnt;
            public int total_size;
            public int read_ptr;
            public int write_ptr;
        }
 
        /* cnc_rdposerrs2:read the position deviation S1 and S2 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPSER
        {
            public int poserr1;
            public int poserr2;
        }
 
        /* cnc_rdctrldi:read the control input signal */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDI_data
        {
            public byte sgnl1;
            public byte sgnl2;
            public byte sgnl3;
            public byte sgnl4;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDI
        {
            public ODBSPDI_data di1 = new ODBSPDI_data();
            public ODBSPDI_data di2 = new ODBSPDI_data();
            public ODBSPDI_data di3 = new ODBSPDI_data();
            public ODBSPDI_data di4 = new ODBSPDI_data();
        }
 
        /* cnc_rdctrldo:read the control output signal */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDO_data
        {
            public byte sgnl1;
            public byte sgnl2;
            public byte sgnl3;
            public byte sgnl4;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDO
        {
            public ODBSPDO_data do1 = new ODBSPDO_data();
            public ODBSPDO_data do2 = new ODBSPDO_data();
            public ODBSPDO_data do3 = new ODBSPDO_data();
            public ODBSPDO_data do4 = new ODBSPDO_data();
        }
 
        /* cnc_rdwaveprm:read the parameter of wave diagnosis */
        /* cnc_wrwaveprm:write the parameter of wave diagnosis */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWAVE_io
        {
            public byte adr;
            public byte bit;
            public short no;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWAVE_axis
        {
            public short axis;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class IODBWAVE_u
        {
            [FieldOffset(0)]
            public IODBWAVE_io io = new IODBWAVE_io();
            [FieldOffset(0)]
            public IODBWAVE_axis axis = new IODBWAVE_axis();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWAVE_ch_data
        {
            public short kind;
            public IODBWAVE_u u = new IODBWAVE_u();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWAVE_ch
        {
            public IODBWAVE_ch_data ch1 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch2 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch3 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch4 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch5 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch6 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch7 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch8 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch9 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch10 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch11 = new IODBWAVE_ch_data();
            public IODBWAVE_ch_data ch12 = new IODBWAVE_ch_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWAVE
        {
            public short condition;
            public char trg_adr;
            public byte trg_bit;
            public short trg_no;
            public short delay;
            public short t_range;
            public IODBWAVE_ch ch = new IODBWAVE_ch();
        }
 
        /* cnc_rdwaveprm2:read the parameter of wave diagnosis 2 */
        /* cnc_wrwaveprm2:write the parameter of wave diagnosis 2 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWVPRM_io
        {
            public byte adr;
            public byte bit;
            public short no;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWVPRM_axis
        {
            public short axis;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class IODBWVPRM_u
        {
            [FieldOffset(0)]
            public IODBWVPRM_io io = new IODBWVPRM_io();
            [FieldOffset(0)]
            public IODBWVPRM_axis axis = new IODBWVPRM_axis();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWVPRM_ch_data
        {
            public short kind;
            public IODBWVPRM_u u = new IODBWVPRM_u();
            public int reserve2;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWVPRM_ch
        {
            public IODBWVPRM_ch_data ch1 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch2 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch3 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch4 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch5 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch6 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch7 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch8 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch9 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch10 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch11 = new IODBWVPRM_ch_data();
            public IODBWVPRM_ch_data ch12 = new IODBWVPRM_ch_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWVPRM
        {
            public short condition;
            public byte trg_adr;
            public byte trg_bit;
            public short trg_no;
            public short reserve1;
            public int delay;
            public int t_range;
            public IODBWVPRM_ch ch = new IODBWVPRM_ch();
        }
 
        /* cnc_rdwavedata:read the data of wave diagnosis */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBWVDT_io
        {
            public byte adr;
            public byte bit;
            public short no;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBWVDT_axis
        {
            public short axis;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class ODBWVDT_u
        {
            [FieldOffset(0)]
            public ODBWVDT_io io = new ODBWVDT_io();
            [FieldOffset(0)]
            public ODBWVDT_axis axis = new ODBWVDT_axis();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBWVDT
        {
            public short channel;
            public short kind;
            public ODBWVDT_u u = new ODBWVDT_u();
            public byte year;
            public byte month;
            public byte day;
            public byte hour;
            public byte minute;
            public byte second;
            public short t_cycle;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8192)]
            public short[] data;
        }
 
        /* cnc_rdrmtwaveprm:read the parameter of wave diagnosis for remort diagnosis */
        /* cnc_wrrmtwaveprm:write the parameter of wave diagnosis for remort diagnosis */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBRMTPRM_alm
        {
            public short no;
            public sbyte axis;
            public byte type;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBRMTPRM_io
        {
            public char adr;
            public byte bit;
            public short no;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class IODBRMTPRM_trg
        {
            [FieldOffset(0)]
            public IODBRMTPRM_alm alm = new IODBRMTPRM_alm();
            [FieldOffset(0)]
            public IODBRMTPRM_io io = new IODBRMTPRM_io();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBRMTPRM_smpl
        {
            public char adr;
            public byte bit;
            public short no;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBRMTPRM1
        {
            public IODBRMTPRM_smpl ampl1 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl2 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl3 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl4 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl5 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl6 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl7 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl8 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl9 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl10 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl11 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl12 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl13 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl14 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl15 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl16 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl17 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl18 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl19 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl20 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl21 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl22 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl23 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl24 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl25 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl26 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl27 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl28 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl29 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl30 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl31 = new IODBRMTPRM_smpl();
            public IODBRMTPRM_smpl ampl32 = new IODBRMTPRM_smpl();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBRMTPRM
        {
            public short condition;
            public short reserve;
            public IODBRMTPRM_trg trg = new IODBRMTPRM_trg();
            public int delay;
            public short wv_intrvl;
            public short io_intrvl;
            public short kind1;
            public short kind2;
            public IODBRMTPRM1 ampl = new IODBRMTPRM1();
        }
 
        /* cnc_rdrmtwavedt:read the data of wave diagnosis for remort diagnosis */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBRMTDT
        {
            public short channel;
            public short kind;
            public byte year;
            public byte month;
            public byte day;
            public byte hour;
            public byte minute;
            public byte second;
            public short t_intrvl;
            public short trg_data;
            public int ins_ptr;
            public short t_delta;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 1917)]
            public short[] data;
        }
 
        /* cnc_rdsavsigadr:read of address for PMC signal batch save */
        /* cnc_wrsavsigadr:write of address for PMC signal batch save */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSIGAD
        {
            public byte adr;
            public byte reserve;
            public short no;
            public short size;
        }
 
        /* cnc_rdmgrpdata:read M-code group data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBMGRP_data
        {
            public int m_code;
            public short grp_no;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 21)]
            public string m_name = new string(' ', 21);
            public byte dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMGRP
        {
            public ODBMGRP_data mgrp1 = new ODBMGRP_data();
            public ODBMGRP_data mgrp2 = new ODBMGRP_data();
            public ODBMGRP_data mgrp3 = new ODBMGRP_data();
            public ODBMGRP_data mgrp4 = new ODBMGRP_data();
            public ODBMGRP_data mgrp5 = new ODBMGRP_data();
            public ODBMGRP_data mgrp6 = new ODBMGRP_data();
            public ODBMGRP_data mgrp7 = new ODBMGRP_data();
            public ODBMGRP_data mgrp8 = new ODBMGRP_data();
            public ODBMGRP_data mgrp9 = new ODBMGRP_data();
            public ODBMGRP_data mgrp10 = new ODBMGRP_data();
        }
 
        /* cnc_wrmgrpdata:write M-code group data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBMGRP
        {
            public short s_no;
            public short dummy;
            public short num;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 500)]
            public short[] group = new short[500];
        }
 
        /* cnc_rdexecmcode:read executing M-code group data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXEM_data
        {
            public int no;
            public short flag;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXEM1
        {
            public ODBEXEM_data m_code1 = new ODBEXEM_data();
            public ODBEXEM_data m_code2 = new ODBEXEM_data();
            public ODBEXEM_data m_code3 = new ODBEXEM_data();
            public ODBEXEM_data m_code4 = new ODBEXEM_data();
            public ODBEXEM_data m_code5 = new ODBEXEM_data();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBEXEM
        {
            public short grp_no;
            public short mem_no;
            public ODBEXEM1 m_code = new ODBEXEM1();
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 21)]
            public string m_name = new string(' ', 21);
            public byte dummy;
        }
 
        /* cnc_rdrstrmcode:read program restart M-code group data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class M_CODE_data
        {
            public int no;
            public short flag;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class M_CODE1
        {
            public M_CODE_data m_code1 = new M_CODE_data();
            public M_CODE_data m_code2 = new M_CODE_data();
            public M_CODE_data m_code3 = new M_CODE_data();
            public M_CODE_data m_code4 = new M_CODE_data();
            public M_CODE_data m_code5 = new M_CODE_data();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBRSTRM
        {
            public short grp_no;
            public short mem_no;
            public M_CODE1 m_code = new M_CODE1();
        }
 
        /* cnc_rdproctime:read processing time stamp data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPTIME_data
        {
            public int prg_no;
            public short hour;
            public byte minute;
            public byte second;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPTIME1
        {
            public ODBPTIME_data data1 = new ODBPTIME_data();
            public ODBPTIME_data data2 = new ODBPTIME_data();
            public ODBPTIME_data data3 = new ODBPTIME_data();
            public ODBPTIME_data data4 = new ODBPTIME_data();
            public ODBPTIME_data data5 = new ODBPTIME_data();
            public ODBPTIME_data data6 = new ODBPTIME_data();
            public ODBPTIME_data data7 = new ODBPTIME_data();
            public ODBPTIME_data data8 = new ODBPTIME_data();
            public ODBPTIME_data data9 = new ODBPTIME_data();
            public ODBPTIME_data data10 = new ODBPTIME_data();
        } /* In case that the number of data is 10 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPTIME
        {
            public short num;
            public ODBPTIME1 data = new ODBPTIME1();
        }
 
        /* cnc_rdprgdirtime:read program directory for processing time data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIRTM_data
        {
            public int prg_no;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 51)]
            public string comment = new string(' ', 51);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 13)]
            public string cuttime = new string(' ', 13);
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIRTM
        {
            public PRGDIRTM_data data1 = new PRGDIRTM_data();
            public PRGDIRTM_data data2 = new PRGDIRTM_data();
            public PRGDIRTM_data data3 = new PRGDIRTM_data();
            public PRGDIRTM_data data4 = new PRGDIRTM_data();
            public PRGDIRTM_data data5 = new PRGDIRTM_data();
            public PRGDIRTM_data data6 = new PRGDIRTM_data();
            public PRGDIRTM_data data7 = new PRGDIRTM_data();
            public PRGDIRTM_data data8 = new PRGDIRTM_data();
            public PRGDIRTM_data data9 = new PRGDIRTM_data();
            public PRGDIRTM_data data10 = new PRGDIRTM_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdprogdir2:read program directory 2 */
#if (!ONO8D)
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR2_data
        {
            public short number;
            public int length;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 51)]
            public string comment = new string(' ', 51);
            public byte dummy;
        }
#else
    [StructLayout(LayoutKind.Sequential,CharSet=CharSet.Ansi,Pack=4)]
    public class PRGDIR2_data
    {
        public int     number ;
        public int     length ;
        [MarshalAs(UnmanagedType.ByValTStr,SizeConst=51)]
        public string  comment= new string(' ',51) ;
        public byte    dummy ;
    }
#endif
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR2
        {
            public PRGDIR2_data dir1 = new PRGDIR2_data();
            public PRGDIR2_data dir2 = new PRGDIR2_data();
            public PRGDIR2_data dir3 = new PRGDIR2_data();
            public PRGDIR2_data dir4 = new PRGDIR2_data();
            public PRGDIR2_data dir5 = new PRGDIR2_data();
            public PRGDIR2_data dir6 = new PRGDIR2_data();
            public PRGDIR2_data dir7 = new PRGDIR2_data();
            public PRGDIR2_data dir8 = new PRGDIR2_data();
            public PRGDIR2_data dir9 = new PRGDIR2_data();
            public PRGDIR2_data dir10 = new PRGDIR2_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdprogdir3:read program directory 3 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class DIR3_MDATE
        {
            public short year;
            public short month;
            public short day;
            public short hour;
            public short minute;
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class DIR3_CDATE
        {
            public short year;
            public short month;
            public short day;
            public short hour;
            public short minute;
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR3_data
        {
            public int number;
            public int length;
            public int page;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 52)]
            public string comment = new string(' ', 52);
            public DIR3_MDATE mdate = new DIR3_MDATE();
            public DIR3_CDATE cdate = new DIR3_CDATE();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR3
        {
            public PRGDIR3_data dir1 = new PRGDIR3_data();
            public PRGDIR3_data dir2 = new PRGDIR3_data();
            public PRGDIR3_data dir3 = new PRGDIR3_data();
            public PRGDIR3_data dir4 = new PRGDIR3_data();
            public PRGDIR3_data dir5 = new PRGDIR3_data();
            public PRGDIR3_data dir6 = new PRGDIR3_data();
            public PRGDIR3_data dir7 = new PRGDIR3_data();
            public PRGDIR3_data dir8 = new PRGDIR3_data();
            public PRGDIR3_data dir9 = new PRGDIR3_data();
            public PRGDIR3_data dir10 = new PRGDIR3_data();
        } /* In case that the number of data is 10 */
 
 
        /* cnc_rdprogdir4:read program directory 4 */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class DIR4_MDATE
        {
            public short year;
            public short month;
            public short day;
            public short hour;
            public short minute;
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class DIR4_CDATE
        {
            public short year;
            public short month;
            public short day;
            public short hour;
            public short minute;
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR4_data
        {
            public int number;
            public int length;
            public int page;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 52)]
            public string comment = new string(' ', 52);
            public DIR4_MDATE mdate = new DIR4_MDATE();
            public DIR4_CDATE cdate = new DIR4_CDATE();
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class PRGDIR4
        {
            public PRGDIR4_data dir1 = new PRGDIR4_data();
            public PRGDIR4_data dir2 = new PRGDIR4_data();
            public PRGDIR4_data dir3 = new PRGDIR4_data();
            public PRGDIR4_data dir4 = new PRGDIR4_data();
            public PRGDIR4_data dir5 = new PRGDIR4_data();
            public PRGDIR4_data dir6 = new PRGDIR4_data();
            public PRGDIR4_data dir7 = new PRGDIR4_data();
            public PRGDIR4_data dir8 = new PRGDIR4_data();
            public PRGDIR4_data dir9 = new PRGDIR4_data();
            public PRGDIR4_data dir10 = new PRGDIR4_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdcomparam:read communication parameter for DNC1, DNC2, OSI-Ethernet */
        /* cnc_wrcomparam:write communication parameter for DNC1, DNC2, OSI-Ethernet */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBCPRM
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 65)]
            public string NcApli = new string(' ', 65);
            public byte Dummy1;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 65)]
            public string HostApli = new string(' ', 65);
            public byte Dummy2;
            public uint StatPstv;
            public uint StatNgtv;
            public uint Statmask;
            public uint AlarmStat;
            public uint PsclHaddr;
            public uint PsclLaddr;
            public ushort SvcMode1;
            public ushort SvcMode2;
            public int FileTout;
            public int RemTout;
        }
 
        /* cnc_rdintchk:read interference check */
        /* cnc_wrintchk:write interference check */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBINT
        {
            public short datano_s;   /* start offset No. */
            public short type;       /* kind of position */
            public short datano_e;   /* end offset No. */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8 * 3)]
            public int[] data = new int[8 * 3];       /* position value of area for not attach */
        }
 
        /* cnc_rdwkcdshft:read work coordinate shift */
        /* cnc_wrwkcdshft:write work coordinate shift */
        /* cnc_rdwkcdsfms:read work coordinate shift measure */
        /* cnc_wrwkcdsfms:write work coordinate shift measure */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBWCSF
        {
            public short datano;    /* datano           */
            public short type;      /* axis number      */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] data = new int[MAX_AXIS];       /* data             */
        }
 
        /* cnc_rdomhisinfo:read operator message history information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOMIF
        {
            public ushort om_max;   /* maximum operator message history */
            public ushort om_sum;   /* actually operator message history */
            public ushort om_char;  /* maximum character (include NULL) */
        }
 
        /* cnc_rdomhistry:read operator message history */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBOMHIS_data
        {
            public short om_no;  /* operator message number */
            public short year;   /* year */
            public short month;  /* month */
            public short day;    /* day */
            public short hour;   /* hour */
            public short minute; /* mimute */
            public short second; /* second */
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 256)]
            public string om_msg = new string(' ', 256);
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBOMHIS
        {
            public ODBOMHIS_data omhis1 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis2 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis3 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis4 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis5 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis6 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis7 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis8 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis9 = new ODBOMHIS_data();
            public ODBOMHIS_data omhis10 = new ODBOMHIS_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdbtofsr:read b-axis tool offset value(area specified) */
        /* cnc_wrbtofsr:write b-axis tool offset value(area specified) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBBTO
        {
            public short datano_s;     /* start offset number */
            public short type;     /* offset type */
            public short datano_e;     /* end offset number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 18)]
            public int[] ofs = new int[18];        /* offset */
        } /* In case that the number of data is 9 (B type) */
 
        /* cnc_rdbtofsinfo:read b-axis tool offset information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBBTLINF
        {
            public short ofs_type;   /* memory type */
            public short use_no;     /* sum of b-axis offset */
            public short sub_no;     /* sub function number of offset cancel */
        }
 
        /* cnc_rdbaxis:read b-axis command */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBBAXIS
        {
            public short flag;        /* b-axis command exist or not */
            public short command;     /* b-axis command */
            public ushort speed;       /* b-axis speed */
            public int sub_data;    /* b-axis sub data */
        }
 
        /* cnc_rdsyssoft:read CNC system soft series and version */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBSYSS
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_p;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_l;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] module_id;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] soft_id;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series16 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version16 = new string(' ', 5);
            public short soft_inst;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string boot_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string boot_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string servo_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string servo_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string ladder_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string ladder_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrlib_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrlib_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrapl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrapl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl1_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl1_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl2_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl2_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl3_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl3_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exelib_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exelib_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exeapl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exeapl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string int_vga_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string int_vga_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string out_vga_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string out_vga_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmm_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmm_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_mng_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_mng_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shin_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shin_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shout_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shout_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_c_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_c_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_edit_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_edit_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_mng_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_mng_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_apl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_apl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl4_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl4_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr2_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr2_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr3_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr3_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string eth_boot_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string eth_boot_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8 * 5)]
            public byte[] reserve;
        }
 
        /* cnc_rdsyssoft2:read CNC system soft series and version (2) */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBSYSS2
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_p;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public byte[] slot_no_l;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] module_id;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] soft_id;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_series16 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version1 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version2 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version3 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version4 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version5 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version6 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version7 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version8 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version9 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version10 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version11 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version12 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version13 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version14 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version15 = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string soft_version16 = new string(' ', 5);
            public short soft_inst;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string boot_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string boot_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string servo_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string servo_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string ladder_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string ladder_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrlib_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrlib_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrapl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcrapl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl1_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl1_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl2_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl2_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl3_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl3_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exelib_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exelib_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exeapl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string c_exeapl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string int_vga_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string int_vga_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string out_vga_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string out_vga_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmm_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmm_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_mng_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_mng_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shin_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shin_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shout_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_shout_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_c_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_c_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_edit_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string pmc_edit_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_mng_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_mng_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_apl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string lddr_apl_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl4_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string spl4_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr2_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr2_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr3_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string mcr3_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string eth_boot_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string eth_boot_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8 * 5)]
            public byte[] reserve;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string embEthe_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string embEthe_ver = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 38 * 5)]
            public byte[] reserve2;
        }
 
        /* cnc_rdsyssoft3:read CNC system soft series and version (3) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSS3_data
        {
            public short soft_id;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public char[] soft_series;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public char[] soft_edition;
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSS3
        {
            public ODBSYSS3_data p1 = new ODBSYSS3_data();
            public ODBSYSS3_data p2 = new ODBSYSS3_data();
            public ODBSYSS3_data p3 = new ODBSYSS3_data();
            public ODBSYSS3_data p4 = new ODBSYSS3_data();
            public ODBSYSS3_data p5 = new ODBSYSS3_data();
            public ODBSYSS3_data p6 = new ODBSYSS3_data();
            public ODBSYSS3_data p7 = new ODBSYSS3_data();
            public ODBSYSS3_data p8 = new ODBSYSS3_data();
            public ODBSYSS3_data p9 = new ODBSYSS3_data();
            public ODBSYSS3_data p10 = new ODBSYSS3_data();
            public ODBSYSS3_data p11 = new ODBSYSS3_data();
            public ODBSYSS3_data p12 = new ODBSYSS3_data();
            public ODBSYSS3_data p13 = new ODBSYSS3_data();
            public ODBSYSS3_data p14 = new ODBSYSS3_data();
            public ODBSYSS3_data p15 = new ODBSYSS3_data();
            public ODBSYSS3_data p16 = new ODBSYSS3_data();
            public ODBSYSS3_data p17 = new ODBSYSS3_data();
            public ODBSYSS3_data p18 = new ODBSYSS3_data();
            public ODBSYSS3_data p19 = new ODBSYSS3_data();
            public ODBSYSS3_data p20 = new ODBSYSS3_data();
            public ODBSYSS3_data p21 = new ODBSYSS3_data();
            public ODBSYSS3_data p22 = new ODBSYSS3_data();
            public ODBSYSS3_data p23 = new ODBSYSS3_data();
            public ODBSYSS3_data p24 = new ODBSYSS3_data();
            public ODBSYSS3_data p25 = new ODBSYSS3_data();
            public ODBSYSS3_data p26 = new ODBSYSS3_data();
            public ODBSYSS3_data p27 = new ODBSYSS3_data();
            public ODBSYSS3_data p28 = new ODBSYSS3_data();
            public ODBSYSS3_data p29 = new ODBSYSS3_data();
            public ODBSYSS3_data p30 = new ODBSYSS3_data();
            public ODBSYSS3_data p31 = new ODBSYSS3_data();
            public ODBSYSS3_data p32 = new ODBSYSS3_data();
            public ODBSYSS3_data p33 = new ODBSYSS3_data();
            public ODBSYSS3_data p34 = new ODBSYSS3_data();
            public ODBSYSS3_data p35 = new ODBSYSS3_data();
            public ODBSYSS3_data p36 = new ODBSYSS3_data();
            public ODBSYSS3_data p37 = new ODBSYSS3_data();
            public ODBSYSS3_data p38 = new ODBSYSS3_data();
            public ODBSYSS3_data p39 = new ODBSYSS3_data();
            public ODBSYSS3_data p40 = new ODBSYSS3_data();
        }
 
        /* cnc_rdsyshard:read CNC system hard info */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSH_data
        {
            public uint id1;
            public uint id2;
            public short group_id;
            public short hard_id;
            public short hard_num;
            public short slot_no;
            public short id1_format;
            public short id2_format;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSH
        {
            public ODBSYSH_data data1 = new ODBSYSH_data();
            public ODBSYSH_data data2 = new ODBSYSH_data();
            public ODBSYSH_data data3 = new ODBSYSH_data();
            public ODBSYSH_data data4 = new ODBSYSH_data();
            public ODBSYSH_data data5 = new ODBSYSH_data();
            public ODBSYSH_data data6 = new ODBSYSH_data();
            public ODBSYSH_data data7 = new ODBSYSH_data();
            public ODBSYSH_data data8 = new ODBSYSH_data();
            public ODBSYSH_data data9 = new ODBSYSH_data();
            public ODBSYSH_data data10 = new ODBSYSH_data();
            public ODBSYSH_data data11 = new ODBSYSH_data();
            public ODBSYSH_data data12 = new ODBSYSH_data();
            public ODBSYSH_data data13 = new ODBSYSH_data();
            public ODBSYSH_data data14 = new ODBSYSH_data();
            public ODBSYSH_data data15 = new ODBSYSH_data();
            public ODBSYSH_data data16 = new ODBSYSH_data();
            public ODBSYSH_data data17 = new ODBSYSH_data();
            public ODBSYSH_data data18 = new ODBSYSH_data();
            public ODBSYSH_data data19 = new ODBSYSH_data();
            public ODBSYSH_data data20 = new ODBSYSH_data();
            public ODBSYSH_data data21 = new ODBSYSH_data();
            public ODBSYSH_data data22 = new ODBSYSH_data();
            public ODBSYSH_data data23 = new ODBSYSH_data();
            public ODBSYSH_data data24 = new ODBSYSH_data();
            public ODBSYSH_data data25 = new ODBSYSH_data();
        }
 
        /* cnc_rdmdlconfig:read CNC module configuration information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMDLC
        {
            public short from;
            public short dram;
            public short sram;
            public short pmc;
            public short crtc;
            public short servo12;
            public short servo34;
            public short servo56;
            public short servo78;
            public short sic;
            public short pos_lsi;
            public short hi_aio;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
            public short[] reserve;
            public short drmmrc;
            public short drmarc;
            public short pmcmrc;
            public short dmaarc;
            public short iopt;
            public short hdiio;
            public short gm2gr1;
            public short crtgr2;
            public short gm1gr2;
            public short gm2gr2;
            public short cmmrb;
            public short sv5axs;
            public short sv7axs;
            public short sicaxs;
            public short posaxs;
            public short hamaxs;
            public short romr64;
            public short srmr64;
            public short dr1r64;
            public short dr2r64;
            public short iopio2;
            public short hdiio2;
            public short cmmrb2;
            public short romfap;
            public short srmfap;
            public short drmfap;
            public short drmare;
            public short pmcmre;
            public short dmaare;
            public short frmbgg;
            public short drmbgg;
            public short asrbgg;
            public short edtpsc;
            public short slcpsc;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 34)]
            public short[] reserve2;
        }
 
        /* cnc_rdpscdproc:read processing condition file (processing data) */
        /* cnc_wrpscdproc:write processing condition file (processing data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSCD_data
        {
            public short slct;
            public int feed;
            public short power;
            public short freq;
            public short duty;
            public short g_press;
            public short g_kind;
            public short g_ready_t;
            public short displace;
            public int supple;
            public short edge_slt;
            public short appr_slt;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] reserve = new short[5];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPSCD
        {
            public IODBPSCD_data data1 = new IODBPSCD_data();
            public IODBPSCD_data data2 = new IODBPSCD_data();
            public IODBPSCD_data data3 = new IODBPSCD_data();
            public IODBPSCD_data data4 = new IODBPSCD_data();
            public IODBPSCD_data data5 = new IODBPSCD_data();
            public IODBPSCD_data data6 = new IODBPSCD_data();
            public IODBPSCD_data data7 = new IODBPSCD_data();
            public IODBPSCD_data data8 = new IODBPSCD_data();
            public IODBPSCD_data data9 = new IODBPSCD_data();
            public IODBPSCD_data data10 = new IODBPSCD_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdpscdpirc:read processing condition file (piercing data) */
        /* cnc_wrpscdpirc:write processing condition file (piercing data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPIRC_data
        {
            public short slct;
            public short power;
            public short freq;
            public short duty;
            public short i_freq;
            public short i_duty;
            public short step_t;
            public short step_sum;
            public int pier_t;
            public short g_press;
            public short g_kind;
            public short g_time;
            public short def_pos;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public short[] reserve = new short[4];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPIRC
        {
            public IODBPIRC_data data1 = new IODBPIRC_data();
            public IODBPIRC_data data2 = new IODBPIRC_data();
            public IODBPIRC_data data3 = new IODBPIRC_data();
        }
 
        /* cnc_rdpscdedge:read processing condition file (edging data) */
        /* cnc_wrpscdedge:write processing condition file (edging data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBEDGE_data
        {
            public short slct;
            public short angle;
            public short power;
            public short freq;
            public short duty;
            public int pier_t;
            public short g_press;
            public short g_kind;
            public int r_len;
            public short r_feed;
            public short r_freq;
            public short r_duty;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] reserve = new short[5];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBEDGE
        {
            public IODBEDGE_data data1 = new IODBEDGE_data();
            public IODBEDGE_data data2 = new IODBEDGE_data();
            public IODBEDGE_data data3 = new IODBEDGE_data();
            public IODBEDGE_data data4 = new IODBEDGE_data();
            public IODBEDGE_data data5 = new IODBEDGE_data();
        }
 
        /* cnc_rdpscdslop:read processing condition file (slope data) */
        /* cnc_wrpscdslop:write processing condition file (slope data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLOP_data
        {
            public int slct;
            public int upleng;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public short[] upsp = new short[10];
            public int dwleng;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public short[] dwsp = new short[10];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 10)]
            public short[] reserve = new short[10];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLOP
        {
            public IODBSLOP_data data1 = new IODBSLOP_data();
            public IODBSLOP_data data2 = new IODBSLOP_data();
            public IODBSLOP_data data3 = new IODBSLOP_data();
            public IODBSLOP_data data4 = new IODBSLOP_data();
            public IODBSLOP_data data5 = new IODBSLOP_data();
        }
 
        /* cnc_rdlpwrdty:read power controll duty data */
        /* cnc_wrlpwrdty:write power controll duty data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBLPWDT
        {
            public short slct;
            public short dty_const;
            public short dty_min;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public short[] reserve = new short[6];
        }
 
        /* cnc_rdlpwrdat:read laser power data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBLOPDT
        {
            public short slct;
            public short pwr_mon;
            public short pwr_ofs;
            public short pwr_act;
            public int feed_act;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public short[] reserve;
        }
 
        /* cnc_rdlagslt:read laser assist gas selection */
        /* cnc_wrlagslt:write laser assist gas selection */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBLAGSL
        {
            public short slct;
            public short ag_slt;
            public short agflow_slt;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public short[] reserve = new short[6];
        }
 
        /* cnc_rdlagst:read laser assist gas flow */
        /* cnc_wrlagst:write laser assist gas flow */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class GASFLOW
        {
            public short slct;
            public short pre_time;
            public short pre_press;
            public short proc_press;
            public short end_time;
            public short end_press;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public short[] reserve = new short[3];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBLAGST
        {
            public GASFLOW data1 = new GASFLOW();
            public GASFLOW data2 = new GASFLOW();
            public GASFLOW data3 = new GASFLOW();
        }
 
        /* cnc_rdledgprc:read laser power for edge processing */
        /* cnc_wrledgprc:write laser power for edge processing */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBLEGPR
        {
            public short slct;
            public short power;
            public short freq;
            public short duty;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] reserve = new short[5];
        }
 
        /* cnc_rdlprcprc:read laser power for piercing */
        /* cnc_wrlprcprc:write laser power for piercing */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBLPCPR
        {
            public short slct;
            public short power;
            public short freq;
            public short duty;
            public int time;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public short[] reserve = new short[4];
        }
 
        /* cnc_rdlcmddat:read laser command data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBLCMDT
        {
            public short slct;
            public int feed;
            public short power;
            public short freq;
            public short duty;
            public short g_kind;
            public short g_ready_t;
            public short g_press;
            public short error;
            public int dsplc;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)]
            public short[] reserve = new short[7];
        }
 
        /* cnc_rdlactnum:read active number */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBLACTN
        {
            public short slct;
            public short act_proc;
            public short act_pirce;
            public short act_slop;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] reserve = new short[5];
        }
 
        /* cnc_rdlcmmt:read laser comment */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBLCMMT
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 25)]
            public string comment = new string(' ', 25);
        }
 
        /* cnc_rdpwofsthis:read power correction factor history data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPWOFST_data
        {
            public int pwratio;
            public int rfvolt;
            public ushort year;
            public ushort month;
            public ushort day;
            public ushort hour;
            public ushort minute;
            public ushort second;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPWOFST
        {
            public ODBPWOFST_data data1 = new ODBPWOFST_data();
            public ODBPWOFST_data data2 = new ODBPWOFST_data();
            public ODBPWOFST_data data3 = new ODBPWOFST_data();
            public ODBPWOFST_data data4 = new ODBPWOFST_data();
            public ODBPWOFST_data data5 = new ODBPWOFST_data();
            public ODBPWOFST_data data6 = new ODBPWOFST_data();
            public ODBPWOFST_data data7 = new ODBPWOFST_data();
            public ODBPWOFST_data data8 = new ODBPWOFST_data();
            public ODBPWOFST_data data9 = new ODBPWOFST_data();
            public ODBPWOFST_data data10 = new ODBPWOFST_data();
            public ODBPWOFST_data data11 = new ODBPWOFST_data();
            public ODBPWOFST_data data12 = new ODBPWOFST_data();
            public ODBPWOFST_data data13 = new ODBPWOFST_data();
            public ODBPWOFST_data data14 = new ODBPWOFST_data();
            public ODBPWOFST_data data15 = new ODBPWOFST_data();
            public ODBPWOFST_data data16 = new ODBPWOFST_data();
            public ODBPWOFST_data data17 = new ODBPWOFST_data();
            public ODBPWOFST_data data18 = new ODBPWOFST_data();
            public ODBPWOFST_data data19 = new ODBPWOFST_data();
            public ODBPWOFST_data data20 = new ODBPWOFST_data();
            public ODBPWOFST_data data21 = new ODBPWOFST_data();
            public ODBPWOFST_data data22 = new ODBPWOFST_data();
            public ODBPWOFST_data data23 = new ODBPWOFST_data();
            public ODBPWOFST_data data24 = new ODBPWOFST_data();
            public ODBPWOFST_data data25 = new ODBPWOFST_data();
            public ODBPWOFST_data data26 = new ODBPWOFST_data();
            public ODBPWOFST_data data27 = new ODBPWOFST_data();
            public ODBPWOFST_data data28 = new ODBPWOFST_data();
            public ODBPWOFST_data data29 = new ODBPWOFST_data();
            public ODBPWOFST_data data30 = new ODBPWOFST_data();
        }
 
        /* cnc_rdmngtime:read management time */
        /* cnc_wrmngtime:write management time */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMNGTIME_data
        {
            public uint life;
            public uint total;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMNGTIME
        {
            public IODBMNGTIME_data data1 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data2 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data3 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data4 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data5 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data6 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data7 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data8 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data9 = new IODBMNGTIME_data();
            public IODBMNGTIME_data data10 = new IODBMNGTIME_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rddischarge:read data related to electrical discharge at power correction ends */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDISCHRG
        {
            public ushort aps;
            public ushort year;
            public ushort month;
            public ushort day;
            public ushort hour;
            public ushort minute;
            public ushort second;
            public short hpc;
            public short hfq;
            public short hdt;
            public short hpa;
            public int hce;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] rfi;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] rfv;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dci;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dcv;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dcw;
        }
 
        /* cnc_rddischrgalm:read alarm history data related to electrical discharg */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDISCHRGALM_data
        {
            public ushort year;
            public ushort month;
            public ushort day;
            public ushort hour;
            public ushort minute;
            public ushort second;
            public int almnum;
            public uint psec;
            public short hpc;
            public short hfq;
            public short hdt;
            public short hpa;
            public int hce;
            public ushort asq;
            public ushort psu;
            public ushort aps;
            public short dummy;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] rfi;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] rfv;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dci;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dcv;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] dcw;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public short[] almcd;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBDISCHRGALM
        {
            public ODBDISCHRGALM_data data1 = new ODBDISCHRGALM_data();
            public ODBDISCHRGALM_data data2 = new ODBDISCHRGALM_data();
            public ODBDISCHRGALM_data data3 = new ODBDISCHRGALM_data();
            public ODBDISCHRGALM_data data4 = new ODBDISCHRGALM_data();
            public ODBDISCHRGALM_data data5 = new ODBDISCHRGALM_data();
        }
 
        /* cnc_gettimer:get date and time from cnc */
        /* cnc_settimer:set date and time for cnc */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public struct TIMER_DATE
        {
            public short year;
            public short month;
            public short date;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public struct TIMER_TIME
        {
            public short hour;
            public short minute;
            public short second;
        }
        [StructLayout(LayoutKind.Explicit)]
        public class IODBTIMER
        {
            [FieldOffset(0)]
            public short type;
            [FieldOffset(2)]
            public short dummy;
            [FieldOffset(4)]
            public TIMER_DATE date;
            [FieldOffset(4)]
            public TIMER_TIME time;
        }
 
        /* cnc_rdtimer:read timer data from cnc */
        /* cnc_wrtimer:write timer data for cnc */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTIME
        {
            public int minute;
            public int msec;
        }
 
        /* cnc_rdtlctldata: read tool controll data */
        /* cnc_wrtlctldata: write tool controll data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLCTL
        {
            public short slct;
            public short used_tool;
            public short turret_indx;
            public int zero_tl_no;
            public int t_axis_move;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] total_punch = new int[2];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 11)]
            public short[] reserve = new short[11];
        }
 
        /* cnc_rdtooldata: read tool data */
        /* cnc_wrtooldata: read tool data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLDT_data
        {
            public short slct;
            public int tool_no;
            public int x_axis_ofs;
            public int y_axis_ofs;
            public int turret_pos;
            public int chg_tl_no;
            public int punch_count;
            public int tool_life;
            public int m_tl_radius;
            public int m_tl_angle;
            public byte tl_shape;
            public int tl_size_i;
            public int tl_size_j;
            public int tl_angle;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public int[] reserve = new int[3];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLDT
        {
            public IODBTLDT_data data1 = new IODBTLDT_data();
            public IODBTLDT_data data2 = new IODBTLDT_data();
            public IODBTLDT_data data3 = new IODBTLDT_data();
            public IODBTLDT_data data4 = new IODBTLDT_data();
            public IODBTLDT_data data5 = new IODBTLDT_data();
            public IODBTLDT_data data6 = new IODBTLDT_data();
            public IODBTLDT_data data7 = new IODBTLDT_data();
            public IODBTLDT_data data8 = new IODBTLDT_data();
            public IODBTLDT_data data9 = new IODBTLDT_data();
            public IODBTLDT_data data10 = new IODBTLDT_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdmultitldt: read multi tool data */
        /* cnc_wrmultitldt: write multi tool data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMLTTL_data
        {
            public short slct;
            public short m_tl_no;
            public int m_tl_radius;
            public int m_tl_angle;
            public int x_axis_ofs;
            public int y_axis_ofs;
            public byte tl_shape;
            public int tl_size_i;
            public int tl_size_j;
            public int tl_angle;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)]
            public int[] reserve = new int[7];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMLTTL
        {
            public IODBMLTTL_data data1 = new IODBMLTTL_data();
            public IODBMLTTL_data data2 = new IODBMLTTL_data();
            public IODBMLTTL_data data3 = new IODBMLTTL_data();
            public IODBMLTTL_data data4 = new IODBMLTTL_data();
            public IODBMLTTL_data data5 = new IODBMLTTL_data();
            public IODBMLTTL_data data6 = new IODBMLTTL_data();
            public IODBMLTTL_data data7 = new IODBMLTTL_data();
            public IODBMLTTL_data data8 = new IODBMLTTL_data();
            public IODBMLTTL_data data9 = new IODBMLTTL_data();
            public IODBMLTTL_data data10 = new IODBMLTTL_data();
        } /* In case that the number of data is 10 */
 
        /* cnc_rdmtapdata: read multi tap data */
        /* cnc_wrmtapdata: write multi tap data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMTAP_data
        {
            public short slct;
            public int tool_no;
            public int x_axis_ofs;
            public int y_axis_ofs;
            public int punch_count;
            public int tool_life;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 11)]
            public int[] reserve = new int[11];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBMTAP
        {
            public IODBMTAP_data data1 = new IODBMTAP_data();
            public IODBMTAP_data data2 = new IODBMTAP_data();
            public IODBMTAP_data data3 = new IODBMTAP_data();
            public IODBMTAP_data data4 = new IODBMTAP_data();
            public IODBMTAP_data data5 = new IODBMTAP_data();
            public IODBMTAP_data data6 = new IODBMTAP_data();
            public IODBMTAP_data data7 = new IODBMTAP_data();
            public IODBMTAP_data data8 = new IODBMTAP_data();
            public IODBMTAP_data data9 = new IODBMTAP_data();
            public IODBMTAP_data data10 = new IODBMTAP_data();
        }
 
        /* cnc_rdtoolinfo: read tool information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPTLINF
        {
            public short tld_max;
            public short mlt_max;
            public short reserve;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] tld_size;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] mlt_size;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)]
            public short[] reserves;
        }
 
        /* cnc_rdsafetyzone: read safetyzone data */
        /* cnc_wrsafetyzone: write safetyzone data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSAFE_data
        {
            public short slct;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public int[] data = new int[3];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSAFE
        {
            public IODBSAFE_data data1 = new IODBSAFE_data();
            public IODBSAFE_data data2 = new IODBSAFE_data();
            public IODBSAFE_data data3 = new IODBSAFE_data();
            public IODBSAFE_data data4 = new IODBSAFE_data();
        } /* In case that the number of data is 4 */
 
        /* cnc_rdtoolzone: read toolzone data */
        /* cnc_wrtoolzone: write toolzone data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLZN_data
        {
            public short slct;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] data = new int[12];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBTLZN
        {
            public IODBTLZN_data data1 = new IODBTLZN_data();
            public IODBTLZN_data data2 = new IODBTLZN_data();
            public IODBTLZN_data data3 = new IODBTLZN_data();
            public IODBTLZN_data data4 = new IODBTLZN_data();
            public IODBTLZN_data data5 = new IODBTLZN_data();
            public IODBTLZN_data data6 = new IODBTLZN_data();
            public IODBTLZN_data data7 = new IODBTLZN_data();
            public IODBTLZN_data data8 = new IODBTLZN_data();
            public IODBTLZN_data data9 = new IODBTLZN_data();
            public IODBTLZN_data data10 = new IODBTLZN_data();
            public IODBTLZN_data data11 = new IODBTLZN_data();
            public IODBTLZN_data data12 = new IODBTLZN_data();
        } /* In case that the number of data is 12 */
 
        /* cnc_rdacttlzone: read active toolzone data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBACTTLZN
        {
            public short act_no;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] data;
        }
 
        /* cnc_rdbrstrinfo:read block restart information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBBRS
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] dest;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] dist;
        } /*  In case that the number of axes is MAX_AXIS */
 
        /* cnc_rdradofs:read tool radius offset for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBROFS
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] pln_axes;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] ofsvct;
        }
 
        /* cnc_rdlenofs:read tool length offset for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBLOFS
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ofsvct;
        } /*  In case that the number of axes is MAX_AXIS */
 
        /* cnc_rdfixcycle:read fixed cycle for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBFIX
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] pln_axes;
            public short drl_axes;
            public int i_pos;
            public int r_pos;
            public int z_pos;
            public int cmd_cnt;
            public int act_cnt;
            public int cut;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] shift;
        }
 
        /* cnc_rdcdrotate:read coordinate rotate for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBROT
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public short[] pln_axes;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] center;
            public int angle;
        }
 
        /* cnc_rd3dcdcnv:read 3D coordinate convert for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DCD
        {
            public short mode;
            public short dno;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public short[] cd_axes;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2 * 3)]
            public int[] center;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2 * 3)]
            public int[] direct;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 2)]
            public int[] angle;
        }
 
        /* cnc_rdmirimage:read programable mirror image for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBMIR
        {
            public short mode;
            public int mir_flag;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] mir_pos;
        } /*  In case that the number of axes is MAX_AXIS */
 
        /* cnc_rdscaling:read scaling data for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSCL
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] center;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] magnif;
        } /*  In case that the number of axes is MAX_AXIS */
 
        /* cnc_rd3dtofs:read 3D tool offset for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DTO
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public short[] ofs_axes;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public int[] ofsvct;
        }
 
        /* cnc_rdposofs:read tool position offset for position data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPOFS
        {
            public short mode;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public int[] ofsvct;
        } /*  In case that the number of axes is MAX_AXIS */
 
        /* cnc_rdhpccset:read hpcc setting data */
        /* cnc_wrhpccset:write hpcc setting data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBHPST
        {
            public short slct;
            public short hpcc;
            public short multi;
            public short ovr1;
            public short ign_f;
            public short foward;
            public int max_f;
            public short ovr2;
            public short ovr3;
            public short ovr4;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)]
            public int[] reserve = new int[7];
        }
 
        /* cnc_rdhpcctupr:read hpcc tuning data ( parameter input ) */
        /* cnc_wrhpcctupr:write hpcc tuning data ( parameter input ) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBHPPR_tune
        {
            public short slct;
            public short diff;
            public short fine;
            public short acc_lv;
            public int max_f;
            public short bipl;
            public short aipl;
            public int corner;
            public short clamp;
            public int radius;
            public int max_cf;
            public int min_cf;
            public int foward;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] reserve = new int[5];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBHPPR
        {
            public IODBHPPR_tune tune1 = new IODBHPPR_tune();
            public IODBHPPR_tune tune2 = new IODBHPPR_tune();
            public IODBHPPR_tune tune3 = new IODBHPPR_tune();
        }
 
        /* cnc_rdhpcctuac:read hpcc tuning data ( acc input ) */
        /* cnc_wrhpcctuac:write hpcc tuning data ( acc input ) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBHPAC_tune
        {
            public short slct;
            public short diff;
            public short fine;
            public short acc_lv;
            public int bipl;
            public short aipl;
            public int corner;
            public int clamp;
            public int c_acc;
            public int foward;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public int[] reserve = new int[8];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBHPAC
        {
            public IODBHPAC_tune tune1 = new IODBHPAC_tune();
            public IODBHPAC_tune tune2 = new IODBHPAC_tune();
            public IODBHPAC_tune tune3 = new IODBHPAC_tune();
        }
 
        /* cnc_rd3dtooltip:read tip of tool for 3D handle */
        /* cnc_rd3dmovrlap:read move overrlap of tool for 3D handle */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DHDL_data
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] axes;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] data;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DHDL
        {
            public ODB3DHDL_data data1 = new ODB3DHDL_data();
            public ODB3DHDL_data data2 = new ODB3DHDL_data();
        }
 
        /* cnc_rd3dpulse:read pulse for 3D handle */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DPLS_data
        {
            public int right_angle_x;
            public int right_angle_y;
            public int tool_axis;
            public int tool_tip_a_b;
            public int tool_tip_c;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODB3DPLS
        {
            public ODB3DPLS_data pls1 = new ODB3DPLS_data();
            public ODB3DPLS_data pls2 = new ODB3DPLS_data();
        }
 
        /* cnc_rdaxisname: read axis name */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAXISNAME_data
        {
            public byte name;          /* axis name */
            public byte suff;          /* suffix */
        }
#if M_AXIS2
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBAXISNAME
    {
        public ODBAXISNAME_data data1 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data2 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data3 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data4 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data5 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data6 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data7 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data8 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data9 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data10= new ODBAXISNAME_data();
        public ODBAXISNAME_data data11= new ODBAXISNAME_data();
        public ODBAXISNAME_data data12= new ODBAXISNAME_data();
        public ODBAXISNAME_data data13= new ODBAXISNAME_data();
        public ODBAXISNAME_data data14= new ODBAXISNAME_data();
        public ODBAXISNAME_data data15= new ODBAXISNAME_data();
        public ODBAXISNAME_data data16= new ODBAXISNAME_data();
        public ODBAXISNAME_data data17= new ODBAXISNAME_data();
        public ODBAXISNAME_data data18= new ODBAXISNAME_data();
        public ODBAXISNAME_data data19= new ODBAXISNAME_data();
        public ODBAXISNAME_data data20= new ODBAXISNAME_data();
        public ODBAXISNAME_data data21= new ODBAXISNAME_data();
        public ODBAXISNAME_data data22= new ODBAXISNAME_data();
        public ODBAXISNAME_data data23= new ODBAXISNAME_data();
        public ODBAXISNAME_data data24= new ODBAXISNAME_data();
    }
#elif FS15D
    [StructLayout(LayoutKind.Sequential,Pack=4)]
    public class ODBAXISNAME
    {
        public ODBAXISNAME_data data1 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data2 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data3 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data4 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data5 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data6 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data7 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data8 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data9 = new ODBAXISNAME_data();
        public ODBAXISNAME_data data10= new ODBAXISNAME_data();
    }
#else
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBAXISNAME
        {
            public ODBAXISNAME_data data1 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data2 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data3 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data4 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data5 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data6 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data7 = new ODBAXISNAME_data();
            public ODBAXISNAME_data data8 = new ODBAXISNAME_data();
        }
#endif
 
        /* cnc_rdspdlname: read spindle name */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDLNAME_data
        {
            public byte name;          /* spindle name */
            public byte suff1;         /* suffix */
            public byte suff2;         /* suffix */
            public byte suff3;         /* suffix */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSPDLNAME
        {
            public ODBSPDLNAME_data data1 = new ODBSPDLNAME_data();
            public ODBSPDLNAME_data data2 = new ODBSPDLNAME_data();
            public ODBSPDLNAME_data data3 = new ODBSPDLNAME_data();
            public ODBSPDLNAME_data data4 = new ODBSPDLNAME_data();
        }
 
        /* cnc_exaxisname: read extended axis name */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBEXAXISNAME
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname1 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname2 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname3 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname4 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname5 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname6 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname7 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname8 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname9 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname10 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname11 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname12 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname13 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname14 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname15 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname16 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname17 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname18 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname19 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname20 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname21 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname22 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname23 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname24 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname25 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname26 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname27 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname28 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname29 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname30 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname31 = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string axname32 = new string(' ', 4);
        }
 
        /* cnc_wrunsolicprm: Set the unsolicited message parameters */
        /* cnc_rdunsolicprm: Get the unsolicited message parameters */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public struct IODBUNSOLIC_pmc
        {
            public short type;
            public short rdaddr;
            public short rdno;
            public short rdsize;
            private int dummy;
        }
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBUNSOLIC
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string ipaddr = new string(' ', 16);
            public ushort port;
            public short reqaddr;
            public short pmcno;
            public short retry;
            public short timeout;
            public short alivetime;
            public short setno;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public IODBUNSOLIC_pmc[] rddata = new IODBUNSOLIC_pmc[3];
        }
 
        /* cnc_rdunsolicmsg: Reads the unsolicited message data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public struct IDBUNSOLICMSG_msg
        {
            public short rdsize;
            public IntPtr data;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBUNSOLICMSG
        {
            public short getno;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public IDBUNSOLICMSG_msg[] msg = new IDBUNSOLICMSG_msg[3];
        }
 
        /* cnc_rdpm_cncitem: read cnc maintenance item */
        /* cnc_rdpm_mcnitem: read machine specific maintenance item */
        /* cnc_wrpm_mcnitem: write machine specific maintenance item */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBITEM
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name1 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name2 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name3 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name4 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name5 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name6 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name7 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name8 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name9 = new string(' ', 62);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name10 = new string(' ', 62);
        }
 
        /* cnc_rdpm_item:read maintenance item status */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMAINTE_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 62)]
            public string name = new string(' ', 62); /* name */
            public int type;        /* life count type */
            public int total;       /* total life time (minite basis) */
            public int remain;      /* life rest time */
            public int stat;        /* life state */
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMAINTE
        {
            public IODBPMAINTE_data data1 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data2 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data3 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data4 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data5 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data6 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data7 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data8 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data9 = new IODBPMAINTE_data();
            public IODBPMAINTE_data data10 = new IODBPMAINTE_data();
        }
 
        /* cnc_sysinfo_ex:read CNC system path information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSEX_path
        {
            public short system;
            public short group;
            public short attrib;
            public short ctrl_axis;
            public short ctrl_srvo;
            public short ctrl_spdl;
            public short mchn_no;
            public short reserved;
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSEX_data
        {
            public ODBSYSEX_path data1 = new ODBSYSEX_path();
            public ODBSYSEX_path data2 = new ODBSYSEX_path();
            public ODBSYSEX_path data3 = new ODBSYSEX_path();
            public ODBSYSEX_path data4 = new ODBSYSEX_path();
            public ODBSYSEX_path data5 = new ODBSYSEX_path();
            public ODBSYSEX_path data6 = new ODBSYSEX_path();
            public ODBSYSEX_path data7 = new ODBSYSEX_path();
            public ODBSYSEX_path data8 = new ODBSYSEX_path();
            public ODBSYSEX_path data9 = new ODBSYSEX_path();
            public ODBSYSEX_path data10 = new ODBSYSEX_path();
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSYSEX
        {
            public short max_axis;
            public short max_spdl;
            public short max_path;
            public short max_mchn;
            public short ctrl_axis;
            public short ctrl_srvo;
            public short ctrl_spdl;
            public short ctrl_path;
            public short ctrl_mchn;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 3)]
            public short[] reserved = new short[3];
            public ODBSYSEX_data path = new ODBSYSEX_data();
        }
 
        /*------------------*/
        /* CNC : SERCOS I/F */
        /*------------------*/
 
        /* cnc_srcsrdidinfo:Read ID information of SERCOS I/F */
        /* cnc_srcswridinfo:Write ID information of SERCOS I/F */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class IODBIDINF
        {
            public int id_no;
            public short drv_no;
            public short acc_element;
            public short err_general;
            public short err_id_no;
            public short err_id_name;
            public short err_attr;
            public short err_unit;
            public short err_min_val;
            public short err_max_val;
            public short id_name_len;
            public short id_name_max;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 60)]
            public string id_name = new string(' ', 60);
            public int attr;
            public short unit_len;
            public short unit_max;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
            public byte[] unit = new byte[12];
            public int min_val;
            public int max_val;
        }
 
        /* cnc_srcsrdexstat:Get execution status of reading/writing operation data of SERCOS I/F */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSRCSST
        {
            public short acc_element;
            public short err_general;
            public short err_id_no;
            public short err_attr;
            public short err_op_data;
        }
 
        /* cnc_srcsrdlayout:Read drive assign of SERCOS I/F */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBSRCSLYT
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
            public short[] spndl;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public short[] servo;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 8)]
            public string axis_name = new string(' ', 8);
        }
 
        /*----------------------------*/
        /* CNC : Servo Guide          */
        /*----------------------------*/
        /* cnc_sdsetchnl:Servo Guide (Channel data set) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBCHAN_data
        {
            public byte chno;
            public sbyte axis;
            public int datanum;
            public ushort datainf;
            public short dataadr;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBCHAN
        {
            public IDBCHAN_data data1 = new IDBCHAN_data();
            public IDBCHAN_data data2 = new IDBCHAN_data();
            public IDBCHAN_data data3 = new IDBCHAN_data();
            public IDBCHAN_data data4 = new IDBCHAN_data();
            public IDBCHAN_data data5 = new IDBCHAN_data();
            public IDBCHAN_data data6 = new IDBCHAN_data();
            public IDBCHAN_data data7 = new IDBCHAN_data();
            public IDBCHAN_data data8 = new IDBCHAN_data();
        }
 
        /* cnc_sdsetchnl:Servo Guide (read Sampling data) */
        /* cnc_sfbreadsmpl:Servo feedback data (read Sampling data) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSD
        {
            public IntPtr chadata;
            public IntPtr count;
        }
 
        /* cnc_sfbsetchnl:Servo feedback data (Channel data set) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IDBSFBCHAN
        {
            public byte chno;
            public sbyte axis;
            public ushort shift;
        }
 
 
        /*-------------------------*/
        /* CNC : FS18-LN function  */
        /*-------------------------*/
 
        /* cnc_allowcnd:read allowanced state */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBCAXIS
        {
            public short dummy;             /* dummy */
            public short type;              /* axis number */
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = MAX_AXIS)]
            public sbyte[] data;              /* data value */
        }
 
 
        /*---------------------------------*/
        /* CNC : C-EXE SRAM file function  */
        /*---------------------------------*/
 
        /* read C-EXE SRAM disk directory */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class CFILEINFO_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 12)]
            public string fname = new string(' ', 12); /* file name */
            public int file_size; /* file size (bytes) */
            public int file_attr; /* attribute */
            public short year;       /* year */
            public short month;      /* month */
            public short day;        /* day */
            public short hour;       /* hour */
            public short minute;     /* mimute */
            public short second;     /* second */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class CFILEINFO
        {
            public CFILEINFO_data data1 = new CFILEINFO_data();
            public CFILEINFO_data data2 = new CFILEINFO_data();
            public CFILEINFO_data data3 = new CFILEINFO_data();
            public CFILEINFO_data data4 = new CFILEINFO_data();
            public CFILEINFO_data data5 = new CFILEINFO_data();
            public CFILEINFO_data data6 = new CFILEINFO_data();
            public CFILEINFO_data data7 = new CFILEINFO_data();
            public CFILEINFO_data data8 = new CFILEINFO_data();
            public CFILEINFO_data data9 = new CFILEINFO_data();
            public CFILEINFO_data data10 = new CFILEINFO_data();
        }
 
        /*-----*/
        /* PMC */
        /*-----*/
 
        /* pmc_rdpmcrng:read PMC data(area specified) */
        /* pmc_wrpmcrng:write PMC data(area specified) */
        [StructLayout(LayoutKind.Explicit)]
        public class IODBPMC0
        {
            [FieldOffset(0)]
            public short type_a;    /* PMC address type */
            [FieldOffset(2)]
            public short type_d;    /* PMC data type */
            [FieldOffset(4)]
            public short datano_s;  /* start PMC address */
            [FieldOffset(6)]
            public short datano_e;  /* end PMC address */
            [FieldOffset(8),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public byte[] cdata;       /* PMC data */
        } /* In case that the number of data is 5 */
 
        [StructLayout(LayoutKind.Explicit)]
        public class IODBPMC1
        {
            [FieldOffset(0)]
            public short type_a;    /* PMC address type */
            [FieldOffset(2)]
            public short type_d;    /* PMC data type */
            [FieldOffset(4)]
            public short datano_s;  /* start PMC address */
            [FieldOffset(6)]
            public short datano_e;  /* end PMC address */
            [FieldOffset(8),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public short[] idata;
        } /* In case that the number of data is 5 */
 
        [StructLayout(LayoutKind.Explicit)]
        public class IODBPMC2
        {
            [FieldOffset(0)]
            public short type_a;    /* PMC address type */
            [FieldOffset(2)]
            public short type_d;    /* PMC data type */
            [FieldOffset(4)]
            public short datano_s;  /* start PMC address */
            [FieldOffset(6)]
            public short datano_e;  /* end PMC address */
            [FieldOffset(8),
           MarshalAs(UnmanagedType.ByValArray, SizeConst = 5)]
            public int[] ldata;
        } /* In case that the number of data is 5 */
 
        /* pmc_rdpmcinfo:read informations of PMC data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCINF_info
        {
            public char pmc_adr;
            public byte adr_attr;
            public ushort top_num;
            public ushort last_num;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCINF1
        {
            public ODBPMCINF_info info1 = new ODBPMCINF_info();
            public ODBPMCINF_info info2 = new ODBPMCINF_info();
            public ODBPMCINF_info info3 = new ODBPMCINF_info();
            public ODBPMCINF_info info4 = new ODBPMCINF_info();
            public ODBPMCINF_info info5 = new ODBPMCINF_info();
            public ODBPMCINF_info info6 = new ODBPMCINF_info();
            public ODBPMCINF_info info7 = new ODBPMCINF_info();
            public ODBPMCINF_info info8 = new ODBPMCINF_info();
            public ODBPMCINF_info info9 = new ODBPMCINF_info();
            public ODBPMCINF_info info10 = new ODBPMCINF_info();
            public ODBPMCINF_info info11 = new ODBPMCINF_info();
            public ODBPMCINF_info info12 = new ODBPMCINF_info();
            public ODBPMCINF_info info13 = new ODBPMCINF_info();
            public ODBPMCINF_info info14 = new ODBPMCINF_info();
            public ODBPMCINF_info info15 = new ODBPMCINF_info();
            public ODBPMCINF_info info16 = new ODBPMCINF_info();
            public ODBPMCINF_info info17 = new ODBPMCINF_info();
            public ODBPMCINF_info info18 = new ODBPMCINF_info();
            public ODBPMCINF_info info19 = new ODBPMCINF_info();
            public ODBPMCINF_info info20 = new ODBPMCINF_info();
            public ODBPMCINF_info info21 = new ODBPMCINF_info();
            public ODBPMCINF_info info22 = new ODBPMCINF_info();
            public ODBPMCINF_info info23 = new ODBPMCINF_info();
            public ODBPMCINF_info info24 = new ODBPMCINF_info();
            public ODBPMCINF_info info25 = new ODBPMCINF_info();
            public ODBPMCINF_info info26 = new ODBPMCINF_info();
            public ODBPMCINF_info info27 = new ODBPMCINF_info();
            public ODBPMCINF_info info28 = new ODBPMCINF_info();
            public ODBPMCINF_info info29 = new ODBPMCINF_info();
            public ODBPMCINF_info info30 = new ODBPMCINF_info();
            public ODBPMCINF_info info31 = new ODBPMCINF_info();
            public ODBPMCINF_info info32 = new ODBPMCINF_info();
            public ODBPMCINF_info info33 = new ODBPMCINF_info();
            public ODBPMCINF_info info34 = new ODBPMCINF_info();
            public ODBPMCINF_info info35 = new ODBPMCINF_info();
            public ODBPMCINF_info info36 = new ODBPMCINF_info();
            public ODBPMCINF_info info37 = new ODBPMCINF_info();
            public ODBPMCINF_info info38 = new ODBPMCINF_info();
            public ODBPMCINF_info info39 = new ODBPMCINF_info();
            public ODBPMCINF_info info40 = new ODBPMCINF_info();
            public ODBPMCINF_info info41 = new ODBPMCINF_info();
            public ODBPMCINF_info info42 = new ODBPMCINF_info();
            public ODBPMCINF_info info43 = new ODBPMCINF_info();
            public ODBPMCINF_info info44 = new ODBPMCINF_info();
            public ODBPMCINF_info info45 = new ODBPMCINF_info();
            public ODBPMCINF_info info46 = new ODBPMCINF_info();
            public ODBPMCINF_info info47 = new ODBPMCINF_info();
            public ODBPMCINF_info info48 = new ODBPMCINF_info();
            public ODBPMCINF_info info49 = new ODBPMCINF_info();
            public ODBPMCINF_info info50 = new ODBPMCINF_info();
            public ODBPMCINF_info info51 = new ODBPMCINF_info();
            public ODBPMCINF_info info52 = new ODBPMCINF_info();
            public ODBPMCINF_info info53 = new ODBPMCINF_info();
            public ODBPMCINF_info info54 = new ODBPMCINF_info();
            public ODBPMCINF_info info55 = new ODBPMCINF_info();
            public ODBPMCINF_info info56 = new ODBPMCINF_info();
            public ODBPMCINF_info info57 = new ODBPMCINF_info();
            public ODBPMCINF_info info58 = new ODBPMCINF_info();
            public ODBPMCINF_info info59 = new ODBPMCINF_info();
            public ODBPMCINF_info info60 = new ODBPMCINF_info();
            public ODBPMCINF_info info61 = new ODBPMCINF_info();
            public ODBPMCINF_info info62 = new ODBPMCINF_info();
            public ODBPMCINF_info info63 = new ODBPMCINF_info();
            public ODBPMCINF_info info64 = new ODBPMCINF_info();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCINF
        {
            public short datano;
            public ODBPMCINF1 info = new ODBPMCINF1();
        }
 
        /* pmc_rdcntldata:read PMC parameter data table control data */
        /* pmc_wrcntldata:write PMC parameter data table control data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMCCNTL_info
        {
            public byte tbl_prm;
            public byte data_type;
            public ushort data_size;
            public ushort data_dsp;
            public short dummy;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMCCNTL1
        {
            public IODBPMCCNTL_info info1 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info2 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info3 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info4 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info5 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info6 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info7 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info8 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info9 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info10 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info11 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info12 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info13 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info14 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info15 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info16 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info17 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info18 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info19 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info20 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info21 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info22 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info23 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info24 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info25 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info26 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info27 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info28 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info29 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info30 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info31 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info32 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info33 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info34 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info35 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info36 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info37 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info38 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info39 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info40 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info41 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info42 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info43 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info44 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info45 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info46 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info47 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info48 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info49 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info50 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info51 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info52 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info53 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info54 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info55 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info56 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info57 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info58 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info59 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info60 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info61 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info62 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info63 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info64 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info65 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info66 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info67 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info68 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info69 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info70 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info71 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info72 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info73 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info74 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info75 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info76 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info77 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info78 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info79 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info80 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info81 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info82 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info83 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info84 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info85 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info86 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info87 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info88 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info89 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info90 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info91 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info92 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info93 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info94 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info95 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info96 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info97 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info98 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info99 = new IODBPMCCNTL_info();
            public IODBPMCCNTL_info info100 = new IODBPMCCNTL_info();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMCCNTL
        {
            public short datano_s;
            public short dummy;
            public short datano_e;
            public IODBPMCCNTL1 info = new IODBPMCCNTL1();
        }
 
        /* pmc_rdalmmsg:read PMC alarm message */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPMCALM_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 128)]
            public string almmsg = new string(' ', 128); /* alarm message */
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCALM
        {
            public ODBPMCALM_data msg1 = new ODBPMCALM_data();
            public ODBPMCALM_data msg2 = new ODBPMCALM_data();
            public ODBPMCALM_data msg3 = new ODBPMCALM_data();
            public ODBPMCALM_data msg4 = new ODBPMCALM_data();
            public ODBPMCALM_data msg5 = new ODBPMCALM_data();
            public ODBPMCALM_data msg6 = new ODBPMCALM_data();
            public ODBPMCALM_data msg7 = new ODBPMCALM_data();
            public ODBPMCALM_data msg8 = new ODBPMCALM_data();
            public ODBPMCALM_data msg9 = new ODBPMCALM_data();
            public ODBPMCALM_data msg10 = new ODBPMCALM_data();
        } /* In case that the number of data is 10 */
 
        /* pmc_getdtailerr:get detail error for pmc */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCERR
        {
            public short err_no;
            public short err_dtno;
        }
 
        /* pmc_rdpmctitle:read pmc title data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPMCTITLE
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string mtb = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string machine = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string type = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 8)]
            public string prgno = new string(' ', 8);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 4)]
            public string prgvers = new string(' ', 4);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string prgdraw = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string date = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string design = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string written = new string(' ', 48);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 48)]
            public string remarks = new string(' ', 48);
        }
 
        /* pmc_rdpmcrng_ext:read PMC data */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPMCEXT
        {
            public short type_a;    /* PMC address type */
            public short type_d;    /* PMC data type */
            public short datano_s;  /* start PMC address */
            public short datano_e;  /* end PMC address */
            public short err_code;  /* error code */
            public short reserved;  /* reserved */
            [MarshalAs(UnmanagedType.AsAny)]
            public object data;      /* pointer to buffer */
        }
 
        /* pmc_rdpmcaddr:read PMC address information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCADR_info
        {
            public byte pmc_adr;
            public byte adr_attr;
            public ushort offset;
            public ushort top;
            public ushort num;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCADR1
        {
            public ODBPMCADR_info info1 = new ODBPMCADR_info();
            public ODBPMCADR_info info2 = new ODBPMCADR_info();
            public ODBPMCADR_info info3 = new ODBPMCADR_info();
            public ODBPMCADR_info info4 = new ODBPMCADR_info();
            public ODBPMCADR_info info5 = new ODBPMCADR_info();
            public ODBPMCADR_info info6 = new ODBPMCADR_info();
            public ODBPMCADR_info info7 = new ODBPMCADR_info();
            public ODBPMCADR_info info8 = new ODBPMCADR_info();
            public ODBPMCADR_info info9 = new ODBPMCADR_info();
            public ODBPMCADR_info info10 = new ODBPMCADR_info();
            public ODBPMCADR_info info11 = new ODBPMCADR_info();
            public ODBPMCADR_info info12 = new ODBPMCADR_info();
            public ODBPMCADR_info info13 = new ODBPMCADR_info();
            public ODBPMCADR_info info14 = new ODBPMCADR_info();
            public ODBPMCADR_info info15 = new ODBPMCADR_info();
            public ODBPMCADR_info info16 = new ODBPMCADR_info();
            public ODBPMCADR_info info17 = new ODBPMCADR_info();
            public ODBPMCADR_info info18 = new ODBPMCADR_info();
            public ODBPMCADR_info info19 = new ODBPMCADR_info();
            public ODBPMCADR_info info20 = new ODBPMCADR_info();
            public ODBPMCADR_info info21 = new ODBPMCADR_info();
            public ODBPMCADR_info info22 = new ODBPMCADR_info();
            public ODBPMCADR_info info23 = new ODBPMCADR_info();
            public ODBPMCADR_info info24 = new ODBPMCADR_info();
            public ODBPMCADR_info info25 = new ODBPMCADR_info();
            public ODBPMCADR_info info26 = new ODBPMCADR_info();
            public ODBPMCADR_info info27 = new ODBPMCADR_info();
            public ODBPMCADR_info info28 = new ODBPMCADR_info();
            public ODBPMCADR_info info29 = new ODBPMCADR_info();
            public ODBPMCADR_info info30 = new ODBPMCADR_info();
            public ODBPMCADR_info info31 = new ODBPMCADR_info();
            public ODBPMCADR_info info32 = new ODBPMCADR_info();
            public ODBPMCADR_info info33 = new ODBPMCADR_info();
            public ODBPMCADR_info info34 = new ODBPMCADR_info();
            public ODBPMCADR_info info35 = new ODBPMCADR_info();
            public ODBPMCADR_info info36 = new ODBPMCADR_info();
            public ODBPMCADR_info info37 = new ODBPMCADR_info();
            public ODBPMCADR_info info38 = new ODBPMCADR_info();
            public ODBPMCADR_info info39 = new ODBPMCADR_info();
            public ODBPMCADR_info info40 = new ODBPMCADR_info();
            public ODBPMCADR_info info41 = new ODBPMCADR_info();
            public ODBPMCADR_info info42 = new ODBPMCADR_info();
            public ODBPMCADR_info info43 = new ODBPMCADR_info();
            public ODBPMCADR_info info44 = new ODBPMCADR_info();
            public ODBPMCADR_info info45 = new ODBPMCADR_info();
            public ODBPMCADR_info info46 = new ODBPMCADR_info();
            public ODBPMCADR_info info47 = new ODBPMCADR_info();
            public ODBPMCADR_info info48 = new ODBPMCADR_info();
            public ODBPMCADR_info info49 = new ODBPMCADR_info();
            public ODBPMCADR_info info50 = new ODBPMCADR_info();
            public ODBPMCADR_info info51 = new ODBPMCADR_info();
            public ODBPMCADR_info info52 = new ODBPMCADR_info();
            public ODBPMCADR_info info53 = new ODBPMCADR_info();
            public ODBPMCADR_info info54 = new ODBPMCADR_info();
            public ODBPMCADR_info info55 = new ODBPMCADR_info();
            public ODBPMCADR_info info56 = new ODBPMCADR_info();
            public ODBPMCADR_info info57 = new ODBPMCADR_info();
            public ODBPMCADR_info info58 = new ODBPMCADR_info();
            public ODBPMCADR_info info59 = new ODBPMCADR_info();
            public ODBPMCADR_info info60 = new ODBPMCADR_info();
            public ODBPMCADR_info info61 = new ODBPMCADR_info();
            public ODBPMCADR_info info62 = new ODBPMCADR_info();
            public ODBPMCADR_info info63 = new ODBPMCADR_info();
            public ODBPMCADR_info info64 = new ODBPMCADR_info();
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBPMCADR
        {
            public uint io_adr;
            public short datano;
            public ODBPMCADR1 info = new ODBPMCADR1();
        }
 
 
        /*--------------------------*/
        /* PROFIBUS function        */
        /*--------------------------*/
 
        /* pmc_prfrdconfig:read PROFIBUS configration data */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBPRFCNF
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string master_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 3)]
            public string master_ver = new string(' ', 3);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string slave_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 3)]
            public string slave_ver = new string(' ', 3);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 5)]
            public string cntl_ser = new string(' ', 5);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 3)]
            public string cntl_ver = new string(' ', 3);
        }
 
        /* pmc_prfrdbusprm:read bus parameter for master function */
        /* pmc_prfwrbusprm:write bus parameter for master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBBUSPRM
        {
            public sbyte fdl_add;
            public sbyte baudrate;
            public ushort tsl;
            public ushort min_tsdr;
            public ushort max_tsdr;
            public byte tqui;
            public byte tset;
            public int ttr;
            public sbyte gap;
            public sbyte hsa;
            public sbyte max_retry;
            public byte bp_flag;
            public ushort min_slv_int;
            public ushort poll_tout;
            public ushort data_cntl;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 6)]
            public byte[] reserve1 = new byte[6];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public byte[] cls2_name = new byte[32];
            public short user_dlen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 62)]
            public byte[] user_data = new byte[62];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 96)]
            public byte[] reserve2 = new byte[96];
        }
 
        /* pmc_prfrdslvprm:read slave parameter for master function */
        /* pmc_prfwrslvprm:write slave parameter for master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLVPRM
        {
            public short dis_enb;
            public ushort ident_no;
            public byte slv_flag;
            public byte slv_type;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
            public byte[] reserve1 = new byte[12];
            public byte slv_stat;
            public byte wd_fact1;
            public byte wd_fact2;
            public byte min_tsdr;
            public char reserve2;
            public byte grp_ident;
            public short user_plen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public byte[] user_pdata = new byte[32];
            public short cnfg_dlen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 126)]
            public byte[] cnfg_data = new byte[126];
            public short slv_ulen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 30)]
            public byte[] slv_udata = new byte[30];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public byte[] reserve3 = new byte[8];
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLVPRM2
        {
            public short dis_enb;
            public ushort ident_no;
            public byte slv_flag;
            public byte slv_type;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
            public byte[] reserve1 = new byte[12];
            public byte slv_stat;
            public byte wd_fact1;
            public byte wd_fact2;
            public byte min_tsdr;
            public sbyte reserve2;
            public byte grp_ident;
            public short user_plen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 206)]
            public byte[] user_pdata = new byte[206];
            public short cnfg_dlen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 126)]
            public byte[] cnfg_data = new byte[126];
            public short slv_ulen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 30)]
            public byte[] slv_udata = new byte[30];
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)]
            public byte[] reserve3 = new byte[8];
        }
 
        /* pmc_prfrdallcadr:read allocation address for master function */
        /* pmc_prfwrallcadr:set allocation address for master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBPRFADR
        {
            public byte di_size;
            public byte di_type;
            public ushort di_addr;
            public short reserve1;
            public byte do_size;
            public byte do_type;
            public ushort do_addr;
            public short reserve2;
            public byte dgn_size;
            public byte dgn_type;
            public ushort dgn_addr;
        }
 
        /* pmc_prfrdslvaddr:read allocation address for slave function */
        /* pmc_prfwrslvaddr:set allocation address for slave function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLVADR
        {
            public byte slave_no;
            public byte di_size;
            public byte di_type;
            public ushort di_addr;
            public byte do_size;
            public byte do_type;
            public ushort do_addr;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)]
            public byte[] reserve = new byte[7];
        }
 
        /* pmc_prfrdslvstat:read status for slave function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBSLVST
        {
            public byte cnfg_stat;
            public byte prm_stat;
            public sbyte wdg_stat;
            public byte live_stat;
            public short ident_no;
        }
 
        /* pmc_prfrdslvid:Reads slave index data of master function */
        /* pmc_prfwrslvid:Writes slave index data of master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLVID
        {
            public short dis_enb;
            public short slave_no;
            public short nsl;
            public byte dgn_size;
            public char dgn_type;
            public ushort dgn_addr;
        }
 
        /* pmc_prfrdslvprm2:Reads  slave parameter of master function(2) */
        /* pmc_prfwrslvprm2:Writes slave parameter of master function(2) */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBSLVPRM3
        {
            public ushort ident_no;
            public byte slv_flag;
            public byte slv_type;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
            public char[] reserve1 = new char[12];
            public byte slv_stat;
            public byte wd_fact1;
            public byte wd_fact2;
            public byte min_tsdr;
            public char reserve2;
            public byte grp_ident;
            public short user_plen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 206)]
            public char[] user_pdata = new char[206];
            public short slv_ulen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 30)]
            public char[] slv_udata = new char[30];
        }
 
        /* pmc_prfrddido:Reads DI/DO parameter of master function */
        /* pmc_prfwrdido:Writes DI/DO parameter of master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBDIDO
        {
            public short slave_no;
            public short slot_no;
            public byte di_size;
            public char di_type;
            public ushort di_addr;
            public byte do_size;
            public char do_type;
            public ushort do_addr;
            public short shift;
            public byte module_dlen;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 128)]
            public char[] module_data = new char[128];
        }
 
        /* pmc_prfrdindiadr:Reads indication address of master function */
        /* pmc_prfwrindiadr:Writes indication address of master function */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBINDEADR
        {
            public byte dummy;
            public char indi_type;
            public ushort indi_addr;
        }
 
        /*-----------------------------------------------*/
        /* DS : Data server & Ethernet board function    */
        /*-----------------------------------------------*/
 
        /* etb_rdparam : read丂the parameter of the Ethernet board  */
        /* etb_wrparam : write the parameter of the Ethernet board  */
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class TCPPRM
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string OwnIPAddress = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string SubNetMask = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string RouterIPAddress = new string(' ', 16);
        }
 
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class HOSTPRM
        {
            public short DataServerPort;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string DataServerIPAddress = new string(' ', 16);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string DataServerUserName = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string DataServerPassword = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 128)]
            public string DataServerLoginDirectory = new string(' ', 128);
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class FTPPRM
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string FTPServerUserName = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
            public string FTPServerPassword = new string(' ', 32);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 128)]
            public string FTPServerLoginDirectory = new string(' ', 128);
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ETBPRM
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 13)]
            public string OwnMACAddress = new string(' ', 128);
            public short MaximumChannel;
            public short HDDExistence;
            public short NumberOfScreens;
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBETP
        {
            public short Dummy_ParameterType;
 
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 210)]
            public byte[] prm = new byte[210];
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBETP_TCP
        {
            public short ParameterType;
            public TCPPRM tcp;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBETP_HOST
        {
            public short ParameterType;
            public HOSTPRM host;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBETP_FTP
        {
            public short ParameterType;
            public FTPPRM ftp;
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class IODBETP_ETB
        {
            public short ParameterType;
            public ETBPRM etb;
        }
 
        /* etb_rderrmsg : read the error message of the Ethernet board */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBETMSG
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 33)]
            public string title = new string(' ', 33);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 390)]
            public string message = new string(' ', 390);
        }
 
        /* ds_rdhddinfo : read information of the Data Server's HDD */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHDDINF
        {
            public int file_num;
            public int remainder_l;
            public int remainder_h;
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
            public char[] current_dir = new char[32];
        }
 
        /* ds_rdhdddir : read the file list of the Data Server's HDD */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHDDDIR_data
        {
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
            public string file_name = new string(' ', 64);
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 80)]
            public string comment = new string(' ', 80);
            public short attribute;
            public short reserved;
            public int size;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 16)]
            public string date = new string(' ', 16);
        }
 
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHDDDIR
        {
            public ODBHDDDIR_data data1 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data2 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data3 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data4 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data5 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data6 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data7 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data8 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data9 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data10 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data11 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data12 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data13 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data14 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data15 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data16 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data17 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data18 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data19 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data20 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data21 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data22 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data23 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data24 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data25 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data26 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data27 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data28 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data29 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data30 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data31 = new ODBHDDDIR_data();
            public ODBHDDDIR_data data32 = new ODBHDDDIR_data();
        }
 
        /* ds_rdhostdir : read the file list of the host */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHOSTDIR_data
        {
            [MarshalAs(UnmanagedType.ByValArray, SizeConst = 128)]
            public char[] host_file = new char[128];
        }
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class ODBHOSTDIR
        {
            public ODBHOSTDIR_data data1 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data2 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data3 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data4 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data5 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data6 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data7 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data8 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data9 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data10 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data11 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data12 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data13 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data14 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data15 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data16 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data17 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data18 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data19 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data20 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data21 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data22 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data23 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data24 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data25 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data26 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data27 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data28 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data29 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data30 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data31 = new ODBHOSTDIR_data();
            public ODBHOSTDIR_data data32 = new ODBHOSTDIR_data();
        }
 
        /* ds_rdmntinfo : read maintenance information */
        [StructLayout(LayoutKind.Sequential, Pack = 4)]
        public class DSMNTINFO
        {
            public ushort empty_cnt;
            public uint total_size;
            public ushort ReadPtr;
            public ushort WritePtr;
        } ;
 
        /*--------------------------*/
        /* HSSB multiple connection */
        /*--------------------------*/
 
        /* cnc_rdnodeinfo:read node informations */
        [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi, Pack = 4)]
        public class ODBNODE
        {
            public int node_no;
            public int io_base;
            public int status;
            public int cnc_type;
            [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 20)]
            public string node_name = new string(' ', 20);
        }
 
 
        /*-------------------------------------*/
        /* CNC: Control axis / spindle related */
        /*-------------------------------------*/
 
        /* read actual axis feedrate(F) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_actf")]
        public static extern short cnc_actf(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBACT a);
 
        /* read absolute axis position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_absolute")]
        public static extern short cnc_absolute(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read machine axis position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_machine")]
        public static extern short cnc_machine(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read relative axis position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_relative")]
        public static extern short cnc_relative(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read distance to go */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_distance")]
        public static extern short cnc_distance(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read skip position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_skip")]
        public static extern short cnc_skip(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read servo delay value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srvdelay")]
        public static extern short cnc_srvdelay(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read acceleration/deceleration delay value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_accdecdly")]
        public static extern short cnc_accdecdly(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read all dynamic data */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddynamic")]
        public static extern short cnc_rddynamic(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDY_1 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddynamic")]
        public static extern short cnc_rddynamic(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDY_2 c);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rddynamico8")]
    public static extern short cnc_rddynamic(ushort FlibHndl,
        short a, short b, [Out,MarshalAs(UnmanagedType.LPStruct)] ODBDY_1 c);
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rddynamico8")]
    public static extern short cnc_rddynamic(ushort FlibHndl,
        short a, short b, [Out,MarshalAs(UnmanagedType.LPStruct)] ODBDY_2 c);
#endif
 
        /* read all dynamic data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddynamic2")]
        public static extern short cnc_rddynamic2(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDY2_1 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddynamic2")]
        public static extern short cnc_rddynamic2(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDY2_2 c);
 
        /* read actual spindle speed(S) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_acts")]
        public static extern short cnc_acts(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBACT a);
 
        /* read actual spindle speed(S) (All or spesified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_acts2")]
        public static extern short cnc_acts2(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBACT2 b);
 
        /* set origin / preset relative axis position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrrelpos")]
        public static extern short cnc_wrrelpos(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBWRR b);
 
        /* preset work coordinate */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_prstwkcd")]
        public static extern short cnc_prstwkcd(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBWRA b);
 
        /* read manual overlapped motion value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmovrlap")]
        public static extern short cnc_rdmovrlap(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBOVL c);
 
        /* cancel manual overlapped motion value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_canmovrlap")]
        public static extern short cnc_canmovrlap(ushort FlibHndl, short a);
 
        /* read load information of serial spindle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspload")]
        public static extern short cnc_rdspload(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPN b);
 
        /* read maximum r.p.m. ratio of serial spindle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspmaxrpm")]
        public static extern short cnc_rdspmaxrpm(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPN b);
 
        /* read gear ratio of serial spindle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspgear")]
        public static extern short cnc_rdspgear(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPN b);
 
        /* read absolute axis position 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_absolute2")]
        public static extern short cnc_absolute2(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read relative axis position 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_relative2")]
        public static extern short cnc_relative2(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* set wire vertival position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setvrtclpos")]
        public static extern short cnc_setvrtclpos(ushort FlibHndl, short a);
 
        /* set wire threading position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setthrdngpos")]
        public static extern short cnc_setthrdngpos(ushort FlibHndl);
 
        /* read tool position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdposition")]
        public static extern short cnc_rdposition(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPOS c);
 
        /* read current speed */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspeed")]
        public static extern short cnc_rdspeed(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPEED b);
 
        /* read servo load meter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsvmeter")]
        public static extern short cnc_rdsvmeter(ushort FlibHndl,
            ref short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSVLOAD b);
 
        /* read spindle load meter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspmeter")]
        public static extern short cnc_rdspmeter(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPLOAD c);
 
        /* read manual feed for 5-axis machining */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd5axmandt")]
        public static extern short cnc_rd5axmandt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB5AXMAN a);
 
        /* read amount of machine axes movement of manual feed for 5-axis machining */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd5axovrlap")]
        public static extern short cnc_rd5axovrlap(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read handle interruption */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhndintrpt")]
        public static extern short cnc_rdhndintrpt(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHND c);
 
        /* clear pulse values of manual feed for 5-axis machining */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clr5axpls")]
        public static extern short cnc_clr5axpls(ushort FlibHndl, short a);
 
        /* read constant surface speed */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspcss")]
        public static extern short cnc_rdspcss(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBCSS a);
 
        /* read execution program pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdexecpt")]
        public static extern short cnc_rdexecpt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGPNT a, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGPNT b);
 
        /* read various axis data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdaxisdata")]
        public static extern short cnc_rdaxisdata(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, short c, ref short d, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXDT e);
 
        /*----------------------*/
        /* CNC: Program related */
        /*----------------------*/
 
        /* start downloading NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnstart")]
        public static extern short cnc_dwnstart(ushort FlibHndl);
 
        /* download NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_download")]
        public static extern short cnc_download(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b);
 
        /* download NC program(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cdownload")]
        public static extern short cnc_cdownload(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b);
 
        /* end of downloading NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnend")]
        public static extern short cnc_dwnend(ushort FlibHndl);
 
        /* end of downloading NC program 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnend2")]
        public static extern short cnc_dwnend2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* start downloading NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnstart3")]
        public static extern short cnc_dwnstart3(ushort FlibHndl, short a);
 
        /* start downloading NC program 3 special */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnstart3_f")]
        public static extern short cnc_dwnstart3_f(ushort FlibHndl,
            short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, [In, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* download NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_download3")]
        public static extern short cnc_download3(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of downloading NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnend3")]
        public static extern short cnc_dwnend3(ushort FlibHndl);
 
        /* start downloading NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnstart4")]
        public static extern short cnc_dwnstart4(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* download NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_download4")]
        public static extern short cnc_download4(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of downloading NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dwnend4")]
        public static extern short cnc_dwnend4(ushort FlibHndl);
 
        /* start verification of NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_vrfstart")]
        public static extern short cnc_vrfstart(ushort FlibHndl);
 
        /* verify NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_verify")]
        public static extern short cnc_verify(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b);
 
        /* verify NC program(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cverify")]
        public static extern short cnc_cverify(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b);
 
        /* end of verification */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_vrfend")]
        public static extern short cnc_vrfend(ushort FlibHndl);
 
        /* start verification of NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_vrfstart4")]
        public static extern short cnc_vrfstart4(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* verify NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_verify4")]
        public static extern short cnc_verify4(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of verification */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_vrfend4")]
        public static extern short cnc_vrfend4(ushort FlibHndl);
 
        /* start downloading DNC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dncstart")]
        public static extern short cnc_dncstart(ushort FlibHndl);
 
        /* download DNC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dnc")]
        public static extern short cnc_dnc(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, ushort b);
 
        /* download DNC program(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cdnc")]
        public static extern short cnc_cdnc(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, ushort b);
 
        /* end of downloading DNC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dncend")]
        public static extern short cnc_dncend(ushort FlibHndl);
 
        /* start downloading DNC program 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dncstart2")]
        public static extern short cnc_dncstart2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* download DNC program 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dnc2")]
        public static extern short cnc_dnc2(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of downloading DNC program 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dncend2")]
        public static extern short cnc_dncend2(ushort FlibHndl, short a);
 
        /* read the diagnosis data of DNC operation */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddncdgndt")]
        public static extern short cnc_rddncdgndt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDNCDGN a);
 
        /* start uploading NC program */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upstart")]
        public static extern short cnc_upstart(ushort FlibHndl, short a);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_upstarto8")]
    public static extern short cnc_upstart( ushort FlibHndl, int a );
#endif
 
        /* upload NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upload")]
        public static extern short cnc_upload(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBUP a, ref ushort b);
 
        /* upload NC program(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cupload")]
        public static extern short cnc_cupload(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBUP a, ref ushort b);
 
        /* end of uploading NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upend")]
        public static extern short cnc_upend(ushort FlibHndl);
 
        /* start uploading NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upstart3")]
        public static extern short cnc_upstart3(ushort FlibHndl, short a, int b, int c);
 
        /* start uploading NC program special 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upstart3_f")]
        public static extern short cnc_upstart3_f(ushort FlibHndl,
            short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, [In, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* upload NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upload3")]
        public static extern short cnc_upload3(ushort FlibHndl, ref int a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of uploading NC program 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upend3")]
        public static extern short cnc_upend3(ushort FlibHndl);
 
        /* start uploading NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upstart4")]
        public static extern short cnc_upstart4(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* upload NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upload4")]
        public static extern short cnc_upload4(ushort FlibHndl, ref int a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* end of uploading NC program 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_upend4")]
        public static extern short cnc_upend4(ushort FlibHndl);
 
        /* read buffer status for downloading/verification NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_buff")]
        public static extern short cnc_buff(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBBUF a);
 
        /* search specified program */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_search")]
        public static extern short cnc_search(ushort FlibHndl, short a);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_searcho8")]
    public static extern short cnc_search( ushort FlibHndl, int a );
#endif
 
        /* search specified program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_search2")]
        public static extern short cnc_search2(ushort FlibHndl, int a);
 
        /* delete all programs */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_delall")]
        public static extern short cnc_delall(ushort FlibHndl);
 
        /* delete specified program */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_delete")]
        public static extern short cnc_delete(ushort FlibHndl, short a);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_deleteo8")]
    public static extern short cnc_delete( ushort FlibHndl, int a );
#endif
 
        /* delete program (area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_delrange")]
        public static extern short cnc_delrange(ushort FlibHndl, int a, int b);
 
        /* read program directory */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogdir")]
        public static extern short cnc_rdprogdir(ushort FlibHndl,
            short a, short b, short c, ushort d, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGDIR e);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rdprogdiro8")]
    public static extern short cnc_rdprogdir( ushort FlibHndl,
        short a, short b, short c, ushort d, [Out,MarshalAs(UnmanagedType.LPStruct)] PRGDIR e );
#endif
 
        /* read program information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdproginfo")]
        public static extern short cnc_rdproginfo(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBNC_1 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdproginfo")]
        public static extern short cnc_rdproginfo(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBNC_2 c);
 
        /* read program number under execution */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprgnum")]
        public static extern short cnc_rdprgnum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPRO a);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rdprgnumo8")]
    public static extern short cnc_rdprgnum( ushort FlibHndl, [Out,MarshalAs(UnmanagedType.LPStruct)] ODBPRO a );
#endif
 
        /* read program name under execution */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_exeprgname")]
        public static extern short cnc_exeprgname(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBEXEPRG a);
 
        /* read sequence number under execution */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdseqnum")]
        public static extern short cnc_rdseqnum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSEQ a);
 
        /* search specified sequence number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_seqsrch")]
        public static extern short cnc_seqsrch(ushort FlibHndl, int a);
 
        /* search specified sequence number (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_seqsrch2")]
        public static extern short cnc_seqsrch2(ushort FlibHndl, int a);
 
        /* rewind cursor of NC program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rewind")]
        public static extern short cnc_rewind(ushort FlibHndl);
 
        /* read block counter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdblkcount")]
        public static extern short cnc_rdblkcount(ushort FlibHndl, out int a);
 
        /* read program under execution */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdexecprog")]
        public static extern short cnc_rdexecprog(ushort FlibHndl, ref ushort a, out short b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* read program for MDI operation */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmdiprog")]
        public static extern short cnc_rdmdiprog(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write program for MDI operation */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmdiprog")]
        public static extern short cnc_wrmdiprog(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read execution pointer for MDI operation */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmdipntr")]
        public static extern short cnc_rdmdipntr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDIP a);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rdmdipntro8")]
    public static extern short cnc_rdmdipntr( ushort FlibHndl, [Out,MarshalAs(UnmanagedType.LPStruct)] ODBMDIP a );
#endif
 
        /* write execution pointer for MDI operation */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmdipntr")]
        public static extern short cnc_wrmdipntr(ushort FlibHndl, int a);
 
        /* register new program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_newprog")]
        public static extern short cnc_newprog(ushort FlibHndl, int a);
 
        /* copy program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_copyprog")]
        public static extern short cnc_copyprog(ushort FlibHndl, int a, int b);
 
        /* rename program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_renameprog")]
        public static extern short cnc_renameprog(ushort FlibHndl, int a, int b);
 
        /* condense program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_condense")]
        public static extern short cnc_condense(ushort FlibHndl, short a, int b);
 
        /* merge program */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_mergeprog")]
        public static extern short cnc_mergeprog(ushort FlibHndl, short a, int b, uint c, int d);
 
        /* read current program and its pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdactpt")]
        public static extern short cnc_rdactpt(ushort FlibHndl, out int a, out int b);
 
        /* read current program and its pointer and UV macro pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rduvactpt")]
        public static extern short cnc_rduvactpt(ushort FlibHndl, out int a, out int b, out int c);
 
        /* set current program and its pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wractpt")]
        public static extern short cnc_wractpt(ushort FlibHndl, int a, short b, ref int c);
 
        /* line edit (read program) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogline")]
        public static extern short cnc_rdprogline(ushort FlibHndl,
            int a, uint b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c, ref uint d, ref uint e);
 
        /* line edit (read program) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogline2")]
        public static extern short cnc_rdprogline2(ushort FlibHndl,
            int a, uint b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c, ref uint d, ref uint e);
 
        /* line edit (write program) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrprogline")]
        public static extern short cnc_wrprogline(ushort FlibHndl, int a, uint b, [In, MarshalAs(UnmanagedType.AsAny)] Object c, uint d);
 
        /* line edit (delete line in program) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_delprogline")]
        public static extern short cnc_delprogline(ushort FlibHndl, int a, uint b, uint c);
 
        /* line edit (search string) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_searchword")]
        public static extern short cnc_searchword(ushort FlibHndl,
            int a, uint b, short c, short d, uint e, [In, MarshalAs(UnmanagedType.AsAny)] Object f);
 
        /* line edit (search string) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_searchresult")]
        public static extern short cnc_searchresult(ushort FlibHndl, out uint a);
 
        /* line edit (read program by file name) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_line")]
        public static extern short cnc_rdpdf_line(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, uint b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c, ref uint d, ref uint e);
 
        /* program lock */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setpglock")]
        public static extern short cnc_setpglock(ushort FlibHndl, int a);
 
        /* program unlock */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_resetpglock")]
        public static extern short cnc_resetpglock(ushort FlibHndl, int a);
 
        /* read the status of the program lock */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpglockstat")]
        public static extern short cnc_rdpglockstat(ushort FlibHndl, out int a, out int b);
 
        /* create file or directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_add")]
        public static extern short cnc_pdf_add(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* condense program file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_cond")]
        public static extern short cnc_pdf_cond(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* change attribute of program file and directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpdf_attr")]
        public static extern short cnc_wrpdf_attr(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [Out, MarshalAs(UnmanagedType.LPStruct)] IDBPDFTDIR b);
 
        /* copy program file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_copy")]
        public static extern short cnc_pdf_copy(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* delete file or directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_del")]
        public static extern short cnc_pdf_del(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* line edit (write program by file name) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpdf_line")]
        public static extern short cnc_wrpdf_line(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, uint b, [In, MarshalAs(UnmanagedType.AsAny)] Object c, uint d);
 
        /* line edit (delete line by file name) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_delline")]
        public static extern short cnc_pdf_delline(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, uint b, uint c);
 
        /* move program file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_move")]
        public static extern short cnc_pdf_move(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read current program and its pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_rdactpt")]
        public static extern short cnc_pdf_rdactpt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a, out int b);
 
        /* read selected file name */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_rdmain")]
        public static extern short cnc_pdf_rdmain(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* rename file or directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_rename")]
        public static extern short cnc_pdf_rename(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* line edit (search string) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_searchword")]
        public static extern short cnc_pdf_searchword(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, uint b, uint c, uint d, uint e, [In, MarshalAs(UnmanagedType.AsAny)] Object f);
 
        /* line edit (search string) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_searchresult")]
        public static extern short cnc_pdf_searchresult(ushort FlibHndl, out uint a);
 
        /* select program file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_slctmain")]
        public static extern short cnc_pdf_slctmain(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* set current program and its pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_pdf_wractpt")]
        public static extern short cnc_pdf_wractpt(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b, ref int c);
 
        /* read program drive information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_inf")]
        public static extern short cnc_rdpdf_inf(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* read program drive directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_drive")]
        public static extern short cnc_rdpdf_drive(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read current directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_curdir")]
        public static extern short cnc_rdpdf_curdir(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* set current directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpdf_curdir")]
        public static extern short cnc_wrpdf_curdir(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read directory (sub directories) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_subdir")]
        public static extern short cnc_rdpdf_subdir(ushort FlibHndl,
            ref short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBPDFSDIR b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPDFSDIR c);
 
        /* read directory (all files) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_alldir")]
        public static extern short cnc_rdpdf_alldir(ushort FlibHndl, ref short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* read file count in directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpdf_subdirn")]
        public static extern short cnc_rdpdf_subdirn(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPDFNFIL b);
 
        /*---------------------------*/
        /* CNC: NC file data related */
        /*---------------------------*/
 
        /* read tool offset value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofs")]
        public static extern short cnc_rdtofs(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTOFS d);
 
        /* write tool offset value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofs")]
        public static extern short cnc_wrtofs(ushort FlibHndl, short a, short b, short c, int d);
 
        /* read tool offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsr")]
        public static extern short cnc_rdtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_1 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsr")]
        public static extern short cnc_rdtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_2 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsr")]
        public static extern short cnc_rdtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_3 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsr")]
        public static extern short cnc_rdtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTO_2 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsr")]
        public static extern short cnc_rdtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTO_3 e);
 
        /* write tool offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofsr")]
        public static extern short cnc_wrtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_1 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofsr")]
        public static extern short cnc_wrtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_2 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofsr")]
        public static extern short cnc_wrtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTO_1_3 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofsr")]
        public static extern short cnc_wrtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTO_2 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtofsr")]
        public static extern short cnc_wrtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTO_3 b);
 
        /* read work zero offset value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdzofs")]
        public static extern short cnc_rdzofs(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBZOFS d);
 
        /* write work zero offset value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrzofs")]
        public static extern short cnc_wrzofs(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBZOFS b);
 
        /* read work zero offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdzofsr")]
        public static extern short cnc_rdzofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBZOR e);
 
        /* write work zero offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrzofsr")]
        public static extern short cnc_wrzofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBZOR b);
 
        /* read mesured point value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmsptype")]
        public static extern short cnc_rdmsptype(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBMSTP d);
 
        /* write mesured point value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmsptype")]
        public static extern short cnc_wrmsptype(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBMSTP d);
 
        /* read parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam")]
        public static extern short cnc_rdparam(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_1 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam")]
        public static extern short cnc_rdparam(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_2 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam")]
        public static extern short cnc_rdparam(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_3 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam")]
        public static extern short cnc_rdparam(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_4 d);
 
        /* write parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrparam")]
        public static extern short cnc_wrparam(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_1 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrparam")]
        public static extern short cnc_wrparam(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_2 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrparam")]
        public static extern short cnc_wrparam(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_3 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrparam")]
        public static extern short cnc_wrparam(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_4 b);
 
        /* read parameter(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparar")]
        public static extern short cnc_rdparar(ushort FlibHndl,
            ref short a, short b, ref short c, ref short d, [Out, MarshalAs(UnmanagedType.AsAny)] Object e);
        //  [DllImport("FWLIB32.dll", EntryPoint="cnc_rdparar")]
        //  public static extern short cnc_rdparar( ushort FlibHndl,
        //      ref short a, short b, ref short c, ref short d, [Out,MarshalAs(UnmanagedType.LPStruct)] IODBPSD_A e );
        //  [DllImport("FWLIB32.dll", EntryPoint="cnc_rdparar")]
        //  public static extern short cnc_rdparar( ushort FlibHndl,
        //      ref short a, short b, ref short c, ref short d, [Out,MarshalAs(UnmanagedType.LPStruct)] IODBPSD_B e );
        //  [DllImport("FWLIB32.dll", EntryPoint="cnc_rdparar")]
        //  public static extern short cnc_rdparar( ushort FlibHndl,
        //      ref short a, short b, ref short c, ref short d, [Out,MarshalAs(UnmanagedType.LPStruct)] IODBPSD_C e );
        //  [DllImport("FWLIB32.dll", EntryPoint="cnc_rdparar")]
        //  public static extern short cnc_rdparar( ushort FlibHndl,
        //      ref short a, short b, ref short c, ref short d, [Out,MarshalAs(UnmanagedType.LPStruct)] IODBPSD_D e );
 
        /* write parameter(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrparas")]
        public static extern short cnc_wrparas(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdset")]
        public static extern short cnc_rdset(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_1 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdset")]
        public static extern short cnc_rdset(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_2 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdset")]
        public static extern short cnc_rdset(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_3 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdset")]
        public static extern short cnc_rdset(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_4 d);
 
        /* write setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrset")]
        public static extern short cnc_wrset(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_1 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrset")]
        public static extern short cnc_wrset(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_2 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrset")]
        public static extern short cnc_wrset(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_3 b);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrset")]
        public static extern short cnc_wrset(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_4 b);
 
        /* read setting data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsetr")]
        public static extern short cnc_rdsetr(ushort FlibHndl,
            ref short a, short b, ref short c, ref short d, [Out, MarshalAs(UnmanagedType.AsAny)] Object e);
 
        /* write setting data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrsets")]
        public static extern short cnc_wrsets(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read parameters */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam_ext")]
        public static extern short cnc_rdparam_ext(ushort FlibHndl,
            [In, Out, MarshalAs(UnmanagedType.LPStruct)] IODBPRMNO a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPRM c);
 
        /* read parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam3")]
        public static extern short cnc_rdparam3(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_1 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam3")]
        public static extern short cnc_rdparam3(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_2 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam3")]
        public static extern short cnc_rdparam3(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_3 e);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparam3")]
        public static extern short cnc_rdparam3(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSD_4 e);
 
        /* async parameter write start */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_start_async_wrparam")]
        public static extern short cnc_start_async_wrparam(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPRM a);
 
        /* async parameter write end */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_end_async_wrparam")]
        public static extern short cnc_end_async_wrparam(ushort FlibHndl, out short a);
 
        /* read cause of busy for async parameter write */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_async_busy_state")]
        public static extern short cnc_async_busy_state(ushort FlibHndl, out short a);
 
        /* read diagnosis data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddiag_ext")]
        public static extern short cnc_rddiag_ext(ushort FlibHndl,
            [In, Out, MarshalAs(UnmanagedType.LPStruct)] IODBPRMNO a, short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPRM c);
 
        /* read pitch error compensation data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpitchr")]
        public static extern short cnc_rdpitchr(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPI d);
 
        /* write pitch error compensation data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpitchr")]
        public static extern short cnc_wrpitchr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPI b);
 
        /* read custom macro variable */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmacro")]
        public static extern short cnc_rdmacro(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBM c);
 
        /* write custom macro variable */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmacro")]
        public static extern short cnc_wrmacro(ushort FlibHndl, short a, short b, int c, short d);
 
        /* read custom macro variables(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmacror")]
        public static extern short cnc_rdmacror(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBMR d);
 
        /* write custom macro variables(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmacror")]
        public static extern short cnc_wrmacror(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBMR b);
 
        /* read custom macro variables(IEEE double version) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmacror2")]
        public static extern short cnc_rdmacror2(ushort FlibHndl, int a, ref int b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* write custom macro variables(IEEE double version) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmacror2")]
        public static extern short cnc_wrmacror2(ushort FlibHndl, int a, ref int b, [In, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* read P code macro variable */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpmacro")]
        public static extern short cnc_rdpmacro(ushort FlibHndl, int a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPM b);
 
        /* write P code macro variable */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpmacro")]
        public static extern short cnc_wrpmacro(ushort FlibHndl, int a, int b, short c);
 
        /* read P code macro variables(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpmacror")]
        public static extern short cnc_rdpmacror(ushort FlibHndl,
            int a, int b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPR d);
 
        /* write P code macro variables(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpmacror")]
        public static extern short cnc_wrpmacror(ushort FlibHndl, ushort a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPR b);
 
        /* read P code macro variables(IEEE double version) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpmacror2")]
        public static extern short cnc_rdpmacror2(ushort FlibHndl, uint a, ref uint b, ushort c, [Out, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* write P code macro variables(IEEE double version) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpmacror2")]
        public static extern short cnc_wrpmacror2(ushort FlibHndl, uint a, ref uint b, ushort c, [In, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* read tool offset information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsinfo")]
        public static extern short cnc_rdtofsinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLINF a);
 
        /* read tool offset information(2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtofsinfo2")]
        public static extern short cnc_rdtofsinfo2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLINF2 a);
 
        /* read work zero offset information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdzofsinfo")]
        public static extern short cnc_rdzofsinfo(ushort FlibHndl, out short a);
 
        /* read pitch error compensation data information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpitchinfo")]
        public static extern short cnc_rdpitchinfo(ushort FlibHndl, out short a);
 
        /* read custom macro variable information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmacroinfo")]
        public static extern short cnc_rdmacroinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMVINF a);
 
        /* read P code macro variable information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpmacroinfo")]
        public static extern short cnc_rdpmacroinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMINF a);
 
        /* read validity of tool offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_tofs_rnge")]
        public static extern short cnc_tofs_rnge(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDATRNG c);
 
        /* read validity of work zero offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_zofs_rnge")]
        public static extern short cnc_zofs_rnge(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDATRNG c);
 
        /* read validity of work zero offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wksft_rnge")]
        public static extern short cnc_wksft_rnge(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDATRNG b);
 
        /* read the information for function cnc_rdhsparam() */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhsprminfo")]
        public static extern short cnc_rdhsprminfo(ushort FlibHndl, int a, [Out, MarshalAs(UnmanagedType.LPStruct)] HSPINFO_data b);
 
        /* read parameters at the high speed */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhsparam")]
        public static extern short cnc_rdhsparam(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.LPStruct)] HSPINFO b, [Out, MarshalAs(UnmanagedType.LPStruct)] HSPDATA_1 c);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhsparam")]
        public static extern short cnc_rdhsparam(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.LPStruct)] HSPINFO b, [Out, MarshalAs(UnmanagedType.LPStruct)] HSPDATA_2 c);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhsparam")]
        public static extern short cnc_rdhsparam(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.LPStruct)] HSPINFO b, [Out, MarshalAs(UnmanagedType.LPStruct)] HSPDATA_3 c);
 
        /*----------------------------------------*/
        /* CNC: Tool life management data related */
        /*----------------------------------------*/
 
        /* read tool life management data(tool group number) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpid")]
        public static extern short cnc_rdgrpid(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE1 b);
 
        /* read tool life management data(number of tool groups) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdngrp")]
        public static extern short cnc_rdngrp(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE2 a);
 
        /* read tool life management data(number of tools) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdntool")]
        public static extern short cnc_rdntool(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE3 b);
 
        /* read tool life management data(tool life) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlife")]
        public static extern short cnc_rdlife(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE3 b);
 
        /* read tool life management data(tool lift counter) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcount")]
        public static extern short cnc_rdcount(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE3 b);
 
        /* read tool life management data(tool length number-1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd1length")]
        public static extern short cnc_rd1length(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(tool length number-2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd2length")]
        public static extern short cnc_rd2length(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(cutter compensation no.-1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd1radius")]
        public static extern short cnc_rd1radius(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(cutter compensation no.-2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd2radius")]
        public static extern short cnc_rd2radius(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(tool information-1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_t1info")]
        public static extern short cnc_t1info(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(tool information-2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_t2info")]
        public static extern short cnc_t2info(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(tool number) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_toolnum")]
        public static extern short cnc_toolnum(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE4 c);
 
        /* read tool life management data(tool number, tool life, tool life counter)(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtoolrng")]
        public static extern short cnc_rdtoolrng(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTR d);
 
        /* read tool life management data(all data within group) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtoolgrp")]
        public static extern short cnc_rdtoolgrp(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTG c);
 
        /* write tool life management data(tool life counter) (area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrcountr")]
        public static extern short cnc_wrcountr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBWRC b);
 
        /* read tool life management data(used tool group number) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdusegrpid")]
        public static extern short cnc_rdusegrpid(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBUSEGR a);
 
        /* read tool life management data(max. number of tool groups) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmaxgrp")]
        public static extern short cnc_rdmaxgrp(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLFNO a);
 
        /* read tool life management data(maximum number of tool within group) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmaxtool")]
        public static extern short cnc_rdmaxtool(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLFNO a);
 
        /* read tool life management data(used tool no. within group) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdusetlno")]
        public static extern short cnc_rdusetlno(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLUSE d);
 
        /* read tool life management data(tool data1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd1tlifedata")]
        public static extern short cnc_rd1tlifedata(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTD c);
 
        /* read tool life management data(tool data2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd2tlifedata")]
        public static extern short cnc_rd2tlifedata(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTD c);
 
        /* write tool life management data(tool data1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wr1tlifedata")]
        public static extern short cnc_wr1tlifedata(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTD a);
 
        /* write tool life management data(tool data2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wr2tlifedata")]
        public static extern short cnc_wr2tlifedata(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTD a);
 
        /* read tool life management data(tool group information) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpinfo")]
        public static extern short cnc_rdgrpinfo(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTGI d);
 
        /* read tool life management data(tool group information 2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpinfo2")]
        public static extern short cnc_rdgrpinfo2(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTGI2 d);
 
        /* read tool life management data(tool group information 3) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpinfo3")]
        public static extern short cnc_rdgrpinfo3(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTGI3 d);
 
        /* read tool life management data(tool group information 4) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpinfo4")]
        public static extern short cnc_rdgrpinfo4(ushort FlibHndl,
            short a, short b, short c, out short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTGI4 e);
 
        /* write tool life management data(tool group information) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrgrpinfo")]
        public static extern short cnc_wrgrpinfo(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTGI b);
 
        /* write tool life management data(tool group information 2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrgrpinfo2")]
        public static extern short cnc_wrgrpinfo2(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTGI2 b);
 
        /* write tool life management data(tool group information 3) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrgrpinfo3")]
        public static extern short cnc_wrgrpinfo3(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTGI3 b);
 
        /* delete tool life management data(tool group) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_deltlifegrp")]
        public static extern short cnc_deltlifegrp(ushort FlibHndl, short a);
 
        /* insert tool life management data(tool data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_instlifedt")]
        public static extern short cnc_instlifedt(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IDBITD a);
 
        /* delete tool life management data(tool data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_deltlifedt")]
        public static extern short cnc_deltlifedt(ushort FlibHndl, short a, short b);
 
        /* clear tool life management data(tool life counter, tool information)(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clrcntinfo")]
        public static extern short cnc_clrcntinfo(ushort FlibHndl, short a, short b);
 
        /* read tool life management data(tool group number) 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrpid2")]
        public static extern short cnc_rdgrpid2(ushort FlibHndl, int a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLIFE5 b);
 
        /* read tool life management data(tool data1) 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd1tlifedat2")]
        public static extern short cnc_rd1tlifedat2(ushort FlibHndl,
            short a, int b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTD2 c);
 
        /* write tool life management data(tool data1) 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wr1tlifedat2")]
        public static extern short cnc_wr1tlifedat2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTD2 a);
 
        /* read tool life management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtlinfo")]
        public static extern short cnc_rdtlinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBTLINFO a);
 
        /* read tool life management data(used tool group number) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtlusegrp")]
        public static extern short cnc_rdtlusegrp(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBUSEGRP a);
 
        /* read tool life management data(tool group information 2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtlgrp")]
        public static extern short cnc_rdtlgrp(ushort FlibHndl,
            int a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLGRP c);
 
        /* read tool life management data (tool data1) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtltool")]
        public static extern short cnc_rdtltool(ushort FlibHndl,
            int a, int b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLTOOL d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdexchgtgrp")]
        public static extern short cnc_rdexchgtgrp(ushort FlibHndl,
            ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBEXGP c);
 
        /*-----------------------------------*/
        /* CNC: Tool management data related */
        /*-----------------------------------*/
 
        /* new registration of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_regtool")]
        public static extern short cnc_regtool(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG c);
 
        /* new registration of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_regtool_f2")]
        public static extern short cnc_regtool_f2(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG_F2 c);
 
        /* deletion of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_deltool")]
        public static extern short cnc_deltool(ushort FlibHndl, short a, ref short b);
 
        /* lead of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtool")]
        public static extern short cnc_rdtool(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG c);
 
        /* lead of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtool_f2")]
        public static extern short cnc_rdtool_f2(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG_F2 c);
 
        /* write of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtool")]
        public static extern short cnc_wrtool(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG b);
 
        /* write of individual data of tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtool2")]
        public static extern short cnc_wrtool2(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBTLM b);
 
        /* write tool management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtool_f2")]
        public static extern short cnc_wrtool_f2(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMNG_F2_data b);
 
        /* new registration of magazine management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_regmagazine")]
        public static extern short cnc_regmagazine(ushort FlibHndl, ref short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMAG b);
 
        /* deletion of magazine management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_delmagazine")]
        public static extern short cnc_delmagazine(ushort FlibHndl, ref short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLMAG2 b);
 
        /* lead of magazine management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmagazine")]
        public static extern short cnc_rdmagazine(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLMAG b);
 
        /* Individual write of magazine management data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmagazine")]
        public static extern short cnc_wrmagazine(ushort FlibHndl, short a, short b, short c);
 
 
        /*-------------------------------------*/
        /* CNC: Operation history data related */
        /*-------------------------------------*/
 
        /* stop logging operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopophis")]
        public static extern short cnc_stopophis(ushort FlibHndl);
 
        /* restart logging operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startophis")]
        public static extern short cnc_startophis(ushort FlibHndl);
 
        /* read number of operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophisno")]
        public static extern short cnc_rdophisno(ushort FlibHndl, out ushort a);
 
        /* read operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry")]
        public static extern short cnc_rdophistry(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHIS d);
 
        /* read operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry2")]
        public static extern short cnc_rdophistry2(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* read operation history data F30i*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_1 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_2 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_3 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_4 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_5 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_6 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_7 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_8 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_9 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_10 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdophistry4")]
        public static extern short cnc_rdophistry4(ushort FlibHndl,
            ushort a, ref ushort b, ref ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOPHIS4_11 d);
 
        /* read number of alarm history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhisno")]
        public static extern short cnc_rdalmhisno(ushort FlibHndl, out ushort a);
 
        /* read alarm history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhistry")]
        public static extern short cnc_rdalmhistry(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAHIS d);
 
        /* read alarm history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhistry_w")]
        public static extern short cnc_rdalmhistry_w(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAHIS d);
 
        /* read alarm history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhistry2")]
        public static extern short cnc_rdalmhistry2(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAHIS2 d);
 
        /* read alarm history data F30i*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhistry3")]
        public static extern short cnc_rdalmhistry3(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAHIS3 d);
 
        /* read alarm history data F30i*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmhistry5")]
        public static extern short cnc_rdalmhistry5(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAHIS5 d);
 
        /* clear operation history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clearophis")]
        public static extern short cnc_clearophis(ushort FlibHndl, short a);
 
        /* read signals related operation history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhissgnl")]
        public static extern short cnc_rdhissgnl(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSIG a);
 
        /* read signals related operation history 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhissgnl2")]
        public static extern short cnc_rdhissgnl2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSIG2 a);
 
        /* read signals related operation history 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhissgnl3")]
        public static extern short cnc_rdhissgnl3(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSIG3 a);
 
        /* write signals related operation history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhissgnl")]
        public static extern short cnc_wrhissgnl(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSIG a);
 
        /* write signals related operation history 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhissgnl2")]
        public static extern short cnc_wrhissgnl2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSIG2 a);
 
        /* write signals related operation history for F30i*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhissgnl3")]
        public static extern short cnc_wrhissgnl3(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSIG3 a);
 
        /* read number of operater message history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdomhisno")]
        public static extern short cnc_rdomhisno(ushort FlibHndl, out ushort a);
 
        /*-------------*/
        /* CNC: Others */
        /*-------------*/
 
        /* read CNC system information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sysinfo")]
        public static extern short cnc_sysinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYS a);
 
        /* read CNC status information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_statinfo")]
        public static extern short cnc_statinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBST a);
 
        /* read alarm status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_alarm")]
        public static extern short cnc_alarm(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBALM a);
 
        /* read alarm status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_alarm2")]
        public static extern short cnc_alarm2(ushort FlibHndl, out int a);
 
        /* read alarm information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalminfo")]
        public static extern short cnc_rdalminfo(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ALMINFO_1 d);
 
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalminfo")]
        public static extern short cnc_rdalminfo(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ALMINFO_2 d);
 
        /* read alarm message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmmsg")]
        public static extern short cnc_rdalmmsg(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBALMMSG c);
 
        /* read alarm message(2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdalmmsg2")]
        public static extern short cnc_rdalmmsg2(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBALMMSG2 c);
 
        /* clear CNC alarm */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clralm")]
        public static extern short cnc_clralm(ushort FlibHndl, short a);
 
        /* read modal data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_modal")]
        public static extern short cnc_modal(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDL_1 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_modal")]
        public static extern short cnc_modal(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDL_2 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_modal")]
        public static extern short cnc_modal(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDL_3 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_modal")]
        public static extern short cnc_modal(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDL_4 c);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_modal")]
        public static extern short cnc_modal(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDL_5 c);
 
        /* read G code */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgcode")]
        public static extern short cnc_rdgcode(ushort FlibHndl,
            short a, short b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBGCD d);
 
        /* read command value */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcommand")]
        public static extern short cnc_rdcommand(ushort FlibHndl,
            short a, short b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBCMD d);
 
        /* read diagnosis data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_diagnoss")]
        public static extern short cnc_diagnoss(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDGN_1 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_diagnoss")]
        public static extern short cnc_diagnoss(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDGN_2 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_diagnoss")]
        public static extern short cnc_diagnoss(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDGN_3 d);
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_diagnoss")]
        public static extern short cnc_diagnoss(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDGN_4 d);
 
        /* read diagnosis data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_diagnosr")]
        public static extern short cnc_diagnosr(ushort FlibHndl,
            ref short a, short b, ref short c, ref short d, [Out, MarshalAs(UnmanagedType.AsAny)] Object e);
        //  [DllImport("FWLIB32.dll", EntryPoint="cnc_diagnosr")]
        //  public static extern short cnc_diagnosr( ushort FlibHndl,
        //      ref short a, short b, ref short c, ref short d, [Out,MarshalAs(UnmanagedType.LPStruct)] ODBDGN e );
 
        /* read A/D conversion data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_adcnv")]
        public static extern short cnc_adcnv(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAD c);
 
        /* read operator's message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopmsg")]
        public static extern short cnc_rdopmsg(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] OPMSG c);
 
        /* read operator's message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopmsg2")]
        public static extern short cnc_rdopmsg2(ushort FlibHndl, short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] OPMSG2 c);
 
        /* read operator's message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopmsg3")]
        public static extern short cnc_rdopmsg3(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] OPMSG3 c);
 
        /* set path number(for 4 axes lathes, multi-path) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setpath")]
        public static extern short cnc_setpath(ushort FlibHndl, short a);
 
        /* get path number(for 4 axes lathes, multi-path) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getpath")]
        public static extern short cnc_getpath(ushort FlibHndl, out short a, out short b);
 
        /* allocate library handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allclibhndl")]
        public static extern short cnc_allclibhndl(out ushort FlibHndl);
 
        /* free library handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_freelibhndl")]
        public static extern short cnc_freelibhndl(ushort FlibHndl);
 
        /* get library option */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getlibopt")]
        public static extern short cnc_getlibopt(ushort FlibHndl, int a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* set library option */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setlibopt")]
        public static extern short cnc_setlibopt(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, int c);
 
        /* get custom macro type */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getmactype")]
        public static extern short cnc_getmactype(ushort FlibHndl, out short a);
 
        /* set custom macro type */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setmactype")]
        public static extern short cnc_setmactype(ushort FlibHndl, short a);
 
        /* get P code macro type */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getpmactype")]
        public static extern short cnc_getpmactype(ushort FlibHndl, out short a);
 
        /* set P code macro type */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setpmactype")]
        public static extern short cnc_setpmactype(ushort FlibHndl, short a);
 
        /* get screen status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getcrntscrn")]
        public static extern short cnc_getcrntscrn(ushort FlibHndl, out short a);
 
        /* change screen mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_slctscrn")]
        public static extern short cnc_slctscrn(ushort FlibHndl, short a);
 
        /* read CNC configuration information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sysconfig")]
        public static extern short cnc_sysconfig(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSC a);
 
        /* read program restart information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprstrinfo")]
        public static extern short cnc_rdprstrinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPRS a);
 
        /* search sequence number for program restart */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rstrseqsrch")]
        public static extern short cnc_rstrseqsrch(ushort FlibHndl, int a, int b, short c, short d);
 
        /* search sequence number for program restart 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rstrseqsrch2")]
        public static extern short cnc_rstrseqsrch2(ushort FlibHndl, int a, int b, short c, short d, int e);
 
        /* read output signal image of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopnlsgnl")]
        public static extern short cnc_rdopnlsgnl(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSGNL b);
 
        /* write output signal of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wropnlsgnl")]
        public static extern short cnc_wropnlsgnl(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSGNL a);
 
        /* read general signal image of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopnlgnrl")]
        public static extern short cnc_rdopnlgnrl(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBGNRL b);
 
        /* write general signal image of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wropnlgnrl")]
        public static extern short cnc_wropnlgnrl(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBGNRL a);
 
        /* read general signal name of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopnlgsname")]
        public static extern short cnc_rdopnlgsname(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBRDNA b);
 
        /* write general signal name of software operator's panel  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wropnlgsname")]
        public static extern short cnc_wropnlgsname(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBRDNA a);
 
        /* get detail error */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getdtailerr")]
        public static extern short cnc_getdtailerr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBERR a);
 
        /* read informations of CNC parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparainfo")]
        public static extern short cnc_rdparainfo(ushort FlibHndl,
            short a, ushort b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPARAIF c);
 
        /* read informations of CNC setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsetinfo")]
        public static extern short cnc_rdsetinfo(ushort FlibHndl,
            short a, ushort b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSETIF c);
 
        /* read informations of CNC diagnose data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddiaginfo")]
        public static extern short cnc_rddiaginfo(ushort FlibHndl,
            short a, ushort b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDIAGIF c);
 
        /* read maximum, minimum and total number of CNC parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdparanum")]
        public static extern short cnc_rdparanum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPARANUM a);
 
        /* read maximum, minimum and total number of CNC setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsetnum")]
        public static extern short cnc_rdsetnum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSETNUM a);
 
        /* read maximum, minimum and total number of CNC diagnose data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddiagnum")]
        public static extern short cnc_rddiagnum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDIAGNUM a);
 
        /* get maximum valid figures and number of decimal places */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getfigure")]
        public static extern short cnc_getfigure(ushort FlibHndl,
            short a, out short b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c, [Out, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* read F-ROM information on CNC  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdfrominfo")]
        public static extern short cnc_rdfrominfo(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBFINFO b);
 
        /* start of reading F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromsvstart")]
        public static extern short cnc_fromsvstart(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, int c);
 
        /* read F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromsave")]
        public static extern short cnc_fromsave(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* end of reading F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromsvend")]
        public static extern short cnc_fromsvend(ushort FlibHndl);
 
        /* start of writing F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromldstart")]
        public static extern short cnc_fromldstart(ushort FlibHndl, short a, int b);
 
        /* write F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromload")]
        public static extern short cnc_fromload(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, ref int b);
 
        /* end of writing F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromldend")]
        public static extern short cnc_fromldend(ushort FlibHndl);
 
        /* delete F-ROM data on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromdelete")]
        public static extern short cnc_fromdelete(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, int c);
 
        /* read S-RAM information on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsraminfo")]
        public static extern short cnc_rdsraminfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSINFO a);
 
        /* start of reading S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srambkstart")]
        public static extern short cnc_srambkstart(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, int b);
 
        /* read S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srambackup")]
        public static extern short cnc_srambackup(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* end of reading S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srambkend")]
        public static extern short cnc_srambkend(ushort FlibHndl);
 
        /* read F-ROM information on CNC  */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getfrominfo")]
        public static extern short cnc_getfrominfo(ushort FlibHndl,
            short a, out short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBFINFORM c);
 
        /* start of reading F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromgetstart")]
        public static extern short cnc_fromgetstart(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromget")]
        public static extern short cnc_fromget(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* end of reading F-ROM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromgetend")]
        public static extern short cnc_fromgetend(ushort FlibHndl);
 
        /* start of writing F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromputstart")]
        public static extern short cnc_fromputstart(ushort FlibHndl, short a);
 
        /* write F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromput")]
        public static extern short cnc_fromput(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, ref int b);
 
        /* end of writing F-ROM data to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromputend")]
        public static extern short cnc_fromputend(ushort FlibHndl);
 
        /* delete F-ROM data on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_fromremove")]
        public static extern short cnc_fromremove(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read S-RAM information on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getsraminfo")]
        public static extern short cnc_getsraminfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSINFO a);
 
        /* start of reading S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramgetstart")]
        public static extern short cnc_sramgetstart(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* start of reading S-RAM data from CNC (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramgetstart2")]
        public static extern short cnc_sramgetstart2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramget")]
        public static extern short cnc_sramget(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* read S-RAM data from CNC (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramget2")]
        public static extern short cnc_sramget2(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* end of reading S-RAM data from CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramgetend")]
        public static extern short cnc_sramgetend(ushort FlibHndl);
 
        /* end of reading S-RAM data from CNC (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sramgetend2")]
        public static extern short cnc_sramgetend2(ushort FlibHndl);
 
        /* read number of S-RAM data kind on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsramnum")]
        public static extern short cnc_rdsramnum(ushort FlibHndl, out short a);
 
        /* read S-RAM data address information on CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsramaddr")]
        public static extern short cnc_rdsramaddr(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.LPStruct)] SRAMADDR b);
 
        /* get current NC data protection information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getlockstat")]
        public static extern short cnc_getlockstat(ushort FlibHndl, short a, out byte b);
 
        /* change NC data protection status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_chgprotbit")]
        public static extern short cnc_chgprotbit(ushort FlibHndl, short a, ref byte b, int c);
 
        /* transfer a file from host computer to CNC by FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvftpget")]
        public static extern short cnc_dtsvftpget(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* transfer a file from CNC to host computer by FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvftpput")]
        public static extern short cnc_dtsvftpput(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* get transfer status for FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvftpstat")]
        public static extern short cnc_dtsvftpstat(ushort FlibHndl);
 
        /* read file directory in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvrdpgdir")]
        public static extern short cnc_dtsvrdpgdir(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDSDIR c);
 
        /* delete files in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvdelete")]
        public static extern short cnc_dtsvdelete(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* down load from CNC (transfer a file from CNC to MMC) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvdownload")]
        public static extern short cnc_dtsvdownload(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* up load to CNC (transfer a file from MMC to CNC) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvupload")]
        public static extern short cnc_dtsvupload(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* close upload/download between Data Server and CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvcnclupdn")]
        public static extern short cnc_dtsvcnclupdn(ushort FlibHndl);
 
        /* get transfer status for up/down load */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvupdnstat")]
        public static extern short cnc_dtsvupdnstat(ushort FlibHndl);
 
        /* get file name for DNC operation in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvgetdncpg")]
        public static extern short cnc_dtsvgetdncpg(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* set program number of DNC oparation to CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvsetdncpg")]
        public static extern short cnc_dtsvsetdncpg(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read setting data for Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvrdset")]
        public static extern short cnc_dtsvrdset(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBDSSET a);
 
        /* write setting data for Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvwrset")]
        public static extern short cnc_dtsvwrset(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBDSSET a);
 
        /* check hard disk in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvchkdsk")]
        public static extern short cnc_dtsvchkdsk(ushort FlibHndl);
 
        /* format hard disk in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvhdformat")]
        public static extern short cnc_dtsvhdformat(ushort FlibHndl);
 
        /* save interface area in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvsavecram")]
        public static extern short cnc_dtsvsavecram(ushort FlibHndl);
 
        /* get interface area in Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvrdcram")]
        public static extern short cnc_dtsvrdcram(ushort FlibHndl, int a, ref int b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* read maintenance information for Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvmntinfo")]
        public static extern short cnc_dtsvmntinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDSMNT a);
 
        /* get Data Server mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvgetmode")]
        public static extern short cnc_dtsvgetmode(ushort FlibHndl, out short a);
 
        /* set Data Server mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvsetmode")]
        public static extern short cnc_dtsvsetmode(ushort FlibHndl, short a);
 
        /* read error message for Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvrderrmsg")]
        public static extern short cnc_dtsvrderrmsg(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* transfar file from Pc to Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvwrfile")]
        public static extern short cnc_dtsvwrfile(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, short c);
 
        /* transfar file from Data Server to Pc */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dtsvrdfile")]
        public static extern short cnc_dtsvrdfile(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, short c);
 
        /* read the loop gain for each axis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdloopgain")]
        public static extern short cnc_rdloopgain(ushort FlibHndl, out int a);
 
        /* read the actual current for each axis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcurrent")]
        public static extern short cnc_rdcurrent(ushort FlibHndl, out short a);
 
        /* read the actual speed for each axis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsrvspeed")]
        public static extern short cnc_rdsrvspeed(ushort FlibHndl, out int a);
 
        /* read the operation mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdopmode")]
        public static extern short cnc_rdopmode(ushort FlibHndl, out short a);
 
        /* read the position deviation S */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdposerrs")]
        public static extern short cnc_rdposerrs(ushort FlibHndl, out int a);
 
        /* read the position deviation S1 and S2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdposerrs2")]
        public static extern short cnc_rdposerrs2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPSER a);
 
        /* read the position deviation Z in the rigid tap mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdposerrz")]
        public static extern short cnc_rdposerrz(ushort FlibHndl, out int a);
 
        /* read the synchronous error in the synchronous control mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsynerrsy")]
        public static extern short cnc_rdsynerrsy(ushort FlibHndl, out int a);
 
        /* read the synchronous error in the rigid tap mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsynerrrg")]
        public static extern short cnc_rdsynerrrg(ushort FlibHndl, out int a);
 
        /* read the spindle alarm */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspdlalm")]
        public static extern short cnc_rdspdlalm(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the control input signal */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdctrldi")]
        public static extern short cnc_rdctrldi(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPDI a);
 
        /* read the control output signal */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdctrldo")]
        public static extern short cnc_rdctrldo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPDO a);
 
        /* read the number of controled spindle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdnspdl")]
        public static extern short cnc_rdnspdl(ushort FlibHndl, out short a);
 
        /* read data from FANUC BUS */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdfbusmem")]
        public static extern short cnc_rdfbusmem(ushort FlibHndl,
            short a, short b, int c, int d, [Out, MarshalAs(UnmanagedType.AsAny)] Object e);
 
        /* write data to FANUC BUS */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrfbusmem")]
        public static extern short cnc_wrfbusmem(ushort FlibHndl,
            short a, short b, int c, int d, [In, MarshalAs(UnmanagedType.AsAny)] Object e);
 
        /* read the parameter of wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdwaveprm")]
        public static extern short cnc_rdwaveprm(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBWAVE a);
 
        /* write the parameter of wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrwaveprm")]
        public static extern short cnc_wrwaveprm(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBWAVE a);
 
        /* read the parameter of wave diagnosis 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdwaveprm2")]
        public static extern short cnc_rdwaveprm2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBWVPRM a);
 
        /* write the parameter of wave diagnosis 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrwaveprm2")]
        public static extern short cnc_wrwaveprm2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBWVPRM a);
 
        /* start the sampling for wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wavestart")]
        public static extern short cnc_wavestart(ushort FlibHndl);
 
        /* stop the sampling for wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wavestop")]
        public static extern short cnc_wavestop(ushort FlibHndl);
 
        /* read the status of wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wavestat")]
        public static extern short cnc_wavestat(ushort FlibHndl, out short a);
 
        /* read the data of wave diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdwavedata")]
        public static extern short cnc_rdwavedata(ushort FlibHndl,
            short a, short b, int c, ref int d, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBWVDT e);
 
        /* read the parameter of wave diagnosis for remort diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrmtwaveprm")]
        public static extern short cnc_rdrmtwaveprm(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBRMTPRM a, short b);
 
        /* write the parameter of wave diagnosis for remort diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrrmtwaveprm")]
        public static extern short cnc_wrrmtwaveprm(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBRMTPRM a);
 
        /* start the sampling for wave diagnosis for remort diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rmtwavestart")]
        public static extern short cnc_rmtwavestart(ushort FlibHndl);
 
        /* stop the sampling for wave diagnosis for remort diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rmtwavestop")]
        public static extern short cnc_rmtwavestop(ushort FlibHndl);
 
        /* read the status of wave diagnosis for remort diagnosis*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rmtwavestat")]
        public static extern short cnc_rmtwavestat(ushort FlibHndl, out short a);
 
        /* read the data of wave diagnosis for remort diagnosis */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrmtwavedt")]
        public static extern short cnc_rdrmtwavedt(ushort FlibHndl,
            short a, int b, ref int c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBRMTDT d);
 
        /* read of address for PMC signal batch save */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsavsigadr")]
        public static extern short cnc_rdsavsigadr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSIGAD a, short b);
 
        /* write of address for PMC signal batch save */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrsavsigadr")]
        public static extern short cnc_wrsavsigadr(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSIGAD a, out short b);
 
        /* read of data for PMC signal batch save */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsavsigdata")]
        public static extern short cnc_rdsavsigdata(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c, ref short d);
 
        /* read M-code group data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmgrpdata")]
        public static extern short cnc_rdmgrpdata(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMGRP c);
 
        /* write M-code group data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmgrpdata")]
        public static extern short cnc_wrmgrpdata(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IDBMGRP a);
 
        /* read executing M-code group data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdexecmcode")]
        public static extern short cnc_rdexecmcode(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBEXEM c);
 
        /* read program restart M-code group data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrstrmcode")]
        public static extern short cnc_rdrstrmcode(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBRSTRM c);
 
        /* read processing time stamp data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdproctime")]
        public static extern short cnc_rdproctime(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPTIME a);
 
        /* read MDI program stat */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmdiprgstat")]
        public static extern short cnc_rdmdiprgstat(ushort FlibHndl, out ushort a);
 
        /* read program directory for processing time data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprgdirtime")]
        public static extern short cnc_rdprgdirtime(ushort FlibHndl,
            ref int a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGDIRTM c);
 
        /* read program directory 2 */
#if (!ONO8D)
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogdir2")]
        public static extern short cnc_rdprogdir2(ushort FlibHndl,
            short a, ref short b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGDIR2 d);
#else
    [DllImport("FWLIB32.dll", EntryPoint="cnc_rdprogdir2o8")]
    public static extern short cnc_rdprogdir2( ushort FlibHndl,
        short a, ref short b, ref short c, [Out,MarshalAs(UnmanagedType.LPStruct)] PRGDIR2 d );
#endif
 
        /* read program directory 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogdir3")]
        public static extern short cnc_rdprogdir3(ushort FlibHndl,
            short a, ref int b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGDIR3 d);
 
        /* read program directory 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdprogdir4")]
        public static extern short cnc_rdprogdir4(ushort FlibHndl,
            short a, int b, ref short c, [Out, MarshalAs(UnmanagedType.LPStruct)] PRGDIR4 d);
 
        /* read DNC file name for DNC1, DNC2, OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddncfname")]
        public static extern short cnc_rddncfname(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* write DNC file name for DNC1, DNC2, OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrdncfname")]
        public static extern short cnc_wrdncfname(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read communication parameter for DNC1, DNC2, OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcomparam")]
        public static extern short cnc_rdcomparam(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBCPRM a);
 
        /* write communication parameter for DNC1, DNC2, OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrcomparam")]
        public static extern short cnc_wrcomparam(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBCPRM a);
 
        /* read log message for DNC2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcomlogmsg")]
        public static extern short cnc_rdcomlogmsg(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read operator message for DNC1, DNC2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcomopemsg")]
        public static extern short cnc_rdcomopemsg(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read recieve message for OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrcvmsg")]
        public static extern short cnc_rdrcvmsg(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read send message for OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsndmsg")]
        public static extern short cnc_rdsndmsg(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* send message for OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sendmessage")]
        public static extern short cnc_sendmessage(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* clear message buffer for OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clrmsgbuff")]
        public static extern short cnc_clrmsgbuff(ushort FlibHndl, short a);
 
        /* read message recieve status for OSI-Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrcvstat")]
        public static extern short cnc_rdrcvstat(ushort FlibHndl, out ushort a);
 
        /* read interference check */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdintchk")]
        public static extern short cnc_rdintchk(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBINT e);
 
        /* write interference check */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrintchk")]
        public static extern short cnc_wrintchk(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBINT b);
 
        /* read interference check information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdintinfo")]
        public static extern short cnc_rdintinfo(ushort FlibHndl, out short a);
 
        /* read work coordinate shift */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdwkcdshft")]
        public static extern short cnc_rdwkcdshft(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBWCSF c);
 
        /* write work coordinate shift */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrwkcdshft")]
        public static extern short cnc_wrwkcdshft(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBWCSF b);
 
        /* read work coordinate shift measure */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdwkcdsfms")]
        public static extern short cnc_rdwkcdsfms(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBWCSF c);
 
        /* write work coordinate shift measure */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrwkcdsfms")]
        public static extern short cnc_wrwkcdsfms(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBWCSF b);
 
        /* stop the sampling for operator message history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopomhis")]
        public static extern short cnc_stopomhis(ushort FlibHndl);
 
        /* start the sampling for operator message history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startomhis")]
        public static extern short cnc_startomhis(ushort FlibHndl);
 
        /* read operator message history information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdomhisinfo")]
        public static extern short cnc_rdomhisinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOMIF a);
 
        /* read operator message history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdomhistry")]
        public static extern short cnc_rdomhistry(ushort FlibHndl,
            ushort a, ref ushort b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOMHIS c);
 
        /* read operater message history data F30i */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdomhistry2")]
        public static extern short cnc_rdomhistry2(ushort FlibHndl,
            ushort a, ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBOMHIS2 d);
 
        /* write external key operation history for F30i*/
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrkeyhistry")]
        public static extern short cnc_wrkeyhistry(ushort FlibHndl, byte a);
 
        /* clear operator message history */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clearomhis")]
        public static extern short cnc_clearomhis(ushort FlibHndl);
 
        /* read b-axis tool offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdbtofsr")]
        public static extern short cnc_rdbtofsr(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBBTO e);
 
        /* write b-axis tool offset value(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrbtofsr")]
        public static extern short cnc_wrbtofsr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBBTO b);
 
        /* read b-axis tool offset information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdbtofsinfo")]
        public static extern short cnc_rdbtofsinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBBTLINF a);
 
        /* read b-axis command */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdbaxis")]
        public static extern short cnc_rdbaxis(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBBAXIS a);
 
        /* read CNC system soft series and version */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsyssoft")]
        public static extern short cnc_rdsyssoft(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSS a);
 
        /* read CNC system soft series and version (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsyssoft2")]
        public static extern short cnc_rdsyssoft2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSS2 a);
 
        /* read CNC module configuration information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmdlconfig")]
        public static extern short cnc_rdmdlconfig(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMDLC a);
 
        /* read CNC module configuration information 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmdlconfig2")]
        public static extern short cnc_rdmdlconfig2(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read processing condition file (processing data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpscdproc")]
        public static extern short cnc_rdpscdproc(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPSCD c);
 
        /* write processing condition file (processing data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpscdproc")]
        public static extern short cnc_wrpscdproc(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPSCD c);
 
        /* read processing condition file (piercing data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpscdpirc")]
        public static extern short cnc_rdpscdpirc(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPIRC c);
 
        /* write processing condition file (piercing data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpscdpirc")]
        public static extern short cnc_wrpscdpirc(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPIRC c);
 
        /* read processing condition file (edging data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpscdedge")]
        public static extern short cnc_rdpscdedge(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBEDGE c);
 
        /* write processing condition file (edging data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpscdedge")]
        public static extern short cnc_wrpscdedge(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBEDGE c);
 
        /* read processing condition file (slope data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpscdslop")]
        public static extern short cnc_rdpscdslop(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLOP c);
 
        /* write processing condition file (slope data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpscdslop")]
        public static extern short cnc_wrpscdslop(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLOP c);
 
        /* read power controll duty data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlpwrdty")]
        public static extern short cnc_rdlpwrdty(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBLPWDT a);
 
        /* write power controll duty data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlpwrdty")]
        public static extern short cnc_wrlpwrdty(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBLPWDT a);
 
        /* read laser power data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlpwrdat")]
        public static extern short cnc_rdlpwrdat(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLOPDT a);
 
        /* read power complement */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlpwrcpst")]
        public static extern short cnc_rdlpwrcpst(ushort FlibHndl, out short a);
 
        /* write power complement */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlpwrcpst")]
        public static extern short cnc_wrlpwrcpst(ushort FlibHndl, short a);
 
        /* read laser assist gas selection */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlagslt")]
        public static extern short cnc_rdlagslt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBLAGSL a);
 
        /* write laser assist gas selection */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlagslt")]
        public static extern short cnc_wrlagslt(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBLAGSL a);
 
        /* read laser assist gas flow */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlagst")]
        public static extern short cnc_rdlagst(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBLAGST a);
 
        /* write laser assist gas flow */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlagst")]
        public static extern short cnc_wrlagst(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBLAGST a);
 
        /* read laser power for edge processing */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdledgprc")]
        public static extern short cnc_rdledgprc(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBLEGPR a);
 
        /* write laser power for edge processing */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrledgprc")]
        public static extern short cnc_wrledgprc(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBLEGPR a);
 
        /* read laser power for piercing */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlprcprc")]
        public static extern short cnc_rdlprcprc(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBLPCPR a);
 
        /* write laser power for piercing */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlprcprc")]
        public static extern short cnc_wrlprcprc(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBLPCPR a);
 
        /* read laser command data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlcmddat")]
        public static extern short cnc_rdlcmddat(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLCMDT a);
 
        /* read displacement */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdldsplc")]
        public static extern short cnc_rdldsplc(ushort FlibHndl, out short a);
 
        /* write displacement */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrldsplc")]
        public static extern short cnc_wrldsplc(ushort FlibHndl, short a);
 
        /* read error for axis z */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlerrz")]
        public static extern short cnc_rdlerrz(ushort FlibHndl, out short a);
 
        /* read active number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlactnum")]
        public static extern short cnc_rdlactnum(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLACTN a);
 
        /* read laser comment */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlcmmt")]
        public static extern short cnc_rdlcmmt(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLCMMT a);
 
        /* read laser power select */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlpwrslt")]
        public static extern short cnc_rdlpwrslt(ushort FlibHndl, out short a);
 
        /* write laser power select */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlpwrslt")]
        public static extern short cnc_wrlpwrslt(ushort FlibHndl, short a);
 
        /* read laser power controll */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlpwrctrl")]
        public static extern short cnc_rdlpwrctrl(ushort FlibHndl, out short a);
 
        /* write laser power controll */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrlpwrctrl")]
        public static extern short cnc_wrlpwrctrl(ushort FlibHndl, short a);
 
        /* read power correction factor history data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpwofsthis")]
        public static extern short cnc_rdpwofsthis(ushort FlibHndl,
            int a, ref int b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPWOFST c);
 
        /* read management time */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmngtime")]
        public static extern short cnc_rdmngtime(ushort FlibHndl,
            int a, ref int b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBMNGTIME c);
 
        /* write management time */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmngtime")]
        public static extern short cnc_wrmngtime(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBMNGTIME b);
 
        /* read data related to electrical discharge at power correction ends */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddischarge")]
        public static extern short cnc_rddischarge(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDISCHRG a);
 
        /* read alarm history data related to electrical discharg */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddischrgalm")]
        public static extern short cnc_rddischrgalm(ushort FlibHndl,
            int a, ref int b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBDISCHRGALM c);
 
        /* get date and time from cnc */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_gettimer")]
        public static extern short cnc_gettimer(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTIMER a);
 
        /* set date and time for cnc */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_settimer")]
        public static extern short cnc_settimer(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTIMER a);
 
        /* read timer data from cnc */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtimer")]
        public static extern short cnc_rdtimer(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTIME b);
 
        /* write timer data for cnc */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtimer")]
        public static extern short cnc_wrtimer(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTIME b);
 
        /* read tool controll data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtlctldata")]
        public static extern short cnc_rdtlctldata(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLCTL a);
 
        /* write tool controll data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtlctldata")]
        public static extern short cnc_wrtlctldata(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLCTL a);
 
        /* read tool data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtooldata")]
        public static extern short cnc_rdtooldata(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLDT c);
 
        /* read tool data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtooldata")]
        public static extern short cnc_wrtooldata(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLDT c);
 
        /* read multi tool data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmultitldt")]
        public static extern short cnc_rdmultitldt(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBMLTTL c);
 
        /* write multi tool data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmultitldt")]
        public static extern short cnc_wrmultitldt(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBMLTTL c);
 
        /* read multi tap data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmtapdata")]
        public static extern short cnc_rdmtapdata(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBMTAP c);
 
        /* write multi tap data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmtapdata")]
        public static extern short cnc_wrmtapdata(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBMTAP c);
 
        /* read multi-piece machining number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmultipieceno")]
        public static extern short cnc_rdmultipieceno(ushort FlibHndl, out int a);
 
        /* read tool information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtoolinfo")]
        public static extern short cnc_rdtoolinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPTLINF a);
 
        /* read safetyzone data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsafetyzone")]
        public static extern short cnc_rdsafetyzone(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSAFE c);
 
        /* write safetyzone data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrsafetyzone")]
        public static extern short cnc_wrsafetyzone(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSAFE c);
 
        /* read toolzone data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdtoolzone")]
        public static extern short cnc_rdtoolzone(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBTLZN c);
 
        /* write toolzone data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrtoolzone")]
        public static extern short cnc_wrtoolzone(ushort FlibHndl,
            short a, ref short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBTLZN c);
 
        /* read active toolzone data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdacttlzone")]
        public static extern short cnc_rdacttlzone(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBACTTLZN a);
 
        /* read setzone number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsetzone")]
        public static extern short cnc_rdsetzone(ushort FlibHndl, out short a);
 
        /* write setzone number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrsetzone")]
        public static extern short cnc_wrsetzone(ushort FlibHndl, short a);
 
        /* read block restart information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdbrstrinfo")]
        public static extern short cnc_rdbrstrinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBBRS a);
 
        /* read menu switch signal */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmenuswitch")]
        public static extern short cnc_rdmenuswitch(ushort FlibHndl, out short a);
 
        /* write menu switch signal */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrmenuswitch")]
        public static extern short cnc_wrmenuswitch(ushort FlibHndl, short a, short b);
 
        /* read tool radius offset for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdradofs")]
        public static extern short cnc_rdradofs(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBROFS a);
 
        /* read tool length offset for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdlenofs")]
        public static extern short cnc_rdlenofs(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBLOFS a);
 
        /* read fixed cycle for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdfixcycle")]
        public static extern short cnc_rdfixcycle(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBFIX a);
 
        /* read coordinate rotate for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcdrotate")]
        public static extern short cnc_rdcdrotate(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBROT a);
 
        /* read 3D coordinate convert for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dcdcnv")]
        public static extern short cnc_rd3dcdcnv(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB3DCD a);
 
        /* read programable mirror image for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdmirimage")]
        public static extern short cnc_rdmirimage(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBMIR a);
 
        /* read scaling for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdscaling")]
        public static extern short cnc_rdscaling(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSCL a);
 
        /* read 3D tool offset for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dtofs")]
        public static extern short cnc_rd3dtofs(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB3DTO a);
 
        /* read tool position offset for position data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdposofs")]
        public static extern short cnc_rdposofs(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPOFS a);
 
        /* read hpcc setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhpccset")]
        public static extern short cnc_rdhpccset(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBHPST a);
 
        /* write hpcc setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhpccset")]
        public static extern short cnc_wrhpccset(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBHPST a);
 
        /* hpcc data auto setting data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_hpccatset")]
        public static extern short cnc_hpccatset(ushort FlibHndl);
 
        /* read hpcc tuning data ( parameter input ) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhpcctupr")]
        public static extern short cnc_rdhpcctupr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBHPPR a);
 
        /* write hpcc tuning data ( parameter input ) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhpcctupr")]
        public static extern short cnc_wrhpcctupr(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBHPPR a);
 
        /* read hpcc tuning data ( acc input ) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdhpcctuac")]
        public static extern short cnc_rdhpcctuac(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBHPAC a);
 
        /* write hpcc tuning data ( acc input ) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrhpcctuac")]
        public static extern short cnc_wrhpcctuac(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBHPAC a);
 
        /* hpcc data auto tuning */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_hpccattune")]
        public static extern short cnc_hpccattune(ushort FlibHndl, short a, out short b);
 
        /* read hpcc fine level */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_hpccactfine")]
        public static extern short cnc_hpccactfine(ushort FlibHndl, out short a);
 
        /* select hpcc fine level */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_hpccselfine")]
        public static extern short cnc_hpccselfine(ushort FlibHndl, short a);
 
        /* read active fixture offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdactfixofs")]
        public static extern short cnc_rdactfixofs(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBZOFS b);
 
        /* read fixture offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdfixofs")]
        public static extern short cnc_rdfixofs(ushort FlibHndl,
            short a, short b, short c, short d, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBZOR e);
 
        /* write fixture offset */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrfixofs")]
        public static extern short cnc_wrfixofs(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBZOR b);
 
        /* read tip of tool for 3D handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dtooltip")]
        public static extern short cnc_rd3dtooltip(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB3DHDL a);
 
        /* read pulse for 3D handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dpulse")]
        public static extern short cnc_rd3dpulse(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB3DPLS a);
 
        /* read move overrlap of tool for 3D handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dmovrlap")]
        public static extern short cnc_rd3dmovrlap(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODB3DHDL a);
 
        /* read change offset for 3D handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rd3dofschg")]
        public static extern short cnc_rd3dofschg(ushort FlibHndl, ref int a);
 
        /* clear pulse and change offset for 3D handle */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clr3dplsmov")]
        public static extern short cnc_clr3dplsmov(ushort FlibHndl, short a);
 
        /* cycle start */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_start")]
        public static extern short cnc_start(ushort FlibHndl);
 
        /* reset CNC */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_reset")]
        public static extern short cnc_reset(ushort FlibHndl);
 
        /* reset CNC 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_reset2")]
        public static extern short cnc_reset2(ushort FlibHndl);
 
        /* read axis name */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdaxisname")]
        public static extern short cnc_rdaxisname(ushort FlibHndl,
            ref short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXISNAME b);
 
        /* read spindle name */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdspdlname")]
        public static extern short cnc_rdspdlname(ushort FlibHndl,
            ref short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSPDLNAME b);
 
        /* read extended axis name */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_exaxisname")]
        public static extern short cnc_exaxisname(ushort FlibHndl,
            short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBEXAXISNAME c);
 
        /* read SRAM variable area for C language executor */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcexesram")]
        public static extern short cnc_rdcexesram(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* write SRAM variable area for C language executor */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrcexesram")]
        public static extern short cnc_wrcexesram(ushort FlibHndl, int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, ref int c);
 
        /* read maximum size and linear address of SRAM variable area for C language executor */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cexesraminfo")]
        public static extern short cnc_cexesraminfo(ushort FlibHndl, out short a, out int b, out int c);
 
        /* read maximum size of SRAM variable area for C language executor */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cexesramsize")]
        public static extern short cnc_cexesramsize(ushort FlibHndl, out int a);
 
        /* read additional workpiece coordinate systems number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcoordnum")]
        public static extern short cnc_rdcoordnum(ushort FlibHndl, out short a);
 
        /* converts from FANUC code to Shift JIS code */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_ftosjis")]
        public static extern short cnc_ftosjis(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* Set the unsolicited message parameters */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrunsolicprm")]
        public static extern short cnc_wrunsolicprm(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBUNSOLIC b);
 
        /* Get the unsolicited message parameters */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdunsolicprm")]
        public static extern short cnc_rdunsolicprm(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBUNSOLIC b);
 
        /* Start of unsolicited message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_unsolicstart")]
        public static extern short cnc_unsolicstart(ushort FlibHndl, short a, int hWnd, uint c, short d, out short e);
 
        /* End of unsolicited message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_unsolicstop")]
        public static extern short cnc_unsolicstop(ushort FlibHndl, short a);
 
        /* Reads the unsolicited message data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdunsolicmsg")]
        public static extern short cnc_rdunsolicmsg(short a, [In, Out] IDBUNSOLICMSG b);
 
        /* read machine specific maintenance item */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpm_mcnitem")]
        public static extern short cnc_rdpm_mcnitem(ushort FlibHndl, short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBITEM c);
 
        /* write machine specific maintenance item */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpm_mcnitem")]
        public static extern short cnc_wrpm_mcnitem(ushort FlibHndl, short a, short b, [In, MarshalAs(UnmanagedType.LPStruct)] IODBITEM c);
 
        /* read cnc maintenance item */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpm_cncitem")]
        public static extern short cnc_rdpm_cncitem(ushort FlibHndl, short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBITEM c);
 
        /* read maintenance item status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdpm_item")]
        public static extern short cnc_rdpm_item(ushort FlibHndl, short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMAINTE c);
 
        /* write maintenance item status */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrpm_item")]
        public static extern short cnc_wrpm_item(ushort FlibHndl, short a, short b, short c, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPMAINTE d);
 
        /* Display of optional message */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_dispoptmsg")]
        public static extern short cnc_dispoptmsg(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* Reading of answer for optional message display */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_optmsgans")]
        public static extern short cnc_optmsgans(ushort FlibHndl, out short a);
 
        /* Get CNC Model */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getcncmodel")]
        public static extern short cnc_getcncmodel(ushort FlibHndl, out short a);
 
        /* read number of repeats */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrepeatval")]
        public static extern short cnc_rdrepeatval(ushort FlibHndl, out int a);
 
        /* read CNC system hard info */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsyshard")]
        public static extern short cnc_rdsyshard(ushort FlibHndl, short a, ref short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSH c);
 
        /* read CNC system soft series and version (3) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdsyssoft3")]
        public static extern short cnc_rdsyssoft3(ushort FlibHndl, short a, ref short b, out short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSS3 d);
 
        /* read digit of program number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_progdigit")]
        public static extern short cnc_progdigit(ushort FlibHndl, out short a);
 
        /* read CNC system path information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sysinfo_ex")]
        public static extern short cnc_sysinfo_ex(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSYSEX a);
 
        /*------------------*/
        /* CNC : SERCOS I/F */
        /*------------------*/
 
        /* Get reservation of service channel for SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrsvchnl")]
        public static extern short cnc_srcsrsvchnl(ushort FlibHndl);
 
        /* Read ID information of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrdidinfo")]
        public static extern short cnc_srcsrdidinfo(ushort FlibHndl,
            int a, short b, short c, [Out, MarshalAs(UnmanagedType.AsAny)] IODBIDINF d);
 
        /* Write ID information of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcswridinfo")]
        public static extern short cnc_srcswridinfo(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBIDINF a);
 
        /* Start of reading operation data from drive of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsstartrd")]
        public static extern short cnc_srcsstartrd(ushort FlibHndl, int a, short b);
 
        /* Start of writing operation data to drive of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsstartwrt")]
        public static extern short cnc_srcsstartwrt(ushort FlibHndl, int a, short b);
 
        /* Stop of reading/writing operation data from/to drive of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsstopexec")]
        public static extern short cnc_srcsstopexec(ushort FlibHndl);
 
        /* Get execution status of reading/writing operation data of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrdexstat")]
        public static extern short cnc_srcsrdexstat(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSRCSST a);
 
        /* Read operation data from data buffer for SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrdopdata")]
        public static extern short cnc_srcsrdopdata(ushort FlibHndl, int a, ref int b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* Write operation data to data buffer for SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcswropdata")]
        public static extern short cnc_srcswropdata(ushort FlibHndl, int a, int b, [In, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* Free reservation of service channel for SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsfreechnl")]
        public static extern short cnc_srcsfreechnl(ushort FlibHndl);
 
        /* Read drive assign of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrdlayout")]
        public static extern short cnc_srcsrdlayout(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSRCSLYT a);
 
        /* Read communication phase of drive of SERCOS I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_srcsrddrvcp")]
        public static extern short cnc_srcsrddrvcp(ushort FlibHndl, out short a);
 
 
        /*----------------------------*/
        /* CNC : Graphic command data */
        /*----------------------------*/
 
        /* Start drawing position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startdrawpos")]
        public static extern short cnc_startdrawpos(ushort FlibHndl);
 
        /* Stop drawing position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopdrawpos")]
        public static extern short cnc_stopdrawpos(ushort FlibHndl);
 
        /* Start dynamic graphic */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startdyngrph")]
        public static extern short cnc_startdyngrph(ushort FlibHndl);
 
        /* Stop dynamic graphic */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopdyngrph")]
        public static extern short cnc_stopdyngrph(ushort FlibHndl);
 
        /* Read graphic command data */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrphcmd")]
        public static extern short cnc_rdgrphcmd(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* Update graphic command read pointer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrgrphcmdptr")]
        public static extern short cnc_wrgrphcmdptr(ushort FlibHndl, short a);
 
        /* Read cancel flag */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdgrphcanflg")]
        public static extern short cnc_rdgrphcanflg(ushort FlibHndl, out short a);
 
        /* Clear graphic command */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clrgrphcmd")]
        public static extern short cnc_clrgrphcmd(ushort FlibHndl);
 
 
        /*---------------------------*/
        /* CNC : Servo learning data */
        /*---------------------------*/
 
        /* Servo learning data read start */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtstartrd")]
        public static extern short cnc_svdtstartrd(ushort FlibHndl, short a);
 
        /* Servo learning data write start */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtstartwr")]
        public static extern short cnc_svdtstartwr(ushort FlibHndl, short a);
 
        /* Servo learning data read end */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtendrd")]
        public static extern short cnc_svdtendrd(ushort FlibHndl);
 
        /* Servo learning data write end */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtendwr")]
        public static extern short cnc_svdtendwr(ushort FlibHndl);
 
        /* Servo learning data read/write stop */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtstopexec")]
        public static extern short cnc_svdtstopexec(ushort FlibHndl);
 
        /* Servo learning data read from I/F buffer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtrddata")]
        public static extern short cnc_svdtrddata(ushort FlibHndl,
            out short a, ref int b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* Servo learning data write to I/F buffer */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_svdtwrdata")]
        public static extern short cnc_svdtwrdata(ushort FlibHndl,
            out short a, ref int b, [In, MarshalAs(UnmanagedType.AsAny)] Object c);
 
 
        /*----------------------------*/
        /* CNC : Servo Guide          */
        /*----------------------------*/
        /* Servo Guide (Channel data set) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdsetchnl")]
        public static extern short cnc_sdsetchnl(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IDBCHAN b);
 
        /* Servo Guide (Channel data clear) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdclrchnl")]
        public static extern short cnc_sdclrchnl(ushort FlibHndl);
 
        /* Servo Guide (Sampling start) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdstartsmpl")]
        public static extern short cnc_sdstartsmpl(ushort FlibHndl, short a, int b, [Out, MarshalAs(UnmanagedType.AsAny)] Object c);
 
        /* Servo Guide (Sampling cancel) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdcancelsmpl")]
        public static extern short cnc_sdcancelsmpl(ushort FlibHndl);
 
        /* Servo Guide (read Sampling data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdreadsmpl")]
        public static extern short cnc_sdreadsmpl(ushort FlibHndl,
            out short a, int b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSD c);
 
        /* Servo Guide (Sampling end) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdendsmpl")]
        public static extern short cnc_sdendsmpl(ushort FlibHndl);
 
        /* Servo Guide (read 1 shot data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sdread1shot")]
        public static extern short cnc_sdread1shot(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* Servo feedback data (Channel data set) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbsetchnl")]
        public static extern short cnc_sfbsetchnl(ushort FlibHndl,
            short a, int b, [In, MarshalAs(UnmanagedType.LPStruct)] IDBSFBCHAN c);
 
        /* Servo feedback data (Channel data clear) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbclrchnl")]
        public static extern short cnc_sfbclrchnl(ushort FlibHndl);
 
        /* Servo feedback data (Sampling start) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbstartsmpl")]
        public static extern short cnc_sfbstartsmpl(ushort FlibHndl, short a, int b);
 
        /* Servo feedback data (Sampling cancel) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbcancelsmpl")]
        public static extern short cnc_sfbcancelsmpl(ushort FlibHndl);
 
        /* Servo feedback data (read Sampling data) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbreadsmpl")]
        public static extern short cnc_sfbreadsmpl(ushort FlibHndl,
            out short a, int b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSD c);
 
        /* Servo feedback data (Sampling end) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_sfbendsmpl")]
        public static extern short cnc_sfbendsmpl(ushort FlibHndl);
 
 
        /*----------------------------*/
        /* CNC : NC display function  */
        /*----------------------------*/
 
        /* Start NC display */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startnccmd")]
        public static extern short cnc_startnccmd(ushort FlibHndl);
 
        /* Start NC display (2) */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startnccmd2")]
        public static extern short cnc_startnccmd2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* Stop NC display */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopnccmd")]
        public static extern short cnc_stopnccmd(ushort FlibHndl);
 
        /* Get NC display mode */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getdspmode")]
        public static extern short cnc_getdspmode(ushort FlibHndl, out short a);
 
 
        /*------------------------------------*/
        /* CNC : Remote diagnostics function  */
        /*------------------------------------*/
 
        /* Start remote diagnostics function */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startrmtdgn")]
        public static extern short cnc_startrmtdgn(ushort FlibHndl);
 
        /* Stop remote diagnostics function */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stoprmtdgn")]
        public static extern short cnc_stoprmtdgn(ushort FlibHndl);
 
        /* Read data from remote diagnostics I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdrmtdgn")]
        public static extern short cnc_rdrmtdgn(ushort FlibHndl, out int a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* Write data to remote diagnostics I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrrmtdgn")]
        public static extern short cnc_wrrmtdgn(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* Set CommStatus of remote diagnostics I/F area */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrcommstatus")]
        public static extern short cnc_wrcommstatus(ushort FlibHndl, short a);
 
        /* Check remote diagnostics I/F */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_chkrmtdgn")]
        public static extern short cnc_chkrmtdgn(ushort FlibHndl);
 
 
        /*-------------------------*/
        /* CNC : FS18-LN function  */
        /*-------------------------*/
 
        /* read allowance */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allowance")]
        public static extern short cnc_allowance(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
        /* read allowanced state */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allowcnd")]
        public static extern short cnc_allowcnd(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBCAXIS c);
 
        /* set work zero */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_workzero")]
        public static extern short cnc_workzero(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBZOFS b);
 
        /* set slide position */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_slide")]
        public static extern short cnc_slide(ushort FlibHndl,
            short a, short b, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBAXIS c);
 
 
        /*----------------------------------*/
        /* CNC: Teaching data I/F function  */
        /*----------------------------------*/
 
        /* Teaching data get start */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_startgetdgdat")]
        public static extern short cnc_startgetdgdat(ushort FlibHndl);
 
        /* Teaching data get stop */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_stopgetdgdat")]
        public static extern short cnc_stopgetdgdat(ushort FlibHndl);
 
        /* Teaching data read */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rddgdat")]
        public static extern short cnc_rddgdat(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* Teaching data read pointer write */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrdgdatptr")]
        public static extern short cnc_wrdgdatptr(ushort FlibHndl, short a);
 
        /* Teaching data clear */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_clrdgdat")]
        public static extern short cnc_clrdgdat(ushort FlibHndl);
 
 
        /*---------------------------------*/
        /* CNC : C-EXE SRAM file function  */
        /*---------------------------------*/
 
        /* open C-EXE SRAM file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_opencexefile")]
        public static extern short cnc_opencexefile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, short b, short c);
 
        /* close C-EXE SRAM file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_closecexefile")]
        public static extern short cnc_closecexefile(ushort FlibHndl);
 
        /* read C-EXE SRAM file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdcexefile")]
        public static extern short cnc_rdcexefile(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a, ref uint b);
 
        /* write C-EXE SRAM file */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_wrcexefile")]
        public static extern short cnc_wrcexefile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, ref uint b);
 
        /* read C-EXE SRAM disk directory */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_cexedirectory")]
        public static extern short cnc_cexedirectory(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.AsAny)] Object a, ref ushort b, ushort c, [Out, MarshalAs(UnmanagedType.LPStruct)] CFILEINFO d);
 
 
        /*-----*/
        /* PMC */
        /*-----*/
 
        /* read message from PMC to MMC */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdmsg")]
        public static extern short pmc_rdmsg(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write message from MMC to PMC */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrmsg")]
        public static extern short pmc_wrmsg(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read message from PMC to MMC(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_crdmsg")]
        public static extern short pmc_crdmsg(ushort FlibHndl, ref short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write message from MMC to PMC(conditional) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_cwrmsg")]
        public static extern short pmc_cwrmsg(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read PMC data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcrng")]
        public static extern short pmc_rdpmcrng(ushort FlibHndl,
            short a, short b, ushort c, ushort d, ushort e, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMC0 f);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcrng")]
        public static extern short pmc_rdpmcrng(ushort FlibHndl,
            short a, short b, ushort c, ushort d, ushort e, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMC1 f);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcrng")]
        public static extern short pmc_rdpmcrng(ushort FlibHndl,
            short a, short b, ushort c, ushort d, ushort e, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMC2 f);
 
        /* write PMC data(area specified) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcrng")]
        public static extern short pmc_wrpmcrng(ushort FlibHndl, ushort a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPMC0 b);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcrng")]
        public static extern short pmc_wrpmcrng(ushort FlibHndl, ushort a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPMC1 b);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcrng")]
        public static extern short pmc_wrpmcrng(ushort FlibHndl, ushort a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPMC2 b);
 
        /* read data from extended backup memory */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdkpm")]
        public static extern short pmc_rdkpm(ushort FlibHndl, uint a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, ushort c);
 
        /* write data to extended backup memory */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrkpm")]
        public static extern short pmc_wrkpm(ushort FlibHndl, uint a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, ushort c);
 
        /* read data from extended backup memory 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdkpm2")]
        public static extern short pmc_rdkpm2(ushort FlibHndl, uint a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b, uint c);
 
        /* write data to extended backup memory 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrkpm2")]
        public static extern short pmc_wrkpm2(ushort FlibHndl, uint a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, uint c);
 
        /* read maximum size of extended backup memory */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_kpmsiz")]
        public static extern short pmc_kpmsiz(ushort FlibHndl, out uint a);
 
        /* read informations of PMC data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcinfo")]
        public static extern short pmc_rdpmcinfo(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMCINF b);
 
        /* read PMC parameter data table contorol data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdcntldata")]
        public static extern short pmc_rdcntldata(ushort FlibHndl,
            short a, short b, short c, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMCCNTL d);
 
        /* write PMC parameter data table contorol data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrcntldata")]
        public static extern short pmc_wrcntldata(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPMCCNTL b);
 
        /* read PMC parameter data table contorol data group number */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdcntlgrp")]
        public static extern short pmc_rdcntlgrp(ushort FlibHndl, out short a);
 
        /* write PMC parameter data table contorol data group number */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrcntlgrp")]
        public static extern short pmc_wrcntlgrp(ushort FlibHndl, short a);
 
        /* read PMC alarm message */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdalmmsg")]
        public static extern short pmc_rdalmmsg(ushort FlibHndl,
            short a, ref short b, out short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMCALM d);
 
        /* get detail error for pmc */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_getdtailerr")]
        public static extern short pmc_getdtailerr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMCERR a);
 
        /* read PMC memory data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcmem")]
        public static extern short pmc_rdpmcmem(ushort FlibHndl,
            short a, int b, int c, [Out, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* write PMC memory data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcmem")]
        public static extern short pmc_wrpmcmem(ushort FlibHndl,
            short a, int b, int c, [In, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* read PMC-SE memory data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcsemem")]
        public static extern short pmc_rdpmcsemem(ushort FlibHndl,
            short a, int b, int c, [Out, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* write PMC-SE memory data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcsemem")]
        public static extern short pmc_wrpmcsemem(ushort FlibHndl,
            short a, int b, int c, [In, MarshalAs(UnmanagedType.AsAny)] Object d);
 
        /* read pmc title data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmctitle")]
        public static extern short pmc_rdpmctitle(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMCTITLE a);
 
        /* read PMC parameter start */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdprmstart")]
        public static extern short pmc_rdprmstart(ushort FlibHndl);
 
        /* read PMC parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcparam")]
        public static extern short pmc_rdpmcparam(ushort FlibHndl, ref int a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read PMC parameter end */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdprmend")]
        public static extern short pmc_rdprmend(ushort FlibHndl);
 
        /* write PMC parameter start */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrprmstart")]
        public static extern short pmc_wrprmstart(ushort FlibHndl);
 
        /* write PMC parameter */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrpmcparam")]
        public static extern short pmc_wrpmcparam(ushort FlibHndl, ref int a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write PMC parameter end */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wrprmend")]
        public static extern short pmc_wrprmend(ushort FlibHndl);
 
        /* read PMC data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcrng_ext")]
        public static extern short pmc_rdpmcrng_ext(ushort FlibHndl,
            short a, [In, Out, MarshalAs(UnmanagedType.LPStruct)] IODBPMCEXT b);
 
        /* write PMC I/O link assigned data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_wriolinkdat")]
        public static extern short pmc_wriolinkdat(ushort FlibHndl, uint a, [In, MarshalAs(UnmanagedType.AsAny)] Object b, uint c);
 
        /* read PMC address information */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_rdpmcaddr")]
        public static extern short pmc_rdpmcaddr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPMCADR a);
 
        /* select PMC unit */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_select_pmc_unit")]
        public static extern short pmc_select_pmc_unit(ushort FlibHndl, int a);
 
        /* get current PMC unit */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_get_current_pmc_unit")]
        public static extern short pmc_get_current_pmc_unit(ushort FlibHndl, ref int a);
 
        /* get number of PMC */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_get_number_of_pmc")]
        public static extern short pmc_get_number_of_pmc(ushort FlibHndl, ref int a);
 
        /* get PMC unit types */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_get_pmc_unit_types")]
        public static extern short pmc_get_pmc_unit_types(ushort FlibHndl, int[] a, ref int b);
 
        /* set PMC Timer type */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_set_timer_type")]
        public static extern short pmc_set_timer_type(ushort FlibHndl, ushort a, ushort b, ref short c);
 
        /* get PMC Timer type */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_get_timer_type")]
        public static extern short pmc_get_timer_type(ushort FlibHndl, ushort a, ushort b, ref short c);
 
        /*----------------------------*/
        /* PMC : PROFIBUS function    */
        /*----------------------------*/
 
        /* read PROFIBUS configration data */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdconfig")]
        public static extern short pmc_prfrdconfig(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBPRFCNF a);
 
        /* read bus parameter for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdbusprm")]
        public static extern short pmc_prfrdbusprm(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBBUSPRM a);
 
        /* write bus parameter for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrbusprm")]
        public static extern short pmc_prfwrbusprm(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBBUSPRM a);
 
        /* read slave parameter for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvprm")]
        public static extern short pmc_prfrdslvprm(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM b);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvprm")]
        public static extern short pmc_prfrdslvprm(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM2 b);
 
        /* write slave parameter for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrslvprm")]
        public static extern short pmc_prfwrslvprm(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM b);
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrslvprm")]
        public static extern short pmc_prfwrslvprm(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM2 b);
 
        /* read allocation address for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdallcadr")]
        public static extern short pmc_prfrdallcadr(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBPRFADR b);
 
        /* set allocation address for master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrallcadr")]
        public static extern short pmc_prfwrallcadr(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBPRFADR b);
 
        /* read allocation address for slave function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvaddr")]
        public static extern short pmc_prfrdslvaddr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLVADR a);
 
        /* set allocation address for slave function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrslvaddr")]
        public static extern short pmc_prfwrslvaddr(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLVADR a);
 
        /* read status for slave function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvstat")]
        public static extern short pmc_prfrdslvstat(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBSLVST a);
 
        /* Reads slave index data of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvid")]
        public static extern short pmc_prfrdslvid(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLVID b);
 
        /* Writes slave index data of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrslvid")]
        public static extern short pmc_prfwrslvid(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLVID b);
 
        /* Reads slave parameter of master function(2) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdslvprm2")]
        public static extern short pmc_prfrdslvprm2(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM3 b);
 
        /* Writes slave parameter of master function(2) */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrslvprm2")]
        public static extern short pmc_prfwrslvprm2(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBSLVPRM3 b);
 
        /* Reads DI/DO parameter of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrddido")]
        public static extern short pmc_prfrddido(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBDIDO b);
 
        /* Writes DI/DO parameter of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrdido")]
        public static extern short pmc_prfwrdido(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.LPStruct)] IODBDIDO b);
 
        /* Reads indication address of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdindiadr")]
        public static extern short pmc_prfrdindiadr(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBINDEADR a);
 
        /* Writes indication address of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwrindiadr")]
        public static extern short pmc_prfwrindiadr(ushort FlibHndl, [In, MarshalAs(UnmanagedType.LPStruct)] IODBINDEADR a);
 
        /* Reads operation mode of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfrdopmode")]
        public static extern short pmc_prfrdopmode(ushort FlibHndl, ref short a);
 
        /* Writes operation mode of master function */
        [DllImport("FWLIB32.dll", EntryPoint = "pmc_prfwropmode")]
        public static extern short pmc_prfwropmode(ushort FlibHndl, short a, ref short b);
 
        /*-----------------------------------------------*/
        /* DS : Data server & Ethernet board function    */
        /*-----------------------------------------------*/
 
        /* read the parameter of the Ethernet board */
        [DllImport("FWLIB32.dll", EntryPoint = "etb_rdparam")]
        public static extern short etb_rdparam(ushort FlibHndl,
            short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBETP_TCP b);
        [DllImport("FWLIB32.dll", EntryPoint = "etb_rdparam")]
        public static extern short etb_rdparam(ushort FlibHndl,
            short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBETP_HOST b);
        [DllImport("FWLIB32.dll", EntryPoint = "etb_rdparam")]
        public static extern short etb_rdparam(ushort FlibHndl,
            short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBETP_FTP b);
        [DllImport("FWLIB32.dll", EntryPoint = "etb_rdparam")]
        public static extern short etb_rdparam(ushort FlibHndl,
            short a, [Out, MarshalAs(UnmanagedType.LPStruct)] IODBETP_ETB b);
 
        /* write the parameter of the Ethernet board */
        [DllImport("FWLIB32.dll", EntryPoint = "etb_wrparam")]
        public static extern short etb_wrparam(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.LPStruct)] IODBETP_TCP a);
        [DllImport("FWLIB32.dll", EntryPoint = "etb_wrparam")]
        public static extern short etb_wrparam(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.LPStruct)] IODBETP_HOST a);
        [DllImport("FWLIB32.dll", EntryPoint = "etb_wrparam")]
        public static extern short etb_wrparam(ushort FlibHndl,
            [In, MarshalAs(UnmanagedType.LPStruct)] IODBETP_FTP a);
 
        /* read the error message of the Ethernet board */
        [DllImport("FWLIB32.dll", EntryPoint = "etb_rderrmsg")]
        public static extern short etb_rderrmsg(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBETMSG b);
 
        /* read the mode of the Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdmode")]
        public static extern short ds_rdmode(ushort FlibHndl, ref short a);
 
        /* write the mode of the Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrmode")]
        public static extern short ds_wrmode(ushort FlibHndl, short a);
 
        /* read information of the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhddinfo")]
        public static extern short ds_rdhddinfo(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHDDINF a);
 
        /* read the file list of the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhdddir")]
        public static extern short ds_rdhdddir(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, int b, out short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHDDDIR d);
 
        /* delete the file of the Data Serve's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_delhddfile")]
        public static extern short ds_delhddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* copy the file of the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_copyhddfile")]
        public static extern short ds_copyhddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* change the file name of the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_renhddfile")]
        public static extern short ds_renhddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* execute the PUT command of the FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_puthddfile")]
        public static extern short ds_puthddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* execute the MPUT command of the FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_mputhddfile")]
        public static extern short ds_mputhddfile(ushort hLib, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read information of the host */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhostinfo")]
        public static extern short ds_rdhostinfo(ushort FlibHndl, out int a, int b);
 
        /* read the file list of the host */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhostdir")]
        public static extern short ds_rdhostdir(ushort FlibHndl, short a, int b, out short c, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHOSTDIR d, int e);
 
        /* read the file list of the host 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhostdir2")]
        public static extern short ds_rdhostdir2(ushort FlibHndl, short a, int b, out short c, out int d, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBHOSTDIR e, int f);
 
        /* delete the file of the host */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_delhostfile")]
        public static extern short ds_delhostfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, int b);
 
        /* execute the GET command of the FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_gethostfile")]
        public static extern short ds_gethostfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* execute the MGET command of the FTP */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_mgethostfile")]
        public static extern short ds_mgethostfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the execution result */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdresult")]
        public static extern short ds_rdresult(ushort FlibHndl);
 
        /* stop the execution of the command */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_cancel")]
        public static extern short ds_cancel(ushort FlibHndl);
 
        /* read the file from the Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdncfile")]
        public static extern short ds_rdncfile(ushort FlibHndl, short a, [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* read the file from the Data Server 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdncfile2")]
        public static extern short ds_rdncfile2(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* write the file to the Data Server */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrncfile")]
        public static extern short ds_wrncfile(ushort FlibHndl, short a, int b);
 
        /* read the file name for the DNC operation in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rddnchddfile")]
        public static extern short ds_rddnchddfile(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* write the file name for the DNC operation in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrdnchddfile")]
        public static extern short ds_wrdnchddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the file name for the DNC operation in the host */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rddnchostfile")]
        public static extern short ds_rddnchostfile(ushort FlibHndl, out short a, [Out, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write the file name for the DNC operation in the host */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrdnchostfile")]
        public static extern short ds_wrdnchostfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the connecting host number */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdhostno")]
        public static extern short ds_rdhostno(ushort FlibHndl, out short a);
 
        /* read maintenance information */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdmntinfo")]
        public static extern short ds_rdmntinfo(ushort FlibHndl, short a, [Out, MarshalAs(UnmanagedType.LPStruct)]DSMNTINFO b);
 
        /* check the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_checkhdd")]
        public static extern short ds_checkhdd(ushort FlibHndl);
 
        /* format the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_formathdd")]
        public static extern short ds_formathdd(ushort FlibHndl);
 
        /* create the directory in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_makehdddir")]
        public static extern short ds_makehdddir(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* delete directory in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_delhdddir")]
        public static extern short ds_delhdddir(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* change the current directory */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_chghdddir")]
        public static extern short ds_chghdddir(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* execute the PUT command according to the list file */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_lputhddfile")]
        public static extern short ds_lputhddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* delete files according to the list file */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_ldelhddfile")]
        public static extern short ds_ldelhddfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* execute the GET command according to the list file */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_lgethostfile")]
        public static extern short ds_lgethostfile(ushort FlibHndl, [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the directory for M198 operation */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdm198hdddir")]
        public static extern short ds_rdm198hdddir(ushort FlibHndl, [Out, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* write the directory for M198 operation */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrm198hdddir")]
        public static extern short ds_wrm198hdddir(ushort FlibHndl);
 
        /* read the connecting host number for the M198 operation */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdm198host")]
        public static extern short ds_rdm198host(ushort FlibHndl, out short a);
 
        /* write the connecting host number for the M198 operation */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrm198host")]
        public static extern short ds_wrm198host(ushort FlibHndl);
 
        /* write the connecting host number */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrhostno")]
        public static extern short ds_wrhostno(ushort FlibHndl, short a);
 
        /* search string in data server program */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_searchword")]
        public static extern short ds_searchword(ushort FlibHndl,
                                  [In, MarshalAs(UnmanagedType.AsAny)] Object a);
 
        /* read the searching result */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_searchresult")]
        public static extern short ds_searchresult(ushort FlibHndl);
 
        /* read file in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_rdfile")]
        public static extern short ds_rdfile(ushort FlibHndl,
                                         [In, MarshalAs(UnmanagedType.AsAny)] Object a,
                                         [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /* write file in the Data Server's HDD */
        [DllImport("FWLIB32.dll", EntryPoint = "ds_wrfile")]
        public static extern short ds_wrfile(ushort FlibHndl,
                                         [In, MarshalAs(UnmanagedType.AsAny)] Object a,
                                         [In, MarshalAs(UnmanagedType.AsAny)] Object b);
 
        /*--------------------------*/
        /* HSSB multiple connection */
        /*--------------------------*/
 
        /* read number of node */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdnodenum")]
        public static extern short cnc_rdnodenum(out int a);
 
        /* read node informations */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdnodeinfo")]
        public static extern short cnc_rdnodeinfo(int a, [Out, MarshalAs(UnmanagedType.LPStruct)] ODBNODE b);
 
        /* set default node number */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_setdefnode")]
        public static extern short cnc_setdefnode(int a);
 
        /* allocate library handle 2 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allclibhndl2")]
        public static extern short cnc_allclibhndl2(int node, out ushort FlibHndl);
 
 
        /*---------------------*/
        /* Ethernet connection */
        /*---------------------*/
 
        /* allocate library handle 3 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allclibhndl3")]
        public static extern short cnc_allclibhndl3([In, MarshalAs(UnmanagedType.AsAny)] Object ip,
           ushort port, int timeout, out ushort FlibHndl);
 
        /* allocate library handle 4 */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_allclibhndl4")]
        public static extern short cnc_allclibhndl4([In, MarshalAs(UnmanagedType.AsAny)] Object ip,
           ushort port, int timeout, uint id, out ushort FlibHndl);
 
        /* set timeout for socket */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_settimeout")]
        public static extern short cnc_settimeout(ushort FlibHndl, int a);
 
        /* reset all socket connection */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_resetconnect")]
        public static extern short cnc_resetconnect(ushort FlibHndl);
 
        /* get option state for FOCAS1/Ethernet */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_getfocas1opt")]
        public static extern short cnc_getfocas1opt(ushort FlibHndl, short a, out int b);
 
        /* read Ethernet board information */
        [DllImport("FWLIB32.dll", EntryPoint = "cnc_rdetherinfo")]
        public static extern short cnc_rdetherinfo(ushort FlibHndl, out short a, out short b);
 
 
    } // End for Focas1 class

标签: C# c

实例下载地址

C#连接发那科数控机床

不能下载?内容有错? 点击这里报错 + 投诉 + 提问

好例子网口号:伸出你的我的手 — 分享

网友评论

发表评论

(您的评论需要经过审核才能显示)

查看所有0条评论>>

小贴士

感谢您为本站写下的评论,您的评论对其它用户来说具有重要的参考价值,所以请认真填写。

  • 类似“顶”、“沙发”之类没有营养的文字,对勤劳贡献的楼主来说是令人沮丧的反馈信息。
  • 相信您也不想看到一排文字/表情墙,所以请不要反馈意义不大的重复字符,也请尽量不要纯表情的回复。
  • 提问之前请再仔细看一遍楼主的说明,或许是您遗漏了。
  • 请勿到处挖坑绊人、招贴广告。既占空间让人厌烦,又没人会搭理,于人于己都无利。

关于好例子网

本站旨在为广大IT学习爱好者提供一个非营利性互相学习交流分享平台。本站所有资源都可以被免费获取学习研究。本站资源来自网友分享,对搜索内容的合法性不具有预见性、识别性、控制性,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,平台无法对用户传输的作品、信息、内容的权属或合法性、安全性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论平台是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二与二十三条之规定,若资源存在侵权或相关问题请联系本站客服人员,点此联系我们。关于更多版权及免责申明参见 版权及免责申明

;
报警