tedsalmon / BlueBus

A Bluetooth module for vehicles equipped with I-Bus
Other
169 stars 41 forks source link

Oil Temp on 1.1.18 #104

Open dertimaushh opened 2 years ago

dertimaushh commented 2 years ago

Hi Ted,

Just did a highspeed run on the Autobahn. Water and Ambient Temp was displayed correctly.

But Oil readings were rubbish. 177 degrees celsius (!), next moment 235. Switched back and forth and then it showed 50-60 degrees celsius while doing >200km/h over 30km. Back in town it showed 205.

Any idea for this behavior? Or is this calculated value just pointless?

Besides that - 1.1.18 works great.

Back in love with my E38.

Best regards, Tim

tedsalmon commented 2 years ago

@dertimaushh

Yeah, you're not the only one to mention issues with the value. Off the hop, I can see that I forgot support for the LCMIV -- can you try this revision of the firmware? https://t3ddftw.s3.us-east-2.amazonaws.com/BlueBus/firmware/bluebus_1_1_18_1.hex

Thanks! -Ted

dertimaushh commented 2 years ago

Don't think this will solve it for me as I am not running an LCM4.

The sensor itself was replaced just 6 months ago.

Will do some reading with Inpa to check.

BR, Tim

piersholt commented 2 years ago

@dertimaushh can I confirm which light module you're running in your E38?

@tedsalmon do you believe this might just be the calculation? If it's to do with LM variants or cluster type, we might be at cross purposes.

CaptnO commented 2 years ago

I am running a LCM IIIb in my E38 and I seem to get valid values and wrong ones as well. There might be an issue with the calculation of the value, since as far as I remember it is calculated through two or three different sources.

dertimaushh commented 2 years ago

Looking at my production date - it's an LCM 3b aswell.

LCMs

CaptnO commented 2 years ago

I am not sure about that. The E38 never came with a LCM 3b when stock. That would explain why I had to add the C18 value to get it properly coded. The only difference to the LCM 3 I know is the automatic headlights feature. What does INPA say? It should tell you the exact module.

dertimaushh commented 2 years ago

Yes, ok will check the readings and Version with INPA.

tedsalmon commented 2 years ago

@piersholt @dertimaushh @CaptnO

I did fail to mention that I updated the calculation from what I ripped out of the guts of IBus App to what RichardP of the Intravee shared with me a couple years ago. I wish I could test, but I only have E46s :/

+            uint16_t offset = 310;
+            if (ibus->lmVariant == IBUS_LM_LCM_IV) {
+                offset = 510;
+            }
             // Oil Temp calculation
-            float rawTemperature = (pkt[23] * 0.01275) + (pkt[24] * 0.000050);
-            unsigned char oilTemperature = 1.0 * 67.2529 * log(rawTemperature) + 310.0;
+            float rawTemperature = pkt[23] * 0.00005 + pkt[24] * 0.01275;
+            unsigned char oilTemperature = 67 * log(rawTemperature) + offset;
piersholt commented 2 years ago

@dertimaushh @CaptnO

I'd recommend using INPA to determine the light module variant. The reason being, parameters such as coding index, hardware number etc aren't a reliable means of identifying the variant. I say this having reverse engineered BMW's variant identification system (which INPA uses).

The variant will be listed under Info (F1).

Screen Shot 2021-11-23 at 10 46 18 am

The E38 should have an early light module variant as the later light module variants included the CCM which is discrete in the E38. (Edit: I thought LME38 had a longer life, but it looks like LME38 was phased out in 1995!)

CaptnO commented 2 years ago

@piersholt I just mentioned having a LCM 3b, since I replaced mine to retrofit the automatic headlights feature :). I had a LM38 before, which is in fact a LCM 3.

I just want to add, that I realized that the oil temperature is set on 104°C on startup, which seems like a fictional value (or the last plausible when the car was running before). Once the engine reaches it's operating temperature, it seems to work (at least for me). There are times by the way, when the Bluebus doesn't show any value for the oil temperature. I wonder what that is.

piersholt commented 2 years ago

@CaptnO when I use the term variant, I'm referring to the diagnostic variant.

This is BMW parlance, but it's analogous to an API version. As the module is updated, be it software, hardware etc, the diagnostics interface is updated accordingly.

As a rule of thumb, each major module revision will likely have a corresponding diagnostic variant. In the case of the light module, the variants are:

LME38   : Konzept DS1;
LCM     : Konzept DS2 (integiertes SG Lichtmodul - Check-Control);
LCM_A   : Konzept DS2 (integiertes SG Lichtmodul - Check-Control);
LCM_II  : Konzept DS2 (integiertes SG Lichtmodul - Check-Control);
LCM_III : Konzept DS2 (integiertes SG Lichtmodul - Check-Control);
LCM_IV  : Konzept DS2 incl. LWR und Brake-Force-Display;
LSZ     : Konzept DS2 Lichtschaltzentrum E46;
LSZ_2   : Konzept DS2 Lichtschaltzentrum E46 PU 09/01;

I mention all this for for a couple of reasons.

Firstly, it's the diagnostic variant alone that determines how we communicate with the module. For example, with respect to diagnostics, there's no distinction between "LCM 3" and "LCM 3b".

Secondly, I'd err on the side of scepticism when it comes to information from BMW forums/websites. For example, I have an LM for which the diagnostic variant is LCM_III, but according to the aforementioned "Overview of the existing LCMs", it's an LCM 4.