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

Chassis CAN Logging To ASCII Text Plus Graphing

This site may earn commission on affiliate links.
LL and JP,
Let me know if you need some conversion examples (provided you promise not to laugh at my code :) ). I did some test work in C sharp in Visual Studio and but did the real work in micro controller C without a floating point library.


There must be some purposeful power manipulation going on-
Model X P90D Accleration Testing, wow, be prepared, quicker than the Model S P85D
Looks like it is time to attract an X owner to our little circle for even more data :eek:

I'm getting a case of Sorka/WK in that I'm beginning to feel manipulated. All this would indicate the P90DLs could very well be ten second cars if allowed access to the battery.
 
Last edited:
I just want to put in a request to any of you who may be beginning to log your own CAN data. If you are willing, it would be great if you also logged a comparison run using TeslaLog, so those of us that don't have access to CAN logging might be able to get an idea of how similar or dissimilar that information is from the information you're able to obtain from the CAN bus.

You can enable TeslaLog just for a run or two if you like. The thread on it is here, and for now it is still free:

TeslaLog.com - Your hosted Tesla Data Logger - Announcement / Support threads

Below is a sample of the kind of data it can produce, from a launch I did a few weeks ago in my P85D (cold, with snow tires on, at about 85% SOC.)

View attachment 110111

I was motivated by this theme!

I was also testing a little today:
I would say a good time without effort... :)

My car P85D :smile:
SOC 90%
Snow tires 19" :crying:
Battery "Ready for Insane Mode" = temperature 46°C :redface:
Power is limited by system, notice "Max Power Discharge"
Data provided by CANbus...
Graph from TeslaLog...
All pics from my utility on Linux

Thanks!

Snímek obrazovky 2016-02-07 v 18.22.50.png

IMG_0858.JPG

IMG_0870.JPG

IMG_0871.JPG

IMG_0873.JPG

IMG_0875.JPG
 
Launch Mode vs Fast Foot

Some notes of observation of the starts for run 2 (FF) vs run 4 (LM) charts of 0-60 runs.

The time from pedal action to first car motion takes ~190 msec FF vs 130ms LM. But FF includes 30-40 ms of the time it takes to get the accelerator all the way to the floor, and no signal was available to determine how long for brake pedal release. Accelerator pedal release while staging for LM took 60-70 ms.

At first motion the front/rear motor torques (ft-lbs) and current were nearly the same: 235/400 at 242A for FF, 230/411 at 200A for LM.

The time after first motion and the current level for the big dip in the rear motor torque was nearly the same: 600 ms at 780A for FF, and 700 ms at 790A for LM.

The staging F/R torque and current/power for LM: 170/355 at 113A pulling 41kW

There was a small current pullback ~30-50 ms before first motion in both modes, and LM had another pullback ~40ms after first motion (seen on the run 4 chart).

Speed was x10 and plotted along with voltage on the right side axis to open the view to the current fluctuation at the big dip. Send data when you get some, that's all for now, time for the puppy bowl...

Fast Foot
run2_zoom.png


Launch Mode
run4_zoom.png
 
  • Informative
Reactions: benjiejr
I just thought of something that may be relevant for all of you interested in logging data.

For some time many of us have believed there is an issue with the P85Ds' odometers that cause them to overstate the mileage driven by a bit. This also causes them to slightly overstate the speed being traveled.

Driving on the highway today, with TACC set to 70, the windspeed site I was using showed, based on GPS data, that my speed was 68.8 MPH. I've checked my speedometer using GPS apps before, and the speedometer is consistently high.

My point is that I'm guessing any data coming from the car that you guys are reading from the CAN Bus will be based on the car's measurements, right? So these measurements will line up with the overstated speedometer data. This would then differ from vbox data, which I assume is using GPS data to determine speed.

When you guys are measuring things to the hundredths of a second, I imagine the difference between 0-60 and 0-59 becomes significant, so I wanted to bring this up.
 
@pupik - Which logger setup are you using? What interface is that?

Logger is my (works online), I'm write in C++ using the QT lib ( like Tesla :) ) + OS Linux Ubuntu ( like Tesla :) )
Interface for CANbus be freely. I prefer better more professional (for greater security)

My interface uses good chips:
Philips 82C251 CAN Exciter (fully Compatible with ISO 11898-24V)
Philips SJA1000 CAN Controller running at 16Mhz
FTDI FT245 RL chip interface for USB
...and especially thank you very much for Jason (WK057) and his analysis of CAN IDs :confused:
Thanks!
 
