stlink_target_voltage: Check for libusb error
_stlink_usb_target_voltage already returns an error value.
If value return is positive, this is a voltage, if negative this is an error.
Check the return on callers side to inform there is an error in reading the
voltage, instead of notifying of a too low voltage.
Signed-off-by:
Maxime Coquelin <mcoquelin.stm32@gmail.com>
parent
5fcad7d2
Please register or sign in to comment