Altera_Forum
Honored Contributor
14 years agoCameraLink connectivity issues with a dev kit
I am trying to connect a Dalsa grayscale video camera to a DE2-115 board using CameraLink base mode connectivity. I am using the CLR-HSMC receiver card to achieve that:
http://www.terasic.com.tw/cgi-bin/page/archive.pl?language=english&categoryno=68&no=588&partno=2 (http://www.terasic.com.tw/cgi-bin/page/archive.pl?language=english&categoryno=68&no=588&partno=2) My aim is just to be able to display on a VGA monitor for now. Terasic provides a demo code using a different color camera which outputs 10-bit data and is connected to a DE2-115 via the CLR-HSMC and then displays to VGA. I am trying to modify this code to satisfy my requirements but I am stuck on a few things. From the block diagram shown on the Terasic webpage, the LVDS (DS90CR288A ) Receiver acts as a deserializer and converts the four LVDS data streams into 28 bits of LVCMOS data. Then the author of the code 'builds' the 10-bit camera output by using the following code, where CLRRX_BASE is the 28-bit data:
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
assign CLR_BASE_D = CLRRX_BASE;
My question is: How do I know which bit of the 28 bits must be used to 'build' the 10-bit camera output? For example, why is CLR_BASE_D[5] = CLRRX_BASE[6] and not [5]? If my camera is also outputting a 10-bit data, can I just use that same bit order? Now suppose my camera outputs only 8-bit data, do I just use bits 0,1,2,3,4,6,27,5 with the last bit 5 being the MSB? I'd be very grateful if somebody with experience using cameras and CameraLink (or that CLR-HSMC card) could give me some advice on this. PS: I can upload the full demo code if that's easier to understand.