Roamer
Posts: 1
Joined: Thu Nov 28, 2019 4:17 am

Problems with TC358743 and UV4L

Thu Nov 28, 2019 4:25 am

I'm trying to get the TC358743 chip working on an RPI3 according to this article: https://www.linux-projects.org/uv4l/installation/

Loading the driver yields this:

Code: Select all

sudo uv4l --driver raspicam --auto-video_nr --width 640 --height 480 --encoding jpeg –tc358743-i2c-dev=/dev/i2c-1
<notice> [core] Trying to loading driver 'raspicam' from built-in drivers...
<notice> [core] Loading driver 'raspicam' from external plug-in's...
<notice> [driver] Dual Raspicam & TC358743 Video4Linux2 Driver v1.9.63 built Oct  6 2018
<notice> [driver] Detected camera toshh2c, 1920x1080
<notice> [driver] Selected format: 640x480, encoding: jpeg, JPEG Video Capture
<notice> [driver] Framerate max. 30 fps
<notice> [core] Device detected!
<warning> [core] Cannot create /dev/video0 because file already exists
<notice> [core] Registering device node /dev/video1

so it certainly seems like the device is being recognized.

Code: Select all

vcgencmd get_camera                                          
supported=1 detected=1

However, when trying to get a snapshot from the hdmi source, I run into this error:

Code: Select all

dd if=/dev/video1 of=snapshot.jpeg bs=11M count=1
dd: failed to open '/dev/video1': Bad file descriptor

I've searched around the forums and google but nothing I try seems to get this to work.

Any help is of course appreciated!

allegfede
Posts: 26
Joined: Fri Jan 17, 2014 12:01 pm

Re: Problems with TC358743 and UV4L

Fri Jan 24, 2020 5:01 pm

also i was struggling on this damn toshiba based interfaces :D

at the moment i'm testing on a rapsberry pi 2 model b with latest raspbian (buster) and firmware.

I got some hints on the net and i discovered that with latest firmwares you have to add in the boot/config.txt

"dtoverlay=tc358743" on a Pi 3B/3B+

or

"dtoverlay=tc358743,i2c_pins_28_29=1" on almost all other boards.

this results in the following output for the command v4l2-ctl --list-devices:

bcm2835-codec (platform:bcm2835-codec):
/dev/video10
/dev/video11
/dev/video12

unicam (platform:unicam 3f801000.csi):
/dev/video0

I also followed this guide: http://blog.cudmore.io/post/2019/12/14/ ... an-buster/

and i remove the comment (and set to yes the first one) the first 2 lines of the config file: /etc/uv4l/uv4l-raspicam.conf

but still have troubles let it work

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 13100
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Problems with TC358743 and UV4L

Mon Jan 27, 2020 10:33 am

allegfede wrote:
Fri Jan 24, 2020 5:01 pm
also i was struggling on this damn toshiba based interfaces :D

at the moment i'm testing on a rapsberry pi 2 model b with latest raspbian (buster) and firmware.

I got some hints on the net and i discovered that with latest firmwares you have to add in the boot/config.txt

"dtoverlay=tc358743" on a Pi 3B/3B+

or

"dtoverlay=tc358743,i2c_pins_28_29=1" on almost all other boards.

this results in the following output for the command v4l2-ctl --list-devices:

bcm2835-codec (platform:bcm2835-codec):
/dev/video10
/dev/video11
/dev/video12

unicam (platform:unicam 3f801000.csi):
/dev/video0

I also followed this guide: http://blog.cudmore.io/post/2019/12/14/ ... an-buster/

and i remove the comment (and set to yes the first one) the first 2 lines of the config file: /etc/uv4l/uv4l-raspicam.conf

but still have troubles let it work
There are three implementations for this chip:
- the unsupported firmware drivers that you get through raspivid.
- UV4L: closed source, and you'll need support from RpiName / linux-projects.org
- the supported V4L2 kernel drivers that are loaded via "dtoverlay=tc358743".
Trying to mix and match these will cause issues.

With "dtoverlay=tc358743" you have /dev/video0 as "unicam (platform:unicam 3f801000.csi)", so that is all good.
Next you need to provide it with an EDID describing the formats that it can support, and then select the timings mode that matches the incoming data. See https://www.raspberrypi.org/forums/view ... 8#p1339178 for instructions.
You can then capture raw video as 24bit RGB (up to 1080p30) or UYVY (up to 1080p50) through your own choice of application.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

Return to “Graphics, sound and multimedia”