Snapshot - david-macmahon/wiki_convert_test GitHub Wiki
Block: Snapshot (snapshot
)
Block Author: Andrew Martens
Document Author: Andrew Martens
Summary
The snapshot block is configurable block for capturing blocks of data with a standard interface supporting generic software drivers. It combines functionality from (and deprecates) the snap, sc, snap_64 and snap_circ blocks.
Mask Parameters
Parameter | Variable | Description |
---|---|---|
Storage medium | storage | Specifies whether to store the data in BRAM or DRAM |
DRAM dimm | dram_dimm | Specifies which dimm to use if using DRAM as storage medium. |
DRAM clock rate | dram_clock | Specifies the DRAM controller clock rate if using DRAM as a storage medium. |
No. of Samples ((2^?)) | nsamples | Specifies the maximum depth of the data storage buffer |
Data width | data_width | The bit width of the input data |
Start delay support | offset | Option to support inserting a programmable number of samples between the trigger for the start of capture, and data capture itself. |
Circular capture support | circap | Option to support continual capture until a signal to stop is received. |
Extra value capture support | value | Option to support the capture of a value to a register as the first data item is captured. |
Use DSP48s to implement counters | use_dsp48 | Option to use DSP48s to implement various internal counters to save logic. |
Ports
Port | Dir | Data Type | Description |
---|---|---|---|
din | IN | unsigned_8_0 OR unsigned_16_0 OR unsigned_32_0 OR unsigned_64_0 OR unsigned_128_0 | The data to be captured. Data is stored with oldest data in the lowest addresses and in little endian format. |
we | IN | boolean | After a trigger is begun, enables a write to the data buffer. |
trig | IN | boolean | When high, triggers the beginning of a data capture. Thereafter, every enabled data is written to the data buffer. If offset capture is enabled, capture can be delayed by a configurable number of samples after the trigger. If circular capture is enabled, capture continues until the input to the stop port goes high. |
stop | IN | boolean | Triggers the end of data capture when in circular capture mode. |
vin | IN | unsigned_32_0 | When extra value capture is enabled the value on this port is captured on the same sample as the first data item captured. |
ready | OUT | boolean | When using DRAM as a storage buffer, signals that the DRAM controller has finished calibration and is ready to receive data. |
Software interface
Name | Dir | Data Type | Usage |
---|---|---|---|
ctrl | Write | unsigned_32_0 | |
trig_offset | Write | unsigned_32_0 | |
val | Read | unsigned_32_0 | |
status | Read | unsigned_32_0 | |
tr_en_cnt | Read | unsigned_32_0 | |
bram | Read | unsigned_32_0 | |
dram | Read | unsigned_32_0 | |
Description
Usage
Under TinySH/BORPH, this device will have 3 sub-devices: ctrl
, bram
,
and addr
. ctrl
is an input register. Bit 0, when driven from low to
high, enables a trigger/data capture to occur. Bit 1, when high,
overrides trig
to trigger instantly. Bit 2, when high, overrides we
to always write data to bram. addr
is an output register and records
the last address of bram
to which data was written. bram
is a 32 bit
wide Shared BRAM of the depth specified in Parameters
.