wprint in for next loop slows and hangs
Posted: Mon Jul 04, 2016 3:40 am
Hardware, more recent NodeMCU, version AI-THINKER 4MB, and ESP Basic V3. Alfa 8.
Been playing and trying one of the blink examples.
When placing print or wprint in the blinkMe loop, loops normally about 5 times then slows right down and eventually finishes the loop but crashes the connection to the web browser, requiring hard power reset.
With Serial terminal connected, reports Exception (29) and dumps stack listing.
Also have numerous random resets during the pay, I have read about power supply stability importance and at this stage I'm not ruling anything out. But this is not related to above reported problem, without print or wprint example works fine.
Example listing
Been playing and trying one of the blink examples.
When placing print or wprint in the blinkMe loop, loops normally about 5 times then slows right down and eventually finishes the loop but crashes the connection to the web browser, requiring hard power reset.
With Serial terminal connected, reports Exception (29) and dumps stack listing.
Also have numerous random resets during the pay, I have read about power supply stability importance and at this stage I'm not ruling anything out. But this is not related to above reported problem, without print or wprint example works fine.
Example listing
- noOfBlinks = 10
pin = 16
blinkDelay = 100
[top]
print "How many times to blink"
textbox noOfBlinks
print "Pin To use"
textbox pin
print "Blink Delay"
textbox blinkDelay
button "Blink Me Please", [blinkMe]
button "Exit", [getMeOutOfHere]
wait
[blinkMe]
for x = 1 to noOfBlinks
io(po,pin,1)
delay blinkDelay
io(po,pin,0)
delay blinkDelay
wprint x
next x
print "Finished and waiting"
wait
[getMeOutOfHere]
print "Terminated"
end