Linux CAN drivers development
 help / color / mirror / Atom feed
From: Kurt Van Dijck <dev.kurt@vandijck-laurijssen.be>
To: "André Hartmann" <aha_1980@gmx.de>
Cc: linux-can@vger.kernel.org
Subject: Re: SocketCAN device enumeration API
Date: Tue, 9 Aug 2016 16:04:53 +0200	[thread overview]
Message-ID: <20160809140453.GE25116@airbook.newtec.eu> (raw)
In-Reply-To: <201d5fca-9ea8-aa0e-843e-f21441cd7170@gmx.de>


--- Original message ---
> Date:	Tue, 9 Aug 2016 13:06:39 +0200
> From: André Hartmann <aha_1980@gmx.de>
> To: linux-can@vger.kernel.org
> Subject: SocketCAN device enumeration API
> User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
>  Thunderbird/45.2.0
> 
> Hello all,
> 
> I'm one of the developers working on the new QtSerialBus module [0], [1]
> which encapsulates different CAN hardware drivers (including SocketCAN) in a
> C++ API.
> 
> For a new hardware enumerating function, I'd like to do the following:
> 
> * Enumerate the currently available (i.e. ready to use)
>   SocketCAN devices

I did write myself an enumif() function (abstracted in libenumif)
that you can find on http://github.com/kurt-vd/enumif
You can easily enumerate only CAN interfaces, by hiding non-CAN
interfaces.

> * Get hardware information/manufacturer/bus type for a device
> * Find out if a device is virtual
> * Find out if a device is CAN FD capable

This is IMHO best done using libsocketcan.

Kind regards,
Kurt

  parent reply	other threads:[~2016-08-09 14:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-09 11:06 SocketCAN device enumeration API André Hartmann
2016-08-09 12:33 ` Mirza Krak
2016-08-09 14:04 ` Kurt Van Dijck [this message]
2016-08-11  8:36   ` André Hartmann
2016-08-11 10:05     ` Kurt Van Dijck
2016-08-11 10:31       ` André Hartmann

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=20160809140453.GE25116@airbook.newtec.eu \
    --to=dev.kurt@vandijck-laurijssen.be \
    --cc=aha_1980@gmx.de \
    --cc=linux-can@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox