Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pcf8574 not working #762

Open
QDUNI opened this issue Sep 22, 2020 · 3 comments
Open

pcf8574 not working #762

QDUNI opened this issue Sep 22, 2020 · 3 comments

Comments

@QDUNI
Copy link

QDUNI commented Sep 22, 2020

Hi, I have an esp8266ex and a pcf8574at.
Now im trying to use the pcf8574 library but with no succes.
can you show me how I need to use it?

addr = 0x38

I want all the ports set to output so I can write them on and off.
I started with initializing every pin as output and then turn them all off. but with no succes.

pcf8574_gpio_write(&dev, 0, false); pcf8574_gpio_write(&dev, 1, false); pcf8574_gpio_write(&dev, 2, false); pcf8574_gpio_write(&dev, 3, false); pcf8574_gpio_write(&dev, 4, false); pcf8574_gpio_write(&dev, 5, false); pcf8574_gpio_write(&dev, 6, false); pcf8574_gpio_write(&dev, 7, false; pcf8574_port_write(&dev, 0);

@rangelflavio
Copy link

enable debug on i2c driver - make a loop to view and try each write address - some ic's come with another address

@QDUNI
Copy link
Author

QDUNI commented Nov 6, 2020

Do you have an example ?

@QDUNI
Copy link
Author

QDUNI commented Nov 6, 2020

If I use the Arduino library the address is 0x38... Im also able to use the pcf8574 with Arduino.
I want to make it work with esp open rtos, because of homekit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants