A voltage regulator has a plurality of predetermined configurations and
comprises a measurement circuit to measure an electrical characteristic
of at least one external impedance and to determine a digital value
corresponding to the measured electrical characteristic. An address
generator converts the digital value to a first digital address
corresponding to a memory location having contents. Each of the contents
corresponds to a respective one of the predetermined configurations. A
controller configures the voltage regulator based on the contents of the
memory location corresponding to the first digital address.