⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 useradj.lst

📁 NOVATEK公司的LCD_CONTROLLER源代码 液晶显示器驱动板源代码NT68521
💻 LST
📖 第 1 页 / 共 5 页
字号:
 231      =1  
 232      =1  #endif
  11          #include "MCU.H"
   1      =1  #ifndef _MCU_H_
   2      =1  #define  _MCU_H_
   3      =1  
   4      =1  extern code unsigned char KeyTab[];
   5      =1  
   6      =1  void InitMCU(void);
   7      =1  //void Timer0(void);
   8      =1  void Sleep(unsigned short time);
   9      =1  void CheckKey(void);
  10      =1  void LED_GrnOn(void);
  11      =1  void LED_GrnOff(void);
  12      =1  void LED_RedOn(void);
  13      =1  void LED_RedOff(void);
  14      =1  void BackLightOn(void);
  15      =1  void BackLightOff(void);
  16      =1  void PanelPowerOff(void);
  17      =1  void PanelPowerOn(void);
  18      =1  void ResetOff(void);
  19      =1  void ResetOn(void);
  20      =1  void AUDIO_MUTE(void);
  21      =1  void AUDIO_On(void);
  22      =1  void DVI_On(void);
  23      =1  void DIV_PWND(void);
  24      =1  void AMP_STBY(void);
  25      =1  void AMP_On(void);
  26      =1  void DIG_SEL(void);
  27      =1  void DIG_Off(void);
  28      =1  void CheckDDC2Bi(void);
  29      =1  void ScanKeyPad(void);
  30      =1  void WaitSetup(unsigned short time);
  31      =1  void VideoEnable(void);
  32      =1  void VideoDisable(void);
  33      =1  
  34      =1  #endif
  12          #include "OSD_TAB.H"
   1      =1  #ifndef _OSD_TAB_H
   2      =1  #define _OSD_TAB_H
   3      =1  
   4      =1  extern code unsigned char OneBitFont[];
   5      =1  extern code unsigned char FourBitFont[];
   6      =1  extern code unsigned char *Tab1[];
