Attributes
----------
request : Signal(n)
- Signal where a '1' on the i-th bit represents an incoming request from the i-th device.
+ Signal where a '1' on the i-th bit represents an incoming request
+ from the i-th device.
grant : Signal(range(n))
- Signal that equals to the index of the device which is currently granted access.
+ Signal that equals to the index of the device which is currently
+ granted access.
stb : Signal()
- Strobe signal to enable granting access to the next device requesting. Externally driven.
+ Strobe signal to enable granting access to the next device
+ requesting. Externally driven.
"""
def __init__(self, n):
self.n = n
with m.If(self.request[t]):
m.d.sync += self.grant.eq(t)
- return m
\ No newline at end of file
+ return m