This research focused on the design and implementation of an Engine Control Unit (ECU) to control the performance of a 2 Stroke Internal Combustion Engine (ICE) for a Medium Altitude Unmanned Aerial Vehicle (UAV). The control strategy focused on controlling the Air-Fuel Ratio (AFR) of the combustion process by measuring the exhaust gas and manipulating the quantity of injected fuel by using the Electronic Fuel Injector (EFI). This method was implemented to increase the system’s reliability to operate in a medium altitude environment. There are three major sub-systems in the ECU, i.e. multi-sensors interfacing, spark and fuel injection timing, and the control for injected fuel quantity. Architecture of task used in the system was based on the super loop concept complemented with event-based interrupts for handling time-critical processes. A PID Neural Network (PIDNN) control approach was used in this research to compensate a system with black-box identification which the plant’s parameters were difficult to be obtained numerically. Thus, an adaptive controller approach would be a suitable option to compensate the system.