# Extended PIDs for torque app on prototype EV.



## frodus (Apr 12, 2008)

It looks like you have standard CAN. Torque only talks OBDII style CAN. Meaning, Torque will ONLY send out a PID request and wait for a response, then display. You have data that is broadcast. Torque cannot be set to just listen for a certain value, it has to ask for it, which is part of the spec of OBDII.

What you'd have to do, is use a gateway of sorts to take the CAN traffic and store to a table inside a micro controller. Then, when torque sends a PID request, respond accordingly.

When you say "The app is able to connect to the ECU and display message traffic", what do you mean?

I've worked with torque a LOT and post daily on the torque forum, so I'll help if I can.


----------



## Jasta11 (May 1, 2014)

Hello Travis,

Thanks for taking the time to answer my question. Below you can see the types of responses I'm receiving from the ECU when scanning PIDs with Torque. I'm working on building an arduino based CAN sniffer. Although, they tell me all data eedd to create the tables is in the DBC file. Is there a particular can sniffer you can recommend? Thanks, Travis. I' m looking forward to getting some feedback from you.

Please enter the vehicle type if sending to the developer, thanks!

Command: 2101 response:
* 03D
* 0:6101FFFFFFFF
* 00E
* 0:6101E8000000
* 1:B8191023282300
* 1:15060E03000000
* 2:0C0F5613121313
* 2:00000000000000
* 3:1213120015CC34
* 4:CC590000830000
* 5:3D9D00003D6000
* 6:0016FD0000165D
* 7:000B9BFD450184
* 8:0000000003E800
Command: 2102 response:
* 021
* 0:6102FFFF8000
* 026
* 0:6102FFFFFFFF
* 1:83C20000000000
* 1:CCCCCCCCCCCCCC
* 2:00000004000000
* 2:CCCCCCCCCCCCCC
* 3:00001C003E4343
* 3:CCCCCCCCCCCCCC
* 4:0208FF07F95000
* 4:CCCCCCCCCCCCCC
* 5:CCCCCCCC000000
Command: 2103 response:
* 026
* 0:6103FFFFFFFF
* 7F2112
* 1:CCCCCCCCCCCCCC
* 2:CCCCCCCCCCCCCC
* 3:CCCCCCCCCCCCCC
* 4:CCCCCCCCCCCCCC
* 5:CCCCCCCC000000
Command: 2104 response:
* 026
* 0:6104FFFFFFFF
* 7F2112
* 1:CCCCCCCCCCCCCC
* 2:CCCCCCCCCCCCCC
* 3:CCCCCCCCCCCCCC
* 4:CCCCCCCCCCCCCC
* 5:CCCCCCCC000000
Command: 2105 response:
* 02C
* 0:6105FFFFFFFF
* 7F2112
* 1:00000000001213
* 2:13000000001910
* 3:23280000501414
* 4:00383900280F00
* 5:00000000000000
* 6:00000000000000
Scanning finished


----------



## frodus (Apr 12, 2008)

What are you trying to communicate with?

It looks like it's responding to mode 21 OBD PIDs.... So it MIGHT have some OBD support. You'll have to translate the dbc to figure out what bytes are what and what the scale values are.


----------



## Jasta11 (May 1, 2014)

I run the scan PID function and this is what it returns, It may be that mode 21 is using the OBD 2 can bus. I don't see mode 21 anywhere on the dbc file. Do you think mode 21 carries any EV related traffic? It's quite interesting and complicated work. I enjoy a good challenge and this sure beats logging crap down on a sheet of paper!

I'm thinking about getting the microchip CAN Analyzer for $99. Ever heard of it? (http://www.microchip.com/Developmenttools/ProductDetails.aspx?PartNO=APGDT002)


----------



## frodus (Apr 12, 2008)

What you have works.... It's just encoded in hex. Torque is sending 2101 and it gets a response from several ECUs. The dbc file might help.... But you only attached some of it. 

I doubt the microchip device will help much more. Don't focus on torque right now. Focus on putting the elm327 into monitor mode (see the elm datasheet) with a terminal program on a laptop. Then see what's on the bus. 

Again.... What are you trying to connect to?


----------



## Jasta11 (May 1, 2014)

I think you are right. My main target is the BMS. Most of the information I need is related to SOC

