-->
Page 3 of 3

Re: Looking for feed back on the latest build.

PostPosted: Wed Apr 06, 2016 6:40 am
by peridot
Jim, I have found those $ characters in you string variables ill cause it to crash. Mike


viscomjim wrote:I am not sure what the actual problem is right now, but I will try and break the program down to see where it fails. This little program works very well under the "stable" version, but bombs in the 2.0 alpha version. I think I saw a thread where someone said that using a variable with the wget command wasn't working in the newest firmware, so I will try and start there for troubleshooting.

Code: Select allcls
button "Click to send " [checkit]
button "Exit " [Exit]
timer 30000 [checkit]
wait
'
[checkit]
WBString = "api.openweathermap.org/data/2.5/weather?id=4174855&units=imperial&appid=yourapikeyhere"
a$ = wget(WBString)
'serialprintln a$

serialprintln json(a$,"description")
serialprintln json(a$,"temp")
serialprintln json(a$,"pressure")
serialprintln json(a$,"humidity")
serialprintln json(a$,"name")
serialprintln json(a$,"speed")
serialprintln json(a$,"deg")

let tim = json(a$,"dt")
let timj = unixtime(tim)
serialprintln ""
serialprint "unix time = "
serialprintln tim
serialprintln ""
serialprint "time = "
serialprintln timj
serialprintln ""

wait
[Exit]
timer 0
wprint "<a href='/'>Menu</a>"
end


Re: Looking for feed back on the latest build.

PostPosted: Wed Apr 06, 2016 7:01 am
by viscomjim
Hi Peridot, thanks for that, I never would have guessed that. I will give that a whirl and let you know.

Thanks a million!!!!

Re: Looking for feed back on the latest build.

PostPosted: Wed Apr 06, 2016 11:12 am
by cicciocb
Yes, the $ is not yet supported in the new version.
It will be in the next one

Re: Looking for feed back on the latest build.

PostPosted: Sun Apr 17, 2016 3:16 pm
by viscomjim
The problem actually wound up being the line using timer. You now have to have a comma before the branch label.