📄 csaa7128.c
字号:
/******************************************************************************//* Csaa7128.c : Implementation of the AD7170A interface* REALmagic Quasar Hardware Library* Created by Aurelia Popa-Radu* Copyright Sigma Designs Inc* Sigma Designs Proprietary and confidential* Created on 04/15/02* Description:/******************************************************************************//****h* HwLib/Csaa7128_implementation * NAME * HwLib/Csaa7128_implementation * COPYRIGHT * Copyright Sigma Designs Inc * Sigma Designs Proprietary and confidential * DESCRIPTION * Csaa7128 implementation of the ITvEncoder interface: * void Csaa7128__Init(ITvEncoder* pITvEncoder) * void Csaa7128__InitTvEncoder(ITvEncoder* pITvEncoder) * void Csaa7128__ProgramTV(ITvEncoder* pITvEncoder, * DWORD TvMaster, DWORD nbits, DWORD ccir, DWORD TvStandard, DWORD DacsEnable) * void Csaa7128__SetTVStandard(ITvEncoder* pITvEncoder, DWORD TvStandard) * void Csaa7128__SetCurrentYcYuvRgb(ITvEncoder* pITvEncoder, DWORD YcYuvRgb) * void Csaa7128__SendCCData(ITvEncoder* pITvEncoder, BYTE field, BYTE* Data) * void Csaa7128__ShowCloseCaption(ITvEncoder* pITvEncoder) * void Csaa7128__HideCloseCaption(ITvEncoder* pITvEncoder) * void Csaa7128__DisableTVBlackout(ITvEncoder* pITvEncoder)/******************************************************************************/#include "pch.h"#if defined SAA7128_OBJECT#include "ci2c.h"#include "ctvenc.h"#include "csaa7128.h"BYTE SAA7128_McrvNtscOff[] ={ 0x01, 0x00, 0x03, 0x00, 0x04, 0x00, 0x05, 0x00, 0x06, 0x00, 0x07, 0x00, 0x08, 0x00, 0x10, 0x00, 0x11, 0x00, 0x12, 0x00, 0x14, 0x00, 0x15, 0x00, 0x20, 0x00, 0x21, 0x00, 0x24, 0x00, 0x25, 0x00, 0x30, 0x00, 0x31, 0x00, 0x33, 0x00, 0x36, 0x00, 0x60, 0x00, // AGC 0x7d, 0x00, 0x5d, 0x3A, // BLCLK+MCRV 0x32 0x33 ??? 0x5e, 0x2E, // BLNNL+MCRV 0x6d 0x35 ??? 0x5f, 0x2E, // BLNVB+MCRV 0x2d 0x35 ???// 0x54, 0x0c, // VPSEN *** Bit7 should be 0 when MCRV On// 0x5b, 0x74, // GAINU *** It should be ???? when MCRV On// 0x5c, 0xaa, // GAINV *** It should be ???? when MCRV On// 0x61, 0x11, // YGS *** Bit 4 should be 0 when MCRV On// 0x62, 0x3f, // BSTA *** It should be ???? when MCRV On// 0x6f, 0x00, // CC.. *** Bit 5 should be 0x00 when MCRV On};BYTE SAA7128_McrvNtsc2[] ={ 0x01, 0x1e, 0x03, 0x11, 0x04, 0x26, 0x05, 0x0a, 0x06, 0xc5, 0x07, 0xff, 0x08, 0x03, 0x10, 0x11, 0x11, 0xad, 0x12, 0x60, 0x14, 0x0f, 0x15, 0x78, 0x20, 0x9b, 0x21, 0x04, 0x24, 0x00, 0x25, 0x00, 0x30, 0x1b, 0x31, 0x04, 0x33, 0x0f, 0x36, 0x0f, 0x60, 0x00, // AGC 0x7d, 0xE8, 0x5d, 0x1B, // BLCLK+MCRV 0x32 0x33 ??? 0x5e, 0x0E, // BLNNL+MCRV 0x6d 0x35 ??? 0x5f, 0x2E, // BLNVB+MCRV 0x2d 0x35 ???// 0x54, 0x0c, // VPSEN *** Bit7 should be 0 when MCRV On// 0x5b, 0x74, // GAINU *** It should be ???? when MCRV On// 0x5c, 0xaa, // GAINV *** It should be ???? when MCRV On// 0x61, 0x11, // YGS *** Bit 4 should be 0 when MCRV On// 0x62, 0x3f, // BSTA *** It should be ???? when MCRV On// 0x6f, 0x00, // CC.. *** Bit 5 should be 0x00 when MCRV On};BYTE SAA7128_McrvNtsc3[] ={ 0x01, 0x18, 0x03, 0x15, 0x04, 0x22, 0x05, 0x0a, 0x06, 0xc5, 0x07, 0xff, 0x08, 0x03, 0x10, 0x15, 0x11, 0xad, 0x12, 0x60, 0x14, 0x0f, 0x15, 0x78, 0x20, 0x9b, 0x21, 0x04, 0x24, 0x00, 0x25, 0x00, 0x30, 0x1b, 0x31, 0x04, 0x33, 0x0f, 0x36, 0x0f, 0x60, 0x00, // AGC 0x7d, 0xE8, 0x5d, 0x1B, // BLCLK+MCRV 0x32 0x33 ??? 0x5e, 0x0E, // BLNNL+MCRV 0x6d 0x35 ??? 0x5f, 0x2E, // BLNVB+MCRV 0x2d 0x35 ???// 0x54, 0x0c, // VPSEN *** Bit7 should be 0 when MCRV On// 0x5b, 0x74, // GAINU *** It should be ???? when MCRV On// 0x5c, 0xaa, // GAINV *** It should be ???? when MCRV On// 0x61, 0x11, // YGS *** Bit 4 should be 0 when MCRV On// 0x62, 0x3f, // BSTA *** It should be ???? when MCRV On// 0x6f, 0x00, // CC.. *** Bit 5 should be 0x00 when MCRV On};BYTE SAA7128_McrvPal0ff[] ={ 0x01, 0x00, 0x03, 0x00, 0x04, 0x00, 0x05, 0x00, 0x06, 0x00, 0x07, 0x00, 0x08, 0x00, 0x10, 0x00, 0x11, 0x00, 0x12, 0x00, 0x14, 0x00, 0x15, 0x00, 0x20, 0x00, 0x21, 0x00, 0x24, 0x00, 0x25, 0x00, 0x30, 0x00, 0x31, 0x00, 0x33, 0x00, 0x36, 0x00, 0x60, 0x00, // AGC 0x7d, 0x00, 0x5d, 0x17, // BLCLK+MCRV 0x32 0x33 ??? 0x5e, 0x19, // BLNNL+MCRV 0x6d 0x35 ??? 0x5f, 0x35, // BLNVB+MCRV 0x2d 0x35 ???// 0x54, 0x0c, // VPSEN *** Bit7 should be 0 when MCRV On// 0x5b, 0x74, // GAINU *** It should be ???? when MCRV On// 0x5c, 0xaa, // GAINV *** It should be ???? when MCRV On// 0x61, 0x11, // YGS *** Bit 4 should be 0 when MCRV On// 0x62, 0x3f, // BSTA *** It should be ???? when MCRV On// 0x6f, 0x00, // CC.. *** Bit 5 should be 0x00 when MCRV On};BYTE SAA7128_McrvPal123[] ={ 0x01, 0x1b, 0x03, 0x22, 0x04, 0x2b, 0x05, 0x08, 0x06, 0x74, 0x07, 0x55, 0x08, 0x01, 0x10, 0x22, 0x11, 0x15, 0x12, 0x60, 0x14, 0x07, 0x15, 0x7e, 0x20, 0xbb, 0x21, 0x72, 0x24, 0x02, 0x25, 0x54, 0x30, 0x2c, 0x31, 0x04, 0x33, 0xfe, 0x36, 0x7e, 0x60, 0x00, // AGC 0x7d, 0xc8, 0x5d, 0x17, // BLCLK+MCRV 0x32 0x33 ??? 0x5e, 0x19, // BLNNL+MCRV 0x6d 0x35 ??? 0x5f, 0x35, // BLNVB+MCRV 0x2d 0x35 ???// 0x54, 0x0c, // VPSEN *** Bit7 should be 0 when MCRV On// 0x5b, 0x74, // GAINU *** It should be ???? when MCRV On// 0x5c, 0xaa, // GAINV *** It should be ???? when MCRV On// 0x61, 0x11, // YGS *** Bit 4 should be 0 when MCRV On// 0x62, 0x3f, // BSTA *** It should be ???? when MCRV On// 0x6f, 0x00, // CC.. *** Bit 5 should be 0x00 when MCRV On};// The following values are for NTSCBYTE SAA7128[] ={// Philips tables NTSC PAL 0x00, 0x00, // NULL 0x00 0x10 ??? 0x01, 0x00, // MCRV 0x00 0x18 ? 0x03, 0x00, // MCRV 0x00 0x15 ? 0x04, 0x00, // MCRV 0x00 0x22 ? 0x05, 0x00, // MCRV 0x00 0x0a ? 0x06, 0x00, // MCRV 0x00 0xc5 ? 0x07, 0x00, // MCRV 0x00 0xff ? 0x08, 0x00, // MCRV 0x00 0x03 ? 0x10, 0x00, // MCRV 0x00 0x15 ? 0x11, 0x00, // MCRV 0x00 0xad ? 0x12, 0x00, // MCRV 0x00 0x60 ? 0x14, 0x00, // MCRV 0x00 0x0f ? 0x15, 0x00, // MCRV 0x00 0x78 ? 0x20, 0x00, // MCRV ?*** It should be 0x9B 0x21, 0x00, // MCRV 0x00 0x04 ? 0x24, 0x00, // MCRV 0x25, 0x00, // MCRV 0x30, 0x00, // MCRV 0x00 0x1b ? 0x31, 0x00, // MCRV 0x30 0x30 ?*** It should be 0x04 0x33, 0x00, // MCRV 0x00 0x0f ? 0x36, 0x00, // MCRV 0x00 0x0f ? 0x60, 0x00, // MCRV 0x00 0x7b ??? 0x7d, 0x00, // MCRV ?*** macrovision Off 0x26, 0x00, // WSS 0x00 0x80 ? 0x27, 0x00, // WSS 0x28, 0x19, // BS 0x19 0x21 0x29, 0x1D, // BE 0x2a, 0x00, // CG_LSB 0x2b, 0x00, // CG_MSB 0x00 0x06 ? 0x2c, 0x00, // CG_MMSB 0x2d, 0x3F, // DacEn 0x38, 0x1a, // GY 0x39, 0x1a, // GCD 0x3a, 0x1b, // 656... 0x1b 0x13 ? 0x42, 0x00, // KEY1LU 0x00 0x80 ? 0x43, 0x00, // KEY1LV 0x00 0x80 ? 0x44, 0x00, // KEY1LY 0x00 0x80 ? 0x45, 0x00, // KEY2LU 0x00 0x80 ? 0x46, 0x00, // KEY2LV 0x00 0x80 ? 0x47, 0x00, // KEY2LY 0x00 0x80 ? 0x48, 0x00, // KEY1UU 0x00 0x80 ? 0x49, 0x00, // KEY1UV 0x00 0x80 ? 0x4a, 0x00, // KEY1UY 0x00 0x80 ? 0x4b, 0x00, // KEY2UU 0x00 0x80 ? 0x4c, 0x00, // KEY2UV 0x00 0x80 ? 0x4d, 0x00, // KEY2UY 0x00 0x80 ? 0x4e, 0x00, // FADE1 0x4f, 0x00, // FADE2 0x50, 0x00, // FADE3 0x00 0x3F ? 0x51, 0x00, // LUTU 0x00 0x80 ? 0x52, 0x00, // LUTV 0x00 0x80 ? 0x53, 0x00, // LUTY 0x00 0x80 ?
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -