cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

Anonymous
Not applicable

I'm using PSOC5LP for real time application

1)I would like to transmit (only transmit, not receive) 4 bytes using I2C, but I would like to send them at once in a buffer and then switch to other tasks, without any interrupt to the CPU (because the CPU should run critical timing, real time tasks at that time). I dont care about any response/ result/error of the I2C. Just to transmit them (using the CPU of cource) at once without any additional CPU resources/interupts. May I use the DMA? Is there an option for FIFO for the I2C? What is the best solution to this problem?

2) same question for SPI: I would like to transmit (only transmit, not receive) 4 bytes using SPI, but I would like to send them at once in a buffer and then switch to other tasks, without any interrupt to the CPU (because the CPU should run critical timing, real time tasks at that time).  What is the best solution to this problem?

thanks

0 Likes
7 Replies
JoMe_264151
Expert II

The FIFO buffer is exactly 4 bytes deep in a PSoC5. To transmit 4 bytes via i2c you need 5 bytes, one more for the address.

Using SPI will not need the address and so can handle the complete transfer within the hardware without CPU intervention.

Bob

0 Likes
Anonymous
Not applicable

Does the I2C fix function module include such FIFO?

Does the I2C UDB module include such FIFO?

0 Likes
JoMe_264151
Expert II

Both I2C implementations are using interrupts and have got no fifo,

Bob

0 Likes
Anonymous
Not applicable

So what is the preferred way in  order to implement I2C which doesn't consume CPU resources after sending the buffer? Should I use DMA?

0 Likes
JoMe_264151
Expert II

Use SPI, I2C will need CPU interventions

Bob

0 Likes
Anonymous
Not applicable

Unfortuntly, one of my device is using I2C.

What is the best operation method for it without interputing CPU?

Can I use DMA as the interrupt handler?

0 Likes