Well that updated version works every time exactly 15mins to the second. Then it suddenly stops.
Thank you very much for the reports.
It actually finishes because it thinks the miner is stable and under the max. errror-rate (which I have currently set to 0.2/min, or 1/5min per chain).
The downvolting kicks in as soon as a chain has 0.0 errors in the 10min avg. and the voltage increase kicks in when a chain has more than 0.2 errors per min in the 5min average.
When I look at your end-results, the script assumes the miner as tuned when it does not make any changes within 10min to voltages as it thinks it has found the sweet spot between no errors and too much errors.
I will revisit that part of the code and see what I can improve there, but from what I see it does actually tune your miner, but I agree it should try harder/longer:
| Start 19:20.46 | 0xa0 | 0x8b | 0xcd | 0xa9 |
| Start 19:20.46 | 59 C | 58 C | 54 C | 53 C |
| End 19:35.46 | 0xa0 | 0x92 | 0xcd | 0xb0 |
| End 19:35.46 | 59 C | 58 C | 54 C | 53 C |
| Start 13:39.55 | 0xa3 | 0x6f | 0xa3 | 0x9c |
| Start 13:39.55 | 60 C | 61 C | 58 C | 56 C |
| End 14:01.55 | 0x9f | 0x7d | 0xb1 | 0xa2 |
| End 14:01.55 | 60 C | 60 C | 57 C | 55 C |
| Start 9:40.40 | 0x87 | 0x67 | 0x87 | 0x87 |
| Start 9:40.40 | 60 C | 59 C | 57 C | 54 C |
| End 9:55.40 | 0x8e | 0x6e | 0x87 | 0x87 |
| End 9:55.40 | 59 C | 59 C | 57 C | 54 C |
I was trying to make sure the script doesn't run forever and stops/exits as soon as it can, but I probably went a bit too far wrt this.
For the moment feel free to run the script multiple times, I even recommend to re-run it everytime ambient temperatures change noteably (>=2°C difference). Simply put, the colder the less voltage needed.
Whenever you change frequency you should re-run the script or manually re-tune them anyways.
If you want to run the script multiple times in a row unattended, use a command like below:
for i in range {1..3}; do /path/l3plus_autotune.py -i x.x.x.x; sleep 60; done
^This will run it three times in a row, just as a workaround until I come up with a smarter solution on finding the right point in time to declare the miner tuned.
I will post, once I have an update.