Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

122 lines
3.4 KiB

  1. /*****************************************************************************
  2. *
  3. * Copyright (c) 1996-1999 Microsoft Corporation
  4. *
  5. * @doc
  6. * @module dongle.h | IrSIR NDIS Minport Driver
  7. * @comm
  8. *
  9. *-----------------------------------------------------------------------------
  10. *
  11. * Author: Scott Holden (sholden)
  12. *
  13. * Date: 9/30/1996 (created)
  14. *
  15. * Contents:
  16. * dongle settings
  17. *
  18. *****************************************************************************/
  19. #ifndef DONGLE_H
  20. #define DONGLE_H
  21. //
  22. // Some UART transceiver have minor differences which require special
  23. // treatment. We will retrieve the type out of the registry.
  24. // Any changes to this MUST also be reflected in the oemsetup.inf
  25. // which allows the user to modify transceiver type.
  26. //
  27. typedef enum _IR_TRANSCEIVER_TYPE {
  28. STANDARD_UART = 0,
  29. ACTISYS_200L,
  30. ACTISYS_220L,
  31. ACTISYS_220LPLUS,
  32. AMP_PHASIR,
  33. ESI_9680,
  34. PARALLAX,
  35. TEKRAM_IRMATE_210,
  36. TEMIC_TOIM3232,
  37. GIRBIL,
  38. // CRYSTAL,
  39. // NSC_DEMO_BD, // NSC PC87108 demo board
  40. NUM_TRANSCEIVER_TYPES
  41. } IR_TRANSCEIVER_TYPE;
  42. //
  43. // ir speed masks
  44. //
  45. #define NDIS_IRDA_SPEED_2400 (UINT)(1 << 0) // SLOW IR ...
  46. #define NDIS_IRDA_SPEED_9600 (UINT)(1 << 1)
  47. #define NDIS_IRDA_SPEED_19200 (UINT)(1 << 2)
  48. #define NDIS_IRDA_SPEED_38400 (UINT)(1 << 3)
  49. #define NDIS_IRDA_SPEED_57600 (UINT)(1 << 4)
  50. #define NDIS_IRDA_SPEED_115200 (UINT)(1 << 5)
  51. #define NDIS_IRDA_SPEED_576K (UINT)(1 << 6) // MEDIUM IR ...
  52. #define NDIS_IRDA_SPEED_1152K (UINT)(1 << 7)
  53. #define NDIS_IRDA_SPEED_4M (UINT)(1 << 8) // FAST IR
  54. typedef struct _DONGLE_CAPABILITIES
  55. {
  56. //
  57. // Mask of NDIS_IRDA_SPEED_xxx bit values.
  58. //
  59. UINT supportedSpeedsMask;
  60. //
  61. // Time (in microseconds) that must transpire between
  62. // a transmit and the next receive.
  63. //
  64. UINT turnAroundTime_usec;
  65. //
  66. // Extra BOF (Beginning Of Frame) characters required
  67. // at the start of each received frame.
  68. //
  69. UINT extraBOFsRequired;
  70. } DONGLE_CAPABILITIES, *PDONGLE_CAPABILITIES;
  71. //
  72. // Dongle init, set speed and deinit functions...all
  73. // incorporated into a dongle interface.
  74. //
  75. typedef
  76. NDIS_STATUS (_stdcall *IRSIR_QUERY_CAPS_HANDLER) (
  77. PDONGLE_CAPABILITIES pDongleCaps
  78. );
  79. typedef
  80. NDIS_STATUS (_stdcall *IRSIR_INIT_HANDLER) (
  81. PDEVICE_OBJECT pSerialDevObj
  82. );
  83. typedef
  84. void (_stdcall *IRSIR_DEINIT_HANDLER) (
  85. PDEVICE_OBJECT pSerialDevObj
  86. );
  87. typedef
  88. NDIS_STATUS (_stdcall *IRSIR_SETSPEED_HANDLER) (
  89. PDEVICE_OBJECT pSerialDevObj,
  90. UINT bitsPerSec,
  91. UINT currentSpeed
  92. );
  93. typedef struct _DONGLE_INTERFACE
  94. {
  95. IRSIR_QUERY_CAPS_HANDLER QueryCaps;
  96. IRSIR_INIT_HANDLER Initialize;
  97. IRSIR_SETSPEED_HANDLER SetSpeed;
  98. IRSIR_DEINIT_HANDLER Deinitialize;
  99. } DONGLE_INTERFACE, *PDONGLE_INTERFACE;
  100. #endif // DONGLE_H