?? panelvfd.c
字號:
int bcdsec, bcdmin;
bcdmin = (time >> 16) & 0xff;
bcdsec = (time >> 8) & 0xff;
addMicroRing(PANEL_MIN | bcdmin);
addMicroRing(PANEL_SEC | bcdsec);
#ifdef FU265
Indicator_5 |= (SEG_MIN | SEG_SEC | SEG_COLON
#ifdef YONGSHENG
| SEG_KARAOKE1 | SEG_KARAOKE2
#endif
#ifdef SHARK_REMOTE
| SEG_KARAOKE1 | SEG_KARAOKE2
#endif
#ifdef ZHONGSUO_REMOTE
| SEG_KARAOKE1 | SEG_KARAOKE2
#endif
);
REFRESH_INDICATOR_5;
#ifdef YONGSHENG
Indicator_4 |= SEG_TIME;
REFRESH_INDICATOR_4;
#endif
#else
#ifdef FU_KANGHUI30
Indicator_5 |= SEG_COLON;
REFRESH_INDICATOR_5;
#else
Indicator_5 |= (SEG_MIN | SEG_SEC | SEG_COLON);
REFRESH_INDICATOR_5;
#endif
#endif
/* since we will not get new servo_info in stop mode, we fake a new
servo_info and call osd update routine. */
if ((DiscMode & DISC_OSD_ON) &&
(SystemStatus == SYSTEM_STOP)) {
temp_servo_info = servo_info; /* save real servo info */
servo_info = (bcdmin << 8) | bcdsec;
OSD_time_minute = bcdmin;
OSD_time_second = bcdsec;
OSD_time_track(OSD_TIME_REGION_MASK|OSD_TRACK_REGION_MASK, 0);
OSD_update_info();
servo_info = temp_servo_info; /* put back real servo info */
}
}
void showProgramTime(int type)
{
int time;
if (type!=-1)
TimeMode = type;
if (TimeMode==TIME_SINGLE_ELAPSED) {
time = 0;
}
else if (TimeMode==TIME_SINGLE_REMAIN) {
time = CurrentTrackTime;
}
else {
time = TotalRemainTime;
}
if (!(SystemStatus == SYSTEM_PLAYING)|| type==-1) {
show_panel_time(time);
} else
panel_running_time(ElapsedTime);
}
/*===========================================================================*/
void panel_time_mode_change(void)
{
unsigned char *msg, *c_msg;
/* only single elapsed is available in PBC ON. */
/*
if ((
(DiscMode & DISC_PBC_ON) &&
(SystemStatus == SYSTEM_PLAYING))
#ifdef VCDROM
|| (play_clip == VCD30_PLAY_CLIP)
#endif
) {
#ifndef FU267
Indicator_4 &= ~SEG_HYPHEN;
REFRESH_INDICATOR_4;
#ifndef FU_KANGHUI30
Indicator_5 &= ~SEG_REMAIN;
#endif
REFRESH_INDICATOR_5;
#endif
showProgramTime(TIME_SINGLE_ELAPSED);
assign_osd_msg(msg, MSG_single_elapsed, c_msg, MSG_c_single_elapsed);
} else {
*/
TimeMode++;
if (TimeMode > TIME_TOTAL_REMAIN)
TimeMode = TIME_SINGLE_ELAPSED;
if (TimeMode == TIME_SINGLE_ELAPSED) {
#ifndef FU267
Indicator_4 &= ~SEG_HYPHEN;
REFRESH_INDICATOR_4;
#ifndef FU_KANGHUI30
Indicator_5 &= ~SEG_REMAIN;
#endif
REFRESH_INDICATOR_5;
#endif
showProgramTime(TIME_SINGLE_ELAPSED);
assign_osd_msg(msg, MSG_single_elapsed, c_msg,
MSG_c_single_elapsed);
} else if (TimeMode == TIME_SINGLE_REMAIN) {
#ifndef FU267
Indicator_4 |= SEG_HYPHEN;
REFRESH_INDICATOR_4;
#ifndef FU_KANGHUI30
Indicator_5 |= SEG_REMAIN;
#endif
REFRESH_INDICATOR_5;
#endif
showProgramTime(TIME_SINGLE_REMAIN);
assign_osd_msg(msg, MSG_single_remain, c_msg, MSG_c_single_remain);
} else if (TimeMode == TIME_TOTAL_REMAIN) {
#ifndef FU267
Indicator_4 |= SEG_HYPHEN;
REFRESH_INDICATOR_4;
#ifndef FU_KANGHUI30
Indicator_5 |= SEG_REMAIN;
#endif
REFRESH_INDICATOR_5;
#endif
showProgramTime(TIME_TOTAL_REMAIN);
assign_osd_msg(msg, MSG_total_remain, c_msg, MSG_c_total_remain);
}
/* }*/
/* if (OSD_displayed_regions & OSD_TIME_REGION_MASK) { */
OUTOSD(OSD_FUNCTION_STATUS_REGION, msg, c_msg, QUICK_TIME_OUT);
/* } */
}
/*===========================================================================*/
void panel_running_time(int time)
{
/* host won't call this function if the current state is pause.*/
/* save the current minute and second. 15-08-96 Alger */
/* The playing time is still sending out either regular mode or */
/* PBC ON mode */
if (((DiscMode & DISC_PBC_ON) && (PlayTrack == 0) && (!Motion_Pic))) {
ElapsedTime = 0;
} else {
ElapsedTime = time;
}
if (TimeMode == TIME_SINGLE_REMAIN) {
time = adjCDtime(CurrentTrackTime, time, -1);
} else if (TimeMode == TIME_TOTAL_REMAIN) {
time = adjCDtime(TotalRemainTime, time, -1);
}
/* if system mode is PBC ON, and PlayTrack is 0, we can't display */
/* playing time */
if (!((DiscMode & DISC_PBC_ON) && (PlayTrack == 0) && (!Motion_Pic))) {
show_panel_time(time);
} else {
time = 0;
}
OSD_time_minute = (time >> 16) & 0xff;
OSD_time_second = (time >> 8) & 0xff;
}
/*===========================================================================*/
static char prg_buf[] = " PROGRAM PXX:XX";
#ifdef BILINGUAL_OSD
static char c_prg_buf[] = {
' ', ' ',' ',' ',CN_BIAN1, ' ', ' ', CN_CHENG2, ' ', 'P',
'X', 'X', ':', 'X', 'X', '\0' };
#endif
#define PROGRAM_INDEX_POS 9+3
#define PROGRAM_TRACK_POS (9+3+3)
#define CPROGRAM_INDEX_POS 7+3
#define CPROGRAM_TRACK_POS (7+3+3)
static void show_program_osd_number(int index, int track, int done)
{
prg_buf[PROGRAM_INDEX_POS] = '0'+(hex2bcd[index] >>4);
prg_buf[PROGRAM_INDEX_POS+1] = '0'+(hex2bcd[index] & 0xf);
prg_buf[PROGRAM_TRACK_POS] = '0'+(hex2bcd[track] >>4);
#ifdef BILINGUAL_OSD
c_prg_buf[CPROGRAM_INDEX_POS] = '0'+(hex2bcd[index] >>4);
c_prg_buf[CPROGRAM_INDEX_POS+1] = '0'+(hex2bcd[index] & 0xf);
c_prg_buf[CPROGRAM_TRACK_POS] = '0'+(hex2bcd[track] >>4);
#endif
if (done) {
prg_buf[PROGRAM_TRACK_POS+1] = '0'+(hex2bcd[track] & 0xf);
#ifdef BILINGUAL_OSD
c_prg_buf[CPROGRAM_TRACK_POS+1] = '0'+(hex2bcd[track] & 0xf);
#endif
}
else {
prg_buf[PROGRAM_TRACK_POS+1] = '-';
#ifdef BILINGUAL_OSD
c_prg_buf[CPROGRAM_TRACK_POS+1] = '-';
#endif
}
OUTOSD(OSD_FUNCTION_STATUS_REGION, prg_buf, c_prg_buf, 0);
}
void panel_select_track(int track_num, int flag)
{
{
if (flag == 1 )
addMicroRing(PANEL_TRACK | track_num);
else
addMicroRing(PANEL_TRACK | TotalTrack);
}
}
void panel_osd_on()
{
if (CDinfo.type == CD_NODISC) {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = 'N';
disc_buf1[5] = 'O';
disc_buf1[6] = ' ';
disc_buf1[7] = 'D';
disc_buf1[8] = 'I';
disc_buf1[9] = 'S';
disc_buf1[10] = 'C';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = ' ';
c_disc_buf1[7] = CN_WU2;
c_disc_buf1[8] = ' ';
c_disc_buf1[9] = CN_DIE2;
c_disc_buf1[10] = ' ';
OUTOSD(2,disc_buf1,c_disc_buf1,0);
} else {
OSD_time_track(OSD_TIME_REGION_MASK|OSD_TRACK_REGION_MASK, 0);
if (cd_stop) {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = ' ';
disc_buf1[5] = ' ';
disc_buf1[6] = ' ';
disc_buf1[7] = 'S';
disc_buf1[8] = 'T';
disc_buf1[9] = 'O';
disc_buf1[10] = 'P';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = CN_TING2;
c_disc_buf1[7] = ' ';;
c_disc_buf1[8] = CN_ZHI3;
c_disc_buf1[9] = ' ';
c_disc_buf1[10] = ' ';
OUTOSD(2,disc_buf1,c_disc_buf1,0);
} else {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = ' ';
disc_buf1[5] = ' ';
disc_buf1[6] = ' ';
disc_buf1[7] = 'P';
disc_buf1[8] = 'L';
disc_buf1[9] = 'A';
disc_buf1[10] = 'Y';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = CN_FANG4;
c_disc_buf1[7] = ' ';
c_disc_buf1[8] = CN_YING3;
c_disc_buf1[9] = ' ';
c_disc_buf1[10] = ' ';
OUTOSD(2,disc_buf1,c_disc_buf1,0);
}
if (CDinfo.type == CD_VCD) {
if (PSD_size > 0) {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = 'V';
disc_buf1[5] = 'C';
disc_buf1[6] = 'D';
disc_buf1[7] = ' ';
disc_buf1[8] = '2';
disc_buf1[9] = '.';
disc_buf1[10] = '0';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = 'V';
c_disc_buf1[4] = 'C';
c_disc_buf1[5] = 'D';
c_disc_buf1[6] = '2';
c_disc_buf1[7] = '.';
c_disc_buf1[8] = '0';
c_disc_buf1[9] = CN_DIE2;
c_disc_buf1[10] =' ';
OUTOSD(5,disc_buf1,c_disc_buf1,0);
} else {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = ' ';
disc_buf1[5] = ' ';
disc_buf1[6] = ' ';
disc_buf1[7] = ' ';
disc_buf1[8] = 'V';
disc_buf1[9] = 'C';
disc_buf1[10] = 'D';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = 'V';
c_disc_buf1[7] = 'C';
c_disc_buf1[8] = 'D';
c_disc_buf1[9] = CN_DIE2;
c_disc_buf1[10] = ' ';
OUTOSD(5,disc_buf1,c_disc_buf1,0);
}
if (PBC_on) {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = ' ';
disc_buf1[5] = ' ';
disc_buf1[6] = ' ';
disc_buf1[7] = ' ';
disc_buf1[8] = 'P';
disc_buf1[9] = 'B';
disc_buf1[10] = 'C';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = ' ';
c_disc_buf1[7] = ' ';
c_disc_buf1[8] = 'P';
c_disc_buf1[9] = 'B';
c_disc_buf1[10] = 'C';
OUTOSD(8,disc_buf1,c_disc_buf1,0);
} else {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = 'C';
disc_buf1[4] = 'O';
disc_buf1[5] = 'N';
disc_buf1[6] = 'T';
disc_buf1[7] = 'I';
disc_buf1[8] = 'N';
disc_buf1[9] = 'U';
disc_buf1[10] = 'E';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = FONT_LIAN;
c_disc_buf1[7] = ' ';
c_disc_buf1[8] = CN_FANG4;
c_disc_buf1[9] = ' ';
c_disc_buf1[10] = ' ';
OUTOSD(8,disc_buf1,c_disc_buf1,0);
}
} else {
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = ' ';
disc_buf1[4] = ' ';
disc_buf1[5] = ' ';
disc_buf1[6] = ' ';
disc_buf1[7] = 'C';
disc_buf1[8] = 'D';
disc_buf1[9] = 'D';
disc_buf1[10] = 'A';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = 'C';
c_disc_buf1[6] = 'D';
c_disc_buf1[7] = 'D';
c_disc_buf1[8] = 'A';
c_disc_buf1[9] = CN_DIE2;
c_disc_buf1[10] = ' ';
OUTOSD(5,disc_buf1,c_disc_buf1,0);
disc_buf1[0] = ' ';
disc_buf1[1] = ' ';
disc_buf1[2] = ' ';
disc_buf1[3] = 'C';
disc_buf1[4] = 'O';
disc_buf1[5] = 'N';
disc_buf1[6] = 'T';
disc_buf1[7] = 'I';
disc_buf1[8] = 'N';
disc_buf1[9] = 'U';
disc_buf1[10] = 'E';
c_disc_buf1[0] = ' ';
c_disc_buf1[1] = ' ';
c_disc_buf1[2] = ' ';
c_disc_buf1[3] = ' ';
c_disc_buf1[4] = ' ';
c_disc_buf1[5] = ' ';
c_disc_buf1[6] = FONT_LIAN;
c_disc_buf1[7] = ' ';
c_disc_buf1[8] = CN_FANG4;
c_disc_buf1[9] = ' ';
c_disc_buf1[10] = ' ';
OUTOSD(8,disc_buf1,c_disc_buf1,0);
}
}
}
#ifdef TWO_CDS
#ifdef FU271
void panel_disc_slot(int number)
{
addMicroRing(PANEL_DISC_SLOT | number);
if ((disc_ltoc >> 1) & 0x01)
Indicator_1 |= SEG_DISC_1;
else
Indicator_1 &= ~SEG_DISC_1;
REFRESH_INDICATOR_1;
if ((disc_ltoc >> 3) & 0x01)
Indicator_1 |= SEG_DISC_2;
else
Indicator_1 &= ~SEG_DISC_2;
REFRESH_INDICATOR_1;
if ((disc_ltoc >> 5) & 0x01)
Indicator_1 |= SEG_DISC_3;
else
Indicator_1 &= ~SEG_DISC_3;
REFRESH_INDICATOR_1;
}
void panel_disc_slotrun(int number)
{
addMicroRing(PANEL_DISC_SLOT | number);
if (number == 0) {
Indicator_5 &= ~SEG_DISC_1R;
Indicator_5 &= ~SEG_DISC_2R;
Indicator_5 &= ~SEG_DISC_3R;
REFRESH_INDICATOR_5;
} else if (number == 1) {
Indicator_5 |= SEG_DISC_1R;
Indicator_5 &= ~SEG_DISC_2R;
Indicator_5 &= ~SEG_DISC_3R;
REFRESH_INDICATOR_5;
} else if (number == 2) {
Indicator_5 |= SEG_DISC_2R;
Indicator_5 &= ~SEG_DISC_1R;
Indicator_5 &= ~SEG_DISC_3R;
REFRESH_INDICATOR_5;
} else if (number == 3) {
Indicator_5 |= SEG_DISC_3R;
Indicator_5 &= ~SEG_DISC_1R;
Indicator_5 &= ~SEG_DISC_2R;
REFRESH_INDICATOR_5;
}
}
#endif
#endif
/*===========================================================================*/
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -