[Ovmsdev] TPMS Bug in ovms_server_v2.cpp?

Chris van der Meijden chris at arachnon.de
Mon Mar 9 04:31:37 HKT 2020


Hi Mark,
I merged the new code, compiled and it works like charm. No more TPMS
boxes for the VW e-Up within the app :-)
Thank you very much.
Greetinx
Chris

Am Freitag, den 06.03.2020, 14:47 +0100 schrieb Chris van der Meijden:
> Hi Mark,
> 
> thank you for your quick response.
> 
> I created an issue on github. I feel still a bit to unexperienced to
> start coding on the core elements of OVMS. 
> 
> Thank you for your help.
> 
> Regards
> 
> Chris
> 
> 
> Am Freitag, den 06.03.2020, 20:03 +0800 schrieb Mark Webb-Johnson:
> > Looks like an oversight. The spec says:
> > 
> > > Car TPMS message 0x57 “W”
> > > This message is sent <cartoserver> “C”, or <servertoapp> “s”, and
> > > transmits the last known TPMS values of the vehicle.
> > > <data> is comma-separated list of:
> > > front-right wheel pressure (psi)front-right wheel temperature
> > > (celcius)rear-right wheel pressure (psi)rear-right wheel
> > > temperature (celcius)front-left wheel pressure (psi)front-left
> > > wheel temperature (celcius)rear-left wheel pressure (psi)rear-
> > > left wheel temperature (celcius)Stale TPMS indicator (-1=none,
> > > 0=stale, >0 ok)
> > 
> > We can test the metrics to see if they are defined. If not, then
> > set stale to -1. Should just be another line in the server v2 code.
> > 
> > Can you create a github issue, and I will fix. Or make the fix
> > yourself and pull request?
> > 
> > Regards, Mark
> > 
> > > On 6 Mar 2020, at 6:31 PM, Chris van der Meijden <chris at arachnon.
> > > de> wrote:
> > > 
> > > Hi all,
> > > 
> > > as I can't find the CAN-ID's for TPMS for the VW e-Up at the
> > > moment, I
> > > thought I just disable the feature, so the app won't display the
> > > TPMS
> > > boxes unnecessarily.
> > > 
> > > In OVMS v2 this was possible by setting car_stale_tpms = -1 so
> > > the last
> > > number sent by the "W" message to the server was -1. With that -1
> > > the
> > > app will not display the TMPS boxes.
> > > 
> > > The code in ovms_server_v2.cpp for the message is now
> > > 
> > >   extram::ostringstream buffer;
> > >   buffer
> > >     << "MP-0 W"
> > >     << StandardMetrics.ms_v_tpms_fr_p->AsString("0",PSI)
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_fr_t->AsString("0")
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_rr_p->AsString("0",PSI)
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_rr_t->AsString("0")
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_fl_p->AsString("0",PSI)
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_fl_t->AsString("0")
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_rl_p->AsString("0",PSI)
> > >     << ","
> > >     << StandardMetrics.ms_v_tpms_rl_t->AsString("0")
> > >     << ((stale)?",0":",1")
> > >     ;
> > > 
> > >   Transmit(buffer.str().c_str());
> > > 
> > > and that gives no room for sending a -1 as far as I understand
> > > it.
> > > 
> > > Is this a bug, a feature, or am I missing something?
> > > 
> > > Thanx for help
> > > 
> > > Greetinx
> > > 
> > > Chris
> > > 
> > > _______________________________________________
> > > OvmsDev mailing list
> > > OvmsDev at lists.openvehicles.com
> > > http://lists.openvehicles.com/mailman/listinfo/ovmsdev
> > _______________________________________________
> > OvmsDev mailing list
> > OvmsDev at lists.openvehicles.com
> > http://lists.openvehicles.com/mailman/listinfo/ovmsdev
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.openvehicles.com
> http://lists.openvehicles.com/mailman/listinfo/ovmsdev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20200308/1a6e20d3/attachment.html>


More information about the OvmsDev mailing list