PCA9539PW Output issue

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PCA9539PW Output issue

544 Views
yashveerrampars
Contributor I

Currently using the PCA 9539PW IO expander. Now I can communicate with it and tell it to output individual outputs (works perfectly). However problems arise when I wish to write to pins 7 and 11. What actually happens is that Pin 8 and 11 get set instead. Then when I set Pin 8 and 11(just to see what happens), Pin 7, 8 and 11 are all set! 

That seems to me like it is erroneous behavior. Like I mentioned before, I can set individual pins, problems arise when I wish to set 2 pins at a time!

0 Kudos
1 Reply

488 Views
david_diaz
NXP Employee
NXP Employee

Hello,

I assume that you are setting the corresponding pins as outputs and that you are using the registers 2 and 3 for the logic levels (Note that if some pin is set as input, the bit values in this register has no effect).

In this case, please review the image below:

As we can see, the pin 11 corresponds to the IO0_7 and so on.

Could you please verify that you are configuring the correct pin? Could you please share your initialization process?

Regards,

David

0 Kudos