Page 1 of 2

Measuring Coolant Temp

Posted: Mon Mar 11, 2013 10:31 am
by Grrrmachine
I'm trying to configure my data-logger to read actual coolant temp in degrees, but using the original brown temp sensor in the head.

I understand I need to know what the resistance of the brown sensor is at a given temp, but how do I work out what the temp of the coolant is? I can't just stick a thermometer in the coolant tank.

Any ideas?

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 10:35 am
by Karan
Take sensor out, stick in boiling water-100degC, then tell datalogger that resistance at that point equals 100

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 2:58 pm
by Grrrmachine
Trouble is knowing what temp the water is :D Most thermometers don't go to 100 degrees.

I'm going to have to rig up a saucepan with the brown temp sensor AND an oil temp sensor in, connected to a gauge, and do it that way. Pics to follow :D

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 2:59 pm
by Karan
Well the water will boil at 100..... I don't understand what u mean

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 3:48 pm
by Grrrmachine
Knowing when the sensor is at 100 degrees won't tell me what it reads at 60, 80 or 120 degrees. Considering the dash clocks only cover about 80-90 degrees, I need more points to measure the range.

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 3:48 pm
by capnmchl
Why not take it at a more sensible temperature then?

I don't know how a data-logger works, but surely it needs the difference in resistance for an interval of 1 degree rather than the resistance at an arbitrary temperature?

As long as it's a linear sensor, then taking the temperature at 20 degree and 40 degrees, and dividing the difference by 20 gives you the different in resistance for one degree, and adding (or subtracting) that from a base resistance at a known temperature can give you the resistance at any temperature?

Saves you burning yourself as well.

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 4:04 pm
by Grrrmachine
capnmchl wrote: As long as it's a linear sensor...
That's the key. Pretty much any thermistor is non-linear, especially automotive ones (considering the temps they work at). Otherwise I'd have done what you said yonks ago.

I've got all the readings for the blue temp sensor, so I'm going to stick them both in a saucepan and watch how their resistances change.

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 4:06 pm
by Karan
:mad:

I see what u mean now

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 4:44 pm
by Grrrmachine
This was the concept :D

Image

I just needed a gauge that read 50-120 rather than 60-170 :mad:

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 5:06 pm
by daimlerman
Grrrmachine wrote:This was the concept :D

Image

I just needed a gauge that read 50-120 rather than 60-170 :mad:
You either have a very understanding 'er indoors or are hung like a porn star!

I hope that you remove all oily paw marks from the kitchen....

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 5:18 pm
by Grrrmachine
daimlerman wrote:You either have a very understanding 'er indoors or are hung like a porn star!
I'll let you decide on that one winkeye

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 5:24 pm
by suedenim
Grrrmachine wrote:Trouble is knowing what temp the water is :D Most thermometers don't go to 100 degrees.
Try looking for a cooking thermometer rather than a weather one:

http://www.lakeland.co.uk/8776/Preservi ... tAod7SsASw

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 7:07 pm
by gromgsxr
Think if got a data sheet for the ecu blue sensor with resistance at diff temps if that will help

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 8:38 pm
by Grrrmachine
It's alright, I'm all sorted now. I had a coolant sensor table that turned out to be for the brown sensor, so that's all coded in now (it's a logarithmic formula) so that I'll have a really accurate temp gauge rather than just "above blue, below red".

At the moment the data logger will look like this:

Image

Just need to code the Tacho, Speedo and oil pressure now :D

Re: Measuring Coolant Temp

Posted: Mon Mar 11, 2013 10:25 pm
by gromgsxr
I'm using ms3 and shadow dash connected via blue tooth to ecu so dash is on a 7 inch tablet that has speed gear mpg afr water temp air temp ect its pretty cool, the speed signal is a 5v square wave with 9 pulse per rev if you take it after its been through the spedo custer

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 5:03 am
by Grrrmachine
That speed signal is very useful, thanks for that. How did you get it to detect the gears though?

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 8:59 am
by gromgsxr
the gear is calculated off road speed and engine speed, i put in the diff ratio and the ratios of the gears wheel diameter how many pulses per rev of wheel and my ecu works it out

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 1:03 pm
by Grrrmachine
That's sneaky! I like that!

This thing is a programmable unit, so once I've calibrated all my sensors I can do whatever I want with it, as long as I can work out the logic. But I'm using the original Motronic 1.3, so there won't be any actual modification of engine parameters; it'll be a glorified OBC effectively.

Have you got any idea how the econometer/ injector pulse is calculated? I need that for fuel rate/mpg calculations.

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 2:01 pm
by gromgsxr
i connected the fuel flow that would have come out of the stock motronic to one of my injectors switched earth from megasquirt im fully sequential so that would be 1 injection event per engine cycle 720 deg crank rotation, motronic is batch fire injection im assuming that it fires the both banks alternating eg 1,3,5 bank one then 2,4,6 bank 2 360 deg late, i believe its connected to one of the banks so still gives 1 injection event per cycle. my econometer agrees with what i get on the computer from the ecu within 2mpg.

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 2:47 pm
by gromgsxr
i believe tacho is a square wave as well on facelift cars, what is the logger/software you using out of curiosity?

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 4:35 pm
by Grrrmachine
It's not anything. The input/outboard board is called a Fusion Brain; it's got 15 analogue inputs and 31 digital outputs. I'm using the software that comes with it, which is based on C# in a .NET environment. I've got it running on a Windows laptop, and you can see the built-in screen in the link in my signature.

