platform/upstream/v4l-utils.git
12 years agov4l2-compliance: add tests for VIDIOC_G/S_JPEGCOMP.
Hans Verkuil [Sat, 28 Apr 2012 16:26:23 +0000 (18:26 +0200)]
v4l2-compliance: add tests for VIDIOC_G/S_JPEGCOMP.

Since these ioctls are on their way out a warning is issued if they are
implemented.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-compliance: add tests for VIDIOC_S_HW_FREQ_SEEK.
Hans Verkuil [Fri, 27 Apr 2012 21:38:23 +0000 (23:38 +0200)]
v4l2-compliance: add tests for VIDIOC_S_HW_FREQ_SEEK.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agolibv4lconvert: Fix interpretation of bit 7 of the Pixart JPEG marker
Hans de Goede [Fri, 27 Apr 2012 15:40:53 +0000 (17:40 +0200)]
libv4lconvert: Fix interpretation of bit 7 of the Pixart JPEG marker

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4lconvert: Further Pixart JPEG decompression tweaks
Hans de Goede [Fri, 27 Apr 2012 12:56:18 +0000 (14:56 +0200)]
libv4lconvert: Further Pixart JPEG decompression tweaks

Many thanks to Jean-François Moine <moinejf@free.fr> for digging the
quantization tables out of the windows driver.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agov4l2-compliance: EIO after getting/setting a control is now a warning
Hans Verkuil [Fri, 27 Apr 2012 11:42:42 +0000 (13:42 +0200)]
v4l2-compliance: EIO after getting/setting a control is now a warning

USB devices can return EIO when setting or getting certain controls due
to hardware constraints. Warn about this, but no longer treat it as an error.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-compliance: fix 'OK' results that should have been 'Not Supported'.
Hans Verkuil [Fri, 27 Apr 2012 11:29:06 +0000 (13:29 +0200)]
v4l2-compliance: fix 'OK' results that should have been 'Not Supported'.

For radio devices some format ioctls were reported as being 'OK' when it should
have been 'Not Supported'.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agolibv4lconvert: Drop Pixart JPEG frames with changing chrominance setting
Hans de Goede [Mon, 23 Apr 2012 21:18:24 +0000 (23:18 +0200)]
libv4lconvert: Drop Pixart JPEG frames with changing chrominance setting

Sometimes the pac7302 switches chrominance setting halfway though a
frame, with a quite ugly looking result, so lets drop such frames.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4lconvert: Dynamic quantization tables for Pixart JPEG
Hans de Goede [Mon, 23 Apr 2012 21:03:40 +0000 (23:03 +0200)]
libv4lconvert: Dynamic quantization tables for Pixart JPEG

Inspired by a patch from Jean-François Moine <moinejf@free.fr>, I've spend
4 days on a row investigating (through trial and error) Pixart's JPEG
compression. This patch accumulates what I've learned from this, giving 2
important improvements:
1) Support for properly decompressing pac7302 generated images where some
   of the MCU-s are compressed with a lower quality / higher quantization
   values
2) Proper chrominance quantization tables for Pixart JPEG, getting rid of
   the sometimes horribly over saturation our decompression code was causing

The support for dynamic quantization tables this patch adds also allows us to
enable lower compression ratios in the kernel driver when running at a lower
framerate, resulting in better image quality.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agoRevert "tinyjpeg: Better luminance quantization table for Pixart JPEG"
Hans de Goede [Wed, 25 Apr 2012 14:39:55 +0000 (16:39 +0200)]
Revert "tinyjpeg: Better luminance quantization table for Pixart JPEG"

This reverts commit e2886326345e8750d96b2a5f5fae6dd47c76d534.

