Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
12 years ago

Programming an EPCS4 using JTAG and Quartus II + SFL

Hello,

I am having problems trying to program an EPCS4 attached to a Clyclone IV EP4CE6F17I7 with the JTAG interface (and a USB-Blaster). The EP4CE6 is in a JTAG chain with an Atmel AT91SAM9261 Microcontroller, as follows:

TDI -> AT91SAM9261 -> EP4CE6 -> TDO

The EPCS4 flash device is attached to the EP4CE6 with AS configuration scheme (MSEL0=0, MSEL1=1, MSEL2=0).

Programming the EP4CE6 itself works fine, but not the flash device. I am using the method described in AN370, i.e.:

1) Convert .sof file to .jic file (p 11)

2) Program the flash using Quartus II programmer and .jic file (p 17)

I get the messages:

Info (209060): Started Programmer operation at Fri Jan 31 13:25:55 2014

Info (209016): Configuring device index 2

Info (209017): Device 2 contains JTAG ID code 0x020F10DD

Info (209007): Configuration succeeded -- 1 device(s) configured

Error (209025): Can't recognize silicon ID for device 2

Error (209012): Operation failed

Info (209061): Ended Programmer operation at Fri Jan 31 13:25:56 2014

Testing the JTAG chain using the JTAG Chain Debugger gives this:

!Info: JTAG chain connection is good. Detected 2 device(s)

!Info: Device 1: AT91SAM9261 (USERCODE: - )

!Info: Device 2: EP3C(10|5)/EP4CE(10|6) (USERCODE: 0xFFFFFFFF)

Note: I am using Quartus II 12.0 SP2.16

Thank you for your help,

Regards,

Alex

4 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    It's possible that Quartus programmer is confused by the other device in the chain.

    I use another method to flash an EPCS with a .jic file:[list][*]begin with a FPGA without the SFL image

    [*]click "Autodetect". You should see both your devices

    [*]if the atmel is identified as "UNKNOWN", edit it and give it a name. Strangely when the Quartus programmer sees an "UNKNOWN" component in the chain it is capable of configuring an FPGA but can't flash an EPCS

    [*]left click and then right click on the FPGA (yes I know, it doesn't work if the FPGA isn't selected before you right click...) and select Edit... > Attach Flash Device

    [*]In the list, select your EPCS

    [*]You should now have a line for the EPCS. Put your .jic file in the "File" field of the EPCS

    [*]Select "Program/Configure" on the FPGA line and "Program/Configure" and "Verify" on the EPCS line

    [*]Click "start"[/list]
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi Daixiwen,

    Thanks for your quick reply. I tried your method, following exactly each step, but got the same error message at the end :-(

    Note that I am providing the proper .bsd file for the microcontroller to the Quartus Programmer.

    Alex
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi again,

    Just wanted to give a follow-up to my problem. It seems actually to be my mistake: after double-checking I noticed that there has been some signal swapping on the PCB of our prototype, so the configuration flash did not get the proper signal (nCSO) on its Chip-Select pin. I have re-wired the faulty signal. It's not working yet 100% (it is programming the flash OK but fails to verify) but I have some hope.

    Alex
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    It could be a good idea to check your signals with an oscilloscope, both the JTAG signals and the EPCS signals. Look especially for bounces or crosstalk on the clock signals.