← Back to context

Comment by s3p

3 hours ago

This one is pretty simple to do. It requests a voltage and then starts pulling current and monitors the voltage as it increases its current draw. If the voltage goes down, alert the user.

With data speed I think it could be a little more complicated. Like OP was saying it would need access to some level of hardware information where it can see which pins are used by the cable. Since the connection 'speed' is still variable even when you DO have a supported cable.