12 years agolibv4lconvert: Fix decoding of 160x120 Pixart JPEG images
Hans de Goede [Mon, 23 Apr 2012 17:43:07 +0000 (19:43 +0200)]
libv4lconvert: Fix decoding of 160x120 Pixart JPEG images

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agoqv4l2:add support for integer menu controls.
Hans Verkuil [Thu, 19 Apr 2012 14:45:05 +0000 (16:45 +0200)]
qv4l2:add support for integer menu controls.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-compliance: add integer menu support.
Hans Verkuil [Thu, 19 Apr 2012 14:31:28 +0000 (16:31 +0200)]
v4l2-compliance: add integer menu support.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-ctl: add support for integer menus.
Hans Verkuil [Thu, 19 Apr 2012 14:28:05 +0000 (16:28 +0200)]
v4l2-ctl: add support for integer menus.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-compliance: add tests for control events.
Hans Verkuil [Thu, 19 Apr 2012 14:21:02 +0000 (16:21 +0200)]
v4l2-compliance: add tests for control events.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agovideodev2.h: update to latest version.
Hans Verkuil [Thu, 19 Apr 2012 14:20:11 +0000 (16:20 +0200)]
videodev2.h: update to latest version.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agoioctl-test: update to the latest list of ioctls.
Hans Verkuil [Thu, 19 Apr 2012 10:49:07 +0000 (12:49 +0200)]
ioctl-test: update to the latest list of ioctls.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agodvb: Fix spelling errors found by lintian
Gregor Jasny [Sat, 14 Apr 2012 21:12:15 +0000 (23:12 +0200)]
dvb: Fix spelling errors found by lintian

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: Revert X201 upside down table entry
Gregor Jasny [Sat, 14 Apr 2012 16:46:23 +0000 (18:46 +0200)]
libv4lconvert: Revert X201 upside down table entry

Disabled due to http://bugs.debian.org/667958

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agodvb-file: Allow writing a zap/channel file for a DVBv5-only standard
Mauro Carvalho Chehab [Mon, 9 Apr 2012 21:25:01 +0000 (18:25 -0300)]
dvb-file: Allow writing a zap/channel file for a DVBv5-only standard

ISDB-T is not really supported by a DVB-T format. Yet, DVB-T tools
are able to work with with an ISDB-T frontend in compat mode.

So, while the conversion to a legacy format is not a rocket science,
it is interesting to allow writing/converting a DVB-T file for an
ISDB-T scan file.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb-format-convert: fix argument check and helper message
Mauro Carvalho Chehab [Mon, 9 Apr 2012 20:13:28 +0000 (17:13 -0300)]
dvb-format-convert: fix argument check and helper message

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoDocumentation spelling fixes
Ville Skyttä [Mon, 9 Apr 2012 07:03:53 +0000 (09:03 +0200)]
Documentation spelling fixes

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4lconvert: Use bytesperline instead of width
Robert Abel [Sat, 25 Feb 2012 17:12:38 +0000 (18:12 +0100)]
libv4lconvert: Use bytesperline instead of width

Basically, I found that libv4l and its conversion functions usually
choose to ignore v4l2_pix_format.bytesperline, which seems to work out
most of the time.

I'm currently working with the mt9v032 camera on a Gumstix Overo board.
The mt9v032's driver pads output lines to 768 pixels, giving 0x900 bytes
per line. All code in bayer.c (the camera uses raw bayer pattern) is
written to assume bytesperline = width and thus everything goes horribly
wrong.

Anyway, the patch for bayer => rgb as well as bayer => yuv is attached.
Basically, every time where width was assumed to be the offset to the
neighboring pixel below, now step is used.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconver: Add 06f8:301b pac7302 based cam to the quirk table
Hans de Goede [Sun, 8 Apr 2012 09:27:52 +0000 (11:27 +0200)]
libv4lconver: Add 06f8:301b pac7302 based cam to the quirk table

Reported-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agotinyjpeg: Better luminance quantization table for Pixart JPEG
Jean-Francois Moine [Fri, 23 Mar 2012 19:19:45 +0000 (20:19 +0100)]
tinyjpeg: Better luminance quantization table for Pixart JPEG

An other luminance quantization table gives a better quality to the
Pixart images created by the webcams handled by the gspca drivers
pac7302 and pac7311 (pixel format 'PJPG').

Tests have been done with 5 different pac7302 webcams. The marker was
always 0x44.

Signed-off-by: Jean-François Moine <moinejf@free.fr>
12 years agolibv4lconvert: Fix building when configured with --without-jpeg
Hans de Goede [Sat, 7 Apr 2012 14:40:48 +0000 (16:40 +0200)]
libv4lconvert: Fix building when configured with --without-jpeg

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4lconver/tinyjpeg: Fix out of bounds array usage
Hans de Goede [Sat, 7 Apr 2012 14:31:12 +0000 (16:31 +0200)]
libv4lconver/tinyjpeg: Fix out of bounds array usage

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4l2: Prevent GCC 4.7 inlining error
Gregor Jasny [Fri, 6 Apr 2012 15:06:16 +0000 (17:06 +0200)]
libv4l2: Prevent GCC 4.7 inlining error

