Skip to content

Commit bbf0212

Browse files
committed
Error message more specific.
1 parent 5d9161c commit bbf0212

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

adafruit_esp32spi/adafruit_esp32spi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -812,7 +812,7 @@ def set_analog_read(self, pin, atten=ADC_ATTEN_DB_11):
812812
((pin,), (atten,)))
813813
resp_analog = struct.unpack('<i', resp[0])
814814
if resp_analog[0] < 0:
815-
raise ValueError("_SET_ANALOG_READ parameter error", resp_analog[0])
815+
raise ValueError("_SET_ANALOG_READ parameter error: invalid pin", resp_analog[0])
816816
if self._debug:
817817
print(resp, resp_analog, resp_analog[0], 16 * resp_analog[0])
818818
return 16 * resp_analog[0]

0 commit comments

Comments
 (0)