The DUT_SUM IP is a configurable accumulator module that sums a set of 8-bit input values and outputs the result. It is designed with three main interfaces:
- Data Interface – Handles input and output data.
- Control Interface – Used by other hardware blocks to control or modify the behavior of the IP.
- Configuration Interface – Used by a processor or software to configure the behavior of the IP.
The IP follows the RDY/EN protocol on all interfaces to synchronize data and control signals.
- Accumulates
N8-bit input values and outputs the sum. - The number of values
Ncan be specified:- At the interface via the
lengthport. - Via configuration register accessible through the configuration interface.
- At the interface via the
- A configuration bit determines whether the port or the register value is used as the source of
N. - Once accumulation starts, changes to length (port or register) are ignored until the output is produced.
- Supports pause functionality and software override for length programming.
- Produces a ready signal indicating valid data on output.
| Port | Direction | Width | Description |
|---|---|---|---|
| din_rdy | out | 1 | Ready signal for input data |
| din_en | in | 1 | Enable signal for input data |
| din_value | in | 8 | Input data |
| dout_rdy | out | 1 | Ready signal for output data |
| dout_en | in | 1 | Enable signal for output data |
| dout_value | out | 16 | Accumulated output data |
| len_rdy | out | 1 | Ready signal for length input |
| len_en | in | 1 | Enable signal for length input |
| len_value | in | 8 | Number of input bytes to accumulate |
| cfg_rdy | out | 1 | Ready signal for configuration interface |
| cfg_en | in | 1 | Enable signal for configuration interface |
| cfg_address | in | 8 | Address of register in configuration space |
| cfg_op | in | 1 | Operation type (0=Read, 1=Write) |
| cfg_data_in | in | 32 | Data to write (ignored for read operations) |
| cfg_data_out | out | 32 | Data returned from read operation |
| Address | Access | Bit map | Reset | Field | Description |
|---|---|---|---|---|---|
| 0 | R | 7:0 | 0 | current_count | Number of bytes processed |
| 0 | R | 15:8 | 0 | programmed_length | Length programmed for this session |
| 0 | R | 16 | 0 | busy | 1 if operation is ongoing |
| 4 | R/W | 0 | 0 | sw_override | 0=use length from port, 1=use length from register |
| 4 | R/W | 1 | 0 | pause | 1=input ready will be deasserted after current dataset |
| 8 | R/W | 7:0 | 0 | len | Length register (programmed length for accumulation) |
-
Initialization and Data Input
- Reset the IP.
- Provide input data and enable signals.
- Verify accumulation and ready flags.
-
Length Programming via Port
- Program length via
len_valueport. - Verify accumulation matches programmed length.
- Program length via
-
Length Programming via Configuration Register
- Program length via
cfg_address=8. - Verify accumulation respects register value.
- Program length via
-
Software Override of Length
- Enable software override via
cfg_address=4. - Verify accumulation uses port length over register.
- Enable software override via
-
Pausing Input
- Enable pause bit via configuration register.
- Verify accumulation stops at the programmed length and input ready is deasserted.
-
Reading Configuration Register
- Program values into configuration registers.
- Read back and verify correct values.
-
Busy Signal
- Verify
busyis high during accumulation and low when idle.
- Verify
-
Reset Operation
- Perform reset during accumulation.
- Verify output and internal state reset correctly.
- All outputs are synchronized to the clock.
- Accumulated output width is 16 bits to handle overflow from multiple 8-bit inputs.
- RDY/EN protocol ensures safe handshake between IP and other modules.