See: http://bugs.debian.org/667406

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agodvb: Fix help and version strings
Gregor Jasny [Fri, 6 Apr 2012 14:56:00 +0000 (16:56 +0200)]
dvb: Fix help and version strings

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: Add LIFEBOOK T731 to upside down table
Gregor Jasny [Mon, 2 Apr 2012 19:21:59 +0000 (21:21 +0200)]
libv4lconvert: Add LIFEBOOK T731 to upside down table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agov4l2-ctl/dbg: include config.h for --log-status.
Hans Verkuil [Fri, 30 Mar 2012 09:57:39 +0000 (11:57 +0200)]
v4l2-ctl/dbg: include config.h for --log-status.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agolibv4lconvert: Add ThinkPad Edge E325 to upside down table
Gregor Jasny [Sun, 25 Mar 2012 20:44:59 +0000 (22:44 +0200)]
libv4lconvert: Add ThinkPad Edge E325 to upside down table

12 years agoAdd ThinkPad X201 to upside down table
Gregor Jasny [Thu, 22 Mar 2012 21:05:14 +0000 (22:05 +0100)]
Add ThinkPad X201 to upside down table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoAdd ThinkPad X200 to upside down table
Gregor Jasny [Thu, 22 Mar 2012 21:01:47 +0000 (22:01 +0100)]
Add ThinkPad X200 to upside down table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4l: Miscellaneous Comment Fixes
Robert Abel [Sat, 25 Feb 2012 14:48:46 +0000 (15:48 +0100)]
libv4l: Miscellaneous Comment Fixes

I found some minor spelling/grammar issues in the comments of libv4l. I
fixed the most irksome to me in the patch below.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agov4l2-ctl: add decoder/encoder_cmd support.
Hans Verkuil [Fri, 24 Feb 2012 12:10:29 +0000 (13:10 +0100)]
v4l2-ctl: add decoder/encoder_cmd support.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agovideodev2.h: update to latest version.
Hans Verkuil [Fri, 24 Feb 2012 10:27:31 +0000 (11:27 +0100)]
videodev2.h: update to latest version.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agoqv4l2: Use int64_t instead of __off64_t
Gregor Jasny [Mon, 13 Feb 2012 14:35:06 +0000 (15:35 +0100)]
qv4l2: Use int64_t instead of __off64_t

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agobuildsystem: Convert pattern rules to portable make rules
Gregor Jasny [Mon, 13 Feb 2012 14:35:07 +0000 (15:35 +0100)]
buildsystem: Convert pattern rules to portable make rules

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agov4l2-ctl: Explicitely compare struct timespec members on (k)FreeBSD
Gregor Jasny [Sun, 19 Feb 2012 17:42:56 +0000 (18:42 +0100)]
v4l2-ctl: Explicitely compare struct timespec members on (k)FreeBSD

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoutils: Remove unused features.h include
Gregor Jasny [Sun, 19 Feb 2012 17:38:47 +0000 (18:38 +0100)]
utils: Remove unused features.h include

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoutils: Enable v4l2-compliance, v4l2-ctl, and v4l2-dbg again
Gregor Jasny [Sun, 19 Feb 2012 17:47:38 +0000 (18:47 +0100)]
utils: Enable v4l2-compliance, v4l2-ctl, and v4l2-dbg again

