📄 osdctrl.lst
字号:
C51 COMPILER V7.06 OSDCTRL 10/04/2004 11:34:02 PAGE 1
C51 COMPILER V7.06, COMPILATION OF MODULE OSDCTRL
OBJECT MODULE PLACED IN OSDCTRL.OBJ
COMPILER INVOKED BY: C:\Keil\C51\BIN\C51.EXE OSDCTRL.C DB SB OE
stmt level source
1 //---------------------------------------------------------------------------
2 // Terawins Inc. Company Confidential Strictly Private
3 //
4 // $Archive: OSDCtrl.c $
5 // $Revision: 2.0 $
6 // $Author: jwang $
7 // $Date: 2003/08/13 $
8 //
9 // --------------------------------------------------------------------------
10 // >>>>>>>>>>>>>>>>>>>>>>>>> COPYRIGHT NOTICE <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
11 // --------------------------------------------------------------------------
12 // Copyright 2002 (c) Terawins Inc.
13 // This is an unpublished work.
14 // --------------------------------------------------------------------------
15 #include <reg51.h>
16 #include "common.h"
*** WARNING C318 IN LINE 16 OF OSDCTRL.C: can't open file 'common.h'
17 #include "System.h"
*** WARNING C318 IN LINE 17 OF OSDCTRL.C: can't open file 'System.h'
18 #include "Struct.h"
*** WARNING C318 IN LINE 18 OF OSDCTRL.C: can't open file 'Struct.h'
19 #include "TW101Reg.h"
*** WARNING C318 IN LINE 19 OF OSDCTRL.C: can't open file 'TW101Reg.h'
20 #include "OSDCtrl.h"
*** WARNING C318 IN LINE 20 OF OSDCTRL.C: can't open file 'OSDCtrl.h'
21 #include "TwoWire.h"
*** WARNING C318 IN LINE 21 OF OSDCTRL.C: can't open file 'TwoWire.h'
22 #include "OSDDraw.h"
*** WARNING C318 IN LINE 22 OF OSDCTRL.C: can't open file 'OSDDraw.h'
23 #include "Keypad.h"
*** WARNING C318 IN LINE 23 OF OSDCTRL.C: can't open file 'Keypad.h'
24 //#include "SrcCtrl.h"
25 //#include "ModeCtrl.h"
26 #include "Video.h"
*** WARNING C318 IN LINE 26 OF OSDCTRL.C: can't open file 'Video.h'
27 //#include "Auto.h"
28 #include "Tuner.h"
*** WARNING C318 IN LINE 28 OF OSDCTRL.C: can't open file 'Tuner.h'
29
30 #ifdef NVRAM
#include "NVRam.h"
extern uWORD idata m_wEepRom;
#endif
34 extern bit m_bAir_Cable;
35 extern bit m_bTV_Skip;
36 extern uCHAR ir_data;
*** ERROR C129 IN LINE 36 OF OSDCTRL.C: missing ';' before 'ir_data'
37 extern void BKPower(void);
38 #ifdef TIMER1
extern void Timer1Reset(void);
extern void Timer1Start(void);
extern void Timer1Stop(void);
#endif
43
44 extern uCHAR m_cSoundSystem;
C51 COMPILER V7.06 OSDCTRL 10/04/2004 11:34:02 PAGE 2
45
46 extern bit m_bBKPowerOn;
47 extern LoadFilter(uCHAR);
48 extern BOOL SrcOptimizing(uCHAR cTuneType);
49 extern OSDPARAMS code sOSDParamsDef, sOSDParamsMin, sOSDParamsMax;
50 extern uCHAR idata m_cOSDEvent;
51 extern uCHAR idata m_cOSDFunc;
52 extern uCHAR idata m_cItem;
53 extern uCHAR idata m_cSource;
54 extern uCHAR code OSDPositionTable[];
55 extern uCHAR idata m_cBuff[4];
56 extern uWORD idata m_wBuff[3];
57
58 #if VIDEO_AVAILABLE
*** WARNING C322 IN LINE 58 OF OSDCTRL.C: unknown identifier
extern EEPVIDEO idata EepVideo;
#endif
61
62
63 void OSDItemAdj(uCHAR cAdj)
64 {
65 sCHAR sStep;
66 if(cAdj==INCREASE)
67 sStep=1;
68 else if(cAdj==DECREASE)
69 sStep=-1;
70
71 if(m_cOSDFunc==idVOLUMEMENU)
72 {
73 if(sStep>0)
74 AdjVolume(1);
75 else
76 AdjVolume(-1);
77 return;
78 }
79
80 OSDItemAdjVideo(sStep);
81 }
82
83
84
85 void OSDItemAdjVideo(sCHAR sStep)
86 {
87 switch(m_cOSDFunc){
88 case idBRIGHT_VIDEO:
89 case idBRIGHTMENU_VIDEO:
90 AdjVideoBright(sStep);
91 break;
92 case idCONTRAST_VIDEO:
93 case idCONTRASTMENU_VIDEO:
94 AdjVideoContrast(sStep);
95 break;
96 case idSHARP_VIDEO:
97 case idSHARPMENU_VIDEO:
98 AdjVideoSharp(sStep);
99 break;
100 case idSAT_VIDEO:
101 case idSATMENU_VIDEO:
102 AdjVideoSat(sStep);
103 break;
104 case idHUE_VIDEO:
105 case idHUEMENU_VIDEO:
C51 COMPILER V7.06 OSDCTRL 10/04/2004 11:34:02 PAGE 3
106 AdjVideoHue(sStep);
107 break;
108 #ifdef TV
// case idCHANNEL_TV:
// AdjTVChannel(sStep, 1);
// break;
#ifdef PAL
case iSOUNDSYSTEM_TV:
AdjTVSoundSystem();
break;
#endif
#ifdef NTSC
case idSKIP_TV:
AdjTVSkip();
break;
case idSOURCE_TV:
OSDShowTVSource(sStep);
break;
#endif
case idFINETUNE_TV:
AdjTVFineTune(sStep);
break;
case idAUTOMEMORY_TV:
AutoMemory();
// OSDExit();
break;
case idRECALL_TV:
ResetTVChannel();
// case idAUTOSCAN_TV:
// AutoScan();
break;
#endif
138 default: break;
139 }
140 }
141
142
143 #if 0
void AdjSharp(sCHAR sStep)
{
if( (EepPublic.cSharp+sStep)<=sOSDParamsMax.cSharp
&&(EepPublic.cSharp+sStep)>=sOSDParamsMin.cSharp)
{
EepPublic.cSharp +=sStep;
LoadFilter(EepPublic.cSharp);
OSDShowData(COL_FOCUS);
}
#ifdef NVRAM
SavePubData(1, EepPublic.cSharp, idSHARP_INDEX);
#endif
}
void AdjOSDHPos(sCHAR sStep)
{
uCHAR i;
if( (EepPublic.cOSDHPos+sStep)<=sOSDParamsMax.cOSDHPos
&&(EepPublic.cOSDHPos+sStep)>=sOSDParamsMin.cOSDHPos)
{
EepPublic.cOSDHPos+=sStep;
i=((EepPublic.cOSDVPos&0xe0)>>1)|((EepPublic.cOSDHPos&0xe0)>>5);
OSDCfgWr(CHAR_DLY_0,i);
C51 COMPILER V7.06 OSDCTRL 10/04/2004 11:34:02 PAGE 4
i=EepPublic.cOSDHPos<<3;
OSDCfgWr(CHAR_DLY_1,i);
}
#ifdef NVRAM
SavePubData(1, EepPublic.cOSDHPos, idOSDHPOS_INDEX);
#endif
}
void AdjOSDVPos(sCHAR sStep)
{
if( (EepPublic.cOSDVPos+sStep)<=sOSDParamsMax.cOSDVPos
&&(EepPublic.cOSDVPos+sStep)>=sOSDParamsMin.cOSDVPos)
{
EepPublic.cOSDVPos+=sStep;
OSDCfgWr(CHAR_DLY_0,((EepPublic.cOSDVPos&0xe0)>>1)|((EepPublic.cOSDHPos&0xe0)>>5));
OSDCfgWr(CHAR_DLY_2,EepPublic.cOSDVPos<<3);
}
#ifdef NVRAM
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -