CX25870/871
Appendix D Closed Caption Pseudo Code
Flicker-Free Video Encoder with Ultrascale Technology
//CCSTAT_O = 1 because CC data has already been written for
Field 1=ODD field //& has not yet been encoded onto analog video
output signal for the odd field
//CCSTAT_O will be reset immediately after the clock run-in
online 284 for NTSC //and line 335 for PAL
return 0;
//CCSTAT_0 = 1 so CC bytes were not encoded
on this pass //through the
869_CCEncoding_onField1 procedure
return 0;
}
//****************************************************
Bt869ReadbackFxn(int ESTATUS)
//Unlike the previous Conexant VGA encoder, the CX870/871
does have //registers than can be directly read-back. As a
result this //Bt869ReadbackFxn should only be used IF the
software engineer seeks to use //the legacy method of read-
back found in the Bt868/869.
{
int ReadMONSTAT_CCArray[8] = {0}; //entire array now holds 0
Write ESTATUS;
of register 0xC4}
//ESTATUS[1:0]= {bits 7(MSb) and 6
//
ESTATUS[1:0]= 01 from function call.
//
00 and 10 possible for ESTATUS
as well
//
yielding different readback
information
Graphics controller issues 0x89 or 0x8B for the CX870/871's
device address;
//no subaddress required here since
the CX870/871
//only has 1 read register to check with the
legacy method
//This step has the effect of reading a single byte
//of data from the CX870/871
//Table 2-2 Readback bit map says
that MONSTAT_A,B,C //bits = bits 7-5
//while Bit 4 = CCSTAT_E, bit 3 =
CCSTAT_O,
// bits 2-0 = FIELD[2:0]
// This ensures the least significant bit of the device
write portion of //the transaction is '1' which indicates
to the encoder that it must //send a byte of data on the
next I2C transaction. Do not write a //subaddress to the
CX870/871(this is not necessary since the CX870/871
//only appears to have 1 read register with the legacy
method) and then //read the "next" byte after the ACK.
Controller_Transmits_I2C_STOP; //I2C Master must issue an
I2C STOP to
100381B
Conexant
D-5