An arbiter is a circuit that allows at most one subsystem at a time to use a shared resource. A four-way arbiter is shown in Figure 4.48. Each subsystem sets its request signal to 1 when it wants to use the resource. When the arbiter sets the grant signal to 1, the subsystem uses the resource. The subsystem sets its request back to 0 when it has finished, and waits for grant to be 0 before starting a subsequent request. While a subsystem is granted use of the resource, other requests must wait, rather than pre-empting the active subsystem.
a) Develop a FSM for a priority arbiter, in which subsystem 0 has highest priority and subsystem 3 has least priority. A pending request from a higher-priority subsystem takes precedence over a pending request from a lower-priority system.
b) Develop a FSM for a round-robin arbiter. Subsystems are granted requests in order, starting with 0, then 1, 2, 3 and back to 0. A subsystem is skipped if it has no pending request.