25
25
26
26
class MandelbrotAccelerator (Elaboratable ):
27
27
MAX_PACKET_SIZE = 256
28
- USE_ILA = False
28
+ USE_ILA = True
29
29
ILA_MAX_PACKET_SIZE = 512
30
30
31
31
def create_descriptors (self ):
@@ -111,7 +111,7 @@ def elaborate(self, platform):
111
111
m .submodules .command_fifo = command_fifo = AsyncFIFO (width = 8 , depth = 32 , w_domain = "usb" , r_domain = "fast" )
112
112
m .submodules .result_fifo = result_fifo = AsyncFIFO (width = 8 + 2 , depth = 4 * self .MAX_PACKET_SIZE , w_domain = "fast" , r_domain = "usb" )
113
113
114
- m .submodules .fractalmanager = fractalmanager = DomainRenamer ("fast" )(FractalManager (bitwidth = 8 * 9 , fraction_bits = 8 * 8 , no_cores = 3 ))
114
+ m .submodules .fractalmanager = fractalmanager = DomainRenamer ("fast" )(FractalManager (bitwidth = 8 * 9 , fraction_bits = 8 * 8 , no_cores = 2 ))
115
115
116
116
# wire up USB via FIFOs to fractalmanager
117
117
m .d .comb += [
@@ -144,7 +144,7 @@ def elaborate(self, platform):
144
144
#ep1_out.stream.first,
145
145
#ep1_out.stream.last,
146
146
#ep1_out.stream.payload,
147
- usb_in_active ,
147
+ # usb_in_active,
148
148
result_fifo .r_level ,
149
149
ep1_in .stream .ready ,
150
150
ep1_in .stream .valid ,
@@ -154,13 +154,13 @@ def elaborate(self, platform):
154
154
]
155
155
156
156
signals_bits = sum ([s .width for s in signals ])
157
- depth = 4 * 8 * 1024 #int(33*8*1024/signals_bits)
157
+ depth = 1 * 8 * 1024 #int(33*8*1024/signals_bits)
158
158
m .submodules .ila = ila = \
159
159
StreamILA (
160
160
signals = signals ,
161
161
sample_depth = depth ,
162
162
domain = "usb" , o_domain = "usb" ,
163
- samples_pretrigger = 1024 )
163
+ samples_pretrigger = 128 )
164
164
165
165
stream_ep = USBMultibyteStreamInEndpoint (
166
166
endpoint_number = 3 , # EP 3 IN
@@ -171,7 +171,7 @@ def elaborate(self, platform):
171
171
172
172
m .d .comb += [
173
173
stream_ep .stream .stream_eq (ila .stream ),
174
- ila .trigger .eq (usb_in_active | ep1_in .stream .ready & ep1_in . stream . valid ),
174
+ ila .trigger .eq (ep1_in .stream .first ),
175
175
]
176
176
177
177
ILACoreParameters (ila ).pickle ()
0 commit comments