Welcome to RVForums.com

  • Register now and join the discussion
  • Friendliest RV Community on the web
  • Modern site for PC's, Phones, Tablets - no 3rd party apps required
  • Ask questions, help others, review campgrounds
  • Get the most out of the RV Lifestyle
  • Invite everyone to RVForums.com and let's have fun
  • Commercial/Vendors welcome

myVehicle - CAN / OBDII integration

Welcome to RVForums.com

  • Register now and join the discussion
  • Modern secure site, no 3rd party apps required
  • Invite your friends and let's have fun
  • Commercial/Vendors welcome
  • Friendliest RV community on the web

DavidL

RVF VIP
Joined
May 8, 2021
Messages
210
Location
Metamora, MI
RV Year
2002
RV Make
Newmar
RV Model
MountainAire
RV Length
4370
Chassis
Spartan K2
Engine
Cummins 500hp
TOW/TOAD
Grand Cherokee
Fulltimer
No
Thought I would start a thread to discuss integrating engine / transmissions / CAN / RV-C / KIB data into RVs, Trucks and Boats.
So, as a preface, my background is from automotive. I was responsible for DaimlerChrysler's Service Strategy at a mid point of my career. During that time, I co-invented the first Wifi and then Bluetooth OBDII scan tool. Later, I worked on connecting Fiat/Chrysler vehicles to the internet (Uconnect Access program). Today, in "retirement" my personal company has created a full featured automation and media control system for homes, sports bars, restaurants and entertainment complexes.

So, with that background I have toyed with the idea to retie all of the above together in my RV to integrate all of the silly subsystems that don't integrate well together into an intuitive control system. This month finally found the time to start integrating powertrain data into the system. I have already integrated all of the media systems and for the HOOTS RV trip late this year, integrated the water systems together.

So, here's the plan: Plug a "VID" (Vehicle Interface Device) into the standard diagnostic connector. VID1 will be for all OBDII vehicles (post 1996 cars w/ gas motors). This connects to our software we call "VIC" (Vehicle Interface Controller). VIC currently runs on a Raspberry PI4. VIC software then communicates "MQTT" to our myServer 6 automation system that can run on the same Raspberry PI, or a separate one, or Windows, Linux or Mac OS. The MQTT data has the vehicle data that myServer 6 then creates server variables.

myServer 6 has a very capable user interface design tool we call "myDesigner 6". This is a drag and drop design tool for the non programmer to create custom user interfaces. So, the UI can be pretty much whatever you want. Far more customizable than any scan tool on the market.

So, I have discussed the above with several forum technically adept folks that have attempted same over the last few years. But those conversations just never matured. So, decided to prioritize, roll up the sleeves and Get Er Done. So, current status is we used an ELM inexpensive VID that connects USB (bluetooth and Wifi are also possible) to VIC running on our myServer 6 controller running on a Raspberry Pi. The VIC software talks to the ELM and polls the vehicle data buss. If data has changed, then VIC sends the changes to myServer to update variables. myServer then updates the user interface (and automation rules) to display the data in gauges, charts, button states, text, etc. As of last week, this is now all working very nicely! We can prioritize how often VIC polls VID for updates on a per data element (rpm fast, temperatures medium, fuel level slow) to optimize system performance. And since VIC only sends MQTT on a change, then myServer 6 isn't getting spammed with too much information so it can talk efficiently to all of the media, water systems, lighting, and other systems. All of this can be run locally in the RV (no requirement for Internet) or can also be connected to the Internet if you want (in a secure way).

Next steps: Design a cool "digital dashboard" user interface that looks nice. Once that is done, then I would feel it is time to show a video of how it all works.
We also just started to integrate J1939 vehicles into VID1 / VIC. Same ELM327 chips support J1939. Hopefully this will be working in a couple of weeks so I can use all of the above in my MountainAire (Cummins 500). My 2002 MountainAire also has older J1708 data which the ELM unfortunately does not support. So, that may force us to look at "VID2" which would have a different CAN protocol handling.

Once J1939 works, then next step would be to add "VID2" to support RV-C protocol. This would integrate with Silverleaf and other devices and systems to integrate existing slides, generators, fluid levels, inverters that are in newer higher end coaches.

VID3 would either support marine CAN protocols and possibly to support KIB protocol for RV subsystem integration (lighting etc) for RVs that have that technology. I have a Wakesurf Mastercraft boat that has lots of integration and control systems so this might be a personal priority.

Some of you have used "HomeAssistant" open source automation software. In parallel to the above, we have also created an integration between HA and myServer 6 so you can get the best of both ecosystems (like myServer's user interface capability).

So, I'll post some updates for those interested in this thread as the advancements are available. Feel free to post your ideas on what you would like the system to do and what your vehicle supports. If any of the technically adept would like to contribute (like KIB stuff), lets talk! I bought some KIB hardware to play with already. My RV doesn't have any KIB or RV-C.

Description for the non technical (most): See your RVs motor and transmission data (and any faults) on your own customizable dashboard you can view on your phone, tablet, windows, MAC computer (any modern device that has a browser like Chrome or Safari).
 
Way outside my skillset but I like the idea so I’ll watch and (try to) learn. Thanks for sharing all this. It also seems to have the potential to aid in coping with modern diesel emissions which, as you probably know, has plagued many of us and can effect anyone with a diesel coach built after 2010, whether by being stranded, requiring an otherwise unnecessary tow, costing thousands unnecessarily, etc. So…..watching. Thanks again.
 
Way outside my skillset but I like the idea so I’ll watch and (try to) learn. Thanks for sharing all this. It also seems to have the potential to aid in coping with modern diesel emissions which, as you probably know, has plagued many of us and can effect anyone with a diesel coach built after 2010, whether by being stranded, requiring an otherwise unnecessary tow, costing thousands unnecessarily, etc. So…..watching. Thanks again.
hey Rich W! Yes, this would very likely be able to be support with J1939 (our this weeks work). So, you would be able to see the SPN (a diesel version of a DTC "Diagnostic Trouble Code") and the English description so you know that there is an issue and what the type of issue is. myServer can be programmed to watch for this specific SPN and do "something"...could be to give you yet more information on what to do...could be an audio notification that "Time to mess with DEF again".

So, what would you like it to do to help you with diesel maintenance / repair?
I gotta say I am familiar that there are issues, but since my 2002 doesn't have DEF, haven't concentrated on the topic. So bring me up to date and what you think the gaps are to minimize issues or make it easier to address them when there are issues.
 
Well the first two items that come to mind that would be helpful, and that are missing from the four comercially available devices that I’ve tried (all under $600 - if you want to spend $3500 or more this isnt an issue), are DPF soot level expressed in % to know when to initiate preventative regens before being derated (given that it can go to 200% which is weird, and that this information is not readily available), and DEF system/pump/doser pressure which would tell you if you have a bad sensor or pump, because there are no DTCs (SPN/FMI/etc) to indicate one or the other. You just get between one and three of the typical dreaded DEF SPNs telling you the DEF tank is empty when it isn’t.

But this is already getting way down in the weeds for me because I don’t even really know what we are talking about in terms of user-interface/monitoring capability. These are just my chief complaints after dealing with emissions system component and sensor failures, and muddling through in my on-going trial and error effort. Each SPN has expanded data, trouble shooting, and repair routines attached, but of course they don’t appear on a dash display, or even most consumer code readers. The more you spend, the more info you can access.

Since I know so little about the tech end of all this, I really can’t provide a lot of useful information beyond the complaint level, but as a beta tester I do ok - I performed this function officially for OTR and in an ah-hoc capacity for Diesel Laptops. I know what I’d like to see and I know where the information can be found. Connecting that information with consumer-level diagnostics seems to be the missing link. The most useful data would be that which the owner/operator can use to head off and/or diagnose those issues which can be easily addressed by the non-mechanically inclined as a maintenance-level intervention, primarily to prevent stranding and towing, but also to head off expensive repairs, such as replacing a DPF that could have been saved.

If you think I can be of any assistance beyond the above feel free to contact me by PM, and we can swap email and phone info and go from there. If not I’ll just keep watching this thread and try to understand where its all going. Thanks again for your efforts here.
 
Following
 
Had some time to work on myVehicle...so we have OBDII working and this week got RV-C communications working. We need to add a J1939 Diesel vehicle database for powertrain support next.

Full data available gets sent on startup of the connection between vehicle, VID and VIC and then MQTT to myServer 6. After initial, only updates get sent to reduce the data traffic on the network. Works very responsively. I am seeing smooth throttle changes.

We had a hickup getting SeeLevel fluid sensing in RV-C...ends up it was a defective display gauge. Garett sent us a new one and instantly we have fluid level sensing.

This initiative will allow older RVs to use the very latest in electronics to upgrade their coach. Examples include replacing the error prone 4 level sensors with the 0-100% SeeLevel integrated into your phone, tablet or built in dash screen or SmartRemote or "SmartSwitch" (more on that in the near future). Just connect the VID to your Wifi network, and plug it into the RV-C connector on your RV device to put that subsystem online with myServer 6.

Awnings, Invertors, Generator control etc. are all possible.
 
Interesting idea overall tying everything together.

I’m guessing you are storing data for historical reference in a database?

If that hasn’t been finalized, and you are, would take a look at the overall DB layout if you want another set of eyes on it.

Did Oracle consulting for quite a few years along with DB design and implementation as well as tuning etc.
 
Interesting idea overall tying everything together.

I’m guessing you are storing data for historical reference in a database?

If that hasn’t been finalized, and you are, would take a look at the overall DB layout if you want another set of eyes on it.

Did Oracle consulting for quite a few years along with DB design and implementation as well as tuning etc.
Each of the data elements gets stored as a variable in memory. By default, those variables get rewritten with an update. On myServer shutdown, all values in memory get written to disk so states are maintained during a power cycle. Certainly it is also possible to insert them chronologically in the database but for most reasons, that isn't necessary. ie: do you really need to see how your foot went on / off the gas pedal a zillion times?

Now other data might have interest to see across time. The system exists to do this, but there isn't many common use cases. Anyone want to chime in? What data is useful to see trends? Battery voltage? Solar Array output voltage? (we have weather / cloud data too), Current use? MPG across time? MPG across location across time? (We have GPS too), Lights usage across time?
 
Each of the data elements gets stored as a variable in memory. By default, those variables get rewritten with an update. On myServer shutdown, all values in memory get written to disk so states are maintained during a power cycle. Certainly it is also possible to insert them chronologically in the database but for most reasons, that isn't necessary. ie: do you really need to see how your foot went on / off the gas pedal a zillion times?

Now other data might have interest to see across time. The system exists to do this, but there isn't many common use cases. Anyone want to chime in? What data is useful to see trends? Battery voltage? Solar Array output voltage? (we have weather / cloud data too), Current use? MPG across time? MPG across location across time? (We have GPS too), Lights usage across time?
This is very cool!
 

Latest resources

Back
Top