Dual stage electronic boost controller


#1

Working File on Google Drive

Background

I have converted my 2002 VW mk4 jetta 1.8t to run bi-fuel on CNG. I have free access to CNG at work so this makes running the car much cheaper.

To take advantage of the higher octane rating of the fuel (130+) and to make up for lost O2 due to displacement in the air intake (CNG is injected in the intake port as a gas, not liquid like petrol), I would like to run more turbo boost.

What i’d like to do is run two levels of boost, one for 93 octance (~15 psi) and a second level for CNG at approximately 20 psi. The car determines fueling based an a MAF reading, so I can pretty much increase boost to safely 20psi without causing any engine issues

Project Goals

  1. Dual stage electronic boost controller
  2. Boost pressure sensor (0-5V) signal to be capped at 4.3V to the ECU

===============================================================

Dual stage electronic boost controller

  • Arduino nano or similar microcontroller
  • PWM the stock solenoid valve (N75 valve) to regulate wastegaste pressure and thus control boost
  • PWM frequency to be approximately 20 Hz
  • Drive the solenoid valve with a MOSFET transistor (with appropriate flyback diode)
  • Inputs will be: boost pressure transducer (0-5v input) as well as a 5V digital input from the CNG controller to say that the system is in CNG mode.
  • Logic will read boost transducer voltage and then lookup the desired PWM in one of 2 tables (gasoline mode or CNG mode).

Current questions on boost controller:

  • The N75 valve has a resistance of 30 ohms (2.5 amps current draw) and needs to cycle at 20 Hz. Can anyone recommend an appropriate MOSFET and flyback diode to drive the valve?
  • Can anyone recommend a strategy for filtering the power supply to the controller to keep voltage spikes from the solenoid valve from resetting the controller? I presume the flyback diode will help, but do I need to add any additional RC snubbers, MOV’s etc…

===============================================================

Boost pressure sensor capped at 4.3V to the main ECU
The purpose of this mod is to prevent the stock ECU from seeing more than 11 psi of turbo boost. This is the stock boost reading and therefore the ECU wont sense a problem enter limp mode. Because the ECU determines fueling based on a MAF (mass airflow reading) and O2 sensor feedback, fuelling should be taken care of.

Common solutions to this problem is to install a 4.3V zener diode on the signal line of the pressure sensor. This will dump any voltage over 4.3 volts to ground and prevent the ECU from seeing a value higher than this. The problem I have with this, is that I want to actually read the real signal on the electronic boost controller above, but have the ECU only see 4.3V.

Needs

  • Read the 0-5V output of the pressure sensor unmodified at the electronic boost controller
  • Cap the voltage fed to the ECU at 4.3V

Questions

  • Can someone suggest a circuit to handle this?
  • Would a circuit like below make sense? Anyone suggest a mechanical or solid-state SPDT switch?

Thanks for the help everyone

Here is a photo of the car on its first CNG fill


#2

Paging @LoialOtter ( :slight_smile: ).

My suggestion with regards to the boost signal cap for the ECU is to place a resistor between the boost signal and the zener diode. When the zener diode caps the voltage at 4.3V, then the resistor will create a voltage drop that will allow your boost controller to continue to see the voltages above 4.3V while the ECU only sees a voltage capped at 4.3V by the zener. Resistor size will depend on the amount of current that can be supplied by the signal generator, the current capabilities of the zener and the impedance of the engine ECU boost signal pin. (I’m thinking a good starting point is 2.7K ohm).

What is currently driving the N75 valve? open it and you shall find the proper driving circuit, including diode and power device. If not, try getting the data sheet for the valve, they usually include example typical driving circuitry.

Filtering power: Design the circuit such the N75 power driver circuit runs off 12V as the main voltage supply and 5V as the controlling signal. Then your processor would be protected from power spikes/sags on the supply line by a 5V regulator. The 5V regulator data sheet should tell you about necessary filtering capacitors. You could always place a series inductor after the 5V regulator and before the processor if you wanted additional noise rejection.

You do need to include some kind of input power cleaning as automotive power is usually noisy and unstable. I’m not familiar enough with those issues to give you advice, but I’m sure google can help.