C51 COMPILER V7.20   USERADJ                                                               09/14/2004 12:21:15 PAGE 15  

   7      =1  extern code unsigned char *VideoTab1[];
   8      =1  
   9      =1  #endif
  13          #include "sRGB.H"
   1      =1  
   2      =1  #ifndef _sRGB_H_
   3      =1  #define _sRGB_H_
   4      =1  
   5      =1  int sine(unsigned char alpha);
   6      =1  int cosine(unsigned char alpha);
   7      =1  void product(int *first, int * second, int *result);
   8      =1  void sRGB(void);
   9      =1  
  10      =1  #endif
  14          #include "SAA7114.H"
   1      =1  #ifndef _SAA7114_H_
   2      =1  #define _SAA7114_H_
   3      =1  
   4      =1  #define SAA7114 0x42
   5      =1  
   6      =1  void SAA7114Init(void);
   7      =1  void WritePageSAA7114(unsigned char addr1,unsigned char addr2);
   8      =1  void CheckColorSystem(void);
   9      =1  void CheckVideo(void);
  10      =1  void SetVideoBrightness(void);
  11      =1  void SetVideoContrast(void);
  12      =1  void SetVideoSaturation(void);
  13      =1  void SetVideoTint(void);
  14      =1  void SetVideoSharpness(void);
  15      =1  void SetAV_System(void);
  16      =1  
  17      =1  #endif 
  15          
  16          code unsigned char ColorTab[]={
  17                  0,1,2,3         //USER,6500k,7500k,9300K
  18          };
  19          
  20          void InverterUp(void)
  21          {
  22   1              if(++Inverter > 100)
  23   1                      Inverter = 100;
  24   1              else{
  25   2                      SetInverter();
  26   2                      ShowInverter();
  27   2              }
  28   1      }
  29          
  30          void InverterDown(void)
  31          {
  32   1              if(--Inverter == 0xff)
  33   1                      Inverter = 0x00;
  34   1              else{
  35   2                      SetInverter();
  36   2                      ShowInverter();
  37   2              }
  38   1      }
  39          
  40          void BrightnessUp(void)
  41          {
  42   1              if(++Brightness > 100)
  43   1                      Brightness = 100;
  44   1              else{
C51 COMPILER V7.20   USERADJ                                                               09/14/2004 12:21:15 PAGE 16  

  45   2                      if(PowerStatus == 0x80)
  46   2                              SetBrightness();
  47   2                      else
  48   2                              SetVideoBrightness();
  49   2                      ShowBrightness();
  50   2              }
  51   1      }
  52          
  53          void BrightnessDown(void)
  54          {
  55   1              if(--Brightness == 0xff)
  56   1                      Brightness = 0x00;
  57   1              else{
  58   2                      if(PowerStatus == 0x80)
  59   2                              SetBrightness();
  60   2                      else
  61   2                              SetVideoBrightness();
  62   2                      ShowBrightness();
  63   2              }
  64   1      }
  65          
  66          void ContrastUp(void)
  67          {
  68   1              if(++Contrast > 100)
  69   1                      Contrast = 100;
  70   1              else{
  71   2                      if(PowerStatus == 0x80)
  72   2                              sRGB();
  73   2                      else
  74   2                              SetVideoContrast();
  75   2                      ShowContrast();
  76   2              }
  77   1      }
  78          
  79          void ContrastDown(void)
  80          {
  81   1              if(--Contrast == 0xff)
  82   1                      Contrast = 0x00;
  83   1              else{
  84   2                      if(PowerStatus == 0x80)
  85   2                              sRGB();
  86   2                      else
  87   2                              SetVideoContrast();
  88   2                      ShowContrast();
  89   2              }
  90   1      }
  91          
  92          void ClockUp(void)
  93          {
  94   1              if(++HTotal > Clk_Max)
  95   1                      HTotal = Clk_Max;
  96   1              else{
  97   2                      SetADC_PLL();
  98   2                      ShowClock();
  99   2              }
 100   1      }
 101          
 102          void ClockDown(void)
 103          {
 104   1              if(--HTotal < Clk_Min)
 105   1                      HTotal = Clk_Min;
 106   1              else{
C51 COMPILER V7.20   USERADJ                                                               09/14/2004 12:21:15 PAGE 17  

 107   2                      SetADC_PLL();
 108   2                      ShowClock();
 109   2              }
 110   1      }
 111          
 112          void PhaseUp(void)
 113          {
 114   1              if(++ADC_Phase > 0x3f)
 115   1                      ADC_Phase = 0x3f;
 116   1              else{
 117   2                      SetADC_Phase();
 118   2                      ShowPhase();
 119   2              }
 120   1      }
 121          
 122          void PhaseDown(void)
 123          {
 124   1              if(--ADC_Phase == 0xff)
 125   1                      ADC_Phase = 0x00;
 126   1              else{
 127   2                      SetADC_Phase();
 128   2                      ShowPhase();
 129   2              }
 130   1      }
 131          
 132          void HP_Up(void)
 133          {
 134   1              if(++HP_Start > HP_Max)
 135   1                      HP_Start = HP_Max;
 136   1              else{
 137   2                      SetHP();
 138   2                      ShowHP();
 139   2              }
 140   1      }
 141          
 142          void HP_Down(void)
 143          {
 144   1              if(--HP_Start < HP_Min)
 145   1                      HP_Start = HP_Min;
 146   1              else{
 147   2                      SetHP();
 148   2                      ShowHP();
 149   2              }
 150   1      }
 151          
 152          void VP_Up(void)
 153          {
 154   1              if(++VP_Start > VP_Max)
 155   1                      VP_Start = VP_Max;
 156   1              else{
 157   2                      SetVP();
 158   2                      ShowVP();
 159   2              }
 160   1      }
 161          
 162          void VP_Down(void)
 163          {
 164   1              if(--VP_Start == 0xffff)
 165   1                      VP_Start = 0x00;
 166   1              else{
 167   2                      SetVP();
 168   2                      ShowVP();
C51 COMPILER V7.20   USERADJ                                                               09/14/2004 12:21:15 PAGE 18  

 169   2              }
 170   1      }
 171          
 172          void Recall(void)
 173          {
 174   1      unsigned short addr;
 175   1      unsigned char i;
 176   1              if((flag3 & BIT_0) == 0){
 177   2                      if(PowerStatus == 0x80){
 178   3      // mode recall : Brightness/Contrast/Sharpness/Clock/HP/VP/Phase/User Color = Standard Color
 179   3                              if(ModePoint < UserModeSt){
 180   4                                      addr = 0x100 + (ModePoint * 8);
 181   4                                      for(i=0; i<6; i++){
 182   5                                              Write24C16(addr,MCU_DataMap[addr]);
 183   5                                              addr++;
 184   5                                      }
 185   4                                      addr++;
 186   4                                      Write24C16(addr,MCU_DataMap[addr]);
 187   4                              }
 188   3                              Write24C16(0xdd,MCU_DataMap[0xdd]);     //osd position x
 189   3                              Write24C16(0xde,MCU_DataMap[0xde]);     //osd position y
 190   3                              Write24C16(0xcf,MCU_DataMap[0xcf]);     //osd time
 191   3                              Write24C16(0xd0,MCU_DataMap[0xd0]);     //Brightness
 192   3                              Write24C16(0xd1,MCU_DataMap[0xd1]);     //Contrast
 193   3                              Write24C16(0xd4,MCU_DataMap[0xd4]);     //Volume
 194   3                              Write24C16(0xc8,MCU_DataMap[0xc8]);     //sRGB saturation
 195   3                              Write24C16(0xc9,MCU_DataMap[0xc9]);     //sRGB Tint
 196   3                      
 197   3                              Write24C16(0xee,Read24C16(0xf1));       //R Gain
 198   3                              Write24C16(0xef,Read24C16(0xf2));       //G Gain
 199   3                              Write24C16(0xf0,Read24C16(0xf3));       //B Gain
 200   3                              LoadModeIndependentSettings();
 201   3                              LoadModeDependentSettings();
 202   3                              SetADC_PLL();
 203   3                              SetADC_Phase();
 204   3                              SetScaler();
 205   3                              SetSharpness();
 206   3                              SetBrightness();
 207   3                              sRGB();
 208   3                              SetVolume();
 209   3                      }
 210   2                      else if((PowerStatus == 0x81)||(PowerStatus == 0x82)){
 211   3                              Brightness = MCU_DataMap[0xd6];         //0xd6 = brightness
 212   3                              Contrast = MCU_DataMap[0xd7];           //0xd7 = contrast
 213   3                              Saturation = MCU_DataMap[0xd8];         //0xd8 = video saturation
 214   3                              Tint = MCU_DataMap[0xd9];                       //0xd6 = video hue

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -