ESP-Home, PCF8754, PWM

Hello all!

Is it possible to use the PWM-Output-Component on Pin’s that are provided via the PCF8754-Component?
If YES: How would this be configured?

Best regards and thanks for any help,
Peter

Hello. Been investigating that and it seems the PCF8754 is ON/OFF only.

I would appreciate someone contradicting me because I have a use case for it…

Hello. I can NOT contradict to you, because all try’s to configure went bad… AND: I’d also a use case… :innocent:

Guys… Stuff like this shouldnt be a mystery. Pretty much everything has a data sheet or spec sheet that not only answer questions like this but, its where you learn how to use the thing. Its in those data sheets where it explains for example the PCF8754 is not capable of sending pwm as well as the key detail that the pins can only source a tiny bit of current and you should configure them to sink current or use them as Active Low gpio’s.

Depending on what your doing, you have several options for pwm. The SX1509 for example is a 16 channel and it can do pwm and has normal gpio function. If you only need pwm, the PCA9685 is a 16 channel pwm driver and is great for stuff like big led lighting projects.

1 Like

Unfortunately, I’m not a professional electronics technician; just a hobbyist who learned a little about electronics many years ago…So I have VERY little idea what “components” even exist.
With that said, I’m happy with your advice! THANK YOU!

most of us are hobbyists as well. You don’t need to be a professional, you just need to look at the esphome documentation. It’s all broken down into categories and there’s even a search box. Just about anything you need is there, you just gotta go look.

Of course you’re right that searching, browsing, reading can prevent more or less stupid questions (as mine)… BUT: If I don’t know the HARDWARE components that CAN fulfill the desired function, reading about them is quite difficult .

You’re looking for a gpio expander that can do pwm so, you do a search for “gpio expander” and there you will get a list of all the HARDWARE components available. It’s really very simple.
https://esphome.io/search.html?q=gpio+expander

I wasn’t implying your question was “stupid” either. It’s incredibly overwhelming when you’re just getting into all of this. I remember those days very well and still have them from time to time. I rushed out and bought things to only figure out later that they wont work or something would work better, I wasted my time and money and 95% of it could have been avoided by spending a little time checking documentation first. Helping you avoid the common mistakes is my only intention. There is a real value in searching and browsing the documentation even if it’s just doing it without a specific purpose. Did you find an expander that fits your needs BTW?

I didn’t mean, YOU were implying a “stupid” question… In german language there is a more or less stupid saying: “There are no stupid questions… Only stupid answers”… And that is meant in a funny sense!!! And in this meaning mine was meant also…
You describe MY behavior pretty well! :innocent: I’ve already ordered a “PCA9685” … This sholuld do what’s my intention… drive up to 16 LED’s to show the status of some binary sensors… PWM to dim the LED’s to any pleasant brightness and/or to show a third state of a sensor…

The pca9685 is very nice. I used to use one to drive all my outside landscape lights and accent lights. I broke the project into 2 smaller pieces and dont use it now, but it works good and id highly recommend it over pwm expanders. Just keep in mind its only for outputting digital signals or pwm, you cant read sensors through it.

These are great too if you dont need an expander. You can drive a ton of things with mosfets.
https://www.amazon.com/3-7-27VDC-4-Channel-Driver-Amplifier-Circuit/dp/B07QGXY7F3/ref=asc_df_B07QGXY7F3/?tag=hyprod-20&linkCode=df0&hvadid=459440176747&hvpos=&hvnetw=g&hvrand=1871631736004952973&hvpone=&hvptwo=&hvqmt=&hvdev=m&hvdvcmdl=&hvlocint=&hvlocphy=9016042&hvtargid=pla-949854341482&psc=1&mcid=51dbdb74c95a3691a3f2b885be9f411c&gclid=Cj0KCQiA2KitBhCIARIsAPPMEhIxS1idKfrN6aA7UJm7el-YZKbwvUntZvBkgXtpnBxeXBsD6s3DB2AaApUkEALw_wcB