October 2017
Intermediate to advanced
586 pages
14h 8m
English
What we have discussed in the voltage section also applies here. For example, USB drivers may want to set the limit to 500 mA when supplying power.
Consumers can control their supply current limit by calling the following:
int regulator_set_current_limit(regulator, min_uA, max_uA);
min_uA and max_uA are the minimum and maximum acceptable current limits in microamps.
In the same way, consumers can get the regulator configured to the current limit by calling regulator_get_current_limit(), which will return the current limit whether the regulator is enabled or not:
int regulator_get_current_limit(regulator);
Read now
Unlock full access