Q&A Forum

Merge of KM Tronic ...
 
Notifications
Clear all

Merge of KM Tronic USB relay control and ebay USB relay control

7 Posts
3 Users
1 Reactions
633 Views
(@mx5master)
Posts: 5
Member
Topic starter
 

Hi friends, greetings from Australia. No, the toilets do not flush the other way. Yes our spiders, snakes and kangaroos will try to kill you if you visit. 

 

So I've just acquired the Yourdyno DAQ and have integrated it into my setup. I've setup a ebay 8 channel USB board to be able to control my external WB 02 sensor as well as my engine cooling fan (big 3phase thing that sits on a separate VFD that needs to be triggered).

 

I've gotten everything working using the ebay USB DLL plugin that has been developed, however the interface itself is super basic and doesnt allow hotkey configuration (IE using the xenselabs to create a shortcut to turn the fan on and off). Nor does the plugin allow the WB O2 controller to only be turned on when EGT > a certain temp OR engine RPM > 0, which is important to not have condensation hit the cold sensor and fracture it.

 

What I would love is to merge the KM Tronic plugin which has the ability to configure this logic / hotkeys into the "basic" ebay DLL which at the moment only allows for "on/off" functionality, and even this is not available in the tuning screen.

 

If anyone is workign on this currently, I'd be happy to assist, and if nobody is doing this, then I would love some programming assistance to merge teh two DLLs to enable the logic on the ebay boards.

 

The easy solution is just to buy a KMTronic board, but the ebya boards are ubiquitous and will probably be around much longer, and by performing this integration piece we can make this feature available for future users rather than just me solving the problem for myself by spending AUD$100.

 

Thoughts?

 
Posted : 04/01/2024 9:17 am
(@bigpermgarage)
Posts: 16
Member
 

We have done this.

https://yourdyno.com/community/pluginforum/plugin-usbrelay-ebay-board-with-auto-channel-support-2/

 

I cannot gurantee it on latest yourdyno version, from time to time we have to update things on our end too but if there are issues let us know we will try to update it. I havent had much time to use mine lately. 

 
Posted : 04/01/2024 12:54 pm
(@mx5master)
Posts: 5
Member
Topic starter
 

Hey mate,

 

This is awesome. Thank you very much for your efforts in doing this. I downloaded your updated DLL and configured my WB02 sensor to only heat during engine run (ie when RPM > 400). This will save me a lot of expensive O2 sensors.

 

In other news, I just blew up my 8 channel relay board due to what I think was interference from a VFD drive that is nearby (drives dyno fan). Anyone got suggestions on a replacement board that is a bit more reslient than the ebay / aliexpress specials? I guess I could try mounting it further away or in a steel case to cut down on EMF......

 
Posted : 05/01/2024 6:20 am
(@bigpermgarage)
Posts: 16
Member
 

@mx5master And thank you for giving me the idea to run my o2 controller through the relays! I hadn't thought of that yet and can see it being helpful. 

I'm not sure about the vfd you have vs the relay board but how did you run the load through the relay board? Is the switched load going through that little relay or are you using the little relays to properly switch a bigger relay for switching power? 

 

 

 
Posted : 05/01/2024 1:06 pm
(@mx5master)
Posts: 5
Member
Topic starter
 

@bigpermgarage My pleasure mate, when we all share we all learn and grow together.

I've got a Chinese aliexpress single to 3ph VFD, and it has a separate digital trigger for the relay. Basically there's 240v 50Hz single phase (Australia) going in via a thick cable on a 20A circut, and 3ph coming out the other side. The VFD is activated via a control circuit that just needs to be closed (it's designed for a toggle switch - the relay on the relay board is just basically a computer controlled switch). There is no way I could run the load of the massive 3 phase dyno cooling fan through that little relay.

 

Now......in other news.......

 

The VFD drive is kinda noisy (electrically speaking) and I kind of blew up my 8 channel relay board yesterday. It worked ok, not great and I was kinda disappointed in the general unreliability of the unit. After having a bunch of non-activations and other general rubbish behaviour followed by blowing it up and it no longer working correctly as a USB device, I kinda got the shits on with it. I'm not a very patient man, so instead of waiting a week to get another one, I decided to slap together something to replace it (See pic).

 

Basically I now have an Arduino Nano connected to a generic aliexpress 8 channel relay board. The Arduino is programmed to listen on it's virtual com port for activation commands, at which point it closes the relay contact to activate the big VFD. I then integrated this with the Xencelabs Quick keys that Joisten recommended (which I have been using and have been very happy with - it's stable even in a very electrically noisy environment, and the dial knob is great for steady state tuning). The way I got the mess to hang together is a bit slapped together, but it's stable and works. A working dyno makes me more money than a pretty but broken dyno. The way I was able to integrate it was to create a batch file (*.bat) which fires a powershell script with the following command:

 

powershell -WindowStyle Hidden "& ""C:\Users\hp\Desktop\relay1.ps1"""

 

The powershell script is as follows:

 

$port= new-Object System.IO.Ports.SerialPort COM9,9600,None,8,one
$port.open()
$port.WriteLine("a")

 

This code basically sends the command "a" to the arduino, which is programmed to toggle the dyno fans. I then configured the Xencelabs QuickKeys to "run program" on the .bat file, which means a click of the button turns the dyno fans off and on. Note due to the way most Arduino's work, they reset when you open the serial port, so to avoid turning off the relays inadvertently, it's important to ensure that there's no port.close() in any of the code. Windows then leaves the port open, which might upset some purists, but again, I care about things being working and reliable, not being clean and shiny.

 

