Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.

EPCS Identifier

Altera_Forum
Honored Contributor II
2,550 Views

Does anyone know what a EPCS identifier is ? When I was erasing my EPCS device via the JTAG (via the SDK Shell) I got the following message :-  

 

nios2-flash-programmer --cable='usb-blaster [usb-0]' --epcs -base=0x00069000 --erase-all --debug 

Using cable "usb-blaster [usb-0]", device 1, instance 0x00 

Resetting and pausing target processor: OK 

Proceessor data bus width is 32 bits 

Looking for EPCS registers at addresses 0x00069000 (with 32bit alignment) 

intial values: xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx (where x = garbage) 

Not here:reserved fields are non-zero 

Looking for EPCS registers at addresses 0x00069100 (with 32bit alignment) 

intial values: xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx (where x = garbage) 

Not here:reserved fields are non-zero 

Looking for EPCS registers at addresses 0x00069200 (with 32bit alignment) 

intial values: 00000000 00000000 00000260 00000000 00000000 00000001 (where x = garbage) 

valid registers found 

EPCS signature is 0x12 

EPCS identifier is 0x202013 

No EPCS layout data - looking for section [EPCS-202013] 

Unable to use EPCS device 

Leaving target processor paused 

 

Can anyone help me with this problem ?
0 Kudos
6 Replies
Altera_Forum
Honored Contributor II
834 Views

The EPCS ID is the Silicon ID burned into the configuration chip. Does it consistently return the same ID, or does it change from read to read?

0 Kudos
Altera_Forum
Honored Contributor II
834 Views

schmuel, 

 

It looks like you're using a lead-free device. The flash programmer doesn't....yet, support these devices. 

 

You need to save the following text to <nios2_install>/bin/nios2-flash-override.txt: 

 

# EPCS1N (lead-free) sector_size = 32768 sector_count = 4 # EPCS4N (lead-free) sector_size = 65536 sector_count = 8 

 

Please report back with any further issues that you have. 

 

Cheers, 

 

- slacker 

 

[UPDATED]: Though I&#39;m not sure, you may have to modify the HAL flash abstraction commands....if you have a need to access the flash from your software.
0 Kudos
Altera_Forum
Honored Contributor II
834 Views

 

--- Quote Start ---  

originally posted by slacker@May 1 2006, 08:17 PM 

schmuel, 

 

it looks like you&#39;re using a lead-free device.  the flash programmer doesn&#39;t....yet, support these devices. 

 

you need to save the following text to <nios2_install>/bin/nios2-flash-override.txt: 

 

# epcs1n (lead-free) sector_size = 32768 sector_count = 4 # epcs4n (lead-free) sector_size = 65536 sector_count = 8 

 

please report back with any further issues that you have. 

 

cheers, 

 

- slacker 

 

[updated]:  though i&#39;m not sure, you may have to modify the hal flash abstraction commands....if you have a need to access the flash from your software. 

<div align='right'><{post_snapback}> (index.php?act=findpost&pid=14906)</div> 

--- Quote End ---  

 

 

Dear Slacker http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/laugh.gif http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/laugh.gif , 

Wow it works now !!!!!!!!!! But this is a very BIG slip up by Altera. They better put a patch in real quick - I wasted half a week on this ! Maybe you should put a post up informing all people who are using the EPCS devices that are lead free !  

 

Could you please give me more information on what you wrote :-  

 

UPDATED]: Though I&#39;m not sure, you may have to modify the HAL flash abstraction commands....if you have a need to access the flash from your software. 

 

Thanks again for the response and the help, now finnaly i can get on with the debug ! 

 

Shmuel
0 Kudos
Altera_Forum
Honored Contributor II
834 Views

Yeah.... I think it will be fixed soon. 

 

You can ignore my "UPDATE" statement. The HAL code does not need to be modified. 

 

- slacker
0 Kudos
Altera_Forum
Honored Contributor II
834 Views

Hi Slacker, 

 

I have just seen this same issue when using an EPCS64 boot-prom. 

 

Is this still an issue with the very latest versions of Quartus / Nios 6.0 sp1? 

 

TTFN. 

 

David
0 Kudos
Altera_Forum
Honored Contributor II
834 Views

Hello all, 

 

