This document discusses the design of a microcontroller-based electronic ballast for supplying metal halide lamps. Electronic ballasts have advantages over traditional magnetic ballasts, but can cause acoustic resonances if not properly designed. The proposed ballast uses a low frequency square wave voltage and current to avoid these resonances. It employs a microcontroller to control the lamp starting, heating, and steady-state operations, which provides flexibility. The experimental results show the ballast achieves high power factor and efficiency. It provides a feasible and reliable solution for driving metal halide lamps.