An updated v4l_compat tarball provides all necessary defines and structs.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: Fix printf conversion modifier
Gregor Jasny [Tue, 14 Feb 2012 19:27:57 +0000 (20:27 +0100)]
libv4lconvert: Fix printf conversion modifier

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agov4l2-ctl: Remove unneeded linux/types.h header include
Gregor Jasny [Tue, 14 Feb 2012 08:35:31 +0000 (09:35 +0100)]
v4l2-ctl: Remove unneeded linux/types.h header include

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibdvb5: Fix printf conversion modifier
Gregor Jasny [Tue, 14 Feb 2012 08:34:35 +0000 (09:34 +0100)]
libdvb5: Fix printf conversion modifier

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoutils: use klogctl only if available
Gregor Jasny [Tue, 14 Feb 2012 19:25:52 +0000 (20:25 +0100)]
utils: use klogctl only if available

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4l: Check for correct mode_t promotion type at configure time
Gregor Jasny [Tue, 14 Feb 2012 19:21:37 +0000 (20:21 +0100)]
libv4l: Check for correct mode_t promotion type at configure time

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoDo not use v4l-utils copy of kernel headers on non Linux architectures
Gregor Jasny [Wed, 8 Feb 2012 20:12:03 +0000 (21:12 +0100)]
Do not use v4l-utils copy of kernel headers on non Linux architectures

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4l: Apply conditionals for FreeBSD to kFreeBSD, too
Gregor Jasny [Sun, 5 Feb 2012 17:31:36 +0000 (18:31 +0100)]
libv4l: Apply conditionals for FreeBSD to kFreeBSD, too

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agobuildsystem: Build some of the utils only on Linux
Gregor Jasny [Wed, 1 Feb 2012 17:41:33 +0000 (18:41 +0100)]
buildsystem: Build some of the utils only on Linux

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agobuildsystem: Find argp library during configure run
Gregor Jasny [Wed, 1 Feb 2012 17:41:32 +0000 (18:41 +0100)]
buildsystem: Find argp library during configure run

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agobuildsystem: Find library providing dlopen symbols at configure time
Gregor Jasny [Wed, 1 Feb 2012 17:41:29 +0000 (18:41 +0100)]
buildsystem: Find library providing dlopen symbols at configure time

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoAdd missing includes
Gregor Jasny [Wed, 1 Feb 2012 17:41:30 +0000 (18:41 +0100)]
Add missing includes

They were discovered while compiling on FreeBSD.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoutils: Rename devname to devicename to avoid FreeBSD stdlib conflict
Gregor Jasny [Wed, 1 Feb 2012 17:41:31 +0000 (18:41 +0100)]
utils: Rename devname to devicename to avoid FreeBSD stdlib conflict

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: add missing const for input pointer
Gregor Jasny [Wed, 1 Feb 2012 17:41:36 +0000 (18:41 +0100)]
libv4lconvert: add missing const for input pointer

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4l: update upside down device table
Gregor Jasny [Sun, 5 Feb 2012 16:09:55 +0000 (17:09 +0100)]
libv4l: update upside down device table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: replace strndupa with more portable strndup
Gregor Jasny [Thu, 2 Feb 2012 19:25:07 +0000 (20:25 +0100)]
libv4lconvert: replace strndupa with more portable strndup

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoPrepare 0.9.0-test1 release v4l-utils-0.9.0-test1
Gregor Jasny [Thu, 2 Feb 2012 19:37:02 +0000 (20:37 +0100)]
Prepare 0.9.0-test1 release

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lconvert: Add missing colon in ASUS upside down table
Gregor Jasny [Wed, 1 Feb 2012 21:06:33 +0000 (22:06 +0100)]
libv4lconvert: Add missing colon in ASUS upside down table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoUse globs to shorten ASUS upside down table
Gregor Jasny [Tue, 31 Jan 2012 19:59:24 +0000 (20:59 +0100)]
Use globs to shorten ASUS upside down table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
CC: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4l: update upside down device table
Gregor Jasny [Sun, 29 Jan 2012 22:39:54 +0000 (23:39 +0100)]
libv4l: update upside down device table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agolibv4lcontrol: Add new matching algorithm for upside down table
Gregor Jasny [Sun, 29 Jan 2012 16:56:04 +0000 (17:56 +0100)]
libv4lcontrol: Add new matching algorithm for upside down table

Implemented after this proposal from Hans de Goede:

   Add another matching algorithm, besides the current match all fields if single row algorithm
   to be specific, I would like a 3 step matching algorithm first of all match the dmi_board_vendor
   against a list of strings known to be used by Manufacturer A, then match dmi_board_name against
   a list of known to have upside down laptop models, then match the usb-id against a list of
   webcams known to be used by Manufacturer A.

   This is mainly targeting Asus, since they tend to have many models and sometimes change the
   model webcam used inside a certain model notebook.

   This way we can hopefully define a set of rules which will catch most Asus laptops, including
   models we have not seen yet, without catching the few models which do have their laptop the right
   way up.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
