NefMoto

Technical => Reverse Engineering => Topic started by: Aardschok on April 25, 2020, 09:53:03 AM



Title: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 25, 2020, 09:53:03 AM
I've been working on this for quite a while now.. but I think it's now time to put this out to a wider audience.

It's basically a DIY touch motion.

Figured there might be some interest here :)

Due based: https://github.com/ABangingDonk/OpenHaldex (archived)
ESP32 based: https://github.com/ABangingDonk/OpenHaldex32 (archived)
Teensy 4.x based: https://github.com/ABangingDonk/OpenHaldexT4

Ordering form for boards: https://abangingdonk.github.io/

A quick demo:
https://youtu.be/rtE-rsQuckA


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: IamwhoIam on April 25, 2020, 12:17:08 PM
Nice work!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: eliotroyano on April 25, 2020, 01:18:13 PM
I've been working on this for quite a while now.. but I think it's now time to put this out to a wider audience.
It's basically a DIY touch motion.
https://github.com/ABangingDonk/OpenHaldex
Figured there might be some interest here :)
A quick demo:
https://youtu.be/rtE-rsQuckA

Impressive, great work!!!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 25, 2020, 02:15:47 PM
This is so sick!  Well done!

Is there any reason you went with a Duo and not an ESP? Built in WiFi, Bluetooth...


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 25, 2020, 02:20:40 PM
*I'd like to combine this with FISControl and rework it onto an ESP so I can have the buttons on cruise.  My FIS worked good on a Mega but IMO stock support with Bluetooth, WiFi and loads more processing power and RAM I'd rather an ESP!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Lechuga on April 25, 2020, 02:24:13 PM
Impressive!

Sent from my ANE-LX1 using Tapatalk



Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 25, 2020, 02:33:43 PM
Thanks for the kind words everyone

Due was selected as soon as I saw two CAN ports and an M3 core for £15.. didn't bother looking any further :)

Uno was just because it was cheap and available, anything with a CAN port will be able to do that job and should be a piece of cake to port

Yeah, always wanted to run FISblocks (hence having a controller up front) but haven't found time to explore that yet.. one day


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 25, 2020, 02:44:59 PM
ESPs are much smaller, way more features (every pin is an interrupt), etc.  I used to love Arduino's but have been blown away by these.

Having an ability to build your own EEPROM/not use the app and define using (say FIS control) would be next level.

I'll play with this when I'm "working from home" next week and see if I can port it across and then go from there.

Awesome work man, this will go places!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 25, 2020, 02:59:35 PM
ESP sounds interesting, will pick one up and have a poke at it

Agreed, FISblocks integration is the next step

Looking forward to hearing how you get on


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: NBR on April 26, 2020, 07:43:37 AM
Awesome work, very well done! Which haldex versions have you tested this on so far?


Title: Re: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 26, 2020, 11:22:30 AM
Awesome work, very well done! Which haldex versions have you tested this on so far?
Thanks!

Only gen1, I have no idea what it would take to support more... Could be very similar but could also be very different.. would need to sniff the CAN and read through FR for newer models


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: fknbrkn on April 26, 2020, 01:04:09 PM
Nodemcu would be better for that
If I understand correctly,  the aim is to change some can messages
If it's related to ecu msgs only, we probably could do that in ecu software wo any hw


Title: Re: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 26, 2020, 01:11:51 PM
Nodemcu would be better for that
If I understand correctly,  the aim is to change some can messages
If it's related to ecu msgs only, we probably could do that in ecu software wo any hw
I wish it were that simple, inputs from the ECU will only get you half way.. the ABS is also on the bus, transmitting wheel speed sensor readings which also need to be tweaked


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: yxx499 on April 27, 2020, 01:37:30 AM
Impressive work !


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 27, 2020, 12:41:07 PM
I'm going to be dumb and ask it anyway, but why do we need an inteceptor and then a master?

Would you not just want to have the inteceptor?  Read CAN, if not stock, don't repeat and adjust, if stock, repeat message?  I've probably had too many beers.


Title: Re: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 27, 2020, 01:36:13 PM

I'm going to be dumb and ask it anyway, but why do we need an inteceptor and then a master?

Would you not just want to have the inteceptor?  Read CAN, if not stock, don't repeat and adjust, if stock, repeat message?  I've probably had too many beers.

No, that's a perfectly reasonable question to ask :)

The master exists because I wanted to make FISblocks integration as simple as possible further down the line.

It also means that the interceptor has more time available to forward messages.. there is a lot of traffic and it doesn't take much for controllers to start getting upset. Printing to serial is particularly expensive in terms of CPU time1.. there is a possibility that the interceptor simply doesn't have enough time to do it all.

