# Thread hangs when no delay is used

**URL:** <https://discourse.processing.org/t/thread-hangs-when-no-delay-is-used/5352>\
**Category:** Coding Questions\
**Created:** [November 8, 2018, 6:54pm UTC](https://discourse.processing.org/t/thread-hangs-when-no-delay-is-used/5352 "2018-11-08T18:54:04Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![GoToLoop](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/gotoloop/32/86_2.png) [@GoToLoop](https://discourse.processing.org/u/GoToLoop)\
**Post date:** [November 8, 2018, 7:24pm UTC](https://discourse.processing.org/t/thread-hangs-when-no-delay-is-used/5352/3 "2018-11-08T19:24:27Z")

</div>

For more Thread stuff, you can read this whole post: 👽

> [@While loop bug? Stuck on empty](https://discourse.processing.org/t/while-loop-bug-stuck-on-empty/2557):
>
> Hi I have a weird bug in a sketch that I’m using to control a plotter. I have a while loop that is controlled by a boolean that is switched to false while the plotter is in the middle of doing something. Once the plotter is finished it sends a serial command to my sketch and flips nextMove=true; This aspect of it is working correctly and I am checking the nextMove variable and it is set to true. The weird part the sketch gets stuck in the loop even though the variable is set to true. If I pu…

---

_[View the full topic](https://discourse.processing.org/t/thread-hangs-when-no-delay-is-used/5352)._
