Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Controlling diesel engine with homebrew circuitry

Status
Not open for further replies.

parkland

New Member
Sooooo...
I am trying to get ideas for this personal project, I don't know exactly what it would entail, but I know it would be a large undertaking.
I wanted to get some opinions on how this could be done.
I will detail as much as possible, for those who might be unfamiliar, and also to show the extent of my knowledge also.

The idea/project, is to design an electronics module that will drive modern piezo injectors on a diesel engine.
There are a few different systems used by vehicle manufacturers, and even a few after market ones showing up.
Why not buy one?
I have a vision. My vision is to program the vehicle using an actual programming language, rather than software to map fuel tables, etc.
In other words, I want to run a truck on qbasic.
haha. ( and the ability to use and processor / programming language. )

So, in my head I have the project in 2 parts. (Or 2 sets of processing/ electronics.)
1. A module that runs at high speed, and does nothing but decipher timing signals and run injectors. I imagine this would be some types of RISC processors with PWM generators, and power amplifiers.
2. A module that runs at a much less reliable speed, and does absolutely everything else. This would be the one running the actual code. It would plug into the vehicles harness, and read all the temperature sensors, air flow sensors, talk to transmission controller, etc.

What I'm really interested in talking about, is module "1", the high speed timing / injector driver hardware.

Basically, it would be connected to 2 hall effect sensors; one is on the camshaft of the engine, and the system would need to count pulses to determine the engines position. There is an extra pulse I believe to get an absolute position on the wheel.
The 2nd hall effect sensor is on the crankshaft, and is just used to increase accuracy, I believe.

So this unit would need to read those 2 signals and determine what position the rotation is in, and also have some type of timer, so that it can calculate RPM.

Also, this module, would drive the injectors.
They are driven by PWM signals, up to around 80 volts I think, so a max of 100 anyways.
They are not just single pulses though, they are multiple pulses, up to 5 per injection.
So there needs to be some type of very fast PWM generator IC's there.
( and from the IC's, power amps?)
 
...

To clarify, the unit I'm talking about, would read 2 hall effect sensors, and drive 6 - 8 injectors, and also talk to the main unit over something simple like serial.
Let's call this the injector driver assembly. (IDM)
Let's call the other (main) unit the PCM (powertrain control module)
This is pretty much what it is in standard format from car companies haha.

So the IDM will know when to inject the fuel. It will have the hardware to inject the fuel, but thats it. ( yeah right, "thats it", huge project).

The PCM, will send over serial, little pieces of data to the IDM.
The pieces of data will include volume of fuel, etc.
Also, a good idea would be that if the communication fails for more than a second or so, the IDM would just turn itself off.


How do PWM chips work exactly?
I remember a few months ago thinking about this, and thinking of tiny chips that play back a sound from memory on the chip. I remember thinking...

"What I need is a chip like that for each injector, so when it's triggered to inject, it would play back it's sound (or injector driving PWM data), and drive the amplifier, driving the injector. "
Of course it would need to run at a much higher frequency than a chip meant for sound or music playing, but is similar technology possibly viable for this?



If the IDM was configured to not even adjust timing or anything, but just determine engine position, each injector driver circuit could have the above idea imlemented, and an amp, and the timing could just be changed by changing the data that gets "played back".
I will try to explain that better.
Let's think "like" the IDM for a second, controlling a single injector.

-We just got a signal from the hall sensor on the cam, this is the exhaust stroke.
-OK, another hall cam signal, this will be an injection, wait...
-Now signal detected from crankshaft, time to start injection data.
-Start playing PWM data from memory chip, voltages go to amplifier, and drive injector.

And the data on that chip, would be sent from the PCM, so the IDM could be a fairly dumb machine.
From the seat of the PCM,

-keep sending data over the serial to the IDM : "RPM", and it would send a number back.
-Then, we would send it injection pattern data constantly as the fuel demand changes.

I don't know the exact speed or bitrate etc that this might be, but for simplicity sakes, lets pretend that 30 degrees before top dead center, to 30 degrees after, is represented by something like this:
"0000000000000000000000000000000000000000000011111 000000000000"

So when you send a serial message to the IDM, it would be something like:
"inject=000000000000000000000000000000000000000000 0011111000000000000"
And that would be the data that the IDM "plays" to generate the PWM signals to the amplifiers, and then to the injectors.

So lets's pretend some more, rpm's are 2000, and throttle position is at 0 ( foot off gas pedal), the PCM would send this to the IDM:
"inject=000000000000000000000000000000000000000000 0000000000000000000"

Then when the engine slowed down, the PCM would configure the injection pattern for idling, something like this:
"inject=000000000000110000011000001100000110000001 1000000000000000000"
( That is 5 little shots of fuel.)

Harder fueling might look like this:
"inject=000000111111000111111000111111111000001111 1100000111111000000"

And really hard fueling might not have enough time for 5 injections any more, so it could be 4 injections, 3, 2, 1, whatever.

The point is that the PCM can generate the injection pulse timing in with the injecion pattern, and the IDM will just keep putting out the signals it's told to, at the right time.
 
So thats what I'm really interested in as far as opinions, the IDM module.
A design that could accomplish the above theory, would allow a pile of possible processors to run the actual truck, but take a huge burden off of any such project.
It would create an easy platform for getting started.

The PCM would connect to the IDM via serial, or something similar and simple.
The PCM would connect to the truck through a connector pin-out coupler, and it would do things like adjust turbocharger position servo, change fuel rail pressures, etc etc, things that do not require the speed and accuracy of the injection system.

I'm thinking the PCM could be a processor board like a rasberri pi, or maybe an android style box, with a USB data acquisition board, and other various I/O expansions to drive servo's, run relay's, etc.


Sooooooooo

Think I'm insane yet?
 
Upon further realing, it appears that to drive piezo injectors, they need more than just PWM at a steady voltage.
Maybe the data sent to the IDM would have to be 8 bit, so 0= -127, 128=0, and 255= +128, and the number is multiplied by the amps to generate -200v to 200v in the waveform.
 
What if this chip was used as 1 per injector?


**broken link removed**
Features:
• 32 Bit Core
• 32K of Program Space
• 2000 (2K) Bytes of User / System RAM
• Up to 4 A/D pins
• Up to 100,000 Plus BASIC Instruction Per Second
• Code and Pin compatible to the Basic ATOM
• Hardware based 32 bit math
• Hardware PWM
• Hardware UART
• Hardware SPI and I2C
• Based on a 32 bit processor

There would be the timing chip, which reads the 2 hall sensors, and determines postion, and it would have at least 8 output pins, each connected to one of the above chips.
When the timing chip determined that it's time to fire an injector, it would set the appropriate pin to high, and the rest would be up to the signal generation chip.

The signal generating chip (link above?), would just sit in a loop looking at that 1 pin, waiting for the signal to go.
Whe it gets it, it would read injection data from memory, and output it using the PWM generator.

But then there is the issue that more than just a on/off PWM signal is needed......

Any chips capable out outputting or generating high speed waveforms based on a sequence of data?
 
Just thinking out loud.....
What about a chip from a video board?

Essentailly, those chips read graphics data from a memory chip, and output it at very high speed to a video cable to the monitor, or TV.

Something very similar..... but hacked, so that it would "play" the data on command, not contunously.
Plus it would only need 1 set of data, not RGB.

But something to think about.....
 
Let me be the first to ask why and what for? :confused:
 
Let me be the first to ask why and what for? :confused:

I have a dream.
The dream is to develop an open source programming option for new age diesel vehicles.
The factory computers in cars/ trucks can be so hard to program, that the companies that do it, require large returns for the effort.
At this point in time, I believe that electronics have come so far, that it would be easier to start from scratch, rather than try to conform to factory computers.

Don't get me wrong, the entire idea is far out, I get that, but if a system could be devised to take care of the timing and firing sequence of the injectors, things would be looking up.

Also, if the injecotr driver module (IDM) is designed, it could potentially be controlled by any device using serial data, so the options are endless.
Personally, I think it would be fun to program a truck with a variant of quickbasic, or maybe basic on a chip... something to that effect.
 
Well here is a link to the wiring schematics for the whole engine control system for the all electronically controlled 99 and 02 Ford F250 and up diesel pickups.
https://www.thedieselstop.com/forums/f47/7-3l-wiring-schematic-printable-very-handy-257591/

The injector control module is just that an independent control unit that only needs the correct input signals to be able to fire each injector.

And here are the actual units on eBay.
https://www.ebay.com/sch/i.html?_sacat=0&_from=R40&_nkw=ford+7.3+diesel+injector+control&rt=nc

As far as the market for such a system goes there are already loads of them available for industrial and custom contorl applications. Woodward is one well known company.
https://www.woodward.com/dieselengines.aspx
 
Well here is a link to the wiring schematics for the whole engine control system for the all electronically controlled 99 and 02 Ford F250 and up diesel pickups.
https://www.thedieselstop.com/forums/f47/7-3l-wiring-schematic-printable-very-handy-257591/

The injector control module is just that an independent control unit that only needs the correct input signals to be able to fire each injector.

And here are the actual units on eBay.
https://www.ebay.com/sch/i.html?_sacat=0&_from=R40&_nkw=ford+7.3+diesel+injector+control&rt=nc

As far as the market for such a system goes there are already loads of them available for industrial and custom contorl applications. Woodward is one well known company.
https://www.woodward.com/dieselengines.aspx

Those ford IDM modules are for older 1994-2003 ford engines, which use HEUI injectors.
And yes there are lots of aftermarket engine controllers, but they are cost prohibitive (5000+$) and also not too easy to program.

Megasquirt comes to mind, but it seems based on older technology, and seems limited compared to newer processing power.

Ultimately my goal would be to have a flexible injector driver, using software and data to generate the waveform, not complicated electronics.
And the actual unit used as a PCM, would be awesome if it was something that could be programmed in basic, C languages, so that coding and understanding wouldn't be hard to do.
 
And if the injector driver module was generating the waveform solely from data sent to it, it could potentially control a slough of injectors, not just 1 type, or 1 vehicle.
In the IDM, there could be a timing chip, and it could be set up for any number of cylinders, and then the actual injector drivers could just be stacked for
how many cylinders you have.
The timing chip would just send a high signal to the injector driver it wants to fire.
The injector drivers would all share a common bus, that the PCM can update the injection data on.

It seems like a very simple system, I just don't know what hardware would do it well.
 
Don't know myself.

I personally prefer the old fashioned Bosch and Rosamaster mechanical pump systems.
Turn some screws change a shim or two and double your fuel rates no laptop or reprogramming required! :p
 
Don't know myself.

I personally prefer the old fashioned Bosch and Rosamaster mechanical pump systems.
Turn some screws change a shim or two and double your fuel rates no laptop or reprogramming required! :p

I know, old reliable systems.

Current power tuners are alright, but to actually change anything requires either huge knowledge, or huge money.
The average person is not going to devote that much to a vehicle.

Thats why I was hoping this could make any headway, so a different option could exist.
 
Firstly, what is your level of understanding of digital and analogue electronics ?

Secondly, what is your level of understanding of programming languages ? ASM / C etc ?

Lastly, what is your level of understanding of car mechanics / diesel engines / sensors etc ?

Maybe do some reading up on linbus/ canbus / obdii (obd2) etc first. They are a communication system which has been establised, is reasonably easy to understand and can control and monitor most aspects of an automotive system.

Then have a good read through the megasquirt / megajolt etc forums and websites. They are for petrol engines but a lot of what you'll learn from there is directly relevant to what you want to do.

Then do some research on volumetric calculations for combustion engines etc - this will give you an idea of the kind of mathematics required for on the fly calculation of fuel injection requirements.
 
Current power tuners are alright, but to actually change anything requires either huge knowledge, or huge money.
The average person is not going to devote that much to a vehicle.

So what do you consider a huge knowledge or money?
The Woodward systems are very user friendly on their interface systems and anyone who owns a newer diesel engine that has all electronic injection control already has a pile of cash tied up in just owning it if its any good. Even more money if they intend to refit it into a vehicle or any other application that did not already have a diesel engine in it to begin with.

Lastly if they are refitting a diesel engine into a different vehicle to gain fuel mileage numbers and lower fuel and operating costs putting a modern electronically controlled emissions compliant one in is the last thing they want to be tossing piles of cash at.

So do you have a specific engine and an intended application for it to begin with?
 
There have been several threads on this site already for injector drive circuits. Search for 'injector'.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top