Confused about Canbus and other support

Confused about the current status of the libraries.

Looking in the Libraries repository there is something there pretty much for everything other than CANBUS and j1850.

The readme for the libraries says to grab Collins due_can library to complete the package. Documentation in the “guide” portion of this site makes it sound like the SWCAN stuff is working just as well as the CANBUS stuff.

I have also seen mention to grab Collins stuff to run with SavvyCan. However to run SavvyCan requires Collins specific M2 Library M2RET. This library has a dependency on a number of the libraries listed in the M2 library. The readme from Collins M2RET that is less than a month old states to use HIS versions of the libraries because the ones here are not compatible with his libraries. It also mentions that the SWC and LIN do NOT work with his stuff.

So all of this has me totally confused and need guidance. Is Collins requirements outdated or can we use the M2 libraries?

Does SWCAN work at this time or does it not?

Really need an up to date status in the guide so we know what is needed to be done. Some of the developers that have had close links to Macchina likely know but for those of us getting our feet wet it makes life MUCH harder knowing what does or doesn’t work.

Personally my vehicles have support for CANBUS, SWCAN and j1850 VPW. So I am willing to help get these working but there is a huge learning curve right now that doesn’t need to be there if we can collaborate and know what works, what doesn’t and how to get to where we need to be…

Hey there, sorry for your confusion. Now that we have all of the Beta units out to all of the developers, we are switching gears to focus on exactly what you are looking for. Expect a lot of updates on this subject this week. This is a very fast moving project with a lot of developers working together all over the world. We’ll do our best to curate and organize everything as development progresses.

Here is what we had in mind:

We’ll start (as you suggested) sort of a “dashboard” on the top of this forum that will be the most up-to-date status of each of protocol’s code base. We’ll also be adding a list of projects that haven’t even started - a wish list (for example, automatic protocol detection). I think this would be super useful.

We envision this forum as being sort of the more fluid, faster changing platform while our guide is a more static, more “permanent” place to find information, tutorials, etc.

Our Github repo will ideally contain the latest code. As developers improve/change/update their fork, they’ll submit pull requests and we’ll commit them.

To address your specific questions:

Yes, Single-wire CAN (GMLAN) is working very well now. We’ll update the library we have in our repo with example for both TX and RX. This is the same library we used to start that Tahoe in our Kickstarter video.

A great example of how we’ll need review and merge the code so there is not several versions. For now: If you want to use SavvyCAN/M2RET: follow his instructions.

Finally, regarding J1850 VPW: The library for this protocol needs some more work. We have a head-start, and we’ll post up more information on this here soon.

Thank you for your willingness to help out! We’ll do our best to be organized, and keep everyone on same page as all of us early adopters dive in! Keep the conversation going!

With SWCAN does it use the same framework as standard CANBUS?

At this point I am guessing that it is just the hardware connection that is different but the actual communications protocols are the same. If that is the case then any software that works on CAN should also work with SWCAN?

Yes… SWCAN “is” CAN…it looks identical when you log it, message format is the same etc… its just broadcast on a single wire (and ground) at a lower speed.

Not sure if this needs a new thread or not but I am a little confused on how we can use the interface. Will this map directly to a CAN port under linux with the Lawicel support? Ie I just plug in the unit to a USB port under linux and shows up as Canbus with no necessary secondary drivers? I have the unit working under SavvyCan not just fine but curious about how this is supposed to work outside of that. Obviously Windows would need a specialized driver for it. Will look into how others are accomplishing the CANBUS drivers for windows and go from there.

Rodney

Ok so looking through the schematics and documentation I am trying to sort out a couple things…

I am making some assumptions based on what I am seeing and putting them up here for verification. Still swimming in the information trying to sort everything out. Since this is my first Arduino project I still have a learning curve but think I am getting better handle on some things. So I am posting here hoping to get clarification.

Dual wire CANBUS - Looks like the DUE hardware supports 2 CANBUS ports directly. This is why the Due_Can stuff works without modification is because of the built in support for it in the hardware.

SWCAN - This is using a MCP 2515 chip to do the CANBUS heavy lifting.

The J1850, K-Bus and L-Bus are connected directly to the Due I/O pins and handled directly from the Due.

I realize there are some conversion/processing and protection circuits between the ODBII port and the Due processor so I simplified for this posting.

Just trying to get a grasp on how this is going to work out. I expect a bit of a delay before building anything useful as I begin to fully understand how this stuff all works together and once I have gotten past the learning curve I expect to be much more helpful in building useful firmware. Would be much easier if I could chat with Collin or someone else that knows this stuff inside and out so I understand what needs to be done quicker. Until then I will go through the code I have available to me and try to sort it out.

Your assumptions look good to me. Keep researching and reviewing existing projects and you will learn quickly. You are in the right place to ask questions (and hopefully get good answers) Keep at it!

I will mention that anyone trying to sort out how the due_can drivers work will find the manual for the CanDue hardware very beneficial. They go through how to use the driver programically. Would not be a bad idea to include the documentation in some form in this sites documentation for the canbus stuff since it is possible people will just install the Due_Can drivers. Also looks to be beneficial for helping to structure the stuff I am working on.

The link to the manual I have been looking at is here:

http://media3.ev-tv.me/CANDueUserManual.pdf

Note that the ET7190 works with all the protocols that the M2 supports hardware wise. My Scantool does not support SWCAN but does support the rest of the ODBII protocols that the M2 should support. The ET7190 simulation software doesn’t show the SWCAN as an option but since there is a connection for it I expect it IS supported so if you want to do any programming for the M2 this device would not be a bad one to use. I did have to install a 120 ohm resistor between the CAN- and CAN+ in order for it to work. (Actually have it scrolling on another screen as I write this. )

Been working 8-10 hours of OT at work the last few weeks so haven’t had a bunch of opportunities but I know at least that this setup works. Currently have the ET7190 talking to my STN device through a Y cable.

Currently connected the M2 to the other port on the Y cable and not getting any data through SAVVYCAN and not sure why. May have to update to the latest firmware and see what the issue is. Will try with other devices I have and see what I find out. Was working in my car the last time I tried it. Will try in the vehicle and make sure it works. Will also hook up my PCAN and see if I see the network with it either.

Want to insure it works with the CANBUS before moving onto J1850 etc.

Rodney

The ET7190 does work perfectly for 33.3k SWCAN, and the ET7190 software supports it right out of the box too.

I tested it a while back when I got the ET7190 but havent had a chance to really use it a lot.

Ok, I don’t see an option for it but my STN device doesn’t support it anyhow so can’t really test it as is unless I can use my P-CAN as a SWCAN device which I have not tried.

I saw the 11bit and 29bit can stuff but they seemed to just use the standard CAN Port and not the SWCAN.

It looks like you could use it as a scanner if you wanted to as well.

Rodney