cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 4 MCU

Anonymous
Not applicable

I'm trying to send 3 bytes of data to a DAC, MAX5217, trough I2C. But I can't seem so send more than 2 bytes before the communication stops.

   

I'm doing:
            temp = I2CM_I2CMasterWriteBuf(I2C_SLAVE_ADDRESS, (uint8 *) sample,
                                        WR_BUFFER_SIZE , I2CM_I2C_MODE_COMPLETE_XFER);

   

With WR_BUFFER_SIZE set to 3,  but I only see the address + the first 2 bytes of my data with an oscilloscope. Setting the WR_BUFFER_SIZE to 1, sends 1 byte, anything above 1 sends 2 bytes.

   

Any ideas?

0 Likes
Reply
1 Reply
Honored Contributor II

Here is an example project that should help you understand the I2C process. It also contains a PDF on the I2C example.

0 Likes
Reply