Jump to content
  • 0

Communication with Pcam 5c - 16 bit address


poiuyt

Question

Hi,

I have a question, I am trying to design my own Zybo Z7-20 Pcam 5C project and I have a problem with the SCCB (I2C like) communication. I am trying to develop my own I2C module in the PL (I don't want to use the PS of the Zybo Z7) but contrary to what the I2C protocol requires, the register adresses of the OV5640 camera are on 16bits (instead of 7bits in I2C protocol). So I don't know how to address the registers. I also have to communicate if the transaction is a read or a write with a R/W bit.

I studied the sdk of the demo Pcam 5C but did not understand how the communication was done. The SCCB Application Note doesn't explain it either.

Does anyone have an idea ?

Thank you for your help

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0
17 minutes ago, poiuyt said:

Thank you for your quick response ! Is there an ACK bit between the two bytes ?

Absolutely. The sequence should look something like this: Start -> Pcam address 7bits + Write bit -> ACK -> Register Addr High 8 bits -> ACK -> Register Addr Low 8 bits -> ACK -> Write Data 8 bits -> ACK -> Stop.

The above sequence is meant for a Write transaction. For Read transactions you have to first WRITE the register address and then re-address the Pcam but this time ending in Read bit like so:

Start -> Pcam address 7bits + Write bit -> ACK -> Register Addr High 8 bits -> ACK -> Register Addr Low 8 bits -> ACK -> Repeated Start -> Pcam address 7bits + Read bit -> ACK -> Read Data 8 bits -> NACK -> Stop.

Edited by thinkthinkthink
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...