I'm not familiar with javascript at all, but what you had going on was a busy-loop in the update function somehow, resulting in a massive slowdown of the hash rate when hasing using cpu. In any case, this patch now uses setInterval instead of setTimeout and responds to changes in update times correctly.
Ideally, this would be in its own function and there would be one spot in the code where it needs to be changed (or even a way to do it in the interface). It would be nice for updates to be triggered when adding/removing rig configs as well. However, here I just fixed things in the smallest possible patchset.
I was having the same problem as @zhucc in #5
I'm not familiar with javascript at all, but what you had going on was a busy-loop in the update function somehow, resulting in a massive slowdown of the hash rate when hasing using cpu. In any case, this patch now uses setInterval instead of setTimeout and responds to changes in update times correctly.
Ideally, this would be in its own function and there would be one spot in the code where it needs to be changed (or even a way to do it in the interface). It would be nice for updates to be triggered when adding/removing rig configs as well. However, here I just fixed things in the smallest possible patchset.