Counter - bug / GPIO16

Moderators: grovkillen, Stuntteam, TD-er

Message
Author
Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Counter - bug / GPIO16

#1 Post by Shardan » 24 Jul 2017, 21:50

Hello all,

while prototyping a project I stumbled over two behaviours i want to ask about.

First, GPIO 16 and counter.
I did some testing with R148 and a self compiled ESPEasy 2.0.0 (sources of 07.07.17).
On both firmware versions the GPIO16 does not show any result, it remains on "0".
To make sure that there is no other problem I connected GPIO12 and GPIO16 together to
a signal generator with a 2Hz signal (2 square pulses/second). I can measure the pulse directly
at the pins of the ESP-12. GPIO12 works, GPIO16 with same settings does not.

Is the GPIO16 hardwired internaly in a way that the counter does not work? Software bug?

Second, I tried the mode settings of the 2.0.0 version ("LOW, FALLING, RISING, HIGH")
with the 2Hz signal as described above.
Falling and rising works as expected - at least LOW does nothting (HIGHJ not tested yet.

What did i misunderstand? What should be the result of HIGH / LOW setting?

Regards
Shardan
Regards
Shardan

Domosapiens
Normal user
Posts: 307
Joined: 06 Nov 2016, 13:45

Re: Counter - bug / GPIO16

#2 Post by Domosapiens » 25 Jul 2017, 00:21

Hello Shardan,
So happy to give some back (I learned a lot from your posts and comments).

Found in my notes:
GPIO-16 (D0): No internal pull-up possible; no PWM possible; no interrupt possible
My experience is that GPIO-16 uses polling.
During peak-load of the ESP, the response of GPIO-16 is low.
When I used it as back-light display switch, for the LCD module, response was varying.

I assume that your second question is related to that polling policy.
30+ ESP units for production and test. Ranging from control of heating equipment, flow sensing, floor temp sensing, energy calculation, floor thermostat, water usage, to an interactive "fun box" for my grandson. Mainly Wemos D1.

Shardan
Normal user
Posts: 1156
Joined: 03 Sep 2016, 23:27
Location: Bielefeld / Germany

Re: Counter - bug / GPIO16

#3 Post by Shardan » 25 Jul 2017, 19:29

Domosapiens wrote: 25 Jul 2017, 00:21 Hello Shardan,
So happy to give some back (I learned a lot from your posts and comments).

Found in my notes:
GPIO-16 (D0): No internal pull-up possible; no PWM possible; no interrupt possible
My experience is that GPIO-16 uses polling.
During peak-load of the ESP, the response of GPIO-16 is low.
When I used it as back-light display switch, for the LCD module, response was varying.

I assume that your second question is related to that polling policy.
Hm... i just tested with 1/10 Hz, a pulse every 10 seconds - no reaction on GPIO16 in any of the modes.
I assume that the counter plugin uses interrupts. As the GPIO 16 does not support interrupt
this would explain what's going on.

Thanks for the info

Regards
Shardan
Regards
Shardan

Who is online

Users browsing this forum: No registered users and 19 guests