Start a new topic

odd gif loop

I have the code below in a timer and it does run, but it cycles through my entire picture library for the hmi. oddly it cycles through all my pics one time, then loops through the designated pics on the second pass as well as the following passes.


p10.pic=va0.val // "p10" is Nextion picture # // "va10" is Variable #

va0.val=va0.val+1

if(va0.val>20) // The # ">20" is number of last image

{

va0.val=11 // Animation starts at image 11

}


Any advice would be great.



maybe you forgot to initialize your va0 with the right starting value?  :-)

 

That's all it was! It worked. I'm blind sometimes. Lol thank you very much.
Login or Signup to post a comment