12 years agolibv4lcontrol: Prefix sysfs root with environment variable value
Gregor Jasny [Sun, 29 Jan 2012 16:47:06 +0000 (17:47 +0100)]
libv4lcontrol: Prefix sysfs root with environment variable value

If the LIBV4LCONTROL_SYSFS_PREFIX value is set it will be added
as a prefix to the sysfs root. This allows to fake USB and DMI
values to test upside down table entries.

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
12 years agov4l2-ctl: add support for VIDIOC_S_HW_FREQ_SEEK.
Hans Verkuil [Sat, 28 Jan 2012 12:00:49 +0000 (13:00 +0100)]
v4l2-ctl: add support for VIDIOC_S_HW_FREQ_SEEK.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agodvbv5-scan: Don't process the same freq from channel file twice
Mauro Carvalho Chehab [Wed, 25 Jan 2012 10:57:33 +0000 (08:57 -0200)]
dvbv5-scan: Don't process the same freq from channel file twice

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Allow changing the default output file
Mauro Carvalho Chehab [Tue, 24 Jan 2012 20:03:51 +0000 (18:03 -0200)]
dvbv5-scan: Allow changing the default output file

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb-file: Fix a segfault if network_name is not filled
Mauro Carvalho Chehab [Tue, 24 Jan 2012 20:01:59 +0000 (18:01 -0200)]
dvb-file: Fix a segfault if network_name is not filled

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb-fe-tool: Fix two warnings
Mauro Carvalho Chehab [Tue, 24 Jan 2012 19:54:29 +0000 (17:54 -0200)]
dvb-fe-tool: Fix two warnings

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoAdd the missing license comments to the files
Mauro Carvalho Chehab [Tue, 24 Jan 2012 19:03:14 +0000 (17:03 -0200)]
Add the missing license comments to the files

While everything is GPLv2 only, the license were missed on
some files. Properly fill them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb: Use the generic read/write file functions
Mauro Carvalho Chehab [Tue, 24 Jan 2012 17:28:51 +0000 (15:28 -0200)]
dvb: Use the generic read/write file functions

This way, on every place, it is possible to read or write using
the legacy or the new formats.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb: Move the generic read/write routines to the library
Mauro Carvalho Chehab [Tue, 24 Jan 2012 17:00:59 +0000 (15:00 -0200)]
dvb: Move the generic read/write routines to the library

Instead of having them only for dvb-format-convert, move them
to the library. This way, they can be used by the other tools.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb-file: Add support for writing at the legacy formats
Mauro Carvalho Chehab [Tue, 24 Jan 2012 15:52:30 +0000 (13:52 -0200)]
dvb-file: Add support for writing at the legacy formats

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb-file: improve parser description structures
Mauro Carvalho Chehab [Tue, 24 Jan 2012 14:00:00 +0000 (12:00 -0200)]
dvb-file: improve parser description structures

Move delimiter to a parser structure. This will allow adding a
generic routine to create one-line formats.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb: Add support for SCR/Unicable
Mauro Carvalho Chehab [Tue, 24 Jan 2012 11:11:53 +0000 (09:11 -0200)]
dvb: Add support for SCR/Unicable

SCR/Unicable is used with Ku-Band satellite configurations, in order
to allow several devices to use the satellites at the same time.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agov4l2-compliance: improve capability compliance tests.
Hans Verkuil [Tue, 24 Jan 2012 09:17:14 +0000 (10:17 +0100)]
v4l2-compliance: improve capability compliance tests.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l2-ctl: add support for device capabilities.
Hans Verkuil [Tue, 24 Jan 2012 07:51:00 +0000 (08:51 +0100)]
v4l2-ctl: add support for device capabilities.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agovideodev2.h: update to latest version.
Hans Verkuil [Tue, 24 Jan 2012 07:32:11 +0000 (08:32 +0100)]
videodev2.h: update to latest version.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
12 years agov4l-utils: ir-keytable file parsing errors
Chris Pockele [Sun, 8 Jan 2012 22:31:35 +0000 (22:31 +0000)]
v4l-utils: ir-keytable file parsing errors

While configuring a remote control I noticed that the ir-keytable
utility would throw the message "Invalid parameter on line 1" if the
first line following the "table ... type: ..." line is a comment.
Also, if a configuration line is invalid, the line number indication
of the error message is sometimes incorrect, because the comments
before it are not counted.
This happens because of the "continue" statement when processing
comments (or the table/type line), thus skipping the line counter
increase at the end of the loop.  The included patch fixes both
problems by making sure the counter is always increased.
The parse_cfgfile() function had a similar problem.

Signed-off-by: Chris Pockelé <chris.pockele.f1@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoconfigure.ac: don't be verbose by default
Mauro Carvalho Chehab [Mon, 23 Jan 2012 11:30:48 +0000 (09:30 -0200)]
configure.ac: don't be verbose by default

libtool builds are too verbose for it to be useful. Be less verbose
by default. If verbose is needed, it can be enabled easily via
$ make V=1

at the commandline.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodescriptors: Fix a few bugs at the tables
Mauro Carvalho Chehab [Mon, 23 Jan 2012 11:22:00 +0000 (09:22 -0200)]
descriptors: Fix a few bugs at the tables

As pointed by clang, previous array values were overriden.
Fix them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodescriptors: Fix DVB-T2 transmission mode parsing
Mauro Carvalho Chehab [Mon, 23 Jan 2012 11:16:07 +0000 (09:16 -0200)]
descriptors: Fix DVB-T2 transmission mode parsing

$ make V=0 CC=clang
descriptors.c:515:65: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
        nit_table->transmission_mode = transmission_mode[(buf[1] >> 2) && 0x07];

Reported-by: Gregor Jasny <gjasny@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agokeytable: Fix copy and paste error for SANYO IR protocol
Gregor Jasny [Thu, 19 Jan 2012 13:42:43 +0000 (14:42 +0100)]
keytable: Fix copy and paste error for SANYO IR protocol

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb: Fix a few warnings
Mauro Carvalho Chehab [Wed, 18 Jan 2012 12:45:49 +0000 (10:45 -0200)]
dvb: Fix a few warnings

Now that the compilation is not verbose anymore, it is possible
to see a few warnings and fix them:

dvb-file.c: In function 'fill_entry':
dvb-file.c:213:27: warning: unused variable 'v' [-Wunused-variable]
descriptors.c: In function 'parse_NIT_ISDBT':
descriptors.c:278:4: warning: format '%d' expects argument of type 'int', but argument 2 has type 'uint64_t' [-Wformat]

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoautotools: allow enabling the silent-rules
Mauro Carvalho Chehab [Wed, 18 Jan 2012 12:41:26 +0000 (10:41 -0200)]
autotools: allow enabling the silent-rules

With this change, it is now possible to do:
$ make V=0
or
$ ./configure --enable-silent-rules

in order to be less verbose.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: bugfix possible crash by parsing strings
Stefan Ringel [Tue, 17 Jan 2012 18:45:42 +0000 (18:45 +0000)]
dvbv5-scan: bugfix possible crash by parsing strings

PID 0x0010, TableID 0x40 ID=0x3001, version 4, size 132
        40 f0 81 30 01 c9 00 00 f0 26 40 18 44 56 42 2d
        54 20 42 65 72 6c 69 6e 2f 42 72 61 6e 64 65 6e
        62 75 72 67 6c 0a 01 01 49 9a 08 89 21 01 ec 00
        f0 4e 01 01 21 14 f0 24 5a 0b 04 10 a6 40 1f 41
        12 ff ff ff ff 6d 07 01 01 04 10 a6 40 00 41 0c
        00 02 01 00 41 01 00 61 01 00 81 01 01 02 21 14
        f0 1e 5a 0b 03 1c 82 40 1f 41 12 ff ff ff ff 41
        0f 00 0b 01 00 0c 01 00 0d 01 00 0e 01 00 0f 01
        5a 5e 75 59
        section_length = 129 section 0, last section 0
Descriptors table len 38
network_name_descriptor (0x40), len 24
        44 56 42 2d 54 20 42 65 72 6c 69 6e 2f 42 72 61
        6e 64 65 6e 62 75 72 67
*** glibc detected *** ./dvbv5-scan: free(): invalid pointer: 0x0000000000618dc0 ***