That being said, I reckon the Haldex doesn't actually need all of the messages on the bus to be forwarded, I would like to try removing each one in turn to see what happens

(1) Edit: At least when I'm printing debug information.. I would have to do some profiling


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 27, 2020, 11:40:43 PM
IMO FISBlocks is quite slow.  Updating the display is slow as is connecting to the ECU.  What benefit/or what were you planning on adding to FISblocks?  Ability to select what mode you'd like?

I was planning on porting my FISCuntrol (largely based on Blocks) over to ESP purely for speed and larger memory.  I added quite a few features to Blocks and it killed an Uno quickly.  Put onto a Mega was fine but I can imagine the limits will be found soon.

As an FYI, ESPs are dual core and tasks can be run on them:
https://circuitdigest.com/microcontroller-projects/esp32-dual-core-programming-using-arduino-ide

I'm not sure how willing you'd be to re-work the whole thing in to one module though!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 28, 2020, 01:29:39 PM
Yep, fair enough, I can see the ESP working quite well as a replacement for the master.. but the Due's shoes are harder to fill, with ESP32's solo CAN port being the biggest and most obvious problem.

Maybe something like this for a pi..

https://www.elektor.com/pican-2-duo-can-bus-board-for-raspberry-pi

But that expansion board alone costs more than all bits of the existing system combined!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: d3irb on April 28, 2020, 05:01:09 PM
ESP32 also has SPI, so you could use an off the shelf MCP2515 (or two!) in addition to the onboard CAN. Breakout boards for this are really inexpensive - like $3-4USD. Anyway I think you have done well and do not want to question what works - but just some ideas. On the same token those PiCAN boards work well but are an absolute ripoff from a pricing point of view - just like with the ESP32 you can also wire some of the $3 SPI CAN boards into the Pi.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on April 28, 2020, 11:25:09 PM
ESP32 also has SPI, so you could use an off the shelf MCP2515 (or two!)

Yeah, that's what I was meaning.  You don't need to be tied to using a board with built-in CAN when there are modules that do it for you.  I'm going to grab my spare FIS cluster this weekend and port my FISCuntrol over to ESP too.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 29, 2020, 01:33:40 AM
Ohhh I see, of course.. sorry, beginning to see the light now :D

Parts ordered, thanks for the valuable input


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: terok on April 29, 2020, 04:11:00 AM
Teensy 3.6 has dual CAN, is cheap and quite speedy also. Transceiver and bt needs add-ons though, but are also cheap.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: SAgti on July 01, 2020, 08:13:48 AM
This is fantastic - awesome work, well flipping done!

I will be needing one of these for my 3.2T project. I was looking at the HPA - but yeah it is very $$$.



Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on January 13, 2021, 04:25:34 AM
Did this gain any further traction? :)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on January 13, 2021, 05:40:05 AM
Traction :D

Not really... I got my ESP32 to talk to itself via two MCP2515s and found the likely cause for slow CAN - the MCP2515 library I was using looks to be pretty inefficient and I intend to improve it.

Lost a lot of my work to a hard drive failure though and never found the motivation to pick this up again :(

I will come back to this at some point... hopefully sooner rather than later


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on January 13, 2021, 08:22:23 AM
I'm hopefully close to firing up my VR6t shortly and then once painting the shell is done it'll be ready for the road, COVID depending.  I started to port the FIScontrol library into the ESP but lost interest because I had a VR to build!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Cadensdad14 on January 26, 2021, 07:03:04 PM
I figured Id offer my support.  Im working on integrating a M4 based system into my car.  Im prototyping with the adafruit M4 Grand Central but would like to go to one of the chips with integrated CAN once i have a working model.  But this is awesome and I really appreciate it.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: sherpagoodness on November 17, 2021, 02:13:09 PM
Does somebody have one of these already put together that theyd be willing to sell?


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on April 29, 2022, 09:10:52 AM
So I finally picked this up again and am fighting my way through dual core FreeRTOS fun on the ESP32.

My boards arrived but the headers for slotting the ESP32 dev board into are a mirror image of what they should be... lesson learned: don't order PCBs at 7am having spent all night designing them  ::)

Going to order more boards after spending time to review the revised design.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on May 03, 2022, 12:19:40 AM
Can I buy a board please?


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on May 04, 2022, 09:23:44 AM
Can I buy a board please?

Don't worry, I'll be making these available when I've got something that works :)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: prj on May 05, 2022, 03:36:09 AM
Btw, not to ninja anything, but this has been available for a while, and it works:
https://www.ecumaster.com/products/haldex-controller/ (https://www.ecumaster.com/products/haldex-controller/)
It's around 300 EUR retail price and allows to use haldex without ABS at all.

Of course this replaces the whole haldex controller, which can be handy as these controllers die sometimes...
The downside is, you don't have any torque based control. They made an analog input for VSS, but they could have also made an analog input for pedal and done a 3d map pedal vs vss...

This solution here has the potential to cost 1/10th of that and it is essentially a piggyback, so a bit different.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: GTB2260VK on August 25, 2022, 06:51:52 AM
Don't worry, I'll be making these available when I've got something that works :)

anything new to get this project started myself :-D


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: wachu on October 09, 2022, 01:12:31 PM
Hello,
I wanted to ask if this project is still alive. I've saw on your github that you are attempting to run it on ESP32.

If there is anything that i can help with, just let me know. I am not really into C++/Java but i can participate in tests with my vehicles or donate this project just to see it alive :)


Regards!


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Riddler92 on October 12, 2022, 10:57:11 PM
Hello, I am also in the process of testing the OpenHaldex.
I have now ordered all the parts I need. But I would prefer it if I could do it without a master and only with buttons.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: hiszpan995 on December 14, 2022, 02:31:41 AM
I followed the thread on GitHub, but I admit that I don't understand it very well and I don't think I'm up to it. It's enough for me to force Haldex to work with one button, and after turning it off, it returned to its natural work. Can you simplify it then?


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on December 14, 2022, 04:23:59 AM
Jam 12v up the pump.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: prj on December 14, 2022, 06:04:20 AM
Jam 12v up the pump.
This is not very good for the pump though, it's not meant to be used like that and will fail much quicker than normal.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: hiszpan995 on December 14, 2022, 06:42:03 AM
Jam 12v up the pump.

and that's enough? I had the impression that the pump was running all the time to maintain pressure in the system. Regardless of the operation of the stepper motor


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: mdz on December 14, 2022, 12:26:33 PM
No, pump is not running all the time and it just supplies hydraulic pressure to the system when it is needed. Stepper motor engages clutch by moving pin/piston.
I've seen control unit being replaced by mechanical valve opening and closing hydraulic circuit normally operated by stepper motor. There was a string routed inside the car to open the valve. Not sure about how the pump was powered but all this ended up with burnt clutch as it is not meant to work all the time.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: terok on December 15, 2022, 11:49:24 AM
To be exact, electric pump only generates pre-supply pressure, which return flow is then restricted by the stepper motor controlled pin. Clutch pressure is made by the mechanical piston pump when there is speed difference between axles.

But yeah, driving the pre-pump continuosly from 12V is not wise.
Also oil needs much more cooling if used in rally/race/whatever, maybe more oil capacity would be enough. Same goes to newer generations too.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: Aardschok on December 16, 2022, 04:55:57 PM
Hi, long time no update... sorry, ESP32 woes put me off for a long time.. plus life has been getting in the way.

Good news though, I ported the project to Teensy 4.x and it's working nicely

Boards arrived this morning and I've been out for testing.. results are excellent

I've got 5 boards to sell at cost ($20 + postage) without Teensy, PM if interested

New repo:
https://github.com/ABangingDonk/OpenHaldexT4

Edit: all boards sold, will order another batch


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on December 19, 2022, 05:34:27 AM
Bought a board. :)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on December 22, 2022, 07:23:59 AM
Board has arrived, Teensy on it's way.  Mocked up a box for it, will print it tonight.

Tempted with a separate Bluetooth module/screen that can be mounted somewhere.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: jesusxd00 on February 22, 2023, 11:29:41 AM
Bought one board! And Teensy 4.0 with headers its on its way.

In my case, OpenHaldex will be used in Slalom competitions.

You can be updated in instagram @soriano.racing

(https://imgur.com/a/EnCzpjA)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: SAMI974 on July 14, 2023, 02:53:19 AM
HELLO i havr interssed fr this
it's is already actual

ps SOrrry for my porr inglish


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on October 11, 2023, 12:21:59 PM
Used the GitHub for reference but designed a few boards with buttons an a RGB LED for clarity.

Tweaked the code slightly and currently building a display with a ESP32 instead of using the app.


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on October 20, 2023, 01:49:46 PM
PCB for a screen that'll mount in a mk4 ash tray (with an airlift controller already there.)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on October 29, 2023, 01:40:13 PM
Yup, can confirm this works.  Couldn't get FWD to work with zero'ing out the buffer to the Haldex, so did some hackery to force all addresses to zero instead. 

Got 4 spare PCBs sitting and will be ordering the screen parts tomorrow.  Got a 3D printed enclosure which keeps it all together; looks OEM! :)


Title: Re: OpenHaldex - HPA touchmotion.. but cheaper
Post by: adam- on November 02, 2023, 01:22:08 AM
3D printed enclosure finalised.  I've ordered up remote screens and PCBs too; should be with me in a few weeks.  Not sure how many PCBs ABangingDonk has, I've also got 4 spare. :)