dmbdrv_wrap_fc8050.h 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. /*
  2. * Copyright(c) 2008 SEC Corp. All Rights Reserved
  3. *
  4. * File name : dmbdrv_wrap_fc8050.h
  5. *
  6. * Description : fc8050 tuner control driver
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation; either version 2 of the License, or
  10. * (at your option) any later version.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this program; if not, write to the Free Software
  19. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  20. *
  21. * History :
  22. * ----------------------------------------------------------------------
  23. *
  24. */
  25. #ifndef __DMBDRV_WRAP_FC8050_H
  26. #define __DMBDRV_WRAP_FC8050_H
  27. #include <linux/string.h>
  28. #include <linux/delay.h>
  29. #define TDMB_SUCCESS 1
  30. #define TDMB_FAIL 0
  31. #define USER_APPL_NUM_MAX 12
  32. #define USER_APPL_DATA_SIZE_MAX 24
  33. struct sub_channel_info_type {
  34. unsigned short uiEnsembleID;
  35. unsigned char ucSubchID;
  36. unsigned short uiStartAddress;
  37. unsigned char ucTMId;
  38. unsigned char ucServiceType;
  39. unsigned long ulServiceID;
  40. unsigned char num_of_user_appl;
  41. unsigned short user_appl_type[USER_APPL_NUM_MAX];
  42. unsigned char user_appl_length[USER_APPL_NUM_MAX];
  43. unsigned char user_appl_data
  44. [USER_APPL_NUM_MAX][USER_APPL_DATA_SIZE_MAX];
  45. unsigned char scids;
  46. unsigned char ecc;
  47. };
  48. void dmb_drv_isr(void);
  49. unsigned char dmb_drv_init(unsigned long param);
  50. unsigned char dmb_drv_deinit(void);
  51. unsigned char dmb_drv_scan_ch(unsigned long frequency);
  52. int dmb_drv_get_dmb_sub_ch_cnt(void);
  53. int dmb_drv_get_dab_sub_ch_cnt(void);
  54. char *dmb_drv_get_ensemble_label(void);
  55. char *dmb_drv_get_sub_ch_dmb_label(int subchannel_count);
  56. char *dmb_drv_get_sub_ch_dab_label(int subchannel_count);
  57. struct sub_channel_info_type *dmb_drv_get_fic_dmb(int subchannel_count);
  58. struct sub_channel_info_type *dmb_drv_get_fic_dab(int subchannel_count);
  59. unsigned char dmb_drv_set_ch(
  60. unsigned long frequency
  61. , unsigned char subchannel
  62. , unsigned char sevice_type);
  63. unsigned char dmb_drv_set_ch_factory(
  64. unsigned long frequency
  65. , unsigned char subchannel
  66. , unsigned char sevice_type);
  67. unsigned short dmb_drv_get_ber(void);
  68. unsigned char dmb_drv_get_ant(void);
  69. signed short dmb_drv_get_rssi(void);
  70. int tdmb_interrupt_fic_callback(u32 userdata, u8 *data, int length);
  71. int tdmb_interrupt_msc_callback(
  72. u32 userdata, u8 subchannel_id, u8 *data, int length);
  73. #endif