All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kurt Van Dijck <dev.kurt@vandijck-laurijssen.be>
To: Mark Santacesaria <mark@keeptruckin.com>
Cc: linux-can@vger.kernel.org
Subject: j1939: recv >8 bytes
Date: Fri, 25 Sep 2015 10:28:46 +0200	[thread overview]
Message-ID: <20150925082846.GA7002@airbook> (raw)
In-Reply-To: <CAKoHjFzLoME76fmon+O7oS5_pKQk2j7QujnMsOfL7aLrr8xDWg@mail.gmail.com>

Hi Mark,

I added linux-can mailing list in CC, and altered the subject.
See my answer to your question below.

--- Original message ---
> Date: Thu, 24 Sep 2015 11:21:48 -0400
> From: Mark Santacesaria <mark@keeptruckin.com>
> To: kurt.van.dijck@eia.be
> Subject: j1939 linux kernel...
> 
>    hey kurt.... thanks for the effort that you put in to the j1939
>    code.... i was trying to receive a VIN request which is a multi-packet
>    message, and while i found examples of sending more that 8 bytes but i
>    am not sure how to receive.....

A "multi-packet message" is treated as a single j1939 packet.
You receive it like any other j1939 packet:
	
	uint8_t buf[1024];
	int ret;

	ret = recv(sock, buf, sizeof(buf), 0);

will receive up to 1024 bytes from the next j1939 packet.
You may use any buffer size you like here.

see also

	man recv

Kind regards,
Kurt

       reply	other threads:[~2015-09-25  8:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAKoHjFzLoME76fmon+O7oS5_pKQk2j7QujnMsOfL7aLrr8xDWg@mail.gmail.com>
2015-09-25  8:28 ` Kurt Van Dijck [this message]
     [not found]   ` <CAKoHjFxUqnPb+QEnTUjEinQHWjhiO-2kwapyjza1iFvGGg2C6g@mail.gmail.com>
2015-09-28  8:58     ` j1939: recv >8 bytes Kurt Van Dijck

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=20150925082846.GA7002@airbook \
    --to=dev.kurt@vandijck-laurijssen.be \
    --cc=linux-can@vger.kernel.org \
    --cc=mark@keeptruckin.com \
    /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.