ElectricMotorcycleForum.com

Makes And Models => Zero Motorcycles Forum | 2013+ => Topic started by: Larry295 on March 10, 2020, 03:29:07 AM

Title: SRF OBD connector
Post by: Larry295 on March 10, 2020, 03:29:07 AM
Does anybody know if the SRF has the possibility of connecting a bluetooth OBD2 adapter?
something like that:
https://www.amazon.com/OBDLink-Bluetooth-Professional-Grade-Diagnostic-Performance/dp/B07JFRFJG6?ref_=ast_sto_dp

In order to obtain similar data as this guy is getting from his Tesla:
https://www.youtube.com/watch?v=x7NJIkOirVE&t=219s

with an app similar to that one:
https://play.google.com/store/apps/details?id=com.emon.canbus.tesla

That would be so cool to be able to extract more data from the bike!
Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on March 12, 2020, 04:47:36 AM
So, the OBD-II port on a Zero is functional, but your standard automotive connector dongles will not work with it.

One main reason is that a lot of the pinouts are different, but a big issue is that there is no power to draw from to power a Bluetooth antenna on it, so whatever data logging or interactive programming you do must have its own power supply. The 12V off the DC-DC converter should be sufficient, but keep some circuit protection in there to avoid an issue.

Anyway, there's an extensive article on MBB console access using this port:
https://zeromanual.com/wiki/MBB_Console

There's also CANBus access, but decoding CANBus messages requires more development time, and no one's proved it out yet on an SR/F or SR/S.
Title: Re: SRF OBD connector
Post by: Auriga on March 12, 2020, 05:52:55 AM
So, the OBD-II port on a Zero is functional, but your standard automotive connector dongles will not work with it.

One main reason is that a lot of the pinouts are different, but a big issue is that there is no power to draw from to power a Bluetooth antenna on it, so whatever data logging or interactive programming you do must have its own power supply. The 12V off the DC-DC converter should be sufficient, but keep some circuit protection in there to avoid an issue.

Anyway, there's an extensive article on MBB console access using this port:
https://zeromanual.com/wiki/MBB_Console

There's also CANBus access, but decoding CANBus messages requires more development time, and no one's proved it out yet on an SR/F or SR/S.

This is no longer true for 2020 models. For EU regulations, they had to add an OBD compliant port that works with standard readers. There are now two OBD ports on 2020 non FST bikes. It also has 12V supplied where you expect it. The FST platform bikes have one port but it works just fine with readers :)
Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on March 12, 2020, 06:47:23 AM
So, the OBD-II port on a Zero is functional, but your standard automotive connector dongles will not work with it.

One main reason is that a lot of the pinouts are different, but a big issue is that there is no power to draw from to power a Bluetooth antenna on it, so whatever data logging or interactive programming you do must have its own power supply. The 12V off the DC-DC converter should be sufficient, but keep some circuit protection in there to avoid an issue.

Anyway, there's an extensive article on MBB console access using this port:
https://zeromanual.com/wiki/MBB_Console

There's also CANBus access, but decoding CANBus messages requires more development time, and no one's proved it out yet on an SR/F or SR/S.

This is no longer true for 2020 models. For EU regulations, they had to add an OBD compliant port that works with standard readers. There are now two OBD ports on 2020 non FST bikes. It also has 12V supplied where you expect it. The FST platform bikes have one port but it works just fine with readers :)
Prove it! Forum posts are cheap. Let’s see some evidence.
Title: Re: SRF OBD connector
Post by: Hans2183 on March 12, 2020, 01:58:25 PM
I have an SRF and a cheap bluetooth dongle... The port is in the tank. just never tried it because my daily phone is an iPhone. I'll try this evening if I can connect with it using an Android phone.
Title: Re: SRF OBD connector
Post by: Larry295 on March 13, 2020, 04:33:48 AM
That would be nice if it worked!!
I'd like to have some sort of an additional data on my dashboard (even if I had to buy a cheap android phone for it), indicating things like the battery charge, temperature, regen levels, instant power ect…
That would be a geek's dream ;)
Title: Re: SRF OBD connector
Post by: TheRan on March 13, 2020, 04:51:18 AM
The official app and the Metrics For Zero Motorcycles app can get you all of that data.
Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on March 13, 2020, 05:30:18 AM
No, it cannot get you "all of that data". I work with MBB logs, the MBB console, CANBus data, and the metrics app, and they are much deeper when parsed correctly.

Plus, the official app and metrics app only deal with numbers, not logical conditions and events for diagnostics.
Title: Re: SRF OBD connector
Post by: TheRan on March 13, 2020, 05:47:43 AM
I was talking about the data that Larry is after. Battery charge (SoC and voltage), temperature (motor, battery, and controller), regen amount, power output.
Title: Re: SRF OBD connector
Post by: Hans2183 on March 13, 2020, 04:07:58 PM
Metrics For Zero Motorcycles app doesn't work for the SR/F and SR/S right?
Title: Re: SRF OBD connector
Post by: Larry295 on March 13, 2020, 10:13:18 PM
The official app and the Metrics For Zero Motorcycles app can get you all of that data.

