You are here

Using UART and I2C together | Cypress Semiconductor

Using UART and I2C together

Summary: 1 Reply, Latest post by Bob Marlowe on 15 Jan 2016 01:35 AM PST
Verified Answers: 1
Last post
Log in to post new comments.
CYang's picture
14 posts

I have 2 sensors, and oxygen sensor that communicates through uart and an accelerometer that uses i2c. Both works correctly by themselves but when I try to run them together, I can no longer read from the accelerometer. I was wondering if psoc 4 ble allows for one uart and one i2c to run at the same time. They are both scb blocks, one configured for i2c and the other for uart. I know there is a dedicated uart block but we need that for another sensor that is also using uart.

user_1377889's picture
9294 posts

When you place components onto the topdesign schematic and successfully build the project you may control via the "Resources" tab the complete usage. I2C and UART will go together.

Some pitfalls coming to my mind are

  • Float formatting
  • Buffer overflows
  • Bad interrupt handling

An easy check could be to put the I2C handling into a critical section (CyEnterCriticalSection()) to see if something changes.



Log in to post new comments.