PCVisionplus
Hardware Reference
Registers
3–27
Rev 02; February 8, 2002
3.4.1 PTG Horizontal 1 (PTGH1) R/W
0
7
BADR2 + 0x00
HTOTAL7
HTOTAL6
HTOTAL5
HTOTAL4
HTOTAL3
HTOTAL2
HTOTAL1
HTOTAL0
8
15
HESYNC5
HESYNC4
HESYNC3
HESYNC2
HESYNC1
HESYNC0
HTOTAL9
HTOTAL8
PCP_PTGH1_32
16
23
Reserved
Reserved
Reserved
Reserved
XTALMD
HSYNCPOL
HESYNC7
HESYNC6
24
31
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
HPOL
The PTGH1 register defines the horizontal timing for the Programmable Timing Generator (PTG).
Bit
Mnemonic
Function
0–9
HTOTAL
Horizontal Sync Pixel Count Total
10–17
HESYNC
Horizontal Sync End
18
HSYNCPOL
Horizontal Sync Output Polarity
19
XTALMDHPOL
Internal Timing Horizontal Sync Polarity
20–31
Reserved
“Don’t care”
3.4.1.1 Horizontal Sync Pixel Count Total (HTOTAL) R/W
HTOTAL defines the Programmable Timing Generator (PTG) horizontal total line time. The 10-bit value is the
number of pixel clocks in half the horizontal line time or sync time (duty cycle), including both sync high and sync
low time. In internal timing (XTAL) mode, the PTG generates the horizontal sync (Hsync) output to the camera and
to the PWG to gen-lock the system. The Maximum total line length is 2048 pixel clocks.
“Total Line Time” includes the sync, blank, and active regions. The pixel clock rate is the clock rate programmed into
the frequency synthesizer in XTAL mode. The Total Line Time for RS170 is 63.556 us. The Total Line Time for
CCIR is 64 us. The pixel clock time varies from 50 to 100 ns based on the number of samples per line.
Use the following formula for calculating HTOTAL. Also, refer to the example of XTAL mode programming in
Appendix A.
HTOTAL = [ (Total Line Time (ns)/2) / pixel clock time (ns)] –1
HTOTAL
Function
0
1/2 hsync total = 1 pixel clock
1
1/2 hsync total = 2 pixel clocks
2
1/2 hsync total = 3 pixel clocks
3
1/2 hsync total = 4 pixel clocks
. . .
. . .
1023 (0x3FF)
1/2 hsync total = 1024 pixel clocks
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com