cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

Anonymous
Not applicable

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.

0 Likes
Reply
1 Solution
Esteemed Contributor II

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

View solution in original post

0 Likes
Reply
7 Replies
Esteemed Contributor II

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

View solution in original post

0 Likes
Reply
Anonymous
Not applicable

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?

0 Likes
Reply
Esteemed Contributor II

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

0 Likes
Reply
Anonymous
Not applicable

oh.. thank you.

   

How to correct this error?

   

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

0 Likes
Reply
Esteemed Contributor II

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

   

 

   

Bob

0 Likes
Reply
Anonymous
Not applicable

i want psoc as slave

0 Likes
Reply
Esteemed Contributor II

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

   

 

   

Bob

0 Likes
Reply