#3

What level are you trying to do this at? Like, connecting a bunch of modules together, or are you planning on spinning your own board?

Boost controller:

Go to Digikey’s website and start narrowing down parameters to find your MOSFET. 20Hz is really slow, so there should be lots of choice. Something like this looks pretty good. You should order this before your board and play around with an oscilloscope, because it probably needs a gate driver!

For power:

First thing I’d is read this, to get yourself appropriately frightened :slight_smile:

Here are a couple app-notes that have more specific recommendations:


I’ve never built any automotive device so I may be over-paranoid, but the gist of what I’m getting out of those is that SMPS are better than linear power supplies in this application, and TVS diodes are important.

It would also be a good idea to use only automotive grade microcontrollers - AVRs in that category are $2-$3, up from $0.50 or so, which is a totally reasonable extra cost.


#4

I’ll probably build a board in KiCAD to mount everything, but only after I’ve bench tested (and car tested) the system

I was thinking of powering the microcontroller with a step down converter like this, and then just run vehicle 12V to the mosfet / solenoid valve
12V to 5V step down converter

Thanks for the reply, I’ll have a read and go from there. Sounds like the most important thing to not cheap out on is a power supply for the microcontroller (not surprising)


#5

Perhaps a circuit like this


#6

If you are going with a SMPS, I bought this unit in December and I’m very happy with the design and quality of parts used. It’s modular so you can remove the USB charging component without interfering with the 5V power supply. It did not get hot at all charging 3 cell phones ( around 3.5 amps load ).


#7

Since I will be tapping into the boost pressure sensor circuit anyway, There should be easy access to a +5V source for the arduino nano (as the pressure sensor is a 3 wire sensor, gnd, +5V and signal).

I presume the +5V source from the ECU for sensor driving should be relatively stable? Perhaps a couple more capacitors on the line would filter out any instability of the +5V sensor voltage.


#8

Added a link to the top post to the working google drive file
https://docs.google.com/spreadsheets/d/1OzPPGatqRz8RGiIXKr-OKo-HBvJbae0W4BEx1Ng5FWE/edit?usp=sharing


#9

Whatever 12V-to-5V supply block you use, put two or three 16V or so Zeners in front of it, along with an appropriate resistor, plus a couple of DC surge supressors as well. Spikes to 60V can, and will, happen on the car battery buss. Do a search along the lines of… “protecting car electronics from spikes” and that should give you plenty of food for thought (and applications…).

Interesting project you have there, are you working for Westport Innovations?


#10

I was hoping to drive the controllers off of the +5V output the ECU is currently sending to the boost sensor as it should be a cleaner source of voltage (not sure how much cleaner though)

Yep I am working for Westport


#11

Make sure the feed from the ECU can supply the extra current to your components, including driving spikes to the power FETs. And make sure that YOUR device does not generate AND backfeed noise to the ECU.

Say Hi! to Peter Lui and Gary Gill for me (Stephen Young)…


#12

Hey everyone, so I have generated this schematic in KiCAD (as well as the PCB for fabricating), but wanted to get some feedback on it before ordering.

Here is some logic behind the decisions I made in this schematic.

The arduino (pro-micro) is a 5V board. So to ensure stability I wanted to feed the board a 7-9V signal so it can generate its own stable 5V signal. This meant not using the 5V signal output from the engine ECU. So I have included in the schematic a 12V to 8V voltage circuit using an LM2940 linear voltage regulator. Along with the regulator there is a 16V zener diode and a input (0.47 uF ceramic) and output capacitor (22 uF ceramic).

The arduino will also ouput a DAC circuit to feed an analog voltage back to the ECU to simulate the boost pressure signal. This is done with a RC circuit with a comparator on the end (pulled from the below link). I understand the RC (1k resistor and a 10 uF cap) part but am not as confident in the use of the comparator in the circuit.
https://arduino-info.wikispaces.com/Analog-Output

The +12V CNG circuit on signal is fed through a SSR that tells the arduino when the CNG system is active. This was fed using a SSR as the +12V signal is pulled from a solenoid valve and I wanted to isolate the signal to minimize and noise / voltage spikes. 1.2k resistor on the +12V circuit to keep the current on the SSR to ~10 ma.

