New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
StreamFragmentWidthAdapter.make missing earlylast argument #1303
Comments
Sorry to open this issue again (should I start a new one?), but further implementing the width adapter, I noticed the dataMask is not available when using the I worked around it by defining my own class StreamFragmentWA
object StreamFragmentWA {
def apply[T <: Data,T2 <: Data](input : Stream[Fragment[T]],output : Stream[Fragment[T2]], endianness : Endianness, earlyLast : Boolean = false): Bits = {
StreamFragmentWA(input, output, endianness, false, earlyLast)
}
def apply[T <: Data,T2 <: Data](input : Stream[Fragment[T]],output : Stream[Fragment[T2]], endianness : Endianness, padding : Boolean, earlyLast : Boolean): Bits = {
StreamFragmentWidthAdapter(input, output, endianness, padding, earlyLast).dataMask
}
def make[T <: Data, T2 <: Data](input : Stream[Fragment[T]], outputPayloadType : HardType[T2], endianness : Endianness, earlyLast : Boolean) : (Stream[Fragment[T2]], Bits) = {
val ret = Stream(Fragment(outputPayloadType()))
val mask = StreamFragmentWA(input,ret,endianness,false,earlyLast)
(ret, mask)
}
} The in my module I write val (axi_stream, axi_mask) = StreamFragmentWA.make(fifo.io.pop,
Bits(io.axi.config.dataWidth bits),
LITTLE,
earlyLast = true) |
Hmm what's about adding it to StreamFragment, but with an alternative name ? (PR welcome) ^^ |
The earlylast argument is not available in the
StreamFragmentWidthAdapter
'smake
methodsSpinalHDL/lib/src/main/scala/spinal/lib/Stream.scala
Line 1833 in 2527c7c
The text was updated successfully, but these errors were encountered: