This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

PCF8574A IO Expander with nRF52-DK

Hi,

I'm trying to use PCF8574A IO Expander with a nRF52-DK board to display characters on an HD44780 LCD. I noticed that I have to use the function nrf_drv_twi_tx(). Since PCF8574A doesn't have a register address, how do I send commands and text to the LCD?

Thanks

Parents
  • The PCF8574A has an address, it has to have an address, it's an I2C device, I2C requires things to have an address. The address is whatever you set up on the A0-A2 pins.

    So you give the command the address of the expander and write a byte of data.

    I do have to ask however, since you have an nRF52 development kit which has masses of output lines just begging to be used, why do you need a port expander? Port expanders are for arduinos which come with about 1 1/2 pins available.

  • Yeah, I've never worked with ARM core processors before nor Nordic SDKs; so, I'm trying to get my code working in blocking mode first, and if successful, then I'll try to use twi_handler later. I'll most likely have more questions about how to use a handler later.

Reply Children
No Data
Related