AnsweredAssumed Answered

ADV7180 Register configuration causes out of sync video

Question asked by MikeYeh on Jan 18, 2011
Latest reply on Jan 20, 2011 by DaveD

I'm running into a peculiar issue with the ADV7180 decoder that is used on a dev board at work. An analog video source (an old nintendo) is connected to the ADV7180 on Ain1, which is then run through Altera's VIP megacore function suite and finally output on an Chrontel CH7010B encoder. Without setting the configuration registers on the ADV7180, everything works fine and the nintendo feed is successfully displayed on an lcd. However, if I try to configure the registers per the datasheet, the image becomes out of sync.

 

The code I have used to configure the registers is:

 

 

i2c_reg_write(i2c_base, decoder_base, 0x00, 0x00);     //INSELF = CVBS in on Ain1
i2c_reg_write(i2c_base, decoder_base, 0x04, 0x57);     //Enable SFL
i2c_reg_write(i2c_base, decoder_base, 0x17, 0x41);     //Select SH1
i2c_reg_write(i2c_base, decoder_base, 0x31, 0x02);     //Clear NEWAVMODE, SAV/EAV to suit ADV video encoders
i2c_reg_write(i2c_base, decoder_base, 0x3D, 0xA2);     //MWE enable manual window, color kill threshold to 2
i2c_reg_write(i2c_base, decoder_base, 0x3E, 0x6A);     //BLM optimization
i2c_reg_write(i2c_base, decoder_base, 0x3F, 0xA0);     //BGB optimization
i2c_reg_write(i2c_base, decoder_base, 0x0E, 0x80);     //Hidden Space
i2c_reg_write(i2c_base, decoder_base, 0x55, 0x81);     //ADC Configuration
i2c_reg_write(i2c_base, decoder_base, 0x0E, 0x00);     //User Space
This is exactly as shown in Table 111 on the ADV7180 datasheet example. My confusion is in register 0x00, wherein the VID_SEL is set to autodetect NTSC J, amongst other video types. I am quite sure that the nintendo I am using is outputting an NTSC M signal. I have tried multiple configurations of register 0x00 and here are the results of each value:
// 0x00      --out of sync
// 0x01      --blue screen
// 0x10      --out of sync
// 0x30      --out of sync
// 0x50      --out of sync
Does anyone have any suggestions what might be causing the out of sync video when the decoder is manually configured?

Outcomes