20 sep 2023
This document covers the software and support electronics of the electronic feedback carburetor installed on my 1960 Rambler American, which uses the Nash/Rambler 195.6 OHV engine. You'll need to read the document at the link above for context, description of the hardware and reasoning behind the project.
The YFA carburetor is an improved version of the venerable YF; it's the same basic carb as the YF, same jets, operation, low and high speed systems, and a much passive evaporative-emissions controls.
The "feedback" YFAs are modified to allow the addition of air -- a calibrated and adjustable air leak -- in the emulsion circuit after the main jet. There's a port on the carb, up high, with two holes: clean air from the air horn and an orfice into the emulsion tube.
The feedback YFA has a solenoid atttached to the port. When not energized the solenoid is "off" and the port is blocked -- the YFA is then a plain old carburetor. Solenoid on/open, air is let into the emulsion circuit. Opened fully at idle, the engine won't idle -- too lean. Opened fully "at speed", A/F ratio drops approximately 2 to 4 to 1.
In normal operation the solenoid is pulsed, ten times a second, and the ratio of on to off in each tenth-of-a-second pulse, determines how much air is let in.
In normal operation, the carb is statically set to sea-level normal/rich operation, and the control system leans it out as necessary. This is the beauty of this system -- if you unplug the wires, it's a dumb old reliable Carter YFA.
(Non-feedback YFAs have an "altitude corrector" attached (two screws) over the air-leak port; with these a screwdriver sets a fixed "leak" for over-4000-foot operation. AMC used many of these. You can swap the altitude corrector and feedback solenoid.)
What is a good air/fuel ratio?
The controller needs to know a few things to maintain AFR: engine temperature, manifold pressure, engine RPM, wideband tailpipe oxygen level.
I have an in-dash AutoMeter wideband A/F ratio meter and use it to dial in and manually adjust the carb, including seasonal choke adjustments. Most aftermarket AFR meters have a wire that no one uses, intended for a datalogger, that outputs a voltage proportional to displayed AFR.
Like modern EFI and especially older GM throttle-body EFI systems, there is a "fuel map", a table of ideal AFRs for the entire operating range of the engine. Manifold pressure and engine RPM select row and column, respectively, of a cell in the table and the carburetor is "enleaned" to make actual measured AFR at that moment match what the AFR table says it ought to be.
There is a parallel table of the same dimensions (row and column) that remembers the enleanment adjustment made. When the gas pedal is pressed, manifold presure drops (and selects a new row) and rpm increases (selecting a new column) the cell at the intersection of row and column contains the most-recently-calculated eneanment adjustment, which is adjusted as long as the engine operates in that "cell".
The table of desired AFR is created by hand, usually edits to an existing table. I seeded mine from EFI VE tables. This process is described later but it's fairly easy -- recall this is a carburetor already working, so you're not in the data-hell of a newly installed EFI system. The short of it is, you "copy" the carb AFR values read off the in-dash meter into the table, then adjust the table as you'd like it to be. More later.
I don't code in a github-compatible manner and I'm uninterested in adapting. I haven't figured out how to make code available on this website.
But here is the YFA task loop code, one of eight tasks in the YFA controller. There is a task loop that runs the sensors and does minimal filtering and error handling, and task loops for the LCD, power management, fuel pump control, etc. This project a rigorous example of the event-driven strategy mentioned on the main Code page.
Source code snapshot this date is Source.zip. It's probably out of date, ask me if you want up to date.
Here is the July 2023 schematic for the "shield" that the MCU attaches to.
The custom control electronics stacks on top of an Arduino Mega 2560 board (next revision, Arduino Due) and contains all of the electronics to control the YFA and fuel pump relay. It contains an on-board manifold pressure sensor. It needs wires to the carb, fuel pump relay, temperature sensor, a small hose to manifold vacuum, and switched ignition and direct battery. It connects to the "data logger" output of the in-dash wideband, required equipment.
There is a 2 x 16 LCD display and a rotary encoder with push switch. This is the only manual control. Operation is completely automatic.
I am driving on this now in closed-loop operation and chasing out bugs and tuning.
I built the AFR table editor right into the computer. No laptop is necessary. The AFR map editor is arranged such that the cell is selected (by manifold pressure and RPM) automatically, displaying the target AFR for that cell, and to adjust it, you just turn the knob. RPM and KPa can be selected by hand when the engine isn't running.
The second photo above is the complete package, ready to install, with the cover off. The orange panel fits between the instrument panel and controls pod on 1958 to 1963 Rambler Americans (and earlier Nash Ramblers).
The guts. This is the first board; you can see it's a bit hacked. New board is in the works now. Wires to the left are for the LCD and rotary encoder; to the right are power in, controls out, and sensors in.
Just some under-construction photos.
This was an early test showing the early PWM solenoid control signal,
using a manual software control for the purpose. The proof-of-concept hack
was to drive around with a box with a knob that controlled pulse-width, 0 to
100%, and turn the knob to characterize. Touchy at idle, easily
controlled a 60 mph cruise. That was enough.