Torque

Forums

Forums

generic OBD profile...
 
Notifications
Clear all

generic OBD profile?

8 Posts
4 Users
0 Reactions
718 Views
(@toalan)
Posts: 9
Active Member
Topic starter
 

Is there a generic OBD profile for torque? I have a few aftermarket automotive dataloggers and wideband O2 controllers I have designed that I would like to interface with torque and use torque as the mobile app for displaying of metrics and datalogging.

I am not sure where to start, I am hoping there is a generic profile that I can use as a template to talk to torque. If such a profile is not available, is there a recommended profile that I should use? I can emulate the ODB protocol of a common place vehicle like a civic.

 
Posted : 03/06/2015 2:55 am
(@toalan)
Posts: 9
Active Member
Topic starter
 

Bump

 
Posted : 05/06/2015 9:42 pm
(@mrnielsen2000)
Posts: 36
Trusted Member
 

I am actually working on this same thing. Have it going ok with a variety of gauge senders and it is pretty interesting to use as a data logger or just as a display. Here is a quick video:

https://youtu.be/ztz9IEJ7q7U

Been planning on using your SLC OEM wideband, it's sitting here on my desk, currently trying to get it to work with I2C for the extended range.

You can use any standard OBD protocol as far as I know. No need to emulate any particular vehicle. More info on the protocol and formulas for individual gauges can be found here:

http://en.wikipedia.org/wiki/OBD-II_PIDs

 
Posted : 06/06/2015 5:27 am
(@toalan)
Posts: 9
Active Member
Topic starter
 

Ty for the reply.

I think I will start by looking for a obd2 simulator/emulator and running a scope on the uart tx/rx to get an idea of the nitty gritty stuff.

Do you know of an emulator that you can reccommend? I am planning to get this http://freematics.com/store/index.php?route=product/product&product_id=71

 
Posted : 06/06/2015 10:19 pm
(@admin)
Posts: 6550
Member Admin
 

Hi!

(that video's great! :))

To talk to Torque, all you'd need to do is emulate one of the ELM327 chips (search google for ELM327DS for the datasheet which has the command list)

I'd recommend emulating a canbus system (rather, emulate the responses from one) as it's easier to deal with

To emulate an adapter, you should need to implement (I may have missed something but it should be pretty much as follows):

AT E0
AT H (n) - headers are used to determine how many ECU’s present (hint: only send one response to 0100 and emulate a single ECU system to save time coding)
AT L0
AT Z
AT SH (though you may be able to ignore this if you wish)
AT @1
AT I
AT AT (n) (though you can ignore this)
AT SP (set protocol) - you can ignore this
AT DP (always return can11/500)
AT DPN (always return can11/500)
AT RV (adapter voltage)

I think that’s all the ones that Torque uses that are mildly important to the app, then it's just sending/receiving data as per what the ELM would format

Alternatively, you could write a plugin that uses the AIDL api to feed data directly into Torque - that way you can connect however you want (onboard device, bluetooth, usb, heck even i2c if you got that working in android) using your own code, and then simply push the data into the app itself

 
Posted : 06/06/2015 10:56 pm
(@toalan)
Posts: 9
Active Member
Topic starter
 

Can torque open multiple ports at the same time? I mean suppose you want to use a OBD to BT adapter for getting info from the stock ECU and you want to connect to another BT device to fetch data from a datalogger and have torque show info from both data streams at the same time.

 
Posted : 06/06/2015 11:09 pm
(@mrnielsen2000)
Posts: 36
Trusted Member
 

^^^That post on emulating an adapter is great! That is really all you need to do.

Not sure if Torque can read data from multiple sources at once. If not, I think you could connect Torque to the stock ECU and then inject packets from your data logger into that data stream, then Torque would be reading from both the stock ECU and from the data logger via the same connection. Something like this thing maybe:

https://www.kickstarter.com/projects/etx/canbus-triple-the-car-hacking-platform/description

 
Posted : 08/06/2015 1:03 am
(@moreause)
Posts: 650
Honorable Member
 

that is what i did
i was injecting data into the data stream

i was requesting an PID that is not supported by the PCM it wont respond

and was using my arduino to look for that request and send the info requested
in my case it was the 0-5V signal from the map sensor

i was letting the arduino do the math

like if 2.5 V was 15.0 psi ...i was sending 15 and 0 and
in torque a was doing some math to put it back again in a number

 
Posted : 08/06/2015 6:46 am
Share:

  Follow me on twitter