I need to build a few frequency-to-voltage converters to get some readings off speedo and tacho, then I'll examine the fuel rate. I've just tapped into the wires coming out of the cluster, so there's no interfering with the ECU.

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 4:41 pm
by Demlotcrew
Im pretty sure the OBC calculates MPG from injector duty cycles?

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 4:53 pm
by gromgsxr
ok thats pretty cool has everything got to be in an analogue form, say for speed 0v would = not moving and 5v = max speed say?

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 4:59 pm
by Demlotcrew
I would have to dig through all my documents, Just cant remember :(

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 5:20 pm
by gromgsxr
yeah id say so my obc fuel input is connected to a injector now

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 5:33 pm
by Grrrmachine
Completely depends how you write the code, but yes, it all depends on input voltage. This one works on 0-3.3V with 1024 bits resolution, so you can just write "input > 0 = ON" as a basic idea. Because it's 3.3V I have to use a load of voltage dividers to bring all the signals in line, but that's no big drama.

Andy, knowing how the OBC calculates MPG would be useful, cos at the moment I'm using the econometer signal rather than the injectors themselves so I have no idea what the ECU is outputting there.

Re: Measuring Coolant Temp

Posted: Tue Mar 12, 2013 6:43 pm
by Brianmoooore
OBC uses the pulse width and frequency of the injector feeds to calculate fuel used, then divides this by the road speed signal from the yellow (also available at the green) socket on the instrument cluster.

Re: Measuring Coolant Temp

Posted: Thu Mar 14, 2013 6:08 pm
by gromgsxr
Will you be doing anything with fuel level? Was playing with my obc today and realised it has how many liters are in tank, I would assume this it fed down from the clocks to the obc? Anyone have any info on this I assume it varies the resistance according to the fuel level?

Re: Measuring Coolant Temp

Posted: Thu Mar 14, 2013 6:24 pm
by Grrrmachine
Depending on which tank you have, resistance runs from 60 Ohms (55L) or 120 Ohms (63L) down to 0 Ohms.

It's a linear drop so there's no fancy formula to it. Again, I took a wire from the back of the clocks.

If you want to tap into the instrument wires, it's these ones:

Speedo- pin 26 of the yellow connector, or pin 1 of the green connector (brown/red of yellow plug to obc green plug)
fuel level- pin4 white plug (BR/GN) or pin 6 yellow plug (BR/GN) to pin 16 OBC
coolant temp- pin26 blue plug (BR/VI)
Tacho - pin7 blue plug (BK)
fuel rate - pin31 blue plug (YL/WT) or pin25 yellow plug (WT/BU)
Outside air temp - Pin 2 green plug on OBC (BU)

If you're using BMW's wiring diagrams, then:

blue plug - C1
white plug - C2
yellow plug - C3

Re: Measuring Coolant Temp

Posted: Thu Mar 14, 2013 6:32 pm
by gromgsxr
Il have to look in to this that's the only thing I can't log or see on my tuning software / display iv got a few spare inputs to play with

Re: Measuring Coolant Temp

Posted: Sat Mar 16, 2013 1:47 pm
by Grrrmachine
Got a problem :cry:

As soon as I plug in the wire coming from the Tacho, both the tacho gauge and econometer go dead. I've used pin 7 from the blue plug, going into a frequency-to-voltage converter. I guess the gauges don't like it.

Any ideas?

Re: Measuring Coolant Temp

Posted: Sat Mar 16, 2013 2:36 pm
by Brianmoooore
Use a transistor in an emitter follower arrangement as a buffer, or even simpler, just try including a resistor in the wire.

Re: Measuring Coolant Temp

Posted: Sat Mar 16, 2013 5:56 pm
by Grrrmachine
Thanks Brian, a simple 1k resistor sorted that out. I've also got volts coming through from the econometer now, but I need to run some live tests to make sure they're related to the movement of the eco needle.

I now need to sort out the speedo, but I'm not getting a signal out of the yellow plug, so I'll have to tap into the green one that feeds the cruise control... which has never worked. Hmmm.

Re: Measuring Coolant Temp

Posted: Sun Mar 17, 2013 12:46 pm
by Grrrmachine
You win some, you lose some.

I got my calculations wrong for the coolant and oil temp, so I'll have to start again on that one. I've managed to access the Tacho now, and that's sending out a steady linear signal too. Fuel gauge is accurate, and I've got raw voltages for the oil pressure and fuel rate that I can decipher later.

But I'm having a real problem with the speedo. Absolutely nothing coming out that I can detect with my frequency-to-voltage converters, and I don't have access to an oscilloscope. The speedo on the cluster works, and I'm getting continuity between the OBC plug pin (yellow plug on the cluster) and the green plug that feeds the cruise control, but no signal to my data logger.

As grom said, it should be chucking out a square wave - any idea what basic tools I can measure that with aside from an oscilloscope?

Re: Measuring Coolant Temp

Posted: Sun Mar 17, 2013 1:54 pm
by gromgsxr
Iv got a small digital storage scope so can scope stuff if you need.