{"id":1673,"date":"2019-02-20T11:13:28","date_gmt":"2019-02-20T10:13:28","guid":{"rendered":"http:\/\/section5.ch\/?p=1673"},"modified":"2019-07-06T10:20:16","modified_gmt":"2019-07-06T08:20:16","slug":"lattice-vip-imx214-crosslink-issues","status":"publish","type":"post","link":"https:\/\/section5.ch\/index.php\/2019\/02\/20\/lattice-vip-imx214-crosslink-issues\/","title":{"rendered":"Lattice VIP IMX214\/CrossLink issues"},"content":{"rendered":"<h3>Overview<\/h3>\n<p>The imx214 sensors are configured using the &#8216;default&#8217; sequence from the reference design, but at a lower PLL frequency around 54 MHz. Both sensors are started synchronously.<\/p>\n<h4>Single camera configuration<\/h4>\n<p>This setup uses the single camera bit file provided from Helion Vision.<\/p>\n<ul>\n<li>Framing errors occur early in the entire video stream, then it runs stable for a very long time (recorded up to 150&#8217;000 frames)<\/li>\n<\/ul>\n<h4>Dual camera configuration<\/h4>\n<p>This setup uses the stereo camera reference design from the Lattice website (DualCSI2toRaw10_impl1.bit).<\/p>\n<figure id=\"attachment_1674\" aria-describedby=\"caption-attachment-1674\" style=\"width: 300px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001.jpg\"><img loading=\"lazy\" class=\"wp-image-1674 size-medium\" src=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001-300x169.jpg\" alt=\"\" width=\"300\" height=\"169\" srcset=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001-300x169.jpg 300w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001-416x234.jpg 416w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001-768x432.jpg 768w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001-1024x576.jpg 1024w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00001.jpg 1920w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-1674\" class=\"wp-caption-text\">Color shifts<\/figcaption><\/figure>\n<figure id=\"attachment_1675\" aria-describedby=\"caption-attachment-1675\" style=\"width: 300px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016.jpg\"><img loading=\"lazy\" class=\"wp-image-1675 size-medium\" src=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016-300x169.jpg\" alt=\"\" width=\"300\" height=\"169\" srcset=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016-300x169.jpg 300w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016-416x234.jpg 416w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016-768x432.jpg 768w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016-1024x576.jpg 1024w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/test00016.jpg 1920w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-1675\" class=\"wp-caption-text\">Bayer pattern offsets<\/figcaption><\/figure>\n<p>Issues:<\/p>\n<ul>\n<li>Framing very unstable, right image shows interesting color shift<\/li>\n<li>Offset changing from frame to frame, displaying as above<\/li>\n<\/ul>\n<h4>Further analysis<\/h4>\n<p>The reason for the occuring DEMUX errors from the JPEG encoder is occasional invalid framing. Frames are then dropped and the image is out of sync.<\/p>\n<p>Possibilities:<\/p>\n<ol>\n<li>Framing from sensor is wrong (critical sensor configuration mode)<\/li>\n<li>Framing from Sensor correct, but translation hickups inside CrossLink<\/li>\n<li>Irregular timing (too short Hblank time) stressing the JPEG encoder FIFOs<\/li>\n<\/ol>\n<p>(1) can not be verified without a MIPI timing debugger. (2) can not be simulated due to closed source of CrossLink Firmware.<\/p>\n<p>For (3), the LINE_VALID (blue) and FRAME_VALID (yellow) signals, both routed to external debug header display as follows:<\/p>\n<figure id=\"attachment_1676\" aria-describedby=\"caption-attachment-1676\" style=\"width: 300px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/imx214_framing.png\"><img loading=\"lazy\" class=\"size-medium wp-image-1676\" src=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/imx214_framing-300x219.png\" alt=\"\" width=\"300\" height=\"219\" srcset=\"https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/imx214_framing-300x219.png 300w, https:\/\/section5.ch\/wp-content\/uploads\/2019\/02\/imx214_framing.png 320w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-1676\" class=\"wp-caption-text\">IMX214 sensor framing via CrossLink<\/figcaption><\/figure>\n<p>The above behaviour of two subsequent pixel lines with short blanking time occur in the current Stereo and single sensor CrossLink firmware configuration.<\/p>\n<h4>Potential remedies<\/h4>\n<p>Sorted by ascending complexity:<\/p>\n<ul>\n<li>Find magic setting for more regular MIPI data transfer<\/li>\n<li>Use another sensor (parallel interface)<\/li>\n<li>Try to fix irregular timing by a &#8216;sanity checker&#8217; interface with line buffer<\/li>\n<li>Revisit Crosslink firmware (consider fixes by third party)<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Overview The imx214 sensors are configured using the &#8216;default&#8217; sequence from the reference design, but at a lower PLL frequency around 54 MHz. Both sensors are started synchronously. Single camera configuration This setup uses the single camera bit file provided from Helion Vision. Framing errors occur early in the entire video stream, then it runs [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1686,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[17,23,29],"tags":[],"_links":{"self":[{"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/posts\/1673"}],"collection":[{"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/comments?post=1673"}],"version-history":[{"count":7,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/posts\/1673\/revisions"}],"predecessor-version":[{"id":1688,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/posts\/1673\/revisions\/1688"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/media\/1686"}],"wp:attachment":[{"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/media?parent=1673"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/categories?post=1673"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/section5.ch\/index.php\/wp-json\/wp\/v2\/tags?post=1673"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}