This document describes using a two-layer fuzzy logic controller with a unified power flow controller to dampen tie-line power oscillations in an interconnected thermal power system. Conventionally, automatic generation control is performed using primary governor control and a secondary proportional-integral controller. However, this can still result in frequency and tie-line power transients during load disturbances. The document proposes using a UPFC along with a two-layer fuzzy logic controller to further improve damping. Simulation results indicate this approach reduces transients and achieves faster settling times.