You are here

SPI Interrupt | Cypress Semiconductor

SPI Interrupt

Summary: 7 Replies, Latest post by Bob Marlowe on 29 Sep 2016 08:06 AM PDT
Verified Answers: 1
Last post
Log in to post new comments.
creative's picture
User
46 posts

What are the SPI internal interrupt in psoc5lp ? Does the internal interrupt mean those status reflected on status register?if not then where can i find details about internal interrupt? Does the predefined Tx and Rx interrupr are those which is visible in configure tab?

Thank you.

user_1377889's picture
User
10708 posts

The internal interrupt handles sending and receiving from the internal buffer which size you specified. Internal interrupts do not work together with the Rx and Tx interrupts, you have to choose one internal or external. Yes, the rx and tx_interrupt are the signal to which you may connect an isr component to.

Easiest setup: Set both buffers large, 2 to 5 times your normal message size. Do not spend time between sending single bytes, or the ss line may go high. Check for transmission completed by checking GetRxBufferSize() for the expected value.

 

Bob

creative's picture
User
46 posts

thanks bob.

One more thing is if i write command say SPIM_WriteTxData(data); and let data be defined like uint8 data=5;

then Is the ascii value of 5 will be sent over SPI channel?

user_1377889's picture
User
10708 posts

Of course not! the value will be 0x05. When you want to send an ascii 5 you must set data to 0x35

Another choice will be to use sprintf() to convert to ascii and send the resulting string over your interface.

 

Bob

creative's picture
User
46 posts

oh.. thank you.

How to correct this error?

Build error: 'SPIS_STS_SPI_DONE' undeclared (first use in this function)

user_1377889's picture
User
10708 posts

Use the master constant, not the slave: SPIM_STS_SPI_DONE (just a guess)

 

Bob

creative's picture
User
46 posts

i want psoc as slave

user_1377889's picture
User
10708 posts

Then check, if your component name is "SPIS" and not "SPIS_1"

 

Bob

Log in to post new comments.