About halfway through programming this I decided to complicate things a bit more, probably because I was a few beers in at this point. So I setup an input on the Arduino to take "Out2" from the Yourdyno controller to check for engine RPM as a precondition for activating the Wideband O2 (Spartan 3). The reason for doing this is sometimes I don't put the WB probe on the car, but when I do, I only want the probe heater to run when the engine is running, and not when it's off. This is to preserve sensor life - google Bosch sensor failures and OEM sensor heating strategies. It's scandalous how long AEM, Innovate and other WB02 controller manufacturers have gone with just the "power is on, full heater for 30 sec" strategy. This is why aftermarket WBO2 installs die every 6 months, and the same Bosch 4.9 sensor in an OEM installation lasts 10 years.

 

.......anyway the point was using the Arduino combined with the "out2 goes to 5v when RPM > 500" means my sensor is only heating when in an exhaust gas stream, and won't live in an exhaust gas stream unpowered (another big no-no).

 

The reason why I went with the Arduino approach is threefold:

 

Firstly, it gives me a base to create much more sophisticated control and management of external equipment than the relay board because it's stupidly easy to knock out a bit of code to sort out a problem rather than trying to engineer or electronically / physically solve a problem.

Secondly, it's much easier to troubleshoot, and MUCH more stable than the 8 channel board thingy. I can turn the VFD on and off on full load, run my Yourdyno eddy brake power supply up to 100% and have an oldschool ignition lead RPM pickup running nearby all at the same time and the Arduino is rock solid. No delay, no missed commands, no serial / USB drop out, so far it's been more solid than a sailor on shore leave. 

Thirdly, I had all the bits on hand from other projects, and I knew I could slap it together in a few hours ready for showing off to some friends and customers tomorrow, as opposed to waiting a week for another relay board only to have that fail.

 

I've got a few other ideas that I want to implement in the future:

  1. Cooling fan for the eddy brake that picks up a temp sensor and drives a couple of big 12v fans using PWM (ie variable fan speed based on temp)
  2. Integrating the Tunernerd knock sensor equipment with Yourdyno for logging of knock
  3. Setting up torque reading outbound from Yourdyno via canbus into the vehicle and designing an automated spark map tuner, similar to the way that autotune works for fuel maps in megasquirt / Link etc. The ability for the car to tune itself for fuel and spark (under the watchful eye of the tuner) would go a long way to getting a more precise tune, rather than the slow and imprecise feedback loop that is a human looking at each cell and adjusting 

Anyway, that's enough for now, if you've got any questions on the above, or want me to share the Arduino code I'm happy to help out.

  

 

 
Posted : 05/01/2024 2:24 pm
(@rizo15)
Posts: 5
Member
 

Posted by: @mx5master

Hi friends, greetings from Australia. No, the toilets do not flush the other way. Yes our spiders, snakes and kangaroos will try to kill you if you visit. 

 

So I've just acquired the Yourdyno DAQ and have integrated it into my setup. I've setup a ebay 8 channel USB board to be able to control my external WB 02 sensor as well as my engine cooling fan (big 3phase thing that sits on a separate VFD that needs to be triggered).

 

I've gotten everything working using the ebay USB DLL plugin that has been developed, however the interface itself is super basic and doesnt allow hotkey configuration (IE using the xenselabs to create a shortcut to turn the fan on and off). Nor does the plugin allow the WB O2 controller to only be turned on when EGT > a certain temp OR engine RPM > 0, which is important to not have condensation hit the cold sensor and fracture it.

 

What I would love is to merge the KM Tronic plugin which has the ability to configure this logic / hotkeys into the "basic" ebay DLL which at the moment only allows for "on/off" functionality, and even this is not available in the tuning screen.

 

If anyone is workign on this currently, I'd be happy to assist, and if nobody is doing this, then I would love some programming assistance to merge teh two DLLs to enable the logic on the ebay boards.

 

The easy solution is just to buy a KMTronic board, but the ebya boards are ubiquitous and will probably be around much longer, and by performing this integration piece we can make this feature available for future users rather than just me solving the problem for myself by spending AUD$100.

 

Thoughts?

That's an interesting project! Integrating the logic and hotkey functionality from the KMTronic plugin into the eBay USB DLL would make those affordable boards much more versatile. I'm not a programmer, but open-sourcing that merged DLL could benefit many users long-term. Have you considered reaching out to the DLL developer(s) or starting an open source collaboration? With some coding assistance, merging those capabilities seems feasible and valuable for the community. I'd be interested to hear others' thoughts as well.

 

 
Posted : 28/04/2024 11:50 am
(@mx5master)
Posts: 5
Member
Topic starter
 

@rizo15 Well. Things happened. See above. I decided to yeet the relay board which was kinda weak sauce for industrial applications and also kinda unsupported in that I can't see inside the DLL and can't really do anything with it.

The Arduino solution integrated with Yourdyno has been working well so far for a couple of months, and I can control exactly what happens and when. Also, the Arduino IDE and platform is super easy to code for, extremely well supported and when I blow up a Nano I buy another one from Aliexpress for $6.

Now writing some drivers or a python script to wrap a lot of this up and then create a plugin for Yourdyno for the less IT inclined to just "click and install" - that would be something worth doing.....

 
Posted : 28/04/2024 2:16 pm
Share:
Select your currency
EUR Euro
USD United States (US) dollar