Issues related to real-time control of a manufacturing cell using knowledge bases and simulation are discussed. The need for integrated simulation environments for modeling and analysis is advanced. A mathematical framework based on higher level abstractions representing entities, attributes, constraints, and other components of manufacturing cells is presented. A manufacturing cell has been modeled to illustrate the framework and real-time control issues using knowledge-based simulation. A temporal knowledge base has been designed to synchronize the events and their times of occurrence in both the manufacturing cell and the simulation model. Also, a dynamic knowledge base has been implemented using frame structures for storing the results of simulation. This feature provides a faster response to a control problem by reducing the number of resimulations conducted for evaluating various alternative policies in real time.