All of lore.kernel.org
 help / color / mirror / Atom feed
* New USB driver, looking for advice
@ 2020-12-07  2:57 Christian Gagneraud
  2020-12-08 14:59 ` Marc Kleine-Budde
  0 siblings, 1 reply; 8+ messages in thread
From: Christian Gagneraud @ 2020-12-07  2:57 UTC (permalink / raw)
  To: linux-can

Hi all,

I'm looking at creating a new CAN driver for a USB device [1].
This device has a custom protocol over bulk endpoints.
I was able to create a simple driver, based on usb-skeleton.c that
allows to speak this protocol by opening a custom har device.
I've been looking at the current implementation in [2], I think my
device is a bit special, you cannot read CAN frames w/o sending a
'read' command, so i need some sort of polling.
AFAIK, the Linux USB stack provides that for me, except that the
device won't read anything unless you send it a command.
I have the feeling that current drivers are for devices that can
return data by just scheduling read transfer.
Anyone would have a clue on how these drivers work, and if my device
is really that special?

Any hint, point out or reading pointers are much appreciated.

Thanks,
Chris

PS: This is for marine applications, NMEA2000 which uses CAN HW and is
wire-compatible with J1939

[1] https://www.simrad-yachting.com/simrad/type/accessories/cables-connectors/navico-can-to-usb-converter-st10/
[2] https://github.com/torvalds/linux/tree/master/drivers/net/can/usb

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-02-18  2:15 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-07  2:57 New USB driver, looking for advice Christian Gagneraud
2020-12-08 14:59 ` Marc Kleine-Budde
2020-12-09 11:03   ` Marc Kleine-Budde
2020-12-09 20:24   ` Christian Gagneraud
2020-12-10  7:36     ` Marc Kleine-Budde
2020-12-10 22:26       ` Christian Gagneraud
2020-12-11  8:39         ` Marc Kleine-Budde
2021-02-18  2:14           ` Christian Gagneraud

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.