All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Max S." <max@schneidersoft.net>
To: Oliver Hartkopp <socketcan@hartkopp.net>
Cc: "linux-can@vger.kernel.org" <linux-can@vger.kernel.org>,
	Wolfgang Grandegger <wg@grandegger.com>
Subject: Re: GS_USB
Date: Fri, 15 Nov 2013 10:39:59 +0000	[thread overview]
Message-ID: <1384511999.3561.8.camel@blackbox> (raw)
In-Reply-To: <528150F3.8090406@hartkopp.net>

Hello all,

I've been doing some more testing and came across some strange behavior.
Frames appear to be out of order.

I have both chanels of the GS_USB device and a PEAKUSB adapter on a bus,
as well as another node (to ack frames).

I have modified the GS_USB firmware to PANIC when txed frames are out of
sequence.

tx interrupt now looks something like this

static uint8_t count = 0;
void tx_channel_0_interrupt(void){
	PANIC(txframe.data[0] != count);
	count++;

The GS_SUB device never panics, however cansequence -r on the peak
device gives me messages like:

received wrong sequence count. expected: 216, got: 220
received wrong sequence count. expected: 224, got: 216
received wrong sequence count. expected: 220, got: 224
received wrong sequence count. expected: 227, got: 229
received wrong sequence count. expected: 233, got: 227
received wrong sequence count. expected: 229, got: 233

notice that no frames are lost, just rearranged.

I can force frames to be out of order by restarting cansequence, so i
know my monitor code is working.

I have been trying to reproduce this error using libusb in userspace,
but have not had any success.

Any thoughts on this?

Regards,
Max Schneider.


  reply	other threads:[~2013-11-15 10:27 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-04 12:31 GS_USB Max S.
2013-10-04 13:23 ` GS_USB Marc Kleine-Budde
2013-10-05 20:36 ` GS_USB Wolfgang Grandegger
2013-10-07 14:22   ` GS_USB Max S.
2013-10-07 14:37     ` GS_USB Wolfgang Grandegger
2013-10-07 19:52       ` GS_USB Max S.
2013-10-07 20:30         ` GS_USB Wolfgang Grandegger
2013-11-03 17:12           ` GS_USB Max S.
2013-11-03 19:42             ` GS_USB Wolfgang Grandegger
2013-11-09 23:19             ` GS_USB Wolfgang Grandegger
2013-11-11  2:10               ` GS_USB Max S.
2013-11-11  8:05                 ` GS_USB Wolfgang Grandegger
2013-11-11 15:41                   ` GS_USB Oliver Hartkopp
     [not found]                     ` <1384199350.3483.20.camel@blackbox>
2013-11-11 21:49                       ` GS_USB Oliver Hartkopp
2013-11-15 10:39                         ` Max S. [this message]
2013-11-23 16:05                           ` GS_USB Max S.
2013-12-04 21:17                             ` GS_USB Max S.
2013-12-05 19:05                               ` GS_USB Oliver Hartkopp
2013-12-05 19:07                                 ` GS_USB Oliver Hartkopp
2013-12-09 17:53                                   ` GS_USB Max S.
2013-12-05 20:18                               ` GS_USB Wolfgang Grandegger
2013-12-05 20:42                                 ` GS_USB Wolfgang Grandegger
2013-12-07 10:06                             ` GS_USB Wolfgang Grandegger
2013-12-09 10:52                               ` GS_USB Marc Kleine-Budde
2013-12-09 13:15                                 ` GS_USB Wolfgang Grandegger

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=1384511999.3561.8.camel@blackbox \
    --to=max@schneidersoft.net \
    --cc=linux-can@vger.kernel.org \
    --cc=socketcan@hartkopp.net \
    --cc=wg@grandegger.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.