The solenoid is driven via a mosfet transistor, with a pull down resistor on the drive circuit. There is also a 1N4004 flyback diode on the solenoid drive circuit.

Let me know if there is anything obvious I have missed or you would change. If not I’ll order these boards on KiCAD shortly.


#13

This looks neat! I have some suggestions, but obviously feel free to ignore whatever.

This is a good idea. From what I’ve seen, people are usually using switching power supplies instead of linear for automotive purposes, so I just checked the Pro Micro schematics hoping to see one, but nope, it’s linear too :frowning:

In the possible event that transients fry your regulator or Arduino, it might be a good idea to put a 3-pin header footprint, with the input and output power, and ground going to it. That’ll allow you to remove the (potentially dead) LM2940 and solder in a SMPS module instead of having to respin the board.

What op-amp are you using? The LM350 is a regulator, so there might be a mix up on your schematic. One thing to be wary of is that many op-amps are not “rail-to-rail”. That is, you might power it using 0/8v, but the output might only go between 2-6v.

Edit: My bad, couldn’t read LM358. Output range 0v - (8v - 1.5v), looks good.

Your transistor is flipped horizontally. Current goes into the drain, and out the source.

Looks like this optocouple is an open-drain, which means that it pulls the input voltage down to zero. Move the Arduino pin to pin 4, use a 1k or 1.2k or similar resistor to pull it high, and then ground pin 3. From the datasheet:

This will mean that it gives you an active-low signal, but that should be easy to fix in the code.

I’m not familiar with Kicad, are those white spots proper vias?

I’d also recommend a ground pour on the bottom layer, covering all of the parts that are not near the 12V - Basically the Arduino, half the optocouple, and the op-amp.

Also: mounting holes! I usually put at least three 3.4mm holes on the corners, sized for M3 screws.


Overall, looks really good! You covered most of your bases in regards to transients, and I know how overwhelming this can all seem. :slight_smile:
The modularity is really good for risky environments where you might have to swap out components, or bodge on some more circuit protection.


#14

Great, thanks for the reply. All good notes and i’ll incorporate them before I make an order.

Likely to actually make the digikey order first, then once its working on a breadboard make the oshpark order


#15

Need a little help here again, i’ve seen recommendations for a TVS diode or a zener diode on the input side of the voltage regulator to protect the regulator from large voltage spikes. Can someone recommend a product, or tell me if the one here would work?

http://www.digikey.ca/product-detail/en/stmicroelectronics/SMBJ30A-TR/497-7452-1-ND/1883444

Do I need anything else on the circuit i’ve pasted below?


#16

That schematic looks fine.

Reiterating that I don’t have any experience with this in particular, but
the ratings of SMBJ30A-TR are:

Stand-off voltage: 30V

Breakdown voltage (min): 33.3V

Clamping voltage: 64.3V

So the zener will start conducting at around 33V, and not really pass any
voltage above 64V. That seems high to me, and likely to allow your stuff to
break even while it’s within its limits!

Something more like the SMBJ18A-TR might be a better rating - Breakdown at
20V, stand-off at 18V. You could go lower, but if you go too low, your
zener will fry. You go to high, and it won’t do much of anything before the
rest of your system goes!


#17

Insert a fast-blow fuse between the +12V and the vehicle supply. Pick a fuse current rating somewhere between your circuit’s power draw and the zener’s max current capacity. When the zener conducts, it will draw high current which will hopefully blow the fuse before the zener dies and your circuit gets fried.


#18

put more than one of the zener you select in parallel, if one dies, the other(s) is/are still there. I am partial to 18V to 20V zeners in vehicles.


#19

Parallel zeners can blow sequentially, leaving a fuse intact. Better to create a crowbar circuit to take out a fuse. Place a zener on a power transistor base, MOSFET gate, or thyristor gate. Once the zener conducts, your power device shorts out the supply, taking out the fuse.


#20

Yes, if you are going to sub-fuse, and money is no object (usually the case in qty 1, for your own use), then I do agree that an electronic crowbar is worth its weight in gold. Good point.