Any ideas on how to extract PIDs from the info above? Can we break it down? I know the mode and PID are 2101 and 2102, right? The units are "A" = Amps "V" = Volts. About the only thing I need is to decipher the equation.


----------



## frodus (Apr 12, 2008)

What bms.... You've told me nothing... I keep asking but I can't really help unless I get a better idea of what you're trying to do.

You should really go read Wikipedia about PIDs first. I don't think 1429 is the mode and pid.


----------



## Jasta11 (May 1, 2014)

Travis,

I ran some more tests on the vehicle and retrieved some data. In regards to your question about the BMS, I have no idea who makes it. Here is some of the retrieved data. Is there a better program than OBDwiz to extract data? Any suggestions. 

Trying Protocol: ISO 15765-4 CAN (11 bit ID, 500 Kbaud)
ATSP 6: [OK]
01 00: [41 00 80 00 00 01 
41 00 80 00 00 01 ]
Protocol detected: ISO 15765-4 CAN (11 bit ID, 500 Kbaud)

ATH1: [OK]
Reading vehicle information
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 20: [7EC 06 41 20 00 01 80 00 00 
7EA 06 41 20 80 01 80 00 00 ]
Detected PIDs:
ECU: 7EA
0x00 - SupportedPIDs0
0x01 - MonitorStatus
0x20 - SupportedPIDs1
0x21 - DistanceTraveledWithMILOn
0x30 - NumWarmUpsSinceCodesCleared
0x31 - DistanceSinceCodesCleared
ECU: 7EC
0x00 - SupportedPIDs0
0x01 - MonitorStatus
0x20 - SupportedPIDs1
0x30 - NumWarmUpsSinceCodesCleared
0x31 - DistanceSinceCodesCleared

09 0A: [7EC 10 17 49 0A 01 42 45 43 
7EC 21 4D 2D 42 2B 45 6E 65 
7EC 22 72 67 79 43 74 72 6C 
7EC 23 00 00 00 00 00 00 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
ATSH 7DF: [OK]
01 01: [7EA 06 41 01 00 04 00 00 00 ]
No Data Received: MonitorStatus, Invalid Count: 1
No data was received.
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
09 02: [NO DATA]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
STMFR: [ScanTool.net LLC]
STI: [STN1151 v3.4.1]
STDI: [OBDLink MX BT r2.2]
STSN: [115110068036]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
STDIX: [Device: OBDLink MX BT r2.2
Firmware: STN1151 v3.4.1 [2013.07.10]
Mfr: ScanTool.net LLC
Serial #: 115110068036
BL Ver: 2.15
IC ID/Rev: 0x0100, 0x067F, 0x3004
BT Modem: BT33LT, R3 130217H IDPS, 00043E303BBD
BT Dev Name: OBDLink MX
Init Date: 2013.12.23
POR Count: 55
POR Time: 0 days 00:30:34
Tot Run Time: 2 days 23:55
Eng Cranks: 1
Eng Starts: 1]
OBDStandard is not supported by this vehicle.
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00 
7EA 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EA 06 41 00 80 00 00 01 00 
7EC 06 41 00 80 00 00 01 00 ]
01 00: [7EC 06 41 00 80 00 00 01 00


----------



## frodus (Apr 12, 2008)

You've given no information on what vehicle you're trying to talk to, what BMS, no pictures or idea about the system. 

It seems like you have little understanding of OBDII and want a simple answer on how to make it work. If you can't give any answers, then don't expect any help.


----------



## Jasta11 (May 1, 2014)

Travis,

I do appreciate your help. You've given some good insights into what needs to be done. You are right about my limited knowledge when it comes to OBD II theory. Although, I'm more interested in the proprietary layer (which no one knows anything about) rather than emissions related OBD II stuff. Afterall, this is an EV!


----------



## CKidder (Dec 12, 2009)

Basically any PID code with a mode of more than 0x10 is proprietary. 0x21 is a pretty common mode to use for proprietary PID communication. If you have a DBC file you might try loading it in something like Busmaster to see the definition of frames. However, DBC files are really geared toward non-PID comm - just straight canbus. So, it might not do you a lot of good. Then again, maybe they implemented their PID comm such that it essentially mirrors the info in the DBC file. It's worth a look. If you post the DBC I could probably help to decipher it. 

Torque will allow you to specify custom PID codes and how the return information is formatted so you should be able to do what you want so long as you can obtain the relevant information on the formatting.


----------

