Has anyone been able to capture with v4l2 frames of interlaced video? Using the latest driver, I see the timings and format being detected, and I notice my capture settings being set to the same:
[14349.739706] tc358743 7-000f: -----Signal status-----
[14349.739712] tc358743 7-000f: TMDS signal detected: yes
[14349.739718] tc358743 7-000f: Stable sync signal: yes
[14349.739723] tc358743 7-000f: PHY PLL locked: yes
[14349.739729] tc358743 7-000f: PHY DE detected: yes
[14349.749102] tc358743 7-000f: 495:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 1
[14349.749111] tc358743 7-000f: Detected format: 1920x1080i30.0 (2200x562)
[14349.749118] tc358743 7-000f: horizontal: fp = 0, -sync = 280, bp = 0
[14349.749124] tc358743 7-000f: vertical: fp = 0, -sync = 22, bp = 0
[14349.749130] tc358743 7-000f: vertical bottom field: fp = 0, -sync = 23, bp = 0
[14349.749135] tc358743 7-000f: pixelclock: 37092000
[14349.749140] tc358743 7-000f: flags (0x0):
[14349.749144] tc358743 7-000f: standards (0x0):
[14349.749151] tc358743 7-000f: Configured format: 1920x1080i30.0 (2200x562)
[14349.749155] tc358743 7-000f: horizontal: fp = 0, -sync = 280, bp = 0
[14349.749160] tc358743 7-000f: vertical: fp = 0, -sync = 22, bp = 0
[14349.749165] tc358743 7-000f: vertical bottom field: fp = 0, -sync = 23, bp = 0
[14349.749169] tc358743 7-000f: pixelclock: 37092000
[14349.749173] tc358743 7-000f: flags (0x0):
[14349.749177] tc358743 7-000f: standards (0x0):
But, after setting those in my code, using:
struct v4l2_dv_timings dv = {0};
r = xioctl(fd_video,VIDIOC_QUERY_DV_TIMINGS, &dv);
r = xioctl(fd_video,VIDIOC_S_DV_TIMINGS, &dv);
fmt.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
xioctl(fd_video, VIDIOC_G_FMT, &fmt);
fmt.fmt.pix.field = V4L2_FIELD_ALTERNATE;
//fmt.fmt.pix.pixelformat = V4L2_PIX_FMT_UYVY;
fmt.fmt.pix.pixelformat = V4L2_PIX_FMT_ABGR32;
(I am using ABGR32 since UYVY does not appear to be supported by the TC358743 chip in interlaced mode.
When I create my buffers, I can see they are wrong:
OFFSET: 0, START -1805475840, LENGTH: 8294400
That length corresponds to 1920x1080x4 which would be correct for a full frame.
When I enable detailed csi reporting, I see:
[14518.060494] tc358743 7-000f: Calling tc358743_query_dv_timings
[14518.074711] tc358743 7-000f: 495:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 1
[14518.074744] tc358743 7-000f: tc358743_query_dv_timings: 1920x1080i30.0 (2200x562)
[14518.074762] tc358743 7-000f: tc358743_query_dv_timings: @@@@@ timings out of range
Over and over and the captured from is green.
Any ideas?