- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I'm working on a CY8C4247, and this is the first time I use a Cypress microcontroller.
I'm trying to set up a I2C communication where my micro is the slave. I have found only examples where the interrupt aren't used (the code use polling).
I need to have the code as faster as possible, so I have enabled the interrupt, but as explained on your application note the callback is triggered every time one of the several I2C event happen.
I want to be able to understand which event triggered the interrupt, so I need to know more about the I2C registers.
I have tried to find a complete datasheet, but I have found only a brief datasheet (around 50 pages without register description).
Is it possible to find the information I need about the I2C somewhere ? Can someone send me the link for a complete datasheet and an example of code that use the I2C interrupt, if it exist ?
Thank you
Riccardo
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here is register map of PSoC4200 BLE,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You are here in the world of PSoCs which differs a bit from other micros. There is real hardware inside as the SCBs (Serial Control Block) from which the i2c interface is made of. Since the nature of I2C is transfering multiple bytes, all the handling is done internally. Polling is the usual way to be informed of a transfer completed. For I2C protocol there was never an interrupt defined, so there is none.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
thanks for your quick replay.
From the AN90799 page 3 : "The following events generate an interrupt: arbitration lost, slave address match,
start/stop detect, bus error, byte/word transfer complete, TX FIFO not full, TX/RX FIFO
empty, RX FIFO not empty, RX FIFO overrun, and RX FIFO full".
Can you help me to understand why an interrupt is associated at those event, if is it impossible to understand which one triggered
the interrupt ? I'm trying to understand the PSoCs world.
Thank you
Riccardo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here is register map of PSoC4200 BLE,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you !