I have a program that does a 7 second "scan" sensor calibration routine whenever a setting (setting is called assistance level or "AL" and ranges from 5-10) is adjusted on the HMI. Currently, a scan occurs every time the AL setpoint setting is changed (the rescan is triggered when the HMI buttons are pressed to adjust the AL). I want to reduce the frequency of the scans that occur, and I only need it to scan when the AL is changed to 5 OR when the AL is change to 6-10 (rescan calibration is not needed as the sensor is not affected significantly between AL settings 6-10). For example. If I am at AL 5 and change to AL 10, I want a scan to occur, but if I switch from 10 to 6, I do not need to rescan. But if I go from 6 to AL 5, I want to rescan. I attached my current code. for the current code. For context, while the MinTimer is timing, I run the rescan, so I need some help with updating the "AssistLevelChange" variable to only trigger with the above scenario.