Add SimpleBus object

This commit is contained in:
Dolu1990 2018-10-20 12:39:20 +02:00
parent 85e696b286
commit 7c0f2dc713
1 changed files with 3 additions and 1 deletions

View File

@ -22,7 +22,9 @@ case class SimpleBusRsp(config : SimpleBusConfig) extends Bundle{
val data = Bits(config.dataWidth bits)
}
object SimpleBus{
def apply(addressWidth : Int, dataWidth : Int) = new SimpleBus(SimpleBusConfig(addressWidth, dataWidth))
}
case class SimpleBus(config : SimpleBusConfig) extends Bundle with IMasterSlave {
val cmd = Stream(SimpleBusCmd(config))
val rsp = Flow(SimpleBusRsp(config))