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
/* automatically generated by rust-bindgen */

pub const _STDINT_H: ::std::os::raw::c_uint = 1;
pub const _FEATURES_H: ::std::os::raw::c_uint = 1;
pub const _DEFAULT_SOURCE: ::std::os::raw::c_uint = 1;
pub const __USE_ISOC11: ::std::os::raw::c_uint = 1;
pub const __USE_ISOC99: ::std::os::raw::c_uint = 1;
pub const __USE_ISOC95: ::std::os::raw::c_uint = 1;
pub const __USE_POSIX_IMPLICITLY: ::std::os::raw::c_uint = 1;
pub const _POSIX_SOURCE: ::std::os::raw::c_uint = 1;
pub const _POSIX_C_SOURCE: ::std::os::raw::c_uint = 200809;
pub const __USE_POSIX: ::std::os::raw::c_uint = 1;
pub const __USE_POSIX2: ::std::os::raw::c_uint = 1;
pub const __USE_POSIX199309: ::std::os::raw::c_uint = 1;
pub const __USE_POSIX199506: ::std::os::raw::c_uint = 1;
pub const __USE_XOPEN2K: ::std::os::raw::c_uint = 1;
pub const __USE_XOPEN2K8: ::std::os::raw::c_uint = 1;
pub const _ATFILE_SOURCE: ::std::os::raw::c_uint = 1;
pub const __USE_MISC: ::std::os::raw::c_uint = 1;
pub const __USE_ATFILE: ::std::os::raw::c_uint = 1;
pub const __USE_FORTIFY_LEVEL: ::std::os::raw::c_uint = 0;
pub const _STDC_PREDEF_H: ::std::os::raw::c_uint = 1;
pub const __STDC_IEC_559__: ::std::os::raw::c_uint = 1;
pub const __STDC_IEC_559_COMPLEX__: ::std::os::raw::c_uint = 1;
pub const __STDC_ISO_10646__: ::std::os::raw::c_uint = 201605;
pub const __STDC_NO_THREADS__: ::std::os::raw::c_uint = 1;
pub const __GNU_LIBRARY__: ::std::os::raw::c_uint = 6;
pub const __GLIBC__: ::std::os::raw::c_uint = 2;
pub const __GLIBC_MINOR__: ::std::os::raw::c_uint = 24;
pub const _SYS_CDEFS_H: ::std::os::raw::c_uint = 1;
pub const __WORDSIZE: ::std::os::raw::c_uint = 64;
pub const __WORDSIZE_TIME64_COMPAT32: ::std::os::raw::c_uint = 1;
pub const __SYSCALL_WORDSIZE: ::std::os::raw::c_uint = 64;
pub const _BITS_WCHAR_H: ::std::os::raw::c_uint = 1;
pub const INT8_MIN: ::std::os::raw::c_int = -128;
pub const INT16_MIN: ::std::os::raw::c_int = -32768;
pub const INT32_MIN: ::std::os::raw::c_int = -2147483648;
pub const INT8_MAX: ::std::os::raw::c_uint = 127;
pub const INT16_MAX: ::std::os::raw::c_uint = 32767;
pub const INT32_MAX: ::std::os::raw::c_uint = 2147483647;
pub const UINT8_MAX: ::std::os::raw::c_uint = 255;
pub const UINT16_MAX: ::std::os::raw::c_uint = 65535;
pub const UINT32_MAX: ::std::os::raw::c_uint = 4294967295;
pub const INT_LEAST8_MIN: ::std::os::raw::c_int = -128;
pub const INT_LEAST16_MIN: ::std::os::raw::c_int = -32768;
pub const INT_LEAST32_MIN: ::std::os::raw::c_int = -2147483648;
pub const INT_LEAST8_MAX: ::std::os::raw::c_uint = 127;
pub const INT_LEAST16_MAX: ::std::os::raw::c_uint = 32767;
pub const INT_LEAST32_MAX: ::std::os::raw::c_uint = 2147483647;
pub const UINT_LEAST8_MAX: ::std::os::raw::c_uint = 255;
pub const UINT_LEAST16_MAX: ::std::os::raw::c_uint = 65535;
pub const UINT_LEAST32_MAX: ::std::os::raw::c_uint = 4294967295;
pub const INT_FAST8_MIN: ::std::os::raw::c_int = -128;
pub const INT_FAST16_MIN: ::std::os::raw::c_longlong = -9223372036854775808;
pub const INT_FAST32_MIN: ::std::os::raw::c_longlong = -9223372036854775808;
pub const INT_FAST8_MAX: ::std::os::raw::c_uint = 127;
pub const INT_FAST16_MAX: ::std::os::raw::c_ulonglong = 9223372036854775807;
pub const INT_FAST32_MAX: ::std::os::raw::c_ulonglong = 9223372036854775807;
pub const UINT_FAST8_MAX: ::std::os::raw::c_uint = 255;
pub const UINT_FAST16_MAX: ::std::os::raw::c_int = -1;
pub const UINT_FAST32_MAX: ::std::os::raw::c_int = -1;
pub const INTPTR_MIN: ::std::os::raw::c_longlong = -9223372036854775808;
pub const INTPTR_MAX: ::std::os::raw::c_ulonglong = 9223372036854775807;
pub const UINTPTR_MAX: ::std::os::raw::c_int = -1;
pub const PTRDIFF_MIN: ::std::os::raw::c_longlong = -9223372036854775808;
pub const PTRDIFF_MAX: ::std::os::raw::c_ulonglong = 9223372036854775807;
pub const SIG_ATOMIC_MIN: ::std::os::raw::c_int = -2147483648;
pub const SIG_ATOMIC_MAX: ::std::os::raw::c_uint = 2147483647;
pub const SIZE_MAX: ::std::os::raw::c_int = -1;
pub const WINT_MIN: ::std::os::raw::c_uint = 0;
pub const WINT_MAX: ::std::os::raw::c_uint = 4294967295;
pub const PCAN_NONEBUS: ::std::os::raw::c_uint = 0;
pub const PCAN_ISABUS1: ::std::os::raw::c_uint = 33;
pub const PCAN_ISABUS2: ::std::os::raw::c_uint = 34;
pub const PCAN_ISABUS3: ::std::os::raw::c_uint = 35;
pub const PCAN_ISABUS4: ::std::os::raw::c_uint = 36;
pub const PCAN_ISABUS5: ::std::os::raw::c_uint = 37;
pub const PCAN_ISABUS6: ::std::os::raw::c_uint = 38;
pub const PCAN_ISABUS7: ::std::os::raw::c_uint = 39;
pub const PCAN_ISABUS8: ::std::os::raw::c_uint = 40;
pub const PCAN_DNGBUS1: ::std::os::raw::c_uint = 49;
pub const PCAN_PCIBUS1: ::std::os::raw::c_uint = 65;
pub const PCAN_PCIBUS2: ::std::os::raw::c_uint = 66;
pub const PCAN_PCIBUS3: ::std::os::raw::c_uint = 67;
pub const PCAN_PCIBUS4: ::std::os::raw::c_uint = 68;
pub const PCAN_PCIBUS5: ::std::os::raw::c_uint = 69;
pub const PCAN_PCIBUS6: ::std::os::raw::c_uint = 70;
pub const PCAN_PCIBUS7: ::std::os::raw::c_uint = 71;
pub const PCAN_PCIBUS8: ::std::os::raw::c_uint = 72;
pub const PCAN_PCIBUS9: ::std::os::raw::c_uint = 1033;
pub const PCAN_PCIBUS10: ::std::os::raw::c_uint = 1034;
pub const PCAN_PCIBUS11: ::std::os::raw::c_uint = 1035;
pub const PCAN_PCIBUS12: ::std::os::raw::c_uint = 1036;
pub const PCAN_PCIBUS13: ::std::os::raw::c_uint = 1037;
pub const PCAN_PCIBUS14: ::std::os::raw::c_uint = 1038;
pub const PCAN_PCIBUS15: ::std::os::raw::c_uint = 1039;
pub const PCAN_PCIBUS16: ::std::os::raw::c_uint = 1040;
pub const PCAN_USBBUS1: ::std::os::raw::c_uint = 81;
pub const PCAN_USBBUS2: ::std::os::raw::c_uint = 82;
pub const PCAN_USBBUS3: ::std::os::raw::c_uint = 83;
pub const PCAN_USBBUS4: ::std::os::raw::c_uint = 84;
pub const PCAN_USBBUS5: ::std::os::raw::c_uint = 85;
pub const PCAN_USBBUS6: ::std::os::raw::c_uint = 86;
pub const PCAN_USBBUS7: ::std::os::raw::c_uint = 87;
pub const PCAN_USBBUS8: ::std::os::raw::c_uint = 88;
pub const PCAN_USBBUS9: ::std::os::raw::c_uint = 1289;
pub const PCAN_USBBUS10: ::std::os::raw::c_uint = 1290;
pub const PCAN_USBBUS11: ::std::os::raw::c_uint = 1291;
pub const PCAN_USBBUS12: ::std::os::raw::c_uint = 1292;
pub const PCAN_USBBUS13: ::std::os::raw::c_uint = 1293;
pub const PCAN_USBBUS14: ::std::os::raw::c_uint = 1294;
pub const PCAN_USBBUS15: ::std::os::raw::c_uint = 1295;
pub const PCAN_USBBUS16: ::std::os::raw::c_uint = 1296;
pub const PCAN_PCCBUS1: ::std::os::raw::c_uint = 97;
pub const PCAN_PCCBUS2: ::std::os::raw::c_uint = 98;
pub const PCAN_LANBUS1: ::std::os::raw::c_uint = 2049;
pub const PCAN_LANBUS2: ::std::os::raw::c_uint = 2050;
pub const PCAN_LANBUS3: ::std::os::raw::c_uint = 2051;
pub const PCAN_LANBUS4: ::std::os::raw::c_uint = 2052;
pub const PCAN_LANBUS5: ::std::os::raw::c_uint = 2053;
pub const PCAN_LANBUS6: ::std::os::raw::c_uint = 2054;
pub const PCAN_LANBUS7: ::std::os::raw::c_uint = 2055;
pub const PCAN_LANBUS8: ::std::os::raw::c_uint = 2056;
pub const PCAN_LANBUS9: ::std::os::raw::c_uint = 2057;
pub const PCAN_LANBUS10: ::std::os::raw::c_uint = 2058;
pub const PCAN_LANBUS11: ::std::os::raw::c_uint = 2059;
pub const PCAN_LANBUS12: ::std::os::raw::c_uint = 2060;
pub const PCAN_LANBUS13: ::std::os::raw::c_uint = 2061;
pub const PCAN_LANBUS14: ::std::os::raw::c_uint = 2062;
pub const PCAN_LANBUS15: ::std::os::raw::c_uint = 2063;
pub const PCAN_LANBUS16: ::std::os::raw::c_uint = 2064;
pub const PCAN_ERROR_OK: ::std::os::raw::c_uint = 0;
pub const PCAN_ERROR_XMTFULL: ::std::os::raw::c_uint = 1;
pub const PCAN_ERROR_OVERRUN: ::std::os::raw::c_uint = 2;
pub const PCAN_ERROR_BUSLIGHT: ::std::os::raw::c_uint = 4;
pub const PCAN_ERROR_BUSHEAVY: ::std::os::raw::c_uint = 8;
pub const PCAN_ERROR_BUSWARNING: ::std::os::raw::c_uint = 8;
pub const PCAN_ERROR_BUSPASSIVE: ::std::os::raw::c_uint = 262144;
pub const PCAN_ERROR_BUSOFF: ::std::os::raw::c_uint = 16;
pub const PCAN_ERROR_ANYBUSERR: ::std::os::raw::c_uint = 262172;
pub const PCAN_ERROR_QRCVEMPTY: ::std::os::raw::c_uint = 32;
pub const PCAN_ERROR_QOVERRUN: ::std::os::raw::c_uint = 64;
pub const PCAN_ERROR_QXMTFULL: ::std::os::raw::c_uint = 128;
pub const PCAN_ERROR_REGTEST: ::std::os::raw::c_uint = 256;
pub const PCAN_ERROR_NODRIVER: ::std::os::raw::c_uint = 512;
pub const PCAN_ERROR_HWINUSE: ::std::os::raw::c_uint = 1024;
pub const PCAN_ERROR_NETINUSE: ::std::os::raw::c_uint = 2048;
pub const PCAN_ERROR_ILLHW: ::std::os::raw::c_uint = 5120;
pub const PCAN_ERROR_ILLNET: ::std::os::raw::c_uint = 6144;
pub const PCAN_ERROR_ILLCLIENT: ::std::os::raw::c_uint = 7168;
pub const PCAN_ERROR_ILLHANDLE: ::std::os::raw::c_uint = 7168;
pub const PCAN_ERROR_RESOURCE: ::std::os::raw::c_uint = 8192;
pub const PCAN_ERROR_ILLPARAMTYPE: ::std::os::raw::c_uint = 16384;
pub const PCAN_ERROR_ILLPARAMVAL: ::std::os::raw::c_uint = 32768;
pub const PCAN_ERROR_UNKNOWN: ::std::os::raw::c_uint = 65536;
pub const PCAN_ERROR_ILLDATA: ::std::os::raw::c_uint = 131072;
pub const PCAN_ERROR_CAUTION: ::std::os::raw::c_uint = 33554432;
pub const PCAN_ERROR_INITIALIZE: ::std::os::raw::c_uint = 67108864;
pub const PCAN_ERROR_ILLOPERATION: ::std::os::raw::c_uint = 134217728;
pub const PCAN_NONE: ::std::os::raw::c_uint = 0;
pub const PCAN_PEAKCAN: ::std::os::raw::c_uint = 1;
pub const PCAN_ISA: ::std::os::raw::c_uint = 2;
pub const PCAN_DNG: ::std::os::raw::c_uint = 3;
pub const PCAN_PCI: ::std::os::raw::c_uint = 4;
pub const PCAN_USB: ::std::os::raw::c_uint = 5;
pub const PCAN_PCC: ::std::os::raw::c_uint = 6;
pub const PCAN_VIRTUAL: ::std::os::raw::c_uint = 7;
pub const PCAN_LAN: ::std::os::raw::c_uint = 8;
pub const PCAN_DEVICE_NUMBER: ::std::os::raw::c_uint = 1;
pub const PCAN_5VOLTS_POWER: ::std::os::raw::c_uint = 2;
pub const PCAN_RECEIVE_EVENT: ::std::os::raw::c_uint = 3;
pub const PCAN_MESSAGE_FILTER: ::std::os::raw::c_uint = 4;
pub const PCAN_API_VERSION: ::std::os::raw::c_uint = 5;
pub const PCAN_CHANNEL_VERSION: ::std::os::raw::c_uint = 6;
pub const PCAN_BUSOFF_AUTORESET: ::std::os::raw::c_uint = 7;
pub const PCAN_LISTEN_ONLY: ::std::os::raw::c_uint = 8;
pub const PCAN_LOG_LOCATION: ::std::os::raw::c_uint = 9;
pub const PCAN_LOG_STATUS: ::std::os::raw::c_uint = 10;
pub const PCAN_LOG_CONFIGURE: ::std::os::raw::c_uint = 11;
pub const PCAN_LOG_TEXT: ::std::os::raw::c_uint = 12;
pub const PCAN_CHANNEL_CONDITION: ::std::os::raw::c_uint = 13;
pub const PCAN_HARDWARE_NAME: ::std::os::raw::c_uint = 14;
pub const PCAN_RECEIVE_STATUS: ::std::os::raw::c_uint = 15;
pub const PCAN_CONTROLLER_NUMBER: ::std::os::raw::c_uint = 16;
pub const PCAN_TRACE_LOCATION: ::std::os::raw::c_uint = 17;
pub const PCAN_TRACE_STATUS: ::std::os::raw::c_uint = 18;
pub const PCAN_TRACE_SIZE: ::std::os::raw::c_uint = 19;
pub const PCAN_TRACE_CONFIGURE: ::std::os::raw::c_uint = 20;
pub const PCAN_CHANNEL_IDENTIFYING: ::std::os::raw::c_uint = 21;
pub const PCAN_CHANNEL_FEATURES: ::std::os::raw::c_uint = 22;
pub const PCAN_BITRATE_ADAPTING: ::std::os::raw::c_uint = 23;
pub const PCAN_BITRATE_INFO: ::std::os::raw::c_uint = 24;
pub const PCAN_BITRATE_INFO_FD: ::std::os::raw::c_uint = 25;
pub const PCAN_BUSSPEED_NOMINAL: ::std::os::raw::c_uint = 26;
pub const PCAN_BUSSPEED_DATA: ::std::os::raw::c_uint = 27;
pub const PCAN_IP_ADDRESS: ::std::os::raw::c_uint = 28;
pub const PCAN_LAN_SERVICE_STATUS: ::std::os::raw::c_uint = 29;
pub const PCAN_PARAMETER_OFF: ::std::os::raw::c_uint = 0;
pub const PCAN_PARAMETER_ON: ::std::os::raw::c_uint = 1;
pub const PCAN_FILTER_CLOSE: ::std::os::raw::c_uint = 0;
pub const PCAN_FILTER_OPEN: ::std::os::raw::c_uint = 1;
pub const PCAN_FILTER_CUSTOM: ::std::os::raw::c_uint = 2;
pub const PCAN_CHANNEL_UNAVAILABLE: ::std::os::raw::c_uint = 0;
pub const PCAN_CHANNEL_AVAILABLE: ::std::os::raw::c_uint = 1;
pub const PCAN_CHANNEL_OCCUPIED: ::std::os::raw::c_uint = 2;
pub const PCAN_CHANNEL_PCANVIEW: ::std::os::raw::c_uint = 3;
pub const LOG_FUNCTION_DEFAULT: ::std::os::raw::c_uint = 0;
pub const LOG_FUNCTION_ENTRY: ::std::os::raw::c_uint = 1;
pub const LOG_FUNCTION_PARAMETERS: ::std::os::raw::c_uint = 2;
pub const LOG_FUNCTION_LEAVE: ::std::os::raw::c_uint = 4;
pub const LOG_FUNCTION_WRITE: ::std::os::raw::c_uint = 8;
pub const LOG_FUNCTION_READ: ::std::os::raw::c_uint = 16;
pub const LOG_FUNCTION_ALL: ::std::os::raw::c_uint = 65535;
pub const TRACE_FILE_SINGLE: ::std::os::raw::c_uint = 0;
pub const TRACE_FILE_SEGMENTED: ::std::os::raw::c_uint = 1;
pub const TRACE_FILE_DATE: ::std::os::raw::c_uint = 2;
pub const TRACE_FILE_TIME: ::std::os::raw::c_uint = 4;
pub const TRACE_FILE_OVERWRITE: ::std::os::raw::c_uint = 128;
pub const FEATURE_FD_CAPABLE: ::std::os::raw::c_uint = 1;
pub const SERVICE_STATUS_STOPPED: ::std::os::raw::c_uint = 1;
pub const SERVICE_STATUS_RUNNING: ::std::os::raw::c_uint = 4;
pub const PCAN_MESSAGE_STANDARD: ::std::os::raw::c_uint = 0;
pub const PCAN_MESSAGE_RTR: ::std::os::raw::c_uint = 1;
pub const PCAN_MESSAGE_EXTENDED: ::std::os::raw::c_uint = 2;
pub const PCAN_MESSAGE_FD: ::std::os::raw::c_uint = 4;
pub const PCAN_MESSAGE_BRS: ::std::os::raw::c_uint = 8;
pub const PCAN_MESSAGE_ESI: ::std::os::raw::c_uint = 16;
pub const PCAN_MESSAGE_STATUS: ::std::os::raw::c_uint = 128;
pub const PCAN_MODE_STANDARD: ::std::os::raw::c_uint = 0;
pub const PCAN_MODE_EXTENDED: ::std::os::raw::c_uint = 2;
pub const PCAN_BAUD_1M: ::std::os::raw::c_uint = 20;
pub const PCAN_BAUD_800K: ::std::os::raw::c_uint = 22;
pub const PCAN_BAUD_500K: ::std::os::raw::c_uint = 28;
pub const PCAN_BAUD_250K: ::std::os::raw::c_uint = 284;
pub const PCAN_BAUD_125K: ::std::os::raw::c_uint = 796;
pub const PCAN_BAUD_100K: ::std::os::raw::c_uint = 17199;
pub const PCAN_BAUD_95K: ::std::os::raw::c_uint = 49998;
pub const PCAN_BAUD_83K: ::std::os::raw::c_uint = 34091;
pub const PCAN_BAUD_50K: ::std::os::raw::c_uint = 18223;
pub const PCAN_BAUD_47K: ::std::os::raw::c_uint = 5140;
pub const PCAN_BAUD_33K: ::std::os::raw::c_uint = 35631;
pub const PCAN_BAUD_20K: ::std::os::raw::c_uint = 21295;
pub const PCAN_BAUD_10K: ::std::os::raw::c_uint = 26415;
pub const PCAN_BAUD_5K: ::std::os::raw::c_uint = 32639;
pub const PCAN_TYPE_ISA: ::std::os::raw::c_uint = 1;
pub const PCAN_TYPE_ISA_SJA: ::std::os::raw::c_uint = 9;
pub const PCAN_TYPE_ISA_PHYTEC: ::std::os::raw::c_uint = 4;
pub const PCAN_TYPE_DNG: ::std::os::raw::c_uint = 2;
pub const PCAN_TYPE_DNG_EPP: ::std::os::raw::c_uint = 3;
pub const PCAN_TYPE_DNG_SJA: ::std::os::raw::c_uint = 5;
pub const PCAN_TYPE_DNG_SJA_EPP: ::std::os::raw::c_uint = 6;
pub type int_least8_t = ::std::os::raw::c_schar;
pub type int_least16_t = ::std::os::raw::c_short;
pub type int_least32_t = ::std::os::raw::c_int;
pub type int_least64_t = ::std::os::raw::c_long;
pub type uint_least8_t = ::std::os::raw::c_uchar;
pub type uint_least16_t = ::std::os::raw::c_ushort;
pub type uint_least32_t = ::std::os::raw::c_uint;
pub type uint_least64_t = ::std::os::raw::c_ulong;
pub type int_fast8_t = ::std::os::raw::c_schar;
pub type int_fast16_t = ::std::os::raw::c_long;
pub type int_fast32_t = ::std::os::raw::c_long;
pub type int_fast64_t = ::std::os::raw::c_long;
pub type uint_fast8_t = ::std::os::raw::c_uchar;
pub type uint_fast16_t = ::std::os::raw::c_ulong;
pub type uint_fast32_t = ::std::os::raw::c_ulong;
pub type uint_fast64_t = ::std::os::raw::c_ulong;
pub type intmax_t = ::std::os::raw::c_long;
pub type uintmax_t = ::std::os::raw::c_ulong;
////////////////////////////////////////////////////////////
#[repr(C)]
#[derive(Debug, Copy)]
pub struct tagTPCANMsg {
    pub ID: u32,
    pub MSGTYPE: u8,
    pub LEN: u8,
    pub DATA: [u8; 8usize],
}
#[test]
fn bindgen_test_layout_tagTPCANMsg() {
    assert_eq!(::std::mem::size_of::<tagTPCANMsg>() , 16usize , concat ! (
               "Size of: " , stringify ! ( tagTPCANMsg ) ));
    assert_eq! (::std::mem::align_of::<tagTPCANMsg>() , 4usize , concat ! (
                "Alignment of " , stringify ! ( tagTPCANMsg ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsg ) ) . ID as * const _ as
                usize } , 0usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsg ) , "::" ,
                stringify ! ( ID ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsg ) ) . MSGTYPE as * const _ as
                usize } , 4usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsg ) , "::" ,
                stringify ! ( MSGTYPE ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsg ) ) . LEN as * const _ as
                usize } , 5usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsg ) , "::" ,
                stringify ! ( LEN ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsg ) ) . DATA as * const _ as
                usize } , 6usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsg ) , "::" ,
                stringify ! ( DATA ) ));
}
impl Clone for tagTPCANMsg {
    fn clone(&self) -> Self { *self }
}
pub type TPCANMsg = tagTPCANMsg;
#[repr(C)]
#[derive(Debug, Copy)]
pub struct tagTPCANTimestamp {
    pub millis: u32,
    pub millis_overflow: u16,
    pub micros: u16,
}
#[test]
fn bindgen_test_layout_tagTPCANTimestamp() {
    assert_eq!(::std::mem::size_of::<tagTPCANTimestamp>() , 8usize , concat !
               ( "Size of: " , stringify ! ( tagTPCANTimestamp ) ));
    assert_eq! (::std::mem::align_of::<tagTPCANTimestamp>() , 4usize , concat
                ! ( "Alignment of " , stringify ! ( tagTPCANTimestamp ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANTimestamp ) ) . millis as * const
                _ as usize } , 0usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANTimestamp ) ,
                "::" , stringify ! ( millis ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANTimestamp ) ) . millis_overflow
                as * const _ as usize } , 4usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANTimestamp ) ,
                "::" , stringify ! ( millis_overflow ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANTimestamp ) ) . micros as * const
                _ as usize } , 6usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANTimestamp ) ,
                "::" , stringify ! ( micros ) ));
}
impl Clone for tagTPCANTimestamp {
    fn clone(&self) -> Self { *self }
}
pub type TPCANTimestamp = tagTPCANTimestamp;
#[repr(C)]
pub struct tagTPCANMsgFD {
    pub ID: u32,
    pub MSGTYPE: u8,
    pub DLC: u8,
    pub DATA: [u8; 64usize],
}
#[test]
fn bindgen_test_layout_tagTPCANMsgFD() {
    assert_eq!(::std::mem::size_of::<tagTPCANMsgFD>() , 72usize , concat ! (
               "Size of: " , stringify ! ( tagTPCANMsgFD ) ));
    assert_eq! (::std::mem::align_of::<tagTPCANMsgFD>() , 4usize , concat ! (
                "Alignment of " , stringify ! ( tagTPCANMsgFD ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsgFD ) ) . ID as * const _ as
                usize } , 0usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsgFD ) , "::"
                , stringify ! ( ID ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsgFD ) ) . MSGTYPE as * const _
                as usize } , 4usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsgFD ) , "::"
                , stringify ! ( MSGTYPE ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsgFD ) ) . DLC as * const _ as
                usize } , 5usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsgFD ) , "::"
                , stringify ! ( DLC ) ));
    assert_eq! (unsafe {
                & ( * ( 0 as * const tagTPCANMsgFD ) ) . DATA as * const _ as
                usize } , 6usize , concat ! (
                "Alignment of field: " , stringify ! ( tagTPCANMsgFD ) , "::"
                , stringify ! ( DATA ) ));
}
pub type TPCANMsgFD = tagTPCANMsgFD;
extern "C" {
    /// <summary>
/// Initializes a PCAN Channel
/// </summary>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="Btr0Btr1">"The speed for the communication (BTR0BTR1 code)"</param>
/// <param name="HwType">"NON PLUG&PLAY: The type of hardware and operation mode"</param>
/// <param name="IOPort">"NON PLUG&PLAY: The I/O address for the parallel port"</param>
/// <param name="Interrupt">"NON PLUG&PLAY: Interrupt number of the parallel port"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_Initialize(Channel: u16, Btr0Btr1: u16, HwType: u8,
                          IOPort: u32, Interrupt: u16) -> u32;
}
extern "C" {
    /// <example>f_clock_mhz=80,nom_brp=0,nom_tseg1=13,nom_tseg2=0,nom_sjw=0,data_brp=0,
/// data_tseg1=13,data_tseg2=0,data_sjw=0</example>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_InitializeFD(Channel: u16,
                            BitrateFD: *mut ::std::os::raw::c_char) -> u32;
}
extern "C" {
    /// <summary>
/// Uninitializes one or all PCAN Channels initialized by CAN_Initialize
/// </summary>
/// <remarks>Giving the TPCANHandle value "PCAN_NONEBUS",
/// uninitialize all initialized channels</remarks>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_Uninitialize(Channel: u16) -> u32;
}
extern "C" {
    /// <summary>
/// Resets the receive and transmit queues of the PCAN Channel
/// </summary>
/// <remarks>
/// A reset of the CAN controller is not performed.
/// </remarks>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_Reset(Channel: u16) -> u32;
}
extern "C" {
    /// <summary>
/// Gets the current status of a PCAN Channel
/// </summary>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_GetStatus(Channel: u16) -> u32;
}
extern "C" {
    /// <summary>
/// Reads a CAN message from the receive queue of a PCAN Channel
/// </summary>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="MessageBuffer">"A TPCANMsg structure buffer to store the CAN message"</param>
/// <param name="TimestampBuffer">"A TPCANTimestamp structure buffer to get
/// the reception time of the message. If this value is not desired, this parameter
/// should be passed as NULL"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_Read(Channel: u16, MessageBuffer: *mut TPCANMsg,
                    TimestampBuffer: *mut TPCANTimestamp) -> u32;
}
extern "C" {
    /// <summary>
/// Reads a CAN message from the receive queue of a FD capable PCAN Channel
/// </summary>
/// <param name="Channel">"The handle of a FD capable PCAN Channel"</param>
/// <param name="MessageBuffer">"A TPCANMsgFD structure buffer to store the CAN message"</param>
/// <param name="TimestampBuffer">"A TPCANTimestampFD buffer to get
/// the reception time of the message. If this value is not desired, this parameter
/// should be passed as NULL"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_ReadFD(Channel: u16, MessageBuffer: *mut TPCANMsgFD,
                      TimestampBuffer: *mut u64) -> u32;
}
extern "C" {
    /// <summary>
/// Transmits a CAN message
/// </summary>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="MessageBuffer">"A TPCANMsg buffer with the message to be sent"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_Write(Channel: u16, MessageBuffer: *mut TPCANMsg) -> u32;
}
extern "C" {
    /// <summary>
/// Transmits a CAN message over a FD capable PCAN Channel
/// </summary>
/// <param name="Channel">"The handle of a FD capable PCAN Channel"</param>
/// <param name="MessageBuffer">"A TPCANMsgFD buffer with the message to be sent"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_WriteFD(Channel: u16, MessageBuffer: *mut TPCANMsgFD) -> u32;
}
extern "C" {
    /// <summary>
/// Configures the reception filter.
/// </summary>
/// <remarks>The message filter will be expanded with every call to
/// this function. If it is desired to reset the filter, please use
/// the CAN_SetValue function</remarks>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="FromID">"The lowest CAN ID to be received"</param>
/// <param name="ToID">"The highest CAN ID to be received"</param>
/// <param name="Mode">"Message type, Standard (11-bit identifier) or
/// Extended (29-bit identifier)"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_FilterMessages(Channel: u16, FromID: u32, ToID: u32, Mode: u8)
     -> u32;
}
extern "C" {
    /// <summary>
/// Retrieves a PCAN Channel value
/// </summary>
/// <remarks>Parameters can be present or not according with the kind
/// of Hardware (PCAN Channel) being used. If a parameter is not available,
/// a PCAN_ERROR_ILLPARAMTYPE error will be returned</remarks>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="Parameter">"The TPCANParameter parameter to get"</param>
/// <param name="Buffer">"Buffer for the parameter value"</param>
/// <param name="BufferLength">"Size in bytes of the buffer"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_GetValue(Channel: u16, Parameter: u8,
                        Buffer: *mut ::std::os::raw::c_void,
                        BufferLength: u32) -> u32;
}
extern "C" {
    /// <summary>
/// Configures or sets a PCAN Channel value
/// </summary>
/// <remarks>Parameters can be present or not according with the kind
/// of Hardware (PCAN Channel) being used. If a parameter is not available,
/// a PCAN_ERROR_ILLPARAMTYPE error will be returned</remarks>
/// <param name="Channel">"The handle of a PCAN Channel"</param>
/// <param name="Parameter">"The TPCANParameter parameter to set"</param>
/// <param name="Buffer">"Buffer with the value to be set"</param>
/// <param name="BufferLength">"Size in bytes of the buffer"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_SetValue(Channel: u16, Parameter: u8,
                        Buffer: *mut ::std::os::raw::c_void,
                        BufferLength: u32) -> u32;
}
extern "C" {
    /// <summary>
/// Returns a descriptive text of a given TPCANStatus error
/// code, in any desired language
/// </summary>
/// <remarks>The current languages available for translation are:
/// Neutral (0x00), German (0x07), English (0x09), Spanish (0x0A),
/// Italian (0x10) and French (0x0C)</remarks>
/// <param name="Error">"A TPCANStatus error code"</param>
/// <param name="Language">"Indicates a 'Primary language ID'"</param>
/// <param name="Buffer">"Buffer for a null terminated char array"</param>
/// <returns>"A TPCANStatus error code"</returns>
    pub fn CAN_GetErrorText(Error: u32, Language: u16,
                            Buffer: *mut ::std::os::raw::c_char) -> u32;
}