At line (3) in the following code snippet, we start with a few quasi-constants defining the maximum and minimum voltages we expect to receive through the analog input. When you ran the code previously, your end range voltages probably were not exactly 0 and 3.3 volts. This occurrence is expected, and it can make a program feel like the Pots do not reach the ends of their rotation. The value assigned to A_IN_EDGE_ADJ is used to compensate for this in code. We will revisit this variable in the next section:
A_IN_EDGE_ADJ = 0.002 # (3)
MIN_A_IN_VOLTS = 0 + A_IN_EDGE_ADJ
MAX_A_IN_VOLTS = 3.3 - A_IN_EDGE_ADJ
Next, starting at line (4), we create two AnalogIn instances relating to the A0 and A1 inputs of the ADS1115 that are connected to our Pots. It's through these variables that we determine how much a user has rotated our frequency and duty cycle potentiometers:
frequency_ch = AnalogIn(ads, ADS.P0) #ADS.P0 --> A0 # (4)
duty_cycle_ch = AnalogIn...