Any information on how I would be able to read from a custom k-line, not full obd2.
Would it be doable through lua scripting and reading a digital input?
K-line
Moderators: JeffC, rdoherty, stieg
Sounds like you are talking about bit banging the K line (pin 7) through LUA using the GPIO lines. I have never seen this done before using LUA. Based on the ISO9141-2 spec you would not be able to achieve this as RCP can only drive a signal as high as 5V. The standard dictates that you need 9.6V minimum to replicate a "high" value on the line. See http://www.onboarddiagnostics.com/page03.htm for more info.
Andrew Stiegmann (Stieg)
Principal Engineer
Autosport Labs Inc.
Principal Engineer
Autosport Labs Inc.
-
- Posts: 16
- Joined: Thu Apr 14, 2016 12:53 pm
- Location: Pattaya, Thailand
- Contact:
It seems to me that if you can connect the K-line to the RaceCapture Pro CAN bus connector at the physical level, then the RaceCapture PID protocol should just work. This guy has a schematic of how to go from the single K-line to separate transmit & receive lines:
http://www.clubwrx.net/forums/tutorials ... duino.html
These Tx & Rx lines could then be connected to a serial-to-Canbus adapter.
Sparkfun also has a K-line to serial adapter:
https://www.sparkfun.com/products/9555
Then you could connect the serial port to something like this:
http://gridconnect.com/rs232-can-converter.html
Plug that into the CAN-bus connector on the RaceCapture Pro, and you're talking to your ECU. I need something like this so I can communicate with the ECU on my 2007-2008 Suzuki GSX-R1000 engine.
Does this make sense to anybody?
-JJ
http://www.clubwrx.net/forums/tutorials ... duino.html
These Tx & Rx lines could then be connected to a serial-to-Canbus adapter.
Sparkfun also has a K-line to serial adapter:
https://www.sparkfun.com/products/9555
Then you could connect the serial port to something like this:
http://gridconnect.com/rs232-can-converter.html
Plug that into the CAN-bus connector on the RaceCapture Pro, and you're talking to your ECU. I need something like this so I can communicate with the ECU on my 2007-2008 Suzuki GSX-R1000 engine.
Does this make sense to anybody?
-JJ
LudemannEngineering.com
-
- Posts: 16
- Joined: Thu Apr 14, 2016 12:53 pm
- Location: Pattaya, Thailand
- Contact:
USB / Serial / Bluetooth Communication to GSX-R1000 ECU
I see the Lua scripting page says the USB port is available as serial port 0, but recommends against using it as it " may interfere with normal operations of the unit". Is this still the case?
I already have a device, the HealTech OBD Tool for Suzuki ( http://shop.bluemonkeymotorsports.com/H ... _p_12.html ), that already works to connect the USB port of a laptop PC to the GSX-R1000 ECU. I could put USB sniffer software on the laptop's USB port, figure out the communications protocol, then re-implement it in a Lua script if I could just connect it to the RaceCapture USB port. Failing that, maybe I could get a USB to serial converter and plug it into the RC aux serial port.
The problem with connecting the RC serial port directly to the GSXR diagnostic port is that the GSXR wants a 2000 ms hi, 25 ms low, 25 ms high sequence on TxData to initialize, and I don't think I can make this with the RC serial port. Is there some way to directly control the TxData line? This initialization is already taken care of by the HealTech gizmo.
The Lua script page says it's OK to use the Bluetooth port, so maybe I can put a USB to Bluetooth converter on the HealTech gizmo and do it that way...
I'm going to order hardware for all these approaches, but would appreciate any ideas on the best direction to proceed.
-JJ
I already have a device, the HealTech OBD Tool for Suzuki ( http://shop.bluemonkeymotorsports.com/H ... _p_12.html ), that already works to connect the USB port of a laptop PC to the GSX-R1000 ECU. I could put USB sniffer software on the laptop's USB port, figure out the communications protocol, then re-implement it in a Lua script if I could just connect it to the RaceCapture USB port. Failing that, maybe I could get a USB to serial converter and plug it into the RC aux serial port.
The problem with connecting the RC serial port directly to the GSXR diagnostic port is that the GSXR wants a 2000 ms hi, 25 ms low, 25 ms high sequence on TxData to initialize, and I don't think I can make this with the RC serial port. Is there some way to directly control the TxData line? This initialization is already taken care of by the HealTech gizmo.
The Lua script page says it's OK to use the Bluetooth port, so maybe I can put a USB to Bluetooth converter on the HealTech gizmo and do it that way...
I'm going to order hardware for all these approaches, but would appreciate any ideas on the best direction to proceed.
-JJ
LudemannEngineering.com
Yes. The code that makes use of the USB port is not designed with external use in mind.I see the Lua scripting page says the USB port is available as serial port 0, but recommends against using it as it " may interfere with normal operations of the unit". Is this still the case?
I doubt that plugging in the GSX-R1000 to the RCP unit will even work since (at least on the RaceCapture unit) they are both USB guest devices. The GSX unit would need to support the USB OTG (on the go) spec that allows it to work as both USB host and USB guest devices. I doubt it supports that.I already have a device, the HealTech OBD Tool for Suzuki ( http://shop.bluemonkeymotorsports.com/H ... _p_12.html ), that already works to connect the USB port of a laptop PC to the GSX-R1000 ECU. I could put USB sniffer software on the laptop's USB port, figure out the communications protocol, then re-implement it in a Lua script if I could just connect it to the RaceCapture USB port.
This is more probable to work.Failing that, maybe I could get a USB to serial converter and plug it into the RC aux serial port.
At this time there is no support to do this in our code on our serial ports. Sounds like a PITA.The problem with connecting the RC serial port directly to the GSXR diagnostic port is that the GSXR wants a 2000 ms hi, 25 ms low, 25 ms high sequence on TxData to initialize, and I don't think I can make this with the RC serial port. Is there some way to directly control the TxData line? This initialization is already taken care of by the HealTech gizmo.
Our Bluetooth module only works with tablets and computers as a client. it is not capable of being a host to another Bluetooth device.The Lua script page says it's OK to use the Bluetooth port, so maybe I can put a USB to Bluetooth converter on the HealTech gizmo and do it that way...
Go USB to serial and use the auxiliary port on the front of MK2 to read in and parse the data. Hands down the best approach of the above mentioned. Or see if there is a way to bypass that annoying serial requirement and go serial to serial directly.I'm going to order hardware for all these approaches, but would appreciate any ideas on the best direction to proceed.
Andrew Stiegmann (Stieg)
Principal Engineer
Autosport Labs Inc.
Principal Engineer
Autosport Labs Inc.
-
- Posts: 16
- Joined: Thu Apr 14, 2016 12:53 pm
- Location: Pattaya, Thailand
- Contact:
GSX-R1000 to HealTech to Serial Converter
That's exactly the feedback I needed. Thank you!
First approach will be (GSX-R1000 diagnostic port) to (HealTech gizmo to USB) to (USB to serial converter) to RC aux serial port.
-JJ
First approach will be (GSX-R1000 diagnostic port) to (HealTech gizmo to USB) to (USB to serial converter) to RC aux serial port.
-JJ
LudemannEngineering.com