Start a new topic

FMC667 Board support package test example uart_os init problem

Hi,

We just received the FMC667 mezzanine board which we have fitted to a Xilinx vc707. I have built and compiled the firmware for the FPGA, ublaze and host using the plugin sources supplied.
When I run the ublaze uart_os application I get the following problem in the init() function of that code. Here is the Debug trace output:

[size=0pt][font=Consolas][color=black]    init_leds() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Initialize the leds peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Configure the leds peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_leds() - Exit[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]  main() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]Initializing the operating system, please wait...[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]Watch below lines on LCD[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]  Initialize  [/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]      System    [/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]  init() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_uart() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Initialize the UART peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Attach Send/Receive handlers to the peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Enable interrupts in the UART peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_uart() - Exit[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_i2c() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Initialize the i2c peripheral[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Setup i2c handlers[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_i2c() - Exit[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_intc() - Entry[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Initialize the interrupt controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Connect default UART interrupt routine to the controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Connect I2C interrupt handler to the controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Start the interrupt controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Enable UART interrupts in the interrupt controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    Enable I2C interrupts in the interrupt controller[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]    init_intc() - Exit[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]  Enable interrupts in the Microblaze processor[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]Configuring i2c bridge (PCA9548) for VC707 - HPC1[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]Register 0xF4 in ADM1064 is : 0[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]Could not configure write to ADM1064, the error was : 0x-2[/color][/font][/size][size=0pt][/size]
[size=0pt][font=Consolas][/color][color=black]  main() - Exit([/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black] [/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black]Please can you advise what the issue is and how I can solve this? Since the ublaze is exiting everytime, I am unable to get any further with this first test example and certainly can’t connect from the host[/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black] [/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black]Just to check that it wasn’t an FPGA build problem my end, I also used the FPGA bit image from the supplied vc707 hardware definition available in the bsp (C:\Program Files (x86)\4DSP\4FM Core Development Kit\Plug-Ins\FMC667\Sources\uBlaze\vc707_hw), i.e. the FPGA image built by 4DSP, and I get the same behaviour.[/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black]Digging a little deeper in to the uart_os code, the failure code returned is specific to reading the ADM1064 device registers on the FMC667 card using the I2C bus.[/color][/font][/size]

[size=0pt][font=Consolas][/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black]Regards[/color][/font][/size]

[size=0pt][font=Consolas][/color][/font][/size]
[size=0pt][font=Consolas][/color][color=black]Dom
[/color][/font][/size]

This topic is being closed because the issue is considered as resolved by 4DSP. Feel free to create a new topic for any further inquiries.
Dom,

Perfect!

Best Regards,
Arnaud
Thanks Arnauld

The version of ISE we are running is 14.6, so that should be ok as per your documentation. I will try circumventing the export form SDK as you suggest, but for now that default FPGA  image is perfectly adequate for my early development requirements which mostly involve shifting data across the  PCIe peripheral and nothing todo with the I2C bus. Thanks for your help

Dom
Hello Dom,


This might be required to ISE versions also. I believe that communicating with the power sequencer is one of the first operation, it sounds like you don't have i2c on your compiled image.


I know that there are bugs in ISE where the export to SDK does not really works You should replace the .bit file exported by ISE to EDK with the one created by ISE and that might work.


Communication problems with the ADM1064 indicates no i2c communication in the design.


I hope that helps,
Arnaud
Hi Arnauld

As requested I loaded the following image:
C:\Program Files\4DSP\Common\Firmware\Recovery402_vc707_fmc667_hpc\402_vc707_fmc667_hpc_495t.bit

I can confirm that the LCD display shows "FMC667 - OS Ready"  and that the GPIO LED's are lit as per Figure 62.
The FMC667 Card is fitted to FMC1 (J35)
There is one blue LED lit continuously on the FMC667.

I ran the FM667 Test Peripheral Application against this default image as per seciotn 12.1.11:
C:\Program Files\4DSP\FMC Board Support Package\Bins\fmc667_microblaze_test_peripherals.exe
The first time I ran the test:
10 tests passed and one failed; the DDR 3 test failed with status code 1 = 0x00 and status code 2 = 0x3c
The second time I ran the test:
11 tests passed.

With the eception of the one test failure above, it would seem the physical hardware looks ok, and my problem lies with my compiled FPGA image generated by StellarIP as well as the image in the BSP at
C:\Program Files (x86)\4DSP\4FM Core Development Kit\Plug-Ins\FMC667\Sources\uBlaze\vc707_hw\system.bit?

Regards

Dom
Dear Sir,


Can you please try to run the default .bit file (it has the microblaze inside) as per the 4FM Getting Started Guide?


The bit file is located under C:\Program Files\4DSP\Common\Firmware\Recovery\355_vc707_fmc667_lpc or 402_vc707_fmc667_hpc.


When running the bit file you should get display on both VC707 LCD and the GPIO LEDs, after a successful init, four LEDs should be LIT as per figure 62/63 in the manual.


Can you confirm that this is working? Recompiling software/firmware can surely cause issues and first of all you want to make sure to hardware is fine. We use these bitfiles for our factory tests so we know they are fine.


Can it be that you have the FMC667 in the wrong HPC slot? It should be on VC707's FMC1 (J35).


Can you also check the LED status on FMC667 and let me know how it looks like?


Best Regards,
Arnaud