Need library for DIODES PI4IOE5V9539

Trying to get a 16ch GPIO expander that uses DIODES PI4IOE5V9539 working.
Prefer not writing my own library if I don’t have to. Searches have not revealed anything.
Anyone have or know of a library for this?

If I’m reading datasheets correctly, the Diodes PI4IOE5V9539 just “magically happens to be” equivalent in terms of I2C registers to the TI or NXP PCA9539. They even end with the same numbers.

TI PCA9539 registers

DIODES PI4IOE5V9539 registers

They even have the same prefix for the I2C address (last two bits are configurable via the A0 and A1 pins of the devices)

So really, you should be able to use a library like https://github.com/AD0ND/PCA9539 in the exact same way with no changes.

WOW! That was fast! I’ll take a look. Thank you so much!

https://en.visvie.com/hot/PI4IOE5V9539-Replace-PCA9539.html further confirms my suspicion. They even have 1:1 the same pinout.