ViktorJp / RTRMON

Asus-Merlin Router Health/Performance Monitor
GNU General Public License v3.0
17 stars 1 forks source link

Fixes & Code Improvements #21

Open Martinski4GitHub opened 1 week ago

Martinski4GitHub commented 1 week ago

1) Modified code to ignore ALL character key presses during the initial "Boot Sequence" loop.

2) Modified code to ignore all INVALID character key presses within the main loop.

3) Added code to avoid updating the timer prematurely within the initial & main loops due to repeatedly fast key presses.

4) Modified code to avoid redisplaying the top "Options Menu" unnecessarily too often and resetting the timer loop due to repeatedly fast key presses.

5) Modified code to get elapsed time percentage values with 1 decimal place (e.g. 0.5%). This allows non-integer values to be displayed for percentages of the elapsed time.

6) Modified the top "Operations Menu" section with the title for the "Setup Configuration Menu" to highlight "M" as the key press to launch the Setup Menu instead of the "S" key press which was in conflict with the "S" required to show the "Operations Menu" section.

7) Fixed menu option to set "Timer Interval (seconds)" values because it was accepting any user input (e.g. "0", "X") with very little validation and there was no lower-bound & upper-bound value checking. For example, inputs like "0" && "X" were accepted leading to runtime errors being generated.

8) Added a toggle switch to pause/resume the timer cycle within the main loop. Pressing the character 'X' key (upper-case X only) will toggle the timer to pause/resume. While in the paused state, all character key presses are ignored except for the toggle 'X' key to resume the timer.

9) Various other coding improvements & fine-tuning.