ZC706开发板SI5324配置

ZC706开发板上的SI5324需要通过I2C配置,官网找了一圈,只有VC709和KC705的例程,都是基于MICROBLAZE的,改到ZC706上问题也不大,准备动手这际,转念一想,何不去看一下ZC706的BIST DEMO,果然,rdf0240-zc706-bist-c-2015-1里包括了SI5324的测试代码
打开xiicps_si5324_intr_example.c
1.将开始地址由134改为0

#define EEPROM_START_ADDRESS    0//134

2.增加写寄存器代码

// Write Reg 0 to set BYPASS
WriteBuffer[0] = 0;
WriteBuffer[1] = 0x16; // 0x16 sets Bypass mode; 0x14 sets non-Bypass mode.
Status = EepromWriteData_si5324(2);
if (Status != XST_SUCCESS) {
    xil_printf("Write to Reg 0 FAILED\r\n");
    return XST_FAILURE;
}

你可能感兴趣的:(FPGA)