This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Converting analog monochrome video 640x480 to digital

Other Parts Discussed in Thread: TVP5150AM1, TVP5146, TVP7002, TVP5158, TVP5147M1, TVP5151, TVP5154, TVP5146M2, TVP70025I, ADS5282

Hello, Dear TI supports: I am looking for some sort of ADC chip for converting analog video into digital, which usually are used in Video Capture Card (Graber) application, such as THS8083A (discontinued).

In our application, the AD converting is relatively simple, we use one of SENTECH industrial cameras, (P/N is STC-A33A), which outputs black/white monochrome video at about 640x480 pixel only, so some  simpler versions should be working enough for us.

My question is: is there any such AD chip you can recommend us?

Thank you.

Jason Wang

  • Jason,

    What format is the camera output?

    Is the camera output NTSC or PAL compliant? If so you could use the TVP5150AM1 and either disable chroma or configure as S-video and only use the luma channel.

    If the camera output is progressive then you might be able to use the TVP5146/47 and again only use the luma channel.

    If the camera output is VGA with discrete syncs then you might need to use the TVP7002.

    It all really depends on what the actual output format from the camera is.

    BR,

    Steve

  • Hi, Steve, many thanks for the quick answer.

    The camera datasheet does not clearly show what the standard the video outputs in. However, it should be NTSC or PAL, because it is one-wire signal (with additional individual HS and VS SYNC).  And,  since this is 640x480 black/white monochrom video, so I think it should be CCIR or RS170 (the old standard and version before colour-NTSC/PAL came out). Am i right?

     

    Thanks again.

     

    Jason

  • You say single wire but then say with additional individual H & V ?

    The way to check is to connect the camera to a standard TV composite video input and if the image looks good then it is NTSC/PAL and one of the TVP decoders should work.

    The TVP decoders by default will generate 720 pixels per line but some can be configured in square pixel mode to generate 640 output pixels per line.

    BR,

    Steve

  • Yes, just single wire for the video output.

    As an industrial camera, there is not only the analog output video, but also too many signals including those individual HS and VS. I observed the video signal using scope, HS and VS are also embedded iin the video signal, that means we don't need those individual HS and VS if the camrea is just simply directly connected to a monitor. Here I have one question is that TVP decoders also support PAL/NTSC that is black/white monochrome, not colour? Thank you very much.

  • Yes, the TVP devices can be configured to decode monochrome.

    BR,

    Steve

  • Hi, Steve:

    We want the converted data to be in general format, just like what a general ADC device outputs, that we can take for further processing by processor and FPGA. It seems that TVP devices output dedicated formats.

    Is there other AD devices other than TVP series?

    Thank you.

    Jason

  • The TVP devices output digital data in BT656 format. this is basically interleaved luma and chroma samples. You could simply ignore every other sample to obtain the luma values.

    Alternatively the TVP514x devices can output in 20 bit mode where the luma and chroma are output at the same time, hence one 10 bit channel contains the luma samples you are looking for.

    Using extended range means the output values will range from 1 to 254 when using 8 bit outputs, 4 to 1016 when using 10 bit outputs.

    BR,

    Steve

  • 4530.Ask-TI.pdf

    Hi, Steve:

    I just attached one page PDF block diagram as for your referring, in which my question is included. After taking look at TI TVP series devices, I think there are many devices our appication can use, and I want to choose one the most suitable, you are profressonal, so consult you for the help.

    Thank you very much.

    Jason 

     

  • If you are feeding multiple cameras in to an FPGA then I would probably suggest the TVP5158 since it has 4 channels of analog input and can multiplex the streams into a single 108MHz stream, thus reducing your PCB complexity.

    The down side of this is that the TVP5158 does not support square pixel sampling so your present 720 pixels per line instead of 640. This is not a fundamental issue though. You can either crop the width to 640 or use the internal scaler to scale the image back down to 640 pixels wide.

    Now, if you are only really considering 640 since the camera sensor is 640 then I would probably not worry too much about that and simply go with the more common 720 pixel sampling.

    On a side note the frame rate from the camera will be 30fps but will be interlaced at 60 fields per second if you are looking at a CVBS signal and the pixel rate will be 13.5MHz (clock rate 27MHz for ITU656 format) per channel.

    The following devices support square pixel when the appropriate patch code is applied...
    TVP5151, TVP5150AM1, TVP5146M2, TVP5147M1 & TVP5154

    The monochrome sampling performance will be almost identical between all these devices, with only the color separation differing. Other differences are power, IO voltage, size, number of analog input switches and the choice will depend on your specific design.

    Having said all this I have just looked at the camera datasheet and it does not appear to be PAL/NTSC output capable. It looks like it is progressive output so you would need to use either the TVP5146/47 in component mode, which would limit you to 60fps, or use the TVP7002 which would allow you to support the higher frame rates.

    BR,

    Steve

  • Hi, Steve:

    Thank you so much.

    It is not key concering whether 640 pixels per line or not. Actually the CCD image sensor has line pixel >640, and there are also other parameters like Effective pixels, Active pixels, etc. 640 is a Spec. value only. And the 720 pixel is okay for us since processing in FPGA and processor is flexible.

    I just forgot one thing to mention in previous post that the camera should be progressive output in both 30/60 frame rate. So you means the chosing should be among TVP5146/47 and TVP7200?

    Another thing is, since the camera simply outputs Mono video, and there are also additional HS, VS, etc., how do you think, that, as a alternative or better way, we use TI ADC devices other than these video Decorders to convert the analog mono image signal? Because the camera's additional HS, VS can be set as input or output, and we can easily gnerate controlling for HS, VS by FPGA. In another words, since the camera's video output has no embedded Colour signal to separate and process, and the embedded HS/VS can be ignored (using the additional HS/VS instead), so ,we can use some general ADC (i.e., multi channel per chip) to easily get the video into datat. If you think so , could  you recommend some for us?

    I will study TVP5146/47 and TVP7200.

     

    Best Regards.

    Jason

     

  • You could potentially use a generic ADC and supply the sync signals to the camera but I think this might be very unreliable if the cameras are more than a few inches away from the FPGA due to signal propagation delays. The H & V are going in the opposite direction so there will be a skew between the syncs and the video that will vary significantly with the cable length.

    You would also need to handle all the blank level detection, sync removal etc... in your FPGA.

    If you are ever only going to need 60fps then the TVP5146/7 is most likely your best bet I think. If you want to support other frame rates then the TVP7002 would be required.

    BR,

    Steve

  • Hi, Steve:

    It has been a few days from the last discussing with you. Hope you are everything very well.

    Here firstly I briefly summarize our project below.

    1. Design a video grabber for 12 same industrial CCD cameras.
    2. The Camera’s Spec. are:

    # Black/White, monochrome;

    # Analog video output, CVBS format (embedded HS/VS Sync);

    # Progressive scan, 60~90 Frame speed, Max pixel clock ~=37 MHz;

     

    3.There are additional HS/VS Sync available other than those embedded in the camera’s video signal.

     

    Since the speed issue, it seems only TVP7002 is working for this application?

    If yes, is it possible that uses one piece of TVP7002 for three cameras, by setting TVP7002 working in RGB mode?

    If no, is there any other chip that is multiple channels for multiple cameras? (similar to  TVP5158 but higher speed).

  • There is a contradiction here.

    The signal cannot be CVBS and progressive.

    CVBS is interlaced and fixed at 30 frames per second (60 fields per second).

    In order to check the camera I suggest connecting it to a normal TV through the yellow connector and see if you get a picture.

    BR,

    Steve

  • Hi, Steve:

    "Prograssive" scan is certain.  "CVBS" is what I named, because the manufacture does not have this Spec. listed.  The below is the link to the camera, in which it just lists VGA format.

    http://www.sentechamerica.com/cameras-progressivescan/STC-A33A.aspx

     

    The manufacture doesn't have video waveform charts available neither, I observed using scope, the waveform is just  like general black/white TV's.

    Actually I understand this camera already, for me, the issue is which ADC chip will be the best. If use TVP7002, and one piece for one camera, there are will be 12 PCS of TVP7002 on board, the size of board is too large, and we cannot separate the board into couple pieces. If use general ADC chip with multiple channel per chipe, it save a lot of space and power, however there are may cause skew issue just as you mentioned last time.

    Thank you very much.

    Jason W 

  • There is still uncertainty here though since black and white TVs use basically CVBS but with no color modulation. It is still interlaced video, but the camera you mention is not interlaced.

    The test is simple. plug it in to the yellow connector on a TV and if you get an image then you can use the TVP51xx devices, otherwise you need to use the TVP7002.

    The TVP7002 can only decode one channel since there is only one timing PLL. If the cameras were 100% locked together in the timing domain then you might be able to use a single TVP7002 for 3 channels, but I am pretty sure this is not the case. This synchronizing is often called gen-locked and is common in the broadcast industry to allow video sources to be mixed without complex processing, but the cameras are more expensive and use more than one signal.

    BR,

    Steve

  • Hi, Steve:

    100% sure, the camera is not interlaced. And there are some sorts of difficulites to try on a monitor right now, such as no lens for the camera (Cannot focus), the connector on the camera is 12-pin Hirose (need soldering wire out), to set camera's frame speed (optional 30, 60 and 90) and others needs RS-232 communication ( I have no such a Host right now).

    Basically there must be a video grabber card to try the camera. Currently I do have a very old grabber card on which the ADC chip is TI THS8083A.

    So, TH8083A is still available for new designs? And is there similar chips that are similar to TVP7002 and multiple channel?

    Thank you very much.

    Jason W

  • If it is not interlaced then the TVP7002 is your only option. The THS8083A is obsolete and replaced by the TVP7002.

    BR,

    Steve

  • Hi, Steve:

    I see.  Thank you very much.

    Jason W

  • Hi, Steve:

    I just noticed that STATUS of  both TVP7002 and TVP70025I is NRND, and our project is a new one, so?

    Thank you.

    Jason W

  • This means that support might be limited.

    The devices are not end of life (eol) and will be available for the foreseeable future.

    BR

    Steve

  • Hi, Steve: 

    I am still in studying the feasibility that uses one piece of TVP7002 for three cameras, in RGB working mode.

    I know you concern the timing differences among the cameras. Actually, we have some ways to make all camera analog video outputs arrive at the R/G/B inputs of TVP7002 at exact same time.

    So, with external pixel clock and HS/VS to TVP7002, this approaching should be working?

    If yes, I have two questions below. 

    1. The true R/G/B signal has no HS/VS embedded, but the camera’s video output includes HS/VS, when the      camera’s output is connected to TVP7002’s R or B input, other than G input (it should be working for HS/VS embedded video), there is no problem?  In another words, internally R/G/B are exactly same?

            2. Because we want the digital outputs R[9:0], G[9:0] and B[9:0] are the data of camera 1,2 and 3 respectively,      but I did not find RGB Output format in I2C configurations that is for this RGB format. Is it Address 15H, bit 6.5?

    Thank you very much.

    Jason W

  • Jason,

    I have serious doubts that you can synchronize all the cameras accurately enough. In order for this to work the video signals would need to reach the TVP7002 within +- about 20nS (VESA recommends H-sync stability to be within 1/3 a pixel period)

    For 640x480 video at 60 fps, including blanking, you get a pixel rate of 27MHz hence a pixel period of 37ns. This means an absolute stability requirement of 12ns and a +- requirement of 6ns.

    12ns transposes to a cable length matching (unidirectional) of 8ft for camera to TVP and if your sync signal has to go from a source to the camera then this would become half that.

    Next, the TVP cannot directly support removing the syncs of R & B. Having said this it will clamp the inputs during the primary input sync period (during G sync ) so effectively the syncs on R & B should be removed. The uncertainty in sync alignment may cause the wrong part of the signal to be clamped though resulting in effectively an increased brightness for that channel.

    See the functional diagram on page 2 of the datasheet for an explanation of the datapath. Register 15h controls the clamping ranges and decimation when down converting to 422. In your case you would configure for 444 output, RGB range (0 to 1024), enable sync on green and disable the color space converter.

    Will this all work? Unfortunately I think you will simply need to try it. There are many things which would need to align perfectly for this to work and only you know your system in enough detail.

    BR,

    Steve

  • Hi, Steve:

    Thank you very much.

    So I am going to use TI ADS5282 (12bit, 8 Channel, serial LVDS output) instead of TVP.  Two pieces of ADS5282 will be enough for 12 cameras.

    We will use DC coupling, that means the ADC will convert everything including HS/VS Sync. Removing HS/VS, knowing Black level, and others, will be processed by FPGA and processor.

    Since for us the video signal is black/white monochrome, the digital processing for the aboe should be not difficult.

    Best Regards.

    Jason W 

     

  • Yes, this might work for you as long as the video signals are fully synchronous  to each other and to the FPGA pixel clock.

    Sorry the TVP devices don't fit your requirements.

    BR,

    Steve

  • Hi: Dear Steve: 

    By some reasons, i.e. the cameras may be upgraded to color one that cause difficult for general ADC to decode, we are turning back to use TVP7002, and just one piece for one camera to avoid timing issues.

    Here I have some questions below to confirm.

    The basic specifications of the camra are listed again below.

    1. White/Black, monochrome;

    2. Analog video output, (Composite format that is: image video signal plus embedded SYNC VS and HS);

    3. 640x480 pixels, VGA;

    4. Progressive scan working mode;

    5. Max. frame rate=90, that means Max. pixel clock ~=36Mhz;

     

    My Questions are as below.

    Q1: The correct connections just are: through a Cap as ac couping, connecting the camera's video output to one of four GIN_1/2/3/4, leaving RIN_1/2/3 and BIN_1/2/3 to GND via a capacitor respectively?

    Q2: In this application, it's not necessary (or optional) to connect the camera's video output to any of three SOGIN_1/2/3?

    Q3: Currently since the video is black/white monochrome, output format can be any of R/G/B, or YCbCr4:4:4:4 or YCbCr4:2:2 with no difference?

    Q4: If the camera is color one, which output format is better between RGB and YCbCr4:4:4? The receiver is FPGA.

    Q5: In case the camera is black/white one, and analog video is on one of GIN_1/2/3/4, the 10-bit digital data are always appear at G[9:0] if select output as YCbCr, and all R[9:0], B[9:0] can be unconnected? If select output format as RGB, the digital data can appear same time at R[9:0], G[9:0] and B[9:0] with equal values? 

    Q6: Since the camera always works in progressive mode, (i.e. at 90 frame rate, the pixel clock frequency is about 36MHz), the digital data also outputs at same pixel clock (36MHz)? That means, the output data (any of R/G/B or YCbCr4:4:4:4 or YCbCr4:2:2) do not convert the data results into Interlaced formate?

    Q7: Any output data of R/G/B or YCbCr4:4:4:4 or YCbCr4:2:2 does not have SYNC (HS and VS) embedded, that means we must use HSOUT/VSOUT/A0 for the receiver such as FPGA? Or HS/VS are embedded already, HSOUT/VSOUT are optional only? If they are embedeed, are they in G[9:0] in any output foramt of RGB or YCbCr?

    Q8: The cameras has additional VS and HS, which one is better, using HS/VS that are embedded the analog video, or using these additional HS/VS by connecting them to HSYNC_A/B/VSYNC_A/B inputs?

     Thank you very much.

    Jason W

  • Jason,

    Q1) Correct.

    Q2) SOG input is required since your signal supplies syncs on the luma channel.

    Q3) I would stay with RGB configuration so there is no color space conversion. In this mode you are really just treating the TVP as an ADC that performs sync extraction and synchronization.

    Q4) It depends on what color format comes from the camera and what processing you want to do with the video data. I would choose a format that performs the least amount of conversions though, so if the camera is RGB then use RGB output from the TVP.

    Q5) Many combinations are possible but the simplest for your monochrome camera is to connect to Y/G input, configure for RGB and simply used the Y/G digital outputs. The remaining outputs can be left unconnected.

    Q6 Correct, the TVP does not perform any format conversion.

    Q7) Discrete sync and embedded sync modes are supported for 422 output mode. Discrete syncs are used in 444 mode. I would recommend discrete sync mode since it gives most flexibility (i.e. you could still use embedded mode if you want)

    Q8) Your choice. Discrete syncs usually allows for higher dynamic range but it depends if your camera is able to output video without syncs in the analog signal or not. With discrete syncs though you need to be more careful about length matching of all the cable connections since any length differences will manifest as skew in the signals.

    BR,

    Steve

  • Hi, Steve:

    Hi, Steve:

     

    After reading the datasheet many times, I still have some confusion regarding the format conversion between analog input and digital output of TVP7002.

    Q1: Are there just two input formats, Y/Pb/Pr and PC graphic, right?

    Q2: Are there just two output formats, Y/Cb/Cr (I consider 4:4:4 and 4:2:2 as one format type) and RGB?

    Q3: RGB output format is just the digitalized PC graphic video?

    Q4: Why does not TVP7002 need to know which input format it is connected?

    Q5: In my case, the monochrome video is connected to Gin (also to SOG), so the format is Y/Pb/Pr (with Pb=0 and Pr=0), or is PC graphic (with R=0 and B=0), or no need to know? For this monochrome input, what will it be if I set output 4:4:2 in I2C-register 15H (page 34)? Or what I should set for the output?

    Q6: The correct idea is the selection is input-dependent? For example, if the input is PC graphic, the output can be set to 4:4:4 only, and actually this “4:4:4” is just digitalized RGB, not that “4:4:4” of Y/Cr/Cb, and so cannot set to “4:2:2”? 

     

    Thank you very much.

     

    Jason W

  • Jason,

    The functional diagram on page 2 of the datasheet should help understand the flow.

    Q1) Sort of, yes, but there are also options for signals with analog sync embedded, so you can have PC graphics with and without embedded syncs. In theory you can also capture YPbPr with discrete syncs, but this is much less common.

    Q2) You shouldn't really think of it in these terms. The output format is really more like 422 or 444, then embedded digital syncs or discrete syncs. If you look at the block diagram the output formatter does not care what the actual color format it receives is, it just packages it up. Likewise the color space converter and decimation filters don't care what the input color format is. You can either pass the digitized data through the CSC or not. Likewise yo can either decimate from 444 to 422 or not. The TVP doesn't care.

    Q3) I think what you are really asking here is what is the full range output? The output formatter can clamp and insert embedded synchronization codes, or not.

    Q4) It doesn't really. What is does need to know though is how you want to clamp, gain, offset, convert and format. It is up to you to decide based on your knowledge of the analog input format and your desired digital output format how you want to transpose the signal. The TVP itself does not care.

    Q5) In your specific case you need to clamp, offset and gain the analog input to remove the analog embedded syncs. This is typically the same as for a YPbPr input, so the simplest way to achieve this is to pretend it is a 480P YPbPr input. Next, you need to configure the color space converter (CSC) to transform and/or otherwise manipulate the digitized samples into an output color space that suits you. In your case simply passing through in touched will suffice. This would put the monochrome samples on the Y/G digital output stream and the other 2 channels (GB/CbCr) would be 0. If you wanted/needed this to look like PC RGB then you could use the CSC to copy the Y/G input to the other 2 channels. Alternatively if you needed YCbCr output then you could use the CSC to 'convert' the input such that the Cb & Cr values = 0 (note, these are signed values). The Y/G digital output would be unchanged though.

    Q6) No, any input can be any output. The TVP simply does not care.

    As I say, the block diagram should help understand that each step is completely independent and you can configure as you want/need.

    BR,

    Steve

  • Hi, Steve, you help me a lot, thank you.

    Still have  two questions.

    1. If I change my camera from monochrome to color one, and this color camera’s output is still one-wire      analog (Luma, Color and HS/VS signals are embedded together, just like the old TV’s video), can TVP7002 do the decoding? I am asking this question because when we choose the camera, there are two basic types, one is one-wire analog output, while another is three-wire R-G-B output, if one-wire is working using TVP7002, we prefer to use this one-wire output color camera.
    2. If the input is three-wire YPbPr (Color, not monochrome), which are connected to TVP7002’s Y/Pb/Pr      respectively, can I get the digital output in RGB format? (I see CSC only for conversion from RGB to YPbPr).

     

    Best Regards.

    Jason Wang

  • The TVP7002 cannot decode CVBS so cannot be used for one wire color video.

    The TVP7002 CSC is fully programmable so can convert between format.

    BR,

    Steve

  • Hi, Steve:

    What do the outputs of data and clock will be for TVP7002 during H-Blank and V-Blank periods?

     

    Thanks.

    Jason W 

  • Clock will be active, data is undefined and probably the last active value. This may be different in embedded sync mode.

    BR,

    Steve

  • Hi, Steve:

    What is the output waveform of pin SOGOUT of TVP7002? What is the timing relation between it and others? If I use VSOUT and HSOUT, do I still need using it? I know SOGOUT is a digital output, but i cannot find the detaild description in the datasheet.

     

    Thank you

    Jason W

  • This is a composite H/V sync signal output (not to be confused with composite NTSC/PAL video sync) which reflects the sliced (detected) input sync on green. It can be used to verify the slicing levels are set correct or for systems which require a composite sync.

    I doubt you need it, but that depends entirely on what you are connecting the TVP7002 to.

    BR,

    Steve