I am looking for data as per those in the video, and presented in the form of a dashboard with live updating as I ride around.
I don't think the Zero app would do that? Would it?
Title: Re: SRF OBD connector
Post by: Hans2183 on March 13, 2020, 10:38:17 PM
for SRF that information can only be retrieved by recording a single trip and then watching it back afterwards. So no live data, and you have to start and stop recording manually within the app. 
Title: Re: SRF OBD connector
Post by: TheRan on March 14, 2020, 02:22:30 AM
The official app and the Metrics For Zero Motorcycles app can get you all of that data.

I am looking for data as per those in the video, and presented in the form of a dashboard with live updating as I ride around.
I don't think the Zero app would do that? Would it?
The official app gives you some data. It might be different with the SR/F but for my DS you go to the settings tab (can be in demo mode if you don't want to connect to your bike right now), ride screen setup, then tap on one of the numbered panels to bring up a list of all the info you can choose to display there. You can then click on ride screen preview to see what it will look like, and if you're connected to your bike it will then show live data. I do believe that if you have the app open and connected it will also go to the ride screen automatically when you start moving.
Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on March 14, 2020, 03:05:22 AM
Metrics For Zero Motorcycles app doesn't work for the SR/F and SR/S right?

No one has confirmed a test of that app against the Gen3 motorcycles. I would presume that it doesn't work because the bluetooth data protocol is different, but it's possibly backwards-compatible.
Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on March 14, 2020, 03:10:54 AM
Let's be clear, here:

Zero's official app for Gen3 bikes doesn't accomplish what the OP asked for, and any solutions for Gen2 bikes are reasonably presumable not to work for Gen3.

The one caveat to this is the open source app developed to use the Gen3 cloud service, which focuses on a narrow amount of data, although it does log GPS coordinates. (Note that the GPS coordinates seem to be local on the bike to the cellular data unit, and are not logged by the MBB or emitted to the official app.)
Title: Re: SRF OBD connector
Post by: TheRan on March 14, 2020, 05:11:00 AM
I didn't watch the half hour video to see what data the guy was getting from his Tesla, I was just going by the data requirements that Larry specified in a later post. The official app and Metrics seem useful for seeing how the bike is performing, which I think might be what he's after. Getting data out through the OBD port seems like it would be more beneficial for diagnostics, seeing when a particular issue pops up and what might be causing it.
Title: Re: SRF OBD connector
Post by: Crissa on March 14, 2020, 08:18:37 AM
You can do neat things with OBD data like run sub-systems that react to the information, add additional gauges, etc.

-Crissa
Title: Re: SRF OBD connector
Post by: Hans2183 on March 14, 2020, 02:16:08 PM
Looks like it won’t work. Haven't used it on other ports so not completely sure but all I see is a red light. Even with the bike turned on. And nothing discovered in Bluetooth settings.

(https://i.ibb.co/vYBb5Gk/AAB90947-A7-C1-4978-9741-2-E206-BB96-F04.jpg) (https://ibb.co/JQdNL4H)
(https://i.ibb.co/Hr32JYf/80-C1-C4-E1-CADD-4108-83-CE-A9-F3-BB8-B2-EF6.jpg) (https://ibb.co/55w97vg)
(https://i.ibb.co/KLD6tyh/316-B8-DE7-61-B6-4-FA0-9586-A99-B8-D0-D7-F5-A.jpg) (https://ibb.co/VQxVFB9)
Title: Re: SRF OBD connector
Post by: togo on March 14, 2020, 08:40:41 PM
I have an SRF and a cheap bluetooth dongle... The port is in the tank. just never tried it because my daily phone is an iPhone. I'll try this evening if I can connect with it using an Android phone.

Does it even power up? Gen2 Zeros don't even connect the 12V power lines on the OBD-II connector.
Title: Re: SRF OBD connector
Post by: stevenh on March 15, 2020, 07:44:56 PM
My Scan Gauge powers up and connects, it shows voltage and that's about it (everything else is zero).  It shows no codes when I scan (expected).  This is on my SR/F.

Update: Took a quick ride today, and kept the Scan Gauge connected.  It correctly tracked RPM and MPH and distance on the trip mode.  As expected MPG is was infinite :)

Steve
Title: Re: SRF OBD connector
Post by: togo on March 17, 2020, 05:41:49 AM
> My Scan Gauge powers up and connects, it shows voltage ...

> ... It correctly tracked RPM and MPH and distance on the trip mode. 

Cool!

> As expected MPG is was infinite :)

Haha, I bet some OBD-II readers will have software that malfuntions from that!


Title: Re: SRF OBD connector
Post by: BrianTRice@gmail.com on April 14, 2020, 09:01:09 AM
My Scan Gauge powers up and connects, it shows voltage and that's about it (everything else is zero).  It shows no codes when I scan (expected).  This is on my SR/F.

Update: Took a quick ride today, and kept the Scan Gauge connected.  It correctly tracked RPM and MPH and distance on the trip mode.  As expected MPG is was infinite :)

Steve

Okay, motor speed, ground speed, and trip distance are nice to have. Did any other data come out of it?
Title: Re: SRF OBD connector
Post by: stevenh on April 23, 2020, 04:17:49 AM
No, but it did correctly show a fault code due to my 12v battery sucking.  This was after I attempted to update to version 17 firmware from 16.  I need to get the battery replaced before that's going to work.  I was also able to clear the check engine light using the scangauge.

Steve
Title: Re: SRF OBD connector
Post by: Hans2183 on April 24, 2020, 12:55:21 PM
@stevenh are you sure you cleared it with that OBD port? Cause these errors will clear themselvers after toggling key ignition 3 to 4 times (I think it's 3 but it's been a while). As long as the cause went away obviously. This winter I"ve been riding with the CEL on most of the time so I know.
Title: Re: SRF OBD connector
Post by: stevenh on April 25, 2020, 05:31:52 AM
@stevenh are you sure you cleared it with that OBD port? Cause these errors will clear themselvers after toggling key ignition 3 to 4 times (I think it's 3 but it's been a while). As long as the cause went away obviously. This winter I"ve been riding with the CEL on most of the time so I know.

Yes, I watched it clear with the bike powered up.

Steve
Title: Re: SRF OBD connector
Post by: DPsSRnSD on April 25, 2020, 06:49:20 AM
@stevenh are you sure you cleared it with that OBD port? Cause these errors will clear themselvers after toggling key ignition 3 to 4 times (I think it's 3 but it's been a while). As long as the cause went away obviously. This winter I"ve been riding with the CEL on most of the time so I know.

Yes, I watched it clear with the bike powered up.

Steve

Just to make things less clear, I've also seen the check engine light spontaneously go away when I was doing nothing more than playing with my tire pump.
Title: Re: SRF OBD connector
Post by: stevenh on April 25, 2020, 05:17:48 PM
@stevenh are you sure you cleared it with that OBD port? Cause these errors will clear themselvers after toggling key ignition 3 to 4 times (I think it's 3 but it's been a while). As long as the cause went away obviously. This winter I"ve been riding with the CEL on most of the time so I know.

Yes, I watched it clear with the bike powered up.

Steve

Just to make things less clear, I've also seen the check engine light spontaneously go away when I was doing nothing more than playing with my tire pump.

Good point, but the timing was pretty suspect.  Connected the scanner with the bike on, scanned, saw the code.  Hit clear codes (check engine light goes from on to off, and the scanned code is gone).  Seems like it worked...

Steve
Title: Re: SRF OBD connector
Post by: Hans2183 on May 08, 2022, 05:38:49 PM
Digging up this old topic as I realise I never got back to this. The problem was that that Chinese blue obd2 dongle wasn't properly copied and only supported limited subset. I've since then removed the board of it and just used the housing and the connector for an usb to ttl board so I could connect to the serial interface on the zero using proprietary pins. That is documented on the well known zero wiki.

I've also tested other dongles and some do work with standard obd commands. The data I retrieved that way was rather limited. Think of SOC (using SOH obd command) and non EV stuff like temps, ODO, vin...

Haven't found any way into can bus with these dongles. My zero is gone but if you want more info I would look into that serial communication or proper wired can adapters (non tested) instead.
Title: Re: SRF OBD connector
Post by: ms_smart on May 10, 2022, 01:25:17 PM
I am using a Raspberry PI Zero W with a small housing. The OBD2 port is connected with a simple USB cable (TTL converter). That works great to me. Since I am a shell script man this is what I did:

# Set Serial Line parameter
stty -F /dev/ttyUSB0 0:0:1002:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0
# Read line in background
tail -f /dev/ttyUSB0 >$LOG &
# send commands to line
echo >/dev/ttyUSB0
sleep 1
echo time >/dev/ttyUSB0
sleep 1
echo bms interface >/dev/ttyUSB0
sleep 2
echo performance >/dev/ttyUSB0
sleep 2
......
# stop writing to log file
pkill -P $$
# delete non-printable characters
strings $LOG >$FILE
# Do what you please with the log file $FILE (analyze, store params to mysql database, FTP to your server, ...)

I am sure it will be no rocket science to apply this logic to any script langue you prefer to work with. The Raspberry PI is permanently connected to OBD2 and USB and stores data to a mysql database. This way I learned a lot about the bike. I also tested a simple 2G hat to permanently connect the device to the internet, but learned, that the PI Zero with the additional hat draws too much power from the Zero USB port and malfunctions. For now I only store data in a local database and synchronize if connected with WIFI.

Title: Re: SRF OBD connector
Post by: RightRudder on May 18, 2022, 10:50:30 AM
Is this also true for other bikes 2020 and newer in the zero lineup or just the SRF?

[/quote]

This is no longer true for 2020 models. For EU regulations, they had to add an OBD compliant port that works with standard readers. There are now two OBD ports on 2020 non FST bikes. It also has 12V supplied where you expect it. The FST platform bikes have one port but it works just fine with readers :)
[/quote]