Webasto PTC Heater Programming Help / Arduino Teensy

Buy and sell
Post Reply
jsimonkeller
Posts: 60
Joined: Sun Oct 30, 2022 2:21 am
Has thanked: 2 times
Been thanked: 5 times

Webasto PTC Heater Programming Help / Arduino Teensy

Post by jsimonkeller »

Hello all. Johan suggested I start this post in case someone out there can help me out with an immediate need.

I am implementing the Webasto HVH50 into my Porsche 911 EV build. I had been using an older PTC heater running off PWM, but that heater takes up too much space and stopped working and the Webasto fits nicely under the hood as an upgrade. Unfortunately, the Webasto HVH heaters are mostly run off LIN. Finding a PWM version has proven difficult, so I have given up on that route.

Johan secured an HVH50 and worked out the LIN communication on the unit he secured and implemented the code into the Volvo branch of his OI programming.
johu wrote: Tue Apr 20, 2021 6:34 pm - Only 12V and LIN needs to be connected, interlock needn't be connected to anything.
- Byte 0 sets the power with a scaling factor of 40
- Byte 1 set the temperature setpoint in °C with an offset of 40
- Byte 2 is unused
- Byte 3 =8 heater on (i.e. bit 3 set)
Here is the link to that forum:

viewtopic.php?f=9&p=26692#p26692

and the links to the programming:

https://github.com/jsphuebner/stm32-car ... ar.cpp#L95
https://github.com/jsphuebner/libopenin ... linbus.cpp

Additionally, there a wiki page on this heater with a lot of the same info:

https://openinverter.org/wiki/Webasto_HVH50

At Johan's suggestion, I have purchased the Teensy 4.0 CAN FD and LIN-Bus Board with Teensy 4.0 installed.

HERE IS MY NEED:

I would like to implement the LIN programming into the TEENSY controller such that when I push the heater button in my car that turns on the 12V power to the WEBASTO and TEENSY, the heater will kick in and heat the coolant. I DO NOT NEED TO CONTROL THE TEMP. I just need it to kick on and it will heat to the maximum allowable heat until turned off. I also do NOT need any feedback for gauges or controls. This controller will NOT be a part of the CAN Network on the car that controls the gauges and inverter and BMS. It will be standalone and solely function to provide the messages to the heater to engage in heating the coolant. This heater is on a separate coolant loop from the rest of the car's cooling systems. It is truly standalone.

I am happy to compensate someone for their time, but would really like to jump on this quickly, as it is just kicking into winter for me and I would like to be able to use the car in the coming month when things get nasty outside.

I am competent with computers and electronics and can assist you with the feedback you might need to complete this project. I just am not competent with the programming part of this. I am trying to educate myself, but by the time I do, it will be summer :)

Any takers?
User avatar
uhi22
Posts: 618
Joined: Mon Mar 14, 2022 3:20 pm
Location: Ingolstadt/Germany
Has thanked: 93 times
Been thanked: 418 times

Re: Webasto PTC Heater Programming Help / Arduino Teensy

Post by uhi22 »

I do not know the Teensy. Since you do not need any connectivity besides the LIN, a simple Arduino nano would do the job. There is a LIN master library available. You only need to send static data, so no complicated software. Believe me, Arduino programming is easy, just give a try, you will learn and benefit for future little projects.
jsimonkeller
Posts: 60
Joined: Sun Oct 30, 2022 2:21 am
Has thanked: 2 times
Been thanked: 5 times

Re: Webasto PTC Heater Programming Help / Arduino Teensy

Post by jsimonkeller »

I really appreciate that encouragement and I get it. Since 2018 I have educated myself in many different things to build a EV from scratch and connect all of the systems and troubleshoot equipment not meant for this purpose and those thousands of hours were invaluable learning.

However, on this project I really would love some assistance from someone comfortable in Arduino and I will learn by reverse engineering their work to help jump start my learning on my next programming project.

So . . . if anyone out there is interested in helping, I can venmo you for your time. I have all of the pieces of the puzzle, but I am just not sure how to put them all together and I just do not have the time to work it all out on my own right now.

Thanks, in advance, for anyone out there in a position to assist.

The below attachment is an example file I was directed to in the Teensy Forums to show the programming for sending/writing code for an RGB signal.
APGRD004_TYPICAL_COMMAND_FRAMES.ino
(1.32 KiB) Downloaded 22 times
Converting Johan's STM32 programming into this format just involves more than I understand. I know that 0x55 plays into this code, but just not sure where.
espriev
Posts: 44
Joined: Mon Jan 02, 2023 5:32 pm

Re: Webasto PTC Heater Programming Help / Arduino Teensy

Post by espriev »

I am in my own boat, sailing on the same sea...
Part of the problem is the code on github is snippets of lots of other stuff for stm32.
I think it needs instructions and library files to work, but how this relates ? Try asking someone who knows and you are likely to get an answer that you must already know to be able to understand!
There is arduino code for older Webasto here: https://ev-olution.yolasite.com/DIY.php
I am working on getting it running on an UNO, and comparing with the stm code but part of the problem is LIN seems to want a slave response sent to the master to initiate an instruction, so in order to test you need a full set-up (heater, pump, hoses, water & tank, HV & LV DC, scope, meter...) takes a lot of room!
If I figure it out I'll share
jsimonkeller
Posts: 60
Joined: Sun Oct 30, 2022 2:21 am
Has thanked: 2 times
Been thanked: 5 times

Re: Webasto PTC Heater Programming Help / Arduino Teensy

Post by jsimonkeller »

Thank you for the encouraging words and link.

I have made some headway with the help of royhen99.

Check out this link to the forum: viewtopic.php?p=66903#p66903
Post Reply