CAN FD Analyzer

Hi,
are there any plans to implement a CAN FD analyzer for Logic 2?

1 Like

I started writing one. I haven’t finished it unfortunately. CAN-FD is much more annoying to decode because you can’t just copy down all the bits then interpret them as the standard CAN decoder does. You have to know whether the frame is truly CAN-FD and whether it specifies a baud rate shift. Then you need to potentially also key on the data length as there are THREE different CRC lengths depending on circumstances. So, I got bogged down in feature creep and doing it stupidly and just never finished it.

But, I would like this to be possible as well. Luckily they publish the source code to their analyzers so that’s how I was able to take what they had for CAN and try to convert it to work with both CAN and CAN-FD messages.

If you feel up to it, I’d be OK with publishing the current mess on GitHub and you can see if you can make it work. Otherwise, you are probably stuck waiting for me to get back around to it as I’d wager Saleae has more pressing matters ahead of building a CAN-FD decoder.

@OutlawGentleman A community user actually shared a CAN-FD analyzer that they likely created using our CAN analyzer as a base. I can’t comment on how well it works for CAN-FD as we don’t run extensive tests on community shared analyzers. You can find the repo for it in the list below.

Also, feel free to send me (Tim) a message using the link below in case you need help getting it built! In your message, just make sure to let me know what OS you are running.
https://contact.saleae.com/hc/en-us/requests/new

@Collin I’m glad to hear you’re in the process of creating one as well! I’m not sure if you had a chance to take a look at the existing one above.

Otherwise, you are probably stuck waiting for me to get back around to it as I’d wager Saleae has more pressing matters ahead of building a CAN-FD decoder.

For better or for worse, you’re right. We really want to get to the point where we can churn out new analyzers left and right. Official support for CAN-FD has been highly requested.

Woah, had no idea that someone had already done it. I just compiled it and tried it on Linux. It seems to work but either I’ve got a protocol error in the capture or the analyzer is wrong. Either way, I like that they didn’t botch up the implementation like I did. I erased my attempt and went with the existing project. If need be I can edit it to make little improvements but it seems like a GREAT start.

1 Like

Are these Can FD solutions limited to any particular Saleae family? Now days I see the Logic and Logic Pro are the two main flavors. Is the ability to monitor CanFD tied to the type capabilities of one of these only?

@thestumbler I personally haven’t worked with CAN-FD, however, I would recommend using Logic Pro 8 or Logic Pro 16 due to the ability to configure the voltage threshold between 3 different options as described in the support article below.

Logic 8 does not have the ability to change the digital voltage threshold, which might be required to effectively digitally capture the CAN_L signal, which can swing from 1.25V to 2.5V. Currently, Logic 8s built-in digital voltage threshold does not meet that requirement.

If you have access to a single-ended TTL signal version of your CAN signal somewhere on the PCB that can swing all the way down to 0V, then any device would work (Logic 8, Logic Pro 8, or Logic Pro 16) since the available sampling rates for all of our current devices can meet the max speed for CAN-FD, which seems to be 8Mb/s (feel free to correct me if I’m wrong about the max CAN-FD speed).

One last note to keep in mind is that our devices are not able to natively capture differential signals, hence my recommendation to capture the CAN_L signal only (referenced to ground). You can find more details about this below:

Hope this helps!

1 Like

Yeah, CAN-FD is up to 8Mb/s so the saleae, being a digital capture tool (for this use) would need around 80 million samples per second to get a good approximation. This should easily be within the scope of any of the Logic adapters. Also, I would recommend the idea to grab the signal from the other side of the transceiver if you can. CAN, being differential and not going to zero, is tough to capture otherwise. But, if you grab the CAN_RX line on the transceiver you’ll have either a 0 to 3.3 or 0 to 5v signal and that’s much easier to work with.

2 Likes

Can someone provide the dll files for both community shared CAN-FD analyzers? That would be great, thanks

@Markus It looks like one of the creators provided the .dll library file, which can be found below. I hope this is what you need!

1 Like

