From 67ab163ef79d8065a888cbe909e2bbb61224622e Mon Sep 17 00:00:00 2001 From: PopPaul2021 <93918446+PopPaul2021@users.noreply.github.com> Date: Mon, 13 May 2024 19:17:37 +0300 Subject: [PATCH] docs: page for AD7768 IP (#1322) Signed-off-by: Jorge Marques Signed-off-by: PopPaul2021 --- docs/library/axi_ad7768/block_diagram.svg | 4 + .../axi_ad7768/detailed_architecture.svg | 4 + docs/library/axi_ad7768/index.rst | 167 ++++++++++++++++++ 3 files changed, 175 insertions(+) create mode 100644 docs/library/axi_ad7768/block_diagram.svg create mode 100644 docs/library/axi_ad7768/detailed_architecture.svg create mode 100644 docs/library/axi_ad7768/index.rst diff --git a/docs/library/axi_ad7768/block_diagram.svg b/docs/library/axi_ad7768/block_diagram.svg new file mode 100644 index 000000000..d4688c36f --- /dev/null +++ b/docs/library/axi_ad7768/block_diagram.svg @@ -0,0 +1,4 @@ + + + +
DMA_FIFO
DMA_FIFO
ADC
DATA
PROCESSING
ADC...
REGISTER
MAP
REGISTER...
AD7768
INTERFACE
AD7768...
AXI SLAVE
AXI SLAVE
ADC INTERFACE
ADC INTERFACE
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/library/axi_ad7768/detailed_architecture.svg b/docs/library/axi_ad7768/detailed_architecture.svg new file mode 100644 index 000000000..49858f564 --- /dev/null +++ b/docs/library/axi_ad7768/detailed_architecture.svg @@ -0,0 +1,4 @@ + + + +
UP_ADC_CHANNELS
UP_ADC_CHANNELS
UP_ADC_COMMON
UP_ADC_COMMON
UP_AXI
UP_AXI
AXI_AD7768  IP architecture
AXI_AD7768  IP architecture
S_AXI_MM
S_AXI_MM
data_in[7:0]
data_in[7:0]
adc_data_*[31:0]
adc_data_*[31:0]
adc_dovf
adc_dovf
adc_clk
adc_clk
adc_reset
adc_reset
adc_valid_*
adc_valid_*
ready_in
ready_in
adc_sshot
adc_sshot
AXI_AD7768_IF
AXI_AD7768_IF
clk_in
clk_in
adc_enable_*
adc_enable_*
adc_data[31:0]
adc_data[31:0]
adc_sync
adc_sync
adc_valid
adc_valid
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/library/axi_ad7768/index.rst b/docs/library/axi_ad7768/index.rst new file mode 100644 index 000000000..a99c224b0 --- /dev/null +++ b/docs/library/axi_ad7768/index.rst @@ -0,0 +1,167 @@ +.. _axi_ad7768: + +AXI AD7768 +================================================================================ + +.. hdl-component-diagram:: + +The :git-hdl:`AXI AD7768 ` IP core +can be used to interface the :adi:`AD7768` and +:adi:`AD7768-4` ADC, in 1, 2, 4 or 8 data lines active. +More about the generic framework interfacing ADCs, that contains the +``up_adc_channel`` and ``up_adc_common modules``, can be read in :ref:`axi_adc`. + +Features +-------------------------------------------------------------------------------- + +* AXI based configuration +* CRC validation flag +* Configurable number of active data lines +* Real-time data header access +* Vivado and Quartus compatible + +Files +-------------------------------------------------------------------------------- + +.. list-table:: + :header-rows: 1 + + * - Name + - Description + * - :git-hdl:`library/axi_ad7768/axi_ad7768.v` + - Verilog source for the AXI AD7768. + * - :git-hdl:`library/axi_ad7768/axi_ad7768_if.v` + - Verilog source for the AXI AD7768 interface module. + * - :git-hdl:`library/axi_ad7768/axi_ad7768_ip.tcl` + - TCL script to generate the Vivado IP-integrator project. + * - :git-hdl:`library/axi_ad7768/axi_ad7768_hw.tcl` + - TCL script to generate the Quartus IP-integrator project. + +Block Diagram +-------------------------------------------------------------------------------- + +.. image:: block_diagram.svg + :alt: AXI AD7768 block diagram + +Configuration Parameters +-------------------------------------------------------------------------------- + +.. hdl-parameters:: + + * - ID + - Core ID should be unique for each IP in the system + * - NUM_CHANNELS + - Select number of ADC channels. 8 for AD7768 and 4 for AD7768-4 + +Interface +-------------------------------------------------------------------------------- + +.. hdl-interfaces:: + + * - clk_in + - Input clock. + * - ready_in + - Input ready signal. + * - data_in + - Serial input data. + * - adc_dovf + - Data overflow input, from the DMA. + * - adc_clk + - This is the clock domain that most of the modules of the core run on. + * - adc_reset + - Output reset, on the adc_clk domain. + * - adc_sshot + - Single shot conversion. + * - adc_enable_* + - Set when the channel is enabled, activated by software. + * - adc_valid_* + - Set when valid channel data is available on the bus. + * - adc_data_* + - Channel parallel output data. + * - adc_data + - Serial output data. + * - adc_valid + - Set when valid data is available in the serial output. + * - adc_sync + - Start of transfer flag for serial data. + * - adc_crc_ch_mismatch + - Channels CRC mismatch flags register. + * - s_axi + - Standard AXI Slave Memory Map interface. + + +Detailed Architecture +-------------------------------------------------------------------------------- + +.. image:: detailed_architecture.svg + :alt: AXI AD7768 detailed architecture + +Detailed Description +-------------------------------------------------------------------------------- + +The top module, axi_ad7768, instantiates: + +* The ad7768 interface module +* The ADC channel register map +* The ADC common register map +* The AXI handling interface + +The AD7768 interface module has as input the serial data lines, the ready_in +signal and the interface clock. Data is deserialized according to the number +of active lanes. The interface module also implements a parallel CRC check +algorithm. +The data from the interface module is processed by the adc channel module. +``up_adc_common`` module implements the ADC COMMON register map, allowing for +basic monitoring and control of the ADC. +``up_adc_channel`` module implements the ADC CHANNEL register map, allowing for +basic monitoring and control of the ADC's channel. + +Register Map +-------------------------------------------------------------------------------- + +.. hdl-regmap:: + :name: COMMON + :no-type-info: + +.. hdl-regmap:: + :name: ADC_COMMON + :no-type-info: + +.. hdl-regmap:: + :name: ADC_CHANNEL + :no-type-info: + +Design Guidelines +-------------------------------------------------------------------------------- + +The control of the AD7768 chip is done through a SPI interface, which is needed +at system level. + +The *ADC interface signals* must be connected directly to the top file of the +design, as IO primitives are part of the IP. + +The example design uses a DMA to move the data from the output of the IP to +memory. + +If the data needs to be processed in HDL before moved to the memory, it can be +done at the output of the IP (at system level) or inside of the adc interface +module (at IP level). + +The example design uses a processor to program all the registers. If no +processor is available in your system, you can create your own IP starting from +the interface module. + +Software Guidelines +-------------------------------------------------------------------------------- + +Linux is suported using :git-linux:`/`. + +References +------------------------------------------------------------------------------- + +* :git-hdl:`library/axi_ad7768` +* :adi:`AD7768` +* :adi:`AD7768-4` +* :git-linux:`/` +* :xilinx:`Zynq-7000 SoC Overview ` +* :xilinx:`Zynq-7000 SoC Packaging and Pinout `