Wiki

This version (02 Nov 2023 09:23) was approved by George Mois.The Previously approved version (14 Apr 2022 15:35) is available.Diff

ADI JESD204B/C Receive Peripheral No-OS Driver

Description

The AXI JESD204B RX peripheral driver is a simple driver that supports the ADI JESD204B Receive Peripheral. The driver reads JESD204B link configuration data from the initialization structure and configures the peripheral accordingly. After configuration has completed the JESD204B link is enabled. Link state can be monitored through using the `axi_jesd204_rx_status_read` function.

Initialization example

struct jesd204_rx_init rx_jesd_init = {
	.name = "rx_jesd",
	.base = RX_JESD_BASEADDR,
	.octets_per_frame = 2,
	.frames_per_multiframe = 32,
	.subclass = 1,
	.device_clk_khz = 2500000 / 40, /* (lane_clk_khz / 40) */
	.lane_clk_khz = 2500000, /* LaneRate = (M/L)*NP*(10/8)*DataRate */
};
 
struct axi_jesd204_rx *rx_jesd;
 
status = axi_jesd204_rx_init(&rx_jesd, &rx_jesd_init);
if (status != 0) {
	printf("error: %s: axi_jesd204_rx_init() failed\n", rx_jesd_init.name);
	return status;
}
 
status = axi_jesd204_rx_lane_clk_enable(rx_jesd);
if (status != 0) {
	printf("error: %s: axi_jesd204_rx_lane_clk_enable() failed\n", rx_jesd->name);
	return status;
}
 
status = axi_jesd204_rx_status_read(rx_jesd);
if (status != 0) {
	printf("axi_jesd204_rx_status_read() error: %d\n", status);
}

Code Documentation

Source code documentation for the driver is automatically generated using the Doxygen tool and it is available at:

Source Code

resources/tools-software/uc-drivers/jesd204/axi_jesd204_rx.txt · Last modified: 02 Nov 2023 08:58 by George Mois