This is absolutely doable. I designed and built a FADEC (primitive, I grant you.) for my 1965 Corvair back in 1970. I was racing in SCCA parking lot grand prixs while I was in the Air Force and wanted a little bit of an edge, so I designed an electronic ignition, and a box to control it from the inside of the car. Then I added some electro/mechanical controls to the carburettors, and added those controls to the box.
While I was at IBM Research, I designed a more modern version for a famous race team from Italy in the mid-1990s (I'm not sure if the non-disclosure has run out) and a really high tech fit up for an unlimited class pylon racing team. (I KNOW that non-disclosure has not expired.).
Today, I know I can build and program it for less than $100.00 in off the shelf parts.
And then spend millions fight off the FAA.
There is at least one C-152 flying right now with one in it.
Legal disclaimer: I have no idea who designed it, built it, or installed it.