UG-1098
ADE9000 Technical Reference Manual
Rev. 0 | Page 40 of 86
CONFIGURING THE WAVEFORM BUFFER
The waveform source (sinc4, sinc4 + IIR, xI_PCF/xV_PCF, or
resampled), type of capture (continuous, single capture, or stop
on trigger), and fill mode (continuous, one time, or based on
trigger) must be configured in the WFB_CFG register. To
perform this configuration, first disabled the waveform buffer
by writing WF_CAP_EN = 0. Then write the WF_SRC,
WF_CAP_SEL, and WF_MODE bits in the WFB_CFG register.
When the WF_CAP_EN bit is set, the capture is initiated based
on whichever mode is selected by the WF_CAP_SEL and
WF_MODE bits in the WFB_CFG register.
For example, if WF_CAP_SEL = 0, resampled waveforms are
stored into the buffer. If WF_CAP_SEL = 1, fixed data rate
samples are stored into the buffer, and the WF_MODE bits
indicate whether the buffer is filled continuously or only one
time, and if trigger events affect the buffer filling. All of these
bits must be configured before writing the WF_CAP_EN bit in
the WFB_CFG register.
When the waveform buffer is disabled by clearing the
WF_CAP_EN bit, the waveform buffer data remains valid;
however, the LAST_ADDR and WFB_TRIG_ADDR registers
are reset.
To start a new waveform capture, disable the waveform buffer
by writing WF_CAP_EN = 0. Then configure the
WF_CAP_SEL and WF_MODE bits as desired by writing to the
WFB_CFG register. Finally, set the WF_CAP_EN bit in the
WFB_CFG register to start the capture. Do not change the
WF_CAP_SEL or WF_MODE bits while the WF_CAP_EN bit
is set.
BURST READ WAVEFORM BUFFER SAMPLES
FROM SPI
The waveform buffer contents can be read using SPI burst read
mode. SPI burst read mode allows samples of data to be read
while only sending one SPI command header. The transfer of
data continues as long as the SS line is kept low and SCLK
clocks arrive at the
SCLK pin.
To make it easier to read out the desired data using the SPI
burst read functionality, the user can indicate which channels of
data to read out of the waveform buffer by using the
BURST_CHAN bits in the WFB_CFG register, as shown in
Table 25.
Table 25. Waveform Buffer Burst Read
BURST_CHAN[3:0] Channels to Burst
0000 (default)
All channels
0001
IA and VA
0010
IB and VB
0011
IC and VC
1000
IA
1001
VA
1010
IB
1011
VB
1100
IC
1101
VC
1110
IN if WF_IN_EN = 1 in the WFB_CFG register
1111
Single address read (SPI burst mode is
disabled)
The same BURST_CHAN options are available for both fixed
data rate samples and resampled data.
The waveform buffer sample that is read out depends on the
selection in BURST_CHAN and on whether the stored data is
fixed data rate data or resampled data.
If BURST_CHAN is not equal to 1111 and fixed data rate data
is stored in the waveform buffer, when WF_CAP_SEL = 1, the
three least significant bits of the address are masked out when
determining which sample set to read out.
If BURST_CHAN is not equal to 1111 and resampled data is
stored in the waveform buffer, when WF_CAP_SEL = 0, the
two least significant bits of the address are masked out when
determining which sample set to read out.
If BURST_CHAN is equal to 1111, whichever address was
written in the CMD_HDR is read out.
These cases are summarized in Table 26.
Table 26. SPI Address Interpretation when Reading from
Waveform Buffer
Capture Type
Address of Sample
Set (BURST_CHAN
≠ 1111)
Address of Sample
Set (BURST_CHAN
= 1111)
Fixed Data Rate
Samples
(WF_CAP_SEL = 1)
ADDR[11:3]
ADDR[11:0]
Resampled Data
(WF_CAP_SEL = 0)
ADDR[11:2]
ADDR[11:0]