This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

LP RM46 I2C and PCF8574 issues

Other Parts Discussed in Thread: PCF8574, HALCOGEN

for the sake of learning, trying to implement an I2C communication between Hercules LP RM46 and  PCF8574 (NXP) in write-only mode; I'm using the following settings:

PINMUX configuration in HalCoGen

in the global settings, I have bit count and count data; I read the manual but could not understand the use of "data Count"

Hercules and PCF8574

Hardware configuration in my pull-up resistors have 5KOhm , I have doubts whether it is necessary to apply the pull-up resistors in HalCoGen?

the code to write to the PCF8574 is:

#define PORT_BASE_ADDRESS 0x42 

                                         

void Write_PCF(unsigned char data_byte) 

    i2c_start(); 
    i2c_write(PORT_BASE_ADDRESS); 
    i2c_write(data_byte); 
    i2c_stop(); 
}

It's pretty simple, but do not know the right way to send the data using the functions provided by HalCoGen !!