Chat freely about anything...

User avatar
By Luman
#93268 A GPIO pin designated as an output pin can be set to high (3.3V) or low (0V). Components are usually attached so that setting the output to high will allow current to flow to them, while setting the output to low won't. A GPIO pin that is designated as an input will allow a signal to be received by the Raspberry Pi.
User avatar
By eriksl
#93296 You cannot prevent any of the outputs/GPIO's to prevent from toggling at least a few times after boot. The reason for this is that these pins have multiple purposes, connected by a multiplexer. On boot, they're in their default function which it mostly not "GPIO" but stuff like "clock X output". The initial ROM and/or SDK code will re-assign their functions.

The only way to fix this is to engineer a "slow start" on your device, i.e. only react some few hundred milliseconds after power comes on. Or use an I2C remote I/O expander.
User avatar
By ChrisO
#93327 Well, _I_ cannot prevent this toggling, sure. The person who wrote the firmware probably could.
It you look at the schematics it _is_ a GPIO pin with a pull-up resistor, so a HIGH one and OUT.
So, I expect it to get HIGH without jumping up-and-down.
If I needed to add additional HW to correct this up-and-down I just say
goodbye to ESP8266-01 and use something else like Raspi-Zero with a relay-board. Is, BTW, what I'm currently using.
Linux doesn't touch the GPIOs level on boot. It's up to you to define not only IN or OUT but also initial level for OUT. Just simple and clever.
ESP8266-01 is a very nice small piece of HW, and it's a pity I would need to add twice as much HW to fix, IMHO, buggy firmware.

It is not a problem for me, I'm not forced to use it.
I found it really, really, cool, so small and so powerful thing.
And I cannot understand why it provides us with a useless GPIOs.

Regards,
Chris
User avatar
By ChrisO
#93329
Luman wrote:A GPIO pin designated as an output pin can be set to high (3.3V) or low (0V). Components are usually attached so that setting the output to high will allow current to flow to them, while setting the output to low won't. A GPIO pin that is designated as an input will allow a signal to be received by the Raspberry Pi.


Thanks for the explanation, Luman, even if I didn't learn much more then I already know ;-)
I think you didn't carefully read my problem description.