I just thought of something that may be relevant for all of you interested in logging data.

For some time many of us have believed there is an issue with the P85Ds' odometers that cause them to overstate the mileage driven by a bit. This also causes them to slightly overstate the speed being traveled.

Driving on the highway today, with TACC set to 70, the windspeed site I was using showed, based on GPS data, that my speed was 68.8 MPH. I've checked my speedometer using GPS apps before, and the speedometer is consistently high.

My point is that I'm guessing any data coming from the car that you guys are reading from the CAN Bus will be based on the car's measurements, right? So these measurements will line up with the overstated speedometer data. This would then differ from vbox data, which I assume is using GPS data to determine speed.

When you guys are measuring things to the hundredths of a second, I imagine the difference between 0-60 and 0-59 becomes significant, so I wanted to bring this up.

Interesting point. Would that overstated data be equal to 0.1s, 0.2s or not nothing?
 
That's strange. I've checked all five cars I've had and the spedo has been dead on for all of them (which I found surprising as I too have found almost all other cars over estimate speed).

I'm not trying to stir up the discussion from the following thread. I'm just posting it so you can see some of the discussion, and some of the people who were confirming that the issue existed for them, including wk057.

Do P85Ds and S85Ds have inaccurate odometers that overstate distance traveled?
 
That's strange. I've checked all five cars I've had and the spedo has been dead on for all of them (which I found surprising as I too have found almost all other cars over estimate speed).

Mine is also off by about 1 mph or so when compared to Waze's little speed indicator and my GPS Status app.

Tire tread can be responsible for a small amount of that - about a 1/4 mile per hour or so at 60 mph for old tires compared to new.
 
Andy,
I do not doubt you for a moment. I was actually surprised when my spedo(s) were accurate as they are not on things like my Zero which is actively lying about range :)

Thanks, Bill.

I just wanted to provide the link to the more complete discussion, because there was some controversy in the thread.

And as little as I understand with respect to what you guys are doing with the CAN bus data, I have to assume that when you are measuring stuff down to the hundredth of a second, the fact that the data being supplied by one source could be off by somewhere in the neighborhood of 1%, give or take, vs. the other source could be a factor you'd want to take into consideration.


Mine is also off by about 1 mph or so when compared to Waze's little speed indicator and my GPS Status app.

Tire tread can be responsible for a small amount of that - about a 1/4 mile per hour or so at 60 mph for old tires compared to new.

Yes, in that thread the issue of tread wear was definitely brought up. The problem with that, though, was that what we were all recording was the odometer being off in the wrong direction for tread wear to have been responsible, as we all had essentially brand new tires at that point, and we were seeing the odometer overstate the distance traveled. If anything, the odometer should understate the distance by a bit with brand new tires, and overstate by a bit with worn tires, but to be overstating by .8% (that was the general consensus number in that thread) with essentially new tires meant that the overstatement would only get worse as the tires wore down.
 
Andy,

I'll go back and check my spedo again as being off just a mile an hour would make a significant difference.

I've added my wife's S85 to the ability to log with auto determination of AWD versus RWD. The data from legacy cars seems to be a little less robust.
I'm building a few loggers up and will send them out once tested.
Dropbox - S85.TXT

