The dynamic clamp protocol allows an experimenter to simulate the presence of membrane conductances in, and synaptic connections between, biological neurons. Existing protocols and commercial ADC/DAC boards provide ready control in and between < or =2 neurons. Control at >2 sites is desirable when studying neural circuits with serial or ring connectivity. Here, we describe how to extend dynamic clamp control to four neurons and their associated synaptic interactions, using a single IBM-compatible PC, an ADC/DAC interface with two analog outputs, and an additional demultiplexing circuit. A specific C++ program, DYNCLAMP4, implements these procedures in a Windows environment, allowing one to change parameters while the dynamic clamp is running. Computational efficiency is increased by varying the duration of the input-output cycle. The program simulates < or =8 Hodgkin-Huxley-type conductances and < or =18 (chemical and/or electrical) synapses in < or =4 neurons and runs at a minimum update rate of 5 kHz on a 450 MHz CPU. (Increased speed is possible in a two-neuron version that does not need auxiliary circuitry). Using identified neurons of the crustacean stomatogastric ganglion, we illustrate on-line parameter modification and the construction of three-member synaptic rings.