autorefresh in 1.34.2 Esp8266

Here we can discuss about the problem found
Zim
Posts: 107
Joined: Mon Feb 08, 2021 9:15 pm
Has thanked: 83 times
Been thanked: 46 times

autorefresh in 1.34.2 Esp8266

Post by Zim »

Is it possible autorefresh is not working in 1.34.2 on a Esp8266?
I tried the below test (thanks PeterN) and it doesn't work on Esp8266

'AUTOREFRESH TEST
'autorefresh seems to fail in ANNEX32 1.43 CAN BLE
' This code works in prior version
text$ = "Start"
CLS
HTML TEXTBOX$(text$)
autorefresh 2000 'should update HTML every 2 seconds
timer0 1000, SET_TEXT
Wait

SET_TEXT:
text$ = time$
'refresh 'updates HTML every 1 second if not commented
Return



Thanks
Zim
User avatar
Electroguard
Posts: 272
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 54 times
Been thanked: 127 times

Re: autorefresh in 1.34.2 Esp8266

Post by Electroguard »

I think autorefresh needs to follow CLS else it gets cancelled, so...
CLS
AUTOREFRESH

Edit: Yeah, looks ok, but maybe it doesn't like being followed on the same line by the comments?
User avatar
Electroguard
Posts: 272
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 54 times
Been thanked: 127 times

Re: autorefresh in 1.34.2 Esp8266

Post by Electroguard »

I've just tried your code on Annex32 WiFi BLE 1.43.7 and it worked ok on that.
Jan Volk
Posts: 15
Joined: Wed Mar 03, 2021 1:35 pm
Been thanked: 9 times

Re: autorefresh in 1.34.2 Esp8266

Post by Jan Volk »

I tested it with example from help document with Annex WiFi RDS 42.2 and 43.2


CLS ' annex wifi RDS 42.2 wlog
led = 0
a$ = BUTTON$("Button1", jump1, "but1") ' "but1" is the ID
a$ = a$ + LED$(led)
HTML a$
AutoRefresh 100 ' sync each 100 milliseconds
Wait ' pause waiting for the event

Jump1:
wlog "Clicked on Button1"
led = 1 - led ' invert the variable
Return



log
cls
html<button data-var='jump1' id='but1' onclick='cmdButton(this)'>Button1</button><svg height='20' width='30'><circle cx='15' cy='10' r='9' stroke='black' data-var='led' fill='red' /></svg>
AUTOREFRESH:100
Clicked on Button1


' annex wifi RDS 43.2 wlog test

log ' wlog to running



log
Clicked on Button1 ' cliked on button1 in the output
Zim
Posts: 107
Joined: Mon Feb 08, 2021 9:15 pm
Has thanked: 83 times
Been thanked: 46 times

Re: autorefresh in 1.34.2 Esp8266

Post by Zim »

Hi
I took out all "cls" and tried autorefresh in different locations on my script...no luck.
This is on a ESP8266 not Esp32. Is there a newer version than 1.34.2 for Esp8266?

Thanks
Zim
User avatar
Electroguard
Posts: 272
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 54 times
Been thanked: 127 times

Re: autorefresh in 1.34.2 Esp8266

Post by Electroguard »

Well I haven't done anything with esp8266 for a while, but there's a post which mentions release of a 1.43.4 version for esp8266 here:
[Local Link Removed for Guests]
Zim
Posts: 107
Joined: Mon Feb 08, 2021 9:15 pm
Has thanked: 83 times
Been thanked: 46 times

Re: autorefresh in 1.34.2 Esp8266

Post by Zim »

Hi
Tried 1.43.3 and still no luck. :?
User avatar
Electroguard
Posts: 272
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 54 times
Been thanked: 127 times

Re: autorefresh in 1.34.2 Esp8266

Post by Electroguard »

Yep, I can confirm that AUTOREFRESH does not work in esp8266 Annex WiFi 1.43.3 for me either, but is ok in Annex32.
cicciocb
Site Admin
Posts: 401
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 90 times
Been thanked: 289 times
Contact:

Re: autorefresh in 1.34.2 Esp8266

Post by cicciocb »

Hi all,
I confirm that it does not work in 1.43.3 but I just tested in the release 1.43.4 and it works properly.

Edited to correct 1.34 wrong reference. Thanks Robin
User avatar
Electroguard
Posts: 272
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 54 times
Been thanked: 127 times

Re: autorefresh in 1.34.2 Esp8266

Post by Electroguard »

Welcome back CiccioCB.

To avoid confusion for others, I think that the topic and all subsequent references to 1.34 should actually be saying 1.43.
Anyway, the link to the 1.43.4 update can be found here... [Local Link Removed for Guests]
Post Reply