======= Backtrace: =========
/lib64/libc.so.6(+0x74c06)[0x7ffe9b15dc06]
./dvbv5-scan[0x407ba6]
./dvbv5-scan[0x407339]
./dvbv5-scan[0x405c7e]
./dvbv5-scan[0x4067d3]
./dvbv5-scan[0x401749]
/lib64/libc.so.6(__libc_start_main+0xed)[0x7ffe9b10a23d]
./dvbv5-scan[0x401dd5]
======= Memory map: ========
00400000-0040e000 r-xp 00000000 08:03 15084544                           /home/stefan/build/dvb_utils/v4l-utils/utils/dvb/dvbv5-scan
0060d000-0060e000 r--p 0000d000 08:03 15084544                           /home/stefan/build/dvb_utils/v4l-utils/utils/dvb/dvbv5-scan
0060e000-00610000 rw-p 0000e000 08:03 15084544                           /home/stefan/build/dvb_utils/v4l-utils/utils/dvb/dvbv5-scan
00610000-00631000 rw-p 00000000 00:00 0                                  [heap]
7ffe9acd0000-7ffe9ace5000 r-xp 00000000 08:03 15859816                   /lib64/libgcc_s.so.1
7ffe9ace5000-7ffe9aee4000 ---p 00015000 08:03 15859816                   /lib64/libgcc_s.so.1
7ffe9aee4000-7ffe9aee5000 r--p 00014000 08:03 15859816                   /lib64/libgcc_s.so.1
7ffe9aee5000-7ffe9aee6000 rw-p 00015000 08:03 15859816                   /lib64/libgcc_s.so.1
7ffe9aee6000-7ffe9aee8000 r-xp 00000000 08:03 59904690                   /usr/lib64/gconv/ISO8859-1.so
7ffe9aee8000-7ffe9b0e7000 ---p 00002000 08:03 59904690                   /usr/lib64/gconv/ISO8859-1.so
7ffe9b0e7000-7ffe9b0e8000 r--p 00001000 08:03 59904690                   /usr/lib64/gconv/ISO8859-1.so
7ffe9b0e8000-7ffe9b0e9000 rw-p 00002000 08:03 59904690                   /usr/lib64/gconv/ISO8859-1.so
7ffe9b0e9000-7ffe9b26e000 r-xp 00000000 08:03 15859719                   /lib64/libc-2.14.1.so
7ffe9b26e000-7ffe9b46e000 ---p 00185000 08:03 15859719                   /lib64/libc-2.14.1.so
7ffe9b46e000-7ffe9b472000 r--p 00185000 08:03 15859719                   /lib64/libc-2.14.1.so
7ffe9b472000-7ffe9b473000 rw-p 00189000 08:03 15859719                   /lib64/libc-2.14.1.so
7ffe9b473000-7ffe9b478000 rw-p 00000000 00:00 0
7ffe9b478000-7ffe9b498000 r-xp 00000000 08:03 15859714                   /lib64/ld-2.14.1.so
7ffe9b671000-7ffe9b674000 rw-p 00000000 00:00 0
7ffe9b68e000-7ffe9b68f000 rw-p 00000000 00:00 0
7ffe9b68f000-7ffe9b696000 r--s 00000000 08:03 59904753                   /usr/lib64/gconv/gconv-modules.cache
7ffe9b696000-7ffe9b698000 rw-p 00000000 00:00 0
7ffe9b698000-7ffe9b699000 r--p 00020000 08:03 15859714                   /lib64/ld-2.14.1.so
7ffe9b699000-7ffe9b69a000 rw-p 00021000 08:03 15859714                   /lib64/ld-2.14.1.so
7ffe9b69a000-7ffe9b69b000 rw-p 00000000 00:00 0
7fffab429000-7fffab44a000 rw-p 00000000 00:00 0                          [stack]
7fffab51c000-7fffab51d000 r-xp 00000000 00:00 0                          [vdso]
ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0                  [vsyscall]
Abgebrochen
localhost:/home/stefan/build/dvb_utils/v4l-utils/utils/dvb #

Signed-off-by: Stefan Ringel <linuxtv@stefanringel.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodescriptors: Fix a few NIT descriptor parsers
Mauro Carvalho Chehab [Tue, 17 Jan 2012 17:28:07 +0000 (15:28 -0200)]
descriptors: Fix a few NIT descriptor parsers

The ISDB-T terrestrial delivery system descripotr parser were
completely broken. Fix it.

While here, also fixes the DVB-T2 descriptor parser.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb/dvb-file: Try again after a while, if -EAGAIN is returned
Mauro Carvalho Chehab [Tue, 17 Jan 2012 15:54:01 +0000 (13:54 -0200)]
dvb/dvb-file: Try again after a while, if -EAGAIN is returned

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Don't parse the other NIT/SDT tables by default
Mauro Carvalho Chehab [Tue, 17 Jan 2012 15:56:56 +0000 (13:56 -0200)]
dvbv5-scan: Don't parse the other NIT/SDT tables by default

This speeds up scanning.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb/descriptors: improve ISDB-T verbosity
Mauro Carvalho Chehab [Tue, 17 Jan 2012 15:47:30 +0000 (13:47 -0200)]
dvb/descriptors: improve ISDB-T verbosity

On ISDB-T, most of the network parameters are decoded via the TMCC
carrier, modulated on all segments using DBPSK. It is up to the
ISDB-T demod to parse the TMCC registers and pass their contents via
get_frontend().

Yet, the NIT table provides a few data:
ISDB-T mode (1, 2 or 3);
Guard interval.

The ISDB-T mode is directly related to the number of OFDM carriers,
and the IFFT size:
Mode 1 corresponds to an IFFT size of 2K;
Mode 2 corresponds to an IFFT size of 4K;
Mode 3 corresponds to an IFFT size of 8K.

Provide a better output of those data, if verbose mode is enabled.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvb: Fix the used parameters for ISDB-T
Mauro Carvalho Chehab [Tue, 17 Jan 2012 12:04:43 +0000 (10:04 -0200)]
dvb: Fix the used parameters for ISDB-T

Remove the DVB-T parameters that aren't used on ISDB-T.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Avoid demux open/close every time
Mauro Carvalho Chehab [Tue, 17 Jan 2012 10:58:29 +0000 (08:58 -0200)]
dvbv5-scan: Avoid demux open/close every time

Instead of opening/closing the demux everytime, just open it
once, before starting the scanning.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Fix the parsing for the timeout parameter
Mauro Carvalho Chehab [Tue, 17 Jan 2012 10:21:02 +0000 (08:21 -0200)]
dvbv5-scan: Fix the parsing for the timeout parameter

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agolibv4l: update upside down device table
Gregor Jasny [Sun, 15 Jan 2012 22:12:39 +0000 (23:12 +0100)]
libv4l: update upside down device table

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoutils/DVB/README: Improve comments
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:47:42 +0000 (21:47 -0200)]
utils/DVB/README: Improve comments

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Fix report for non-PAT service ID's
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:41:48 +0000 (21:41 -0200)]
dvbv5-scan: Fix report for non-PAT service ID's

Noticed several scrambled channels on my DVB-C network that don't
appear properly at PAT/PMT tables. Probably, some other table
is needed (CAT?). Anyway, fix the output of such services.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodvbv5-scan: Fix print message on nameless service ID's
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:19:03 +0000 (21:19 -0200)]
dvbv5-scan: Fix print message on nameless service ID's

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agodescriptors.c: don't print an error for 0x83 descriptor on PMT
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:18:20 +0000 (21:18 -0200)]
descriptors.c: don't print an error for 0x83 descriptor on PMT

Removes a bogus error message on DVB-C.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoutils/dvb/dvbv5-scan: optimize it for the delivery systems
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:11:13 +0000 (21:11 -0200)]
utils/dvb/dvbv5-scan: optimize it for the delivery systems

The repetition time of the MPEG-TS tables are different
for each delivery system. Improves the code that handles that,
by using different timeouts, acording with the delivery system.

Also, start parsing the other NIT/SDT tables for most
delivery systems.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agoutils/dvb/parse_string: Fix a wrong cut-and-paste
Mauro Carvalho Chehab [Sun, 15 Jan 2012 23:10:17 +0000 (21:10 -0200)]
utils/dvb/parse_string: Fix a wrong cut-and-paste

While here, cleanup the malloc's for the temp tables.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
12 years agobuildsystem: Convert to autotools buildsystem
Gregor Jasny [Sat, 14 Jan 2012 16:09:36 +0000 (17:09 +0100)]
buildsystem: Convert to autotools buildsystem

Use autoreconf -vfi to bootstrap

Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
12 years agoFix spelling error in manpage
Gregor Jasny [Sat, 14 Jan 2012 14:49:13 +0000 (15:49 +0100)]
Fix spelling error in manpage