Upgraded from v0.36 to v0.37 last week, today to version v0.38.
Since v0.37 unable to get Dual State Buttons to work correctly. The demo Arduino program (part of the v0.7 library) does even not work anymore. My UNO, Mega2560 and WeMos D1 all show this behaviour.
The variable "dual_state" returns in the CompDualStateButton sample program most of the time a value of 1074810966, its only the first reading after power off and back on of the display that dual_state returns a "1" -the correct- value.
Is it just me that observes this strange behaviour? Help appreciated!
I will open a new topic thanks Patrick.
I guess Help is no longer needed.
Perhaps create a new thread in Free Chat
Titled appropriate and described specifically what you request
Trailing at Unrelated Bug Reports
- not the right manner
Trailing at year old and 2 year old posts on 20th page
- not in the right manner
When you have this new thread created
I will try to help you work through your issue
And clean up this misplaced from the Bug Report.
I am sure it is appreciated - How is this related to a Bug Report?
Surely, those following to find example of ESP-12 UART
will not associate such with incorrect value of v0.38 Dual State.
Ensure you are using pins for MCU Hardware UART.
Hardware UART will be more reliable and less pain.
Peter's issue was most likely an Arduino AVR issue
- bitshifting uint32_t causing invalid results, or uninitialized.
Your issue of establishing communications is unrelated.
How you solve the problem, I am using Wemos D1 mini as MCU and I could not get a proper running SoftwareSerial connection. Receiving data from Nextion to Wemos is not working for me.
I use HMISerial(4, 5) pins.
NO BUG but my mistake!! I messed things up using Software Serial.
That sounds like the library didn't initialize the variable and relied on mem space being zeroed.
You may need to set the dual-state on startup to a default value to ensure this is not the case.
Also since v37, integers are no longer unsigned, and negative values are possible.
32 bit unsigned range 0 .. 4294967296
32 bit signed range changes to -2147483648 to -2147483647
variables uninitialized may be playing havoc with these changes
The library should be checked for these conditions as well.
Poor practice to rely on conditions that you have not personally set.