Time......TPS....Speed.....R_Tq...BatV.....BatI......Pwr......TWD
0133.51 100.0 +067.90 +174.9 274.75 -1001.8 275.2
0133.52 099.2 +068.15 +174.9 275.12 -1001.3 275.4
0133.53 090.8 +068.25 +174.8 274.38 -0994.4 272.8
0133.54 076.8 +068.00 +174.0 275.40 -0987.6 271.9
0133.55 061.6 +068.25 +175.7 275.02 -1001.9 275.5
0133.56 042.0 +068.25 +174.0 275.14 -1002.1 275.7
0133.57 022.8 +068.50 +174.6 274.77 -0998.8 274.4
0133.58 004.0 +068.25 +174.6 275.29 -0986.9 271.6
0133.59 000.0 +068.50 +175.3 275.15 -0984.0 270.7
0133.60 000.0 +068.25 +174.6 276.78 -0973.6 269.4
0133.61 000.0 +068.50 +174.8 276.53 -0971.7 268.7
0133.62 000.0 +068.60 +172.7 276.78 -0951.7 263.4
0133.63 000.0 +068.60 +169.8 279.93 -0920.5 257.6
0133.64 000.0 +068.60 +168.3 281.70 -0907.8 255.7
0133.65 000.0 +068.85 +165.2 281.83 -0889.9 250.8
0133.66 000.0 +068.60 +162.6 283.86 -0856.7 243.1
0133.67 000.0 +068.60 +158.5 285.11 -0847.4 241.6
0133.68 000.0 +068.85 +153.7 288.77 -0797.0 230.1
0133.69 000.0 +068.95 +149.3 290.92 -0755.2 219.7
0133.70 000.0 +068.70 +144.7 291.06 -0765.7 222.8
0133.71 000.0 +068.95 +138.6 294.72 -0724.4 213.4
0133.72 000.0 +069.20 +132.5 299.02 -0636.1 190.2
0133.73 000.0 +068.95 +127.2 297.88 -0631.8 188.2
0133.74 000.0 +068.70 +119.8 299.90 -0635.3 190.5
0133.75 000.0 +068.95 +111.1 302.93 -0589.2 178.4
0133.76 000.0 +068.95 +104.1 305.84 -0542.8 166.0
0133.77 000.0 +068.95 +098.6 308.73 -0506.5 156.3
0133.78 000.0 +068.95 +095.1 310.38 -0474.1 147.1
0133.79 000.0 +068.95 +092.5 312.91 -0443.3 138.7
0133.80 000.0 +068.95 +088.5 314.92 -0411.7 129.6
0133.81 000.0 +068.95 +081.6 317.20 -0381.7 121.0
0133.82 000.0 +068.95 +076.7 318.96 -0353.7 112.8
0133.83 000.0 +068.95 +070.4 321.11 -0327.2 105.0
0133.84 000.0 +068.95 +061.7 322.12 -0311.4 100.3
0133.85 000.0 +068.95 +050.7 323.50 -0291.7 094.3
0133.86 000.0 +069.20 +045.5 326.28 -0258.3 084.2
0133.87 000.0 +068.95 +042.5 329.31 -0216.7 071.3
0133.88 000.0 +069.20 +039.6 331.20 -0184.7 061.1
0133.89 000.0 +068.95 +038.7 332.21 -0166.5 055.3
0133.90 000.0 +068.95 +037.2 332.48 -0163.4 054.3
0133.91 000.0 +068.95 +033.0 333.23 -0159.1 053.0
0133.92 000.0 +068.95 +030.0 334.10 -0148.5 049.6
0133.93 000.0 +069.20 +028.3 335.86 -0127.7 042.8
0133.94 000.0 +068.95 +026.7 338.13 -0100.1 033.8
0133.95 000.0 +069.20 +024.5 339.53 -0073.0 024.7
0133.96 000.0 +068.95 +020.6 340.54 -0060.3 020.5
0133.97 000.0 +069.20 +017.1 340.77 -0053.8 018.3
0133.98 000.0 +068.95 +018.0 341.41 -0055.0 018.7
0133.99 000.0 +069.20 +013.6 341.92 -0040.8 013.9
0134.00 000.0 +069.30 +008.2 342.66 -0033.4 011.4
0134.01 000.0 +069.05 +007.7 343.30 -0027.2 009.3
0134.02 000.0 +069.30 +007.1 343.94 -0019.4 006.6
0134.03 000.0 +069.05 +007.3 344.44 -0013.8 004.7
0134.04 000.0 +069.30 +008.4 346.20 +0002.8 000.9
0134.05 000.0 +069.05 +007.7 345.46 +0005.7 001.9
0134.06 000.0 +068.95 +000.0 345.07 -0007.5 002.5
0134.07 000.0 +069.20 +009.2 348.97 +0037.2 012.9
0134.08 000.0 +068.95 +010.8 344.95 +0008.9 003.0
0134.09 000.0 +068.95 +009.5 346.21 -0008.2 002.8
0134.10 000.0 +068.70 +008.4 345.58 -0005.3 001.8
0134.11 000.0 +068.95 +008.1 348.23 +0030.5 010.6
0134.12 000.0 +068.70 +006.8 347.22 +0022.2 007.7
0134.13 000.0 +068.45 +008.2 345.71 -0003.2 001.1
0134.14 000.0 +068.60 +006.6 347.85 +0017.8 006.1
0134.15 000.0 +068.60 +008.6 349.25 +0044.6 015.5
0134.16 000.0 +068.85 +014.7 349.64 +0058.2 020.3
0134.17 000.0 +068.60 +017.8 350.01 +0059.8 020.9
0134.18 000.0 +068.85 +025.2 352.65 +0080.1 028.2
0134.19 000.0 +068.60 +032.6 352.80 +0091.1 032.1
0134.20 000.0 +068.85 +040.5 354.43 +0112.3 039.8
0134.21 000.0 +068.60 +049.9 354.06 +0125.2 044.3
0134.22 000.0 +068.85 +049.6 354.56 +0109.8 038.9
0134.23 000.0 +068.60 +042.7 354.07 +0114.3 040.4
0134.24 000.0 +068.85 +032.0 356.09 +0124.3 044.2
0134.25 000.0 +068.60 +025.2 355.20 +0123.3 043.7
0134.26 000.0 +068.85 +014.9 356.97 +0139.9 049.9
0134.27 000.0 +068.60 +014.7 356.10 +0147.7 052.5
0134.28 000.0 +068.85 -003.1 356.35 +0137.7 049.0
0134.29 000.0 +068.60 -010.3 356.60 +0131.5 046.8
0134.30 000.0 +068.60 -013.8 356.34 +0137.1 048.8
0134.31 000.0 +068.60 -018.9 356.34 +0131.5 046.8
0134.32 000.0 +068.60 -024.7 356.46 +0134.2 047.8
0134.33 000.0 +068.60 -024.7 356.82 +0144.7 051.6
0134.34 000.0 +068.60 -023.7 356.94 +0147.1 052.5
0134.35 000.0 +068.60 -030.0 356.69 +0134.6 048.0
0134.36 000.0 +068.35 -028.3 357.08 +0142.5 050.8
0134.37 000.0 +068.60 -030.6 357.58 +0148.6 053.1
0134.38 000.0 +068.60 -029.6 357.20 +0144.8 051.7
0134.39 000.0 +068.35 -028.9 357.71 +0146.4 052.3
0134.40 000.0 +068.25 -026.9 356.82 +0136.0 048.5
0134.41 000.0 +068.50 -026.9 357.96 +0146.5 052.4
0134.42 000.0 +068.25 -029.6 357.71 +0156.2 055.8
0134.43 000.0 +068.25 -029.3 357.95 +0148.3 053.0
 
I was speaking about the how current seems to lag badly (in comparison to my P85D) behind throttle. In the example above, throttle goes to 0 at the start of the data yet current takes a bit of time to go from negative (depleting the battery) to positive (regen). In my PD, this was a very quick transition. The data agrees with the way the car feels which is sluggish and unresponsive.
 
I was speaking about the how current seems to lag badly (in comparison to my P85D) behind throttle. In the example above, throttle goes to 0 at the start of the data yet current takes a bit of time to go from negative (depleting the battery) to positive (regen). In my PD, this was a very quick transition. The data agrees with the way the car feels which is sluggish and unresponsive.

May be something to ask the local service center about, could be an error somewhere in the drivetrain?
 
I was speaking about the how current seems to lag badly (in comparison to my P85D) behind throttle. In the example above, throttle goes to 0 at the start of the data yet current takes a bit of time to go from negative (depleting the battery) to positive (regen). In my PD, this was a very quick transition. The data agrees with the way the car feels which is sluggish and unresponsive.

Not sure what was happening at the start--TPS was at ~50% and then gradually went to 100. Not like your fast foot at all. Thanks to MikeBur for tips and help with formatting charts although i still haven't figured out how he does it. If anyone needs to make charts i would recommend getting a copy of the setup from him, he is a master. Amps are on the right side axis all others on the left, time axis is seconds.

Now that Jason got runnoft from his 81kWh battery thread, this one and the hardware hacking are the only ones left of interest to me. i'm only interested in the technical findings, not a bunch of blind fanboyz fighting to defend tm...

S85_run1.png
 
So I've managed to put in a little more time into a conversion algorithm that takes SavvyCAN output and converts it to a similar "cross tab" format that lola is outputting from his device.

Now I think I'm there or thereabouts (still a few tweaks to do, I've literally put under an hour in).

Result probably the slowest 0-60 time posted from a full throttle Tesla launch :redface: (Edit: disclaimer I haven't trimmed the start of the file, so that's an easy way to trim c.500ms from my time ;) )

S60 0-60.PNG
 
Last edited: