All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konke Radlow <kradlow@cisco.com>
To: Hans de Goede <hdegoede@redhat.com>
Cc: linux-media@vger.kernel.org
Subject: Re: [RFC PATCH 1/2] Initial version of the RDS-decoder library  Signed-off-by: Konke Radlow <kradlow@cisco.com>
Date: Mon, 30 Jul 2012 14:46:09 +0000	[thread overview]
Message-ID: <201207301446.09260.kradlow@cisco.com> (raw)
In-Reply-To: <5013C828.9090307@redhat.com>

Hello Hans,
no need to thank me for working on it. First of all I do it as a part of a
summerjob, and more importantly I quite enjoy it and  intend to stay a active
member of the development process after my time at Cisco is over.

Thank you for your comments.

> Most fields in this struct (and in the other structs for that matter) could
> do with some more documentation.
I added a lot of short comments explaining the meaning of the fields, and
extended the explanation part that comes before each struct definition.

> > +   /** RDS info fields **/
> > +   bool is_rbds;           /* use RBDS standard version of LUTs */
> > +   uint16_t pi;
> > +   uint8_t ps[8];
>
> Looking at rds-ctl, this contains a string, please make it 9 bytes and
> always 0 terminate it! I also notice in rds-ctl that you filter the chars
> for being valid ascii and if not replace them with a space. Does the spec
> say anything about the encoding used for this string? Could we maybe
> convert it to UTF-8 inside the library so that apps can just consume the
> string?
The character encoding complies with ISO/IEC 10646, so it basically already is
UTF-8, and the data could be stored in a wchar_t array without conversion.
Is that preferred over uint8_t?

> > +/* adds a raw RDS block to decode it into RDS groups
> > + * @return:        bitmask with with updated fields set to 1
> > + * @rds_data:      3 bytes of raw RDS data, obtained by calling read()
> > + *                                 on RDS capable V4L2 devices */
> > +LIBV4L_PUBLIC uint32_t v4l2_rds_add(struct v4l2_rds *handle, struct
> > v4l2_rds_data *rds_data);
>
> Unless I'm missing something, you are no defining struct v4l2_rds_data
> anywhere, why not just make this a uint8_t ?
The v4l2_rds_data structure is defined by v4l in the videodev2.h header, and is
returned when calling the read function on a rds capable device
source: http://hverkuil.home.xs4all.nl/spec/media.html#v4l2-rds-data
Maybe I didn't get you point though?

greetings,
Konke

  parent reply	other threads:[~2012-07-30 12:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-26 16:21 [RFC PATCH 1/2] Initial version of the RDS-decoder library Signed-off-by: Konke Radlow <kradlow@cisco.com> Konke Radlow
2012-07-28 11:08 ` Hans de Goede
2012-07-30 14:41   ` Konke Radlow
2012-07-30 14:46   ` Konke Radlow [this message]
  -- strict thread matches above, loose matches on Subject: below --
2012-07-25 17:43 [RFC PATCH 0/2] Add support for RDS decoding Konke Radlow
2012-07-25 17:44 ` [RFC PATCH 1/2] Initial version of the RDS-decoder library Signed-off-by: Konke Radlow <kradlow@cisco.com> Konke Radlow
2012-07-26 14:28   ` Ezequiel Garcia
2012-07-26 14:39     ` Hans Verkuil
2012-07-26 14:41       ` Ezequiel Garcia
2012-07-26 18:46   ` Gregor Jasny
2012-07-26 18:49   ` Gregor Jasny

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201207301446.09260.kradlow@cisco.com \
    --to=kradlow@cisco.com \
    --cc=hdegoede@redhat.com \
    --cc=linux-media@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.