ec168.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /*
  2. * E3C EC168 DVB USB driver
  3. *
  4. * Copyright (C) 2009 Antti Palosaari <crope@iki.fi>
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; either version 2 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. *
  16. */
  17. #ifndef EC168_H
  18. #define EC168_H
  19. #include "dvb_usb.h"
  20. #define EC168_USB_TIMEOUT 1000
  21. #define EC168_FIRMWARE "dvb-usb-ec168.fw"
  22. struct ec168_req {
  23. u8 cmd; /* [1] */
  24. u16 value; /* [2|3] */
  25. u16 index; /* [4|5] */
  26. u16 size; /* [6|7] */
  27. u8 *data;
  28. };
  29. enum ec168_cmd {
  30. DOWNLOAD_FIRMWARE = 0x00,
  31. CONFIG = 0x01,
  32. DEMOD_RW = 0x03,
  33. GPIO = 0x04,
  34. STREAMING_CTRL = 0x10,
  35. READ_I2C = 0x20,
  36. WRITE_I2C = 0x21,
  37. HID_DOWNLOAD = 0x30,
  38. GET_CONFIG,
  39. SET_CONFIG,
  40. READ_DEMOD,
  41. WRITE_DEMOD,
  42. };
  43. #endif