It seems we are having a similar problem using Quartus/Nios 6.1 with an EPCS64N and EP2C8Q208C7 and are getting the the following error using the command line tools to flash: 

 

$ nios2-flash-programmer --debug --base=0x00001000 --epcs NAVCON. flash Reading override file "c:/altera/61/nios2eds/bin/nios2-flash-override.txt" Using cable "USB-Blaster ", device 1, instance 0x00 Resetting and pausing target processor: OK Processor data bus width is 32 bits Looking for EPCS registers at address 0x00001000 (with 32bit alignment)  Initial values: 0001703A 04C00074 9801483A 9CFFF804 983FFD1E 0000203A  Not here: reserved fields are non-zero Looking for EPCS registers at address 0x00001100 (with 32bit alignment)  Initial values: 92400237 4A40100C 483FFD26 90000135 92400237 4A40200C  Not here: reserved fields are non-zero Looking for EPCS registers at address 0x00001200 (with 32bit alignment)  Initial values: 00000000 00000000 00000260 00000000 00000000 00000001  Valid registers found EPCS signature is 0xFF EPCS device doesn&#39;t support RDID command No EPCS layout data - looking for section Unable to use EPCS device Leaving target processor paused 

 

Our epcs base address as reflected in the memory map in SOPC Builder is 0x00001000. We initially had a problem using the Flash Programmer in the Nios IDE and were getting an error that there was a problem with our &#39;target board&#39;. We got this same error when using the Flash Programmer with the Nios II dev board and the standard.qpf example project. This led us to using the command line tools.  

 

We have verified the hardware, checked that the D-clock looks good when in AS mode (although we are flashing in JTAG mode), checked the doc "Making use of the EPCS Configuration Device" at http://www.fps-tech.net/docs/epcs-ug.pdf (http://www.fps-tech.net/docs/epcs-ug.pdf) as well as the other relevant thread "Erasing/Programming EPCS via NIOS" at http://forum.niosforum.com/forum/index.php?showtopic=3790 (http://forum.niosforum.com/forum/index.php?showtopic=3790

 

We are now assuming that we may have a problem with the RDID tag even though we are using an EPCS64N. Looking at the post in this thread concerning creating the nios2-flash-override.txt (originally from a .zip file from Altera), we assumed that to complete the table, it would look like the following: 

# EPCS1N (lead-free) sector_size = 32768 sector_count = 4 # EPCS4N (lead-free) sector_size = 65536 sector_count = 8 # EPCS16N (lead-free) sector_size = 65536 sector_count = 32 # EPCS64N (lead-free) sector_size = 65536 sector_count = 128 

 

This is a shot in the dark since we are guessing the RDID code. Altera&#39;s datasheet for the EPCS devices provides the &#39;sector_size&#39; and &#39;sector_count&#39; parameters. The datasheet does outline the bits used for the &#39;Silicon ID&#39;, but this is not consistent with the values in nios2-flash-override.txt for EPCS1N and EPCS4N. We tested this, with and without this file, as well as with and without the extra lines (most importantly for the EPCS64N), and had no success. 

 

When running the memory test code in the Nios IDE (from SDRAM) to verify the EPCS, we get the following:Enter the name of the EPCS flash device to be opened, or just press <enter> to open "/dev/epcs_controller") >epcs_controller -ERROR: Could not open epcs_controller Press enter to continue... 

 

We are assuming that the name to be specified here is the same as is shown in the SOPC Builder. We verified the syntax of this name by checking the .ptf. Is this assumption correct?  

 

Also, (not sure if this is relevant) we had a problem when adding an epcs controller in SOPC Builder which gave us an error that there was "No reference designator specified for module epcs_controller". On the Flash Memory tab in the Board Description Editor, we have specified that we are only using the EPCS controller and a hardware image associated with it. We found a thread that suggested a fix that involved manually editing the class.ptf file associated with our board description by adding parentheses after the CLASS name as well as filling in empty fields for the instance designator values. In our case the empty values were for a CFI Interface (which we don&#39;t have on our board or in SOPC Builder). This fix did not work for us.  

 

We found that if we removed the epcs_controller from SOPC Builder, re-generated, then added the epcs_controller back in, then re-generated again, this worked. 

 

Any advice anyone? Thanks in advance http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/smile.gif
0 Kudos
Reply