UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Visitor ravi87
Visitor
6,166 Views
Registered: ‎01-03-2010

spartan 3an atmel spi

I am dng project on spartan 3an,Currently working on atmel SPI flash.I want to have communication between FPGA as MASTER and ATMEL SPI as SLAVE and the result be dispalyed on HYPERTERMINAL.I have tried but not got any outout dispayed on the hyper terminal.I also studied U332 & U333 also. So,please help me in getting the output.

 

Hoping for the response

0 Kudos
8 Replies
Explorer
Explorer
6,159 Views
Registered: ‎07-27-2009

Re: spartan 3an atmel spi

Hi,

 

Assuming your project is an interface between RS232 (Hyperterminal) and SPI check the following:

  • can you output anything on your Hyperterminal; check the UART settings (start/stop bits, number of bits, baudrate, parity, hardware handshake, xon/xoff); use a scope to check the connection and voltage - a scope with UART decoding will help a lot; have you used the correct cable (nullmodem or not); ...
  • use a scope to view the SPI interface. A scope with SPI decoding or logic analyzer functionality will help a lot. Do something simple first like read the ID code of the SPI flash.
  • Did you configure the correct polarity for the flash and SPI interface. Does the FPGA assert the correct chip select line.

Cheers,

Johan

0 Kudos
Visitor ravi87
Visitor
6,150 Views
Registered: ‎01-03-2010

Re: spartan 3an atmel spi

Thanx for the reply,

                                 I haveused null modem and  UART  is working,the data is displaying on the hyper terminal.coming to SPI  there is no communication taking place from hyper terminal to computer and vice versa.I have checked by clicking the batch file "instal spi flash programmer.bat"  but its not working.I have selected the select line m(0..2) as 110 too. I am unable to find out the problem.So, plz help me in getting out of this.

0 Kudos
Visitor ravi87
Visitor
6,128 Views
Registered: ‎01-03-2010

Re: spartan 3an atmel spi

A correction to be made.I have taken select lines m{2..0} as "001"  correctly as mentioned in the pdf.Can I get a code for displaying the device ID in assembly language.Help will be appreciated.
0 Kudos
Historian
Historian
6,114 Views
Registered: ‎02-25-2008

Re: spartan 3an atmel spi


ravi87 wrote:
A correction to be made.I have taken select lines m{2..0} as "001"  correctly as mentioned in the pdf.Can I get a code for displaying the device ID in assembly language.Help will be appreciated.

Assembly language for what processor?

----------------------------Yes, I do this for a living.
0 Kudos
Explorer
Explorer
6,113 Views
Registered: ‎07-27-2009

Re: spartan 3an atmel spi

ravi87,

 

I have no idea what your boards looks like, which CPU is on the board or on the FPGA, etc etc etc.

 

I suggest you read the datasheet of the SPI flash, of the SPI interface module (on the FPGA?), of the PCB and of the CPU/MCU/... Try to simulate this; write some C code and compile that to assembly.

 

Cheers,

Johan

0 Kudos
Visitor ravi87
Visitor
6,107 Views
Registered: ‎01-03-2010

Re: spartan 3an atmel spi

I am using pico blaze processor for SPI comm.I have writtten code in assembly by creating a new folder .In that new folder i have  wriiten code in a note pad and saved it as .psm and in that folder i added KCPSM3 files. After that i have run that .psm file in command window where i got .vhd file which i replaced in the program.This is what i have read and i have done.  You said that to try for reading spi flash(atmel) IDcode. Can u provide me the code , It will be very help ful to me.
0 Kudos
Explorer
Explorer
6,097 Views
Registered: ‎07-27-2009

Re: spartan 3an atmel spi

You should be able to find the datasheet for the SPI flash. It should specify the operations the device supports.
0 Kudos
Visitor ravi87
Visitor
6,078 Views
Registered: ‎01-03-2010

Re: spartan 3an atmel spi

As ur suggestion of writting the code in C and running it in the assembler.I want to know whether there will be an PICO BLAZE COMPILER.If it is where can i find it.
0 Kudos