PCAN receive transmitted

This forum covers issues concerning multiple software products.
Locked
Ales1000
Posts: 54
Joined: Fri 4. Oct 2019, 09:01

PCAN receive transmitted

Post by Ales1000 » Mon 1. Nov 2021, 08:17

Hello,

I am using PCAN-USB Pro FD. I want to trace all communication on CAN including transmitted by this channel, is it somehow possible? If I use one channel for sending/receiving in PCANBasic API or PCAN-View I receive only CAN messages excluding sended messages by this channel. Is there some Promiscuous mode?

Thank you in advance.

Ales

K.Wagner
Software Development
Software Development
Posts: 1080
Joined: Wed 22. Sep 2010, 13:36

Re: PCAN receive transmitted

Post by K.Wagner » Mon 1. Nov 2021, 08:57

Hello,
Ales1000 wrote:
Mon 1. Nov 2021, 08:17
I am using PCAN-USB Pro FD. I want to trace all communication on CAN including transmitted by this channel, is it somehow possible?
Yes, this is possible. Just use the trace functionality offered by PCAN-Basic itself. Check the page 58 of the file "PCAN-Parameter_Documentation.pdf" for more information.
Ales1000 wrote:
Mon 1. Nov 2021, 08:17
If I use one channel for sending/receiving in PCANBasic API or PCAN-View I receive only CAN messages excluding sended messages
yes, this is true. Self sent messages (a.k.a Echoes) are not placed in the reception queue of PCAN-Basic or PCAN-View. This is only possible using the Developer package (CanApi4.dll) at this moment.
Best regards,
Keneth

Ales1000
Posts: 54
Joined: Fri 4. Oct 2019, 09:01

Re: PCAN receive transmitted

Post by Ales1000 » Mon 1. Nov 2021, 09:20

Hello,

I am little bit confused. In first response you say that it is possible to do this with PCAN_Basic API and in second you say that I need Developer package.

So, it is possible to trace (receive and log) all CAN traffic on a BUS including transmitted CAN frames by (tracing) receiving channel using PCAN Basic API (Not developer package)?

I have never use this function before. I traced before using reading RX buffer directly. What is benefit of this? Is it same as PCAN-view trace button?

Thank you in advance for your answers.

Aleš

K.Wagner
Software Development
Software Development
Posts: 1080
Joined: Wed 22. Sep 2010, 13:36

Re: PCAN receive transmitted

Post by K.Wagner » Mon 1. Nov 2021, 10:02

Hello,

second try:
Ales1000 wrote:
Mon 1. Nov 2021, 09:20
So, it is possible to trace (receive and log) all CAN traffic on a BUS including transmitted CAN frames by (tracing) receiving channel using PCAN Basic API (Not developer package)?
YES, you can trace sent and received messages when using the TRACE-Functionality of PCAN-Basic (set using the function CAN_SetValue), which is described in the documentation as stated in my post above.
Ales1000 wrote:
Mon 1. Nov 2021, 09:20
I traced before using reading RX buffer directly.
Self sent messages, are not placed in the reception queue, so you can not trace by yourself those, i.e. CAN_Read will not give you back any self sent message. If this is what you want (to get sent messages in your reception queue, and read those over CAN_Read), is only possible using the PCAN-Developer package.

Hope this is more clear now
Best regards,
Keneth

Ales1000
Posts: 54
Joined: Fri 4. Oct 2019, 09:01

Re: PCAN receive transmitted

Post by Ales1000 » Mon 1. Nov 2021, 10:16

Yes, now it is more clearly, thank you. But I have still one thing that I don't know.

I expect, that this trace functionality works like PCAN-View "Start" trace button, right? So, the only format is .trc, right?

Aleš

K.Wagner
Software Development
Software Development
Posts: 1080
Joined: Wed 22. Sep 2010, 13:36

Re: PCAN receive transmitted

Post by K.Wagner » Mon 1. Nov 2021, 10:31

Hello,

Yes, PCAN-Basic uses the same format as PCAN-View does. Trace file with extension *.trc.
Best regards,
Keneth

Ales1000
Posts: 54
Joined: Fri 4. Oct 2019, 09:01

Re: PCAN receive transmitted

Post by Ales1000 » Mon 1. Nov 2021, 10:33

Ok, thank you.

Aleš

K.Wagner
Software Development
Software Development
Posts: 1080
Joined: Wed 22. Sep 2010, 13:36

Re: PCAN receive transmitted

Post by K.Wagner » Mon 1. Nov 2021, 11:11

Hello,

you are welcome. As a last note, please check the appendices within the same documentation to obtain information about the *.trc trace versions used.

Closed.
Best regards,
Keneth

Locked