Variable 5v analog output for Holley EFI

Do any of the Arduino microcumputers have the capability of outputting a programmable VARIABLE 5v analog signal without adding additional circuitry. I am trying to interface with a Holley fuel injection system and it does not have a PWM input, only 5v and 20v analog voltage inputs. I am currently using a UNO but it has only a PWM output that is programmable, and I am not sure if the Holley ECU will interpret that signal correctly as analog.

Hello
did you try it ?

PWM just needs a resistor and capacitor to smooth it into DC.
Here is PWM with 10K resistor and 4.7uF cap, at analogWrite(output) levels of 25, 50, 75, 100, etc. up to 250, then repeating. I think I changed the level every 1mS maybe? Can't reallhy read the time grid on this shot.

I don’t think you find exactly what you need in the Arduino family. Oops, no, it looks like the DUE has some true digital to analog converters for use. So maybe others? I just came across it googling.

But a few components can fix you up for analaogWrite PWM to constant voltage, worth trying.

google pwm rc filter

for suggested circuitry.

Or you cou,d add a real digital to analog converter, there are quite a few chips easy to interface with SPI or I2C.

a7

Nano 33 IOT has a DAC. I expect that the others in that range do too.

So what is this requirement of "not requiring additional circuitry"? Did someone pose this restriction and on what ground? I would suggest a cheap DAC for a few USD with an easy-to-use library but that's not possible under your restriction. On the other hand, you're willing to buy another Arduino that can do it, so long as nothing but the arduino is required. If you plug a DAC into your arduino UNO's headers, is that counted against that restriction? That's what I do with students sometimes when they are afraid of hooking up wires on a breadboard.

Thanks for the replies.
I rigged up a filter using a 10µF capacitor and a 3.9K ohm resistor and that seemed to work in the sense that it produced a constant DC voltage. Using an Analogwrite value of 200 to pin 10 on the Arduino, when I connect a digital voltmeter to the PWM output of the Arduino I read about 3.7v on the DC scale. When I connect an oscilliscope to the PWM output of the Arduino I get a nice square wave with an amplitude reading from 0v to 0.5v and the filtered voltage is about 0.38v.
If I set the Analogwrite to the maximum value of 255 the PWM value has a max voltage of 0.488v in a flat line as expected and the filtered value is about 0.488v.
Now my question is, and keep in mind that I am no electronics expert, how can I boost the filtered DC output by a factor of 10 so that the filtered output range would be from from 0v to +5v?

You're measuring the wrong point. One end of the resistor connects the the PWM pin, the other end to the + of the capacitor. The - of the capacitor connects to the Uno GND terminal.

You then measure the voltage across the capacitor, not at the PWM pin.

None of the boards previously mentioned will output 0-5V directly, they are all 3.3V devices. To get a direct 0-5V output, add one of the very inexpensive MCP4725 I2C dac breakout-boards to your Uno or stick with the filtered PWM output if it works for you.

I think I have it wired correctly. The measurement between PWM pin 10 and ground was just to show that the PWM signal was the correct form.
The top part of the picture below is the wave form between pin 10 and ground, note the MAX Voltage is 0.508.
The bottom part of the picture is the wave form between pin the ends of the capacitor, note the MAX Voltage is 0.429.
The Analogwrite value for these pictures was 220.

0.429 volts is the expected result... when your probe is set on the X10 setting.

WattsThat:
0.429 volts is the expected result... when your probe is set on the X10 setting.

Well Duuh! My mistake. Thanks for pointing out my mistake.

We like to think that we learn from our past mistakes - but the old scope probe one the wrong setting mistake is one I can assure you will happen again.

When I have something that I’ve assembled and it doesn’t work, the first thing I look for are the things I did wrong. Then it’s the actual design and then only as a last resort, do I start looking for defective parts. The number of times I’ve gotten to the third possible cause I’ll bet is less than ten in forty years.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.