I have tried using the Analyzer with the .dll file but everytime I started Logic with the Analyzer, the programm crashed. (Happened to a colleague on another PC as well)
Is there a dll. file for the other CAN-FD analyzer? Thanks

@marius Sorry to hear that! That’s certainly strange. I was able to get the .dll file working on my end with the latest 2.4.0 software. See image below.

  • Does the crash occur specifically due to attempting to install the .dll file? What happens when the .dll file is not specified? I’m wondering if the .dll is the culprit to the crashes, or if it may be caused by something else.
  • Can you confirm you are following the instructions below to install the anlayzer?
    Import Custom Low Level Analyzer - Saleae Support
  • What version of the software are you using?’
  • Can you ensure that you downloaded the .dll from their latest analyzer.zip from Aug 9?
    analyzer.zip (98.3 KB)
  • If none of the above help provide clues, we may want to take a look at your uploaded crash reports. In this case, could you share your machine Id with us? Instructions are below:
    Getting your Machine ID - Saleae Support

Thanks for the reply - I am using Logic 2.4.0 and I managed to get the .dll file working as you did (I downloaded the latest analyzer). But when I save the settings and start capturing, Logic is crashing after some seconds. Maybe you could try if that happens to you as well when you start capturing data?

Oh wow you’re right… sorry I didn’t test that earlier. I tested another local copy of a CAN_FD analyzer and that seemed to work with demo data. This leads me to believe there is some issue in the CANFD (Molinaro) source code, or we may have made an update in the app that breaks compatibility with this particular CANFD analyzer. I’ll need to run some more tests on my end to try and find the culprit.

In the meantime, here is the other CAN_FD analyzer that works on my end. Let me know if that works for you.
CAN_FDAnalyzer.zip (55.6 KB)

1 Like

Thank you for your help!

When I am trying to use this new Analyzer you shared - this error occurs. I am using Windows.

@marius Oh no… this is quite a series of unfortunate events… Sorry for all of this. I haven’t had a chance to test this yet, but it looks like the original author of the 1st CAN_FD analyzer just posted a new build with a potential fix for the crashes. Could you give that a try?

Now it works - Thank you very much!

1 Like

Hi there,
I wrote my own CAN(-FD) Low Level Analyzer following the well documented guide to generate the DLL.
It works really fine and does exactly what I want!

… B U T …

Now is time to distribute it and I am a little confused.

I got this message:
image

Searching for a solution, I read also a post from you @timreyes on Feb 17 (see [Failed to load Custom Analyzer on Windows10]) mentioning that we have to use the DLL Version from the generated Release Folder and not from the Debug Folder to share this Analyzer with others.

Then, I followed the documented commands:

And as expected, after run the command, I got an Analyzer in the “Debug” Folder.

image

This analyzer works fine in my machine, “Developer” Machine, but my Problem is that I am unable to distribute it because no Release Folder and its DLL Analyzer is being generated.

Could you please bring some light in this shadows @timreyes ? Is there any other command needed to generate a Release Version using CMake? Do you have any Idea what I am doing wrong?

PS: I am on Windows with Logic 2.4.10 Version, CMake Version 3.24.0 (For C++ Edition: VS2019)

Thanks

Hi again!

I got it!.. Probably important for others having the same problem:

This 2 commands made my day:

C:\cmake -B build -A x64

… bla bla …

C:\cmake --build build --config Release

… bla bla …

And then you get your production LLA!

Note: You have to be in the analyzer directory where your CMakeList.txt is → aka:
image

Regards!

2 Likes

@eddy This is absolutely awesome! Glad to hear you were able to solve those initial build hitches. Let me know if you’d like me to list your analyzer below and I can get that up there.

I bought the Logic 16 in particular to aid developing a CAN-(FD) driver, that is I absolutely need to capture both the CAN and the SPI. While SPI works fine, I’m pretty disappointed that a device for 1700€ is not able to analyze CAN directly on the bus (as opposed to at the transceiver).

Why is it not possible to just define the expected voltage interval for every channel seperately?