![]() | Home > Puma (Tdci) > Designing a digitally controlled heater system, help needed. |
![]() ![]() |
|
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
No problem with pen and paper but not easy to get simultaneous measurements and/or take measurements on your own while driving. I've not used the LM35 part, is it directly interchangeable with the DS18B20 or has it a different serial interface format? Good plan for the sensor location. I could place a thermocouple at that location and another at shoulder position in my next test run using the data logger so you can see the difference. I've now found all 8 thermocouples for my logger so can take quite a few simultaneous measurements. Let me know if you want me to set up a particular test configuration? I think you have previously answered one of dgardel's suggestions regarding fan speed control as a later addition. If you get your feedback control system tuned it should not cycle too much above and below the desired cab temperature. If you want a quick drop in temperature you would need to just open the windows for a few minutes. "You are never to old to learn something new" |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Any progress made?? "You are never to old to learn something new"
|
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Hi Mat,
Having gone to the trouble of replacing the valve to electrical control I'd definitely say you should introduce feedback control as the next stage. Don't worry that the valve is only needing to be opened a short duration as long as your PWM can be controlled in fine steps. You should be able to adjust that at least to 256 (1 byte) steps between fully closed to fully open. If you start with a low gain (I. E .don't change the PWM too much in each step to a small error) it will not go unstable. You can increase the gain until you get it reasonablly stable and not overshooting and under shooting too much. You could initially put the temperature sensor in the airflow close to the Matrix as that has a much faster response time to what you will measure in the cab in the position you have selected and then just set your control to obtain a constant hot air temperature. Ideally you should log the temperature readings in eeprom memory or some other storage that you can read back after a run to see the effect of a gain setting change or set up an independent data logger. Since my last post I did some tests of air temperature to various heater knob settings and found the response to a change in setting suprisingly fast but far from linear, it's much more sensitive at the valve more open end, oposite to your valve!. However, the tests did reveal that for any one valve position setting the temperature is highly dependent on engine revs particularly when the valve is more open. This supports the observations made that temperatures are hotter when motorway driving at higher revs. Basically what is happening is the water flow rate increases in the matrix at higher engine revs due to the water pump speed. This in-turn increases the overall heat (input to output pipe) of the heater matrix resulting in the mass air temperature rising. Clearly feedback control will compensate for this effect and make a big difference in the stability of the cab temperature. Maybe a second outer loop control with a sensor in the cab as well as in the direct matrix air flow output would provide very accurate and stable overall climate control but one step at a time. With the microcontroller you have all the power you will ever need to get the results you are seeking if you add a few more temperature sensors and maybe control the air fan speed as a final addition. ![]() |
||
![]() |
|
mata Member Since: 24 Jan 2014 Location: Manchester Posts: 153 ![]() ![]() ![]() |
Hi john, thanks for the info and for taking some more measurements. God to know you were experiencing the same variations with engine use and I like the theory that it’s based on water pump rpm.
I had considered, way back when, that I might need some temperature measurement further up the chain, initially considering a coolant temperature feed, however if the water pump rpm is the thing that’s causig it that won’t be all that helpful, and anyway like you’ve said the thermostat should be keeping that reasonably steady. Perhaps an air temp sensor closer to the matrix would be the way to go. I’ve seen people logging data using the arduino software Over the serial monitor so I’m hopeful I can do this too. I’ll get a couple of temp sensors and have one down the vent and one further in the cabin. I’m yet to find a tutorial for pid control using this so not sure how easy it’ll be for a novice to get working. Like you say though, I’ll get the matrix air temp under control first which should translate to a stable-ish cabin temp as long as windows are kept closed etc etc. That’ll be a good next step before getting into the second cabin temp sensor.... |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Hi Mat,
I do really think you are on the right page now. If you have a control loop that can pretty much hold a steady matrix air temperature you then have an option to introduce an outer control loop at a latter stage that adjusts the set point temperature of the inner matrix air temperature control loop. So for instance you would initially set the matrix temperature set point to the required cabin temperature. When that temperature is achieved or approached, a slower outer loop (larger time delay between correction commands) that would adjust the demanded (set point) temperature of the inner matrix temperature. In general you would expect initially the outer loop to be pushing the inner loop harder as the cabin has a large thermal mass to warm up (and to some extent to cool down). This means during a warming up condition the outer loop would push the matrix air temperature higher than the required cabin temperature until the cabin required temperature is approached. At this phase the outer loop would start to wind down the matrix temperature set point. In effect the outer loop does not need to ask for a specific matrix temperature it only needs to instruct a temperature shift 'up' or 'down'. Some differential gain with proportional gain in the outer loop to prevent overshoot may be the best control method here. As you are using a microcontroller you have the ability to design a non linear control algorithm that takes decisions when to change its control commands such as when a user changes the required cabin temperature setting. Your decision to initially attempt to maintain a steady matrix air temperature is sound and a good basis in the core of the control system. One point to not forget is that a matrix air temperature at a slow fan speed has much lower thermal energy compared to the same temperature at a high fan speed. In the winter with cold external temperature the cabin is loosing heat through the poor thermal insulation a defender provides. This means at lower fan speeds matrix air will need to be higher compared to high fan speeds to maintain the same cabin temperature . Hovever In reality this will be taken into account automatically with the double loop control system in operation. It's a great project you have embarked on and it's nice to keep pace and provide some suggestions. Cheers, John "You are never to old to learn something new" |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
How is progress on this project?
John "You are never to old to learn something new" |
||
![]() |
|
mata Member Since: 24 Jan 2014 Location: Manchester Posts: 153 ![]() ![]() ![]() |
Zero progress due to rear diff failure https://www.defender2.net/forum/topic65907.html
Hope to have the new one in this weekend but now works gone busy.... |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
That's a shame Mat, good luck with your Diff. With Spring coming early it may dampen your enthusiasm for the heater control system development. "You are never to old to learn something new"
|
||
![]() |
|
mata Member Since: 24 Jan 2014 Location: Manchester Posts: 153 ![]() ![]() ![]() |
New diff and half shafts in and driving brilliantly bit now works picked up I’ll have to put this heater control project on hold.
I’ve been using a ford solenoid valve and had read about non genuine copies failing but thought for the purposes of development one of these copies would last long enough while I experimented but I found just now it’s already started to leak and fail. Apparently the latest revision of the genuine ford part is a reliable part so I’ll be getting one of these for future testing. For now though it’s back to old twirly while I rely on the vehicle for work duties. Thanks John B4Lamb for your interest so far, if you fancy taking it on do get in touch. |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Hi Mat,
Glad to here you have sorted out your half shafts and diff. How many miles had it done and why do you think it failed? My Landy is in having a new Stripped FORD Engine fitted. I ordered it from M&D Engineering who were a lot cheaper than Turner Engineering? When you say a Ford solenoid valve, is that the one you bought for modulating with the PWM and driver for the heater matrix? I was hoping you would be able to progress to a finished prototype as I was going to try and compare it functionally and cost wise with a control system that uses the existing plastic water heater valve as Ive found it does fully close and fully open albeit it not that linear but that non linearity is removed with feedback control. The force required to turn tbe valve Infound is quite light and easily within the scope of a small stepper motor or servo motor. The Bowden cable that runs from the heater temperature knob would be disconnected from the heater valve and reused to turn a pot mounted up there near the bulkhead and that would be the user set point temperature control. It would be a parallel development and a bit clonky compared to your solenoid valve solution but it would not need to keep switching on and off as the control loop would adjust the valve opening position as required in an analog fashion. Cheers John "You are never to old to learn something new" |
||
![]() |
|
mata Member Since: 24 Jan 2014 Location: Manchester Posts: 153 ![]() ![]() ![]() |
It had done 140k, I’m not sure exactly what the bolt head sheared but two experts independently suggested it could have been overtightened from factory!
Re valve - yes, it’s a ford part used to control the flow to the heater matrix. Use in Fiesta, Ka and other models. |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
I guess you will never know for sure but its an unusual failure and quite expensive I would think?
Re the Valve, you would think something like that in volume production would be as reliable a hell. Did you manage to find out the pulse repetition rate that Ford uses in their heater controller? I know you have chosen 3 second intervals. Oddly a lot of the complaints of the standard land rover defender heater valve is that they leak water. The only good thing is they are easy to get to to replace and easy to spot the leak...... I've not had any trouble. They are in a pretty vulnerable exposed position and subject to accidental damage. Cheers, John "You are never to old to learn something new" |
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Oh yes I see what you mean, there is loads of those valves on ebay with a huge variation in price. So the cheap £10 ones are a false economy then? "You are never to old to learn something new"
|
||
![]() |
|
B4Lamb Member Since: 21 Mar 2015 Location: Abergavenny, Wales Posts: 233 ![]() ![]() ![]() |
Just for interest I have started to design an alternative, just as a means of comparison for cost and complexity. I find the proportional valve in the standard factory Defender TDCI usable in a control system. Tests show the valve is far from linear however with suitable feedback control and software algorithm the non linearity can be overcome. It seems a negative step to go back to analog control of the existing valve but it negates the need to replace the valve and or modify the hoses that connect to the pump.
The principles of control remain the same i.e. measure the temperature in the cab or direct from the heater matrix air flow, compare (subtract from) the user set value and then adjust the valve to reduce the error. Sample rate, proportional gain and more advanced feedback control such as integral and differential can be applied in the same way as the solenoid valve solution and therefore can be shared. The first part of my design was to come up with an actuator to replace the cable operated valve opening position. I chose to use the very popular 28BYJ-48 4 Pole stepper motor (dirt cheap on eBay). This motor has a built I gearbox but even with its gearing (2000 steps per rev approx. ) it had fairly limited torque. I tried this motor with conventional servo bell crank connections to the valve actuation lever to find friction was too high to overcome. I have now come up with a rack and pinion drive from the same motor that had at least 8 times the effective torque resulting in the need to use circa 4000 pulses from fully open to fully closed compared to 400 so a 10 fold increate in power. I'm using PIC controller technology but that is just a matter of choice as most programmable single chip processors would be more than adequate. I have two digital temperature sensors to measure the matrix air and the cab temperature and a simple analogue potentiometer to set the required cabin temperature. I have basic proportional feedback control working at the moment in the controller where I can easily change the gain and sampling rate for tuning in the car under test. I need some cold weather to test. Ill post some pictures next. "You are never to old to learn something new" |
||
![]() |
|
![]() ![]() |
|
All times are GMT |
< Previous Topic | Next Topic > |
Posting Rules
|
Site Copyright © 2006-2025 Futuranet Ltd & Martin Lewis
