Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register

Exploring the Model S CAN Bus

This site may earn commission on affiliate links.

obrien28

Midnight Engineer
Jan 17, 2014
101
110
NW CT
A while back I posted this Instructable on how to access the Model S diagnostic port and sniff some of the traffic going over it. It just occurred to me that I should probably post it here for the TMC community to have a gander at. Currently the project is ongoing as I am working with another TMC member to decode the CAN ID's and message, we have made a small amount of headway so far, but still have a lot to do. We are hoping to maybe integrate the data into website for logging trip data and such, like the OVMS for the Roadster, that might be a little farther off though.

Message me if anybody would like to help or can contribute in anyway, many hands make light work as they say.

Exploring the Model S CAN Bus
 
@pbceng It isn't actually completely useless, I found out later that they do put out one CAN bus (CAN6 chassis) on pins 1-9, but that isn't as useful as CAN3. Either way a brick works much better as a way to gain entry to a car, if a thief is prodding about with your OBD port than you have larger issues ;-)
 
@Harrod

Nope, everything should be pretty similar, depending on the model year of your car though you could have a different connector (Tesla changed it with the new 2015 models) this is currently be discussed on the "hacking the Model S" thread by wk057, however there are plenty of leads on connector sources so it's just a matter of some wiring details.

I'm currently working on a new article about using the low cost CANtact board with some software that I have written for logging/saving raw data and reading data in engineering units (torque, battery voltages, charge in kWh). If you are interested, I have a beta version over at Github, it's written in python but you can access most options via command line arguments so you don't need to modify the source code.

Let me know if you have any other questions.
 
@obrien28. Actually now I've read through all these various links I can see it is beyond my current technical skills. But I love the idea of logging the car. And as a disclosure: I'm a university researcher (with access to a P85+ and a 90D), and with an interest in understanding typical customer energy consumption (day-to-day basis, not 0-60 ludicrous stuff). Any idea if these types of technology have been used to record, for example, daily energy consumption and daily charging energy on Model S 85s?
 
@obrien28. Actually now I've read through all these various links I can see it is beyond my current technical skills. But I love the idea of logging the car. And as a disclosure: I'm a university researcher (with access to a P85+ and a 90D), and with an interest in understanding typical customer energy consumption (day-to-day basis, not 0-60 ludicrous stuff). Any idea if these types of technology have been used to record, for example, daily energy consumption and daily charging energy on Model S 85s?

@harrod

Just a heads up, I sent you an email via the button on your profile, let me know if you received it.
 
I'm currently working on a new article about using the low cost CANtact board with some software that I have written for logging/saving raw data and reading data in engineering units (torque, battery voltages, charge in kWh). If you are interested, I have a beta version over at Github, it's written in python but you can access most options via command line arguments so you don't need to modify the source code.

Let me know if you have any other questions.

Hi @obrien28
I'm looking into logging data off a Tesla in a set and forget manner (logging to SD card with a GPS component), potentially using a setup consisting of tesla -> cantact -> raspberry pi. How successful were you in getting yours to work? Did you finish writing the article or can you provide details of your full setup?
 
Bumping this thread; am also interested in logging various data from my model S.

Panda looks like a pretty good candidate; could see using it + wireshark running on a small computer (raspi, beaglebone...) to log CAN data from at least 3 busses to an SD card pretty easily.

Logging is only half the fun though; would want to do some analysis too.

Wonder if anyone has thought of creating a wireshark dissector specifically for Tesla CAN data... (or if Tesla techs have access to such tools already for diagnosing CAN issues)
 
This should make things far more interesting on the bus sniffing side: comma.ai

Now, we just need some good EE to make us an adapter from the Tesla hidden can bus to Panda =).
There already is a company selling adaptors to go from the new Model S to OBDII, here is a link to their webstore. I have one, it's a pretty high quality cable. I think they also sell on Panjo.
 
  • Like
Reactions: BigD0g
Bumping this thread; am also interested in logging various data from my model S.

Panda looks like a pretty good candidate; could see using it + wireshark running on a small computer (raspi, beaglebone...) to log CAN data from at least 3 busses to an SD card pretty easily.

Logging is only half the fun though; would want to do some analysis too.

Wonder if anyone has thought of creating a wireshark dissector specifically for Tesla CAN data... (or if Tesla techs have access to such tools already for diagnosing CAN issues)
Tesla techs use the dumbed down Toolbox software to fix/diagnose the car, it's on a totally separate interface (that uses ethernet) rather than CAN, which is different from most auto-tech software. There was a dump of some dbc files floating around a while ago, can't say where.
 
Tesla techs use the dumbed down Toolbox software to fix/diagnose the car, it's on a totally separate interface (that uses ethernet) rather than CAN, which is different from most auto-tech software. There was a dump of some dbc files floating around a while ago, can't say where.

Thanks. If you look at the tooling master list for body shops available on the service website, tesla lists a 4 way CAN breakout cable and a gridconnect USB to CAN adapter. So, while obviously most techs use toolbox, there must be at least some CAN work being done.
 
I have a Model S P85+ made in 11/2013. I've removed my upper cubby and there's NOTHING there.

What an I missing? I can't find any info regarding my year Model S and the lack of a port under the infotainment screen.
 

Attachments

  • 20210228_125357.jpg
    20210228_125357.jpg
    264.7 KB · Views: 173
That wire bundle top right looks correct? Pull the cubby out all the way.
I did end up taking the cubby all the way out (which, btw, will probably never go back to where it came from without the help of a Tesla tech lol). That cable in the upper right corner LOOKS like the size of the cable bundle that attaches to the diag port, but it is FIRMLY in position. I pulled on both ends pretty hard with ZERO movement - so either that IS the cable and it is stuck or pinched behind something, or it is an unrelated grouping of cables (most likely for the MCU)