How do constant current power supplies work? For example I have a power supply that is constant voltage that can supply up to 5A and I have a 12V motor that takes ~500mA so I crank up the supply to 12v and my motor pulls ~500mA from the supply. But how does this work for a constant current power supply? Would it determine its own voltage output depending on the resistance of the load(ohms law)?
The simplest constant current supply is a large value resistor in series with a much smaller load resistance. Suppose we have a 12V supply to a 1k resistor in series with a 10R resistor: the current flowing through the load will be 12/1010 amps or 11.88 mA. If the load is 20R, the current will be 11.76 mA. It's almost the same although the load resistance has been doubled. The voltage across the load has been doubled, in the second case, keeping the current at about the same value.
The short answer is yes. The CC supply will output as much voltage as necessary to generate the current. So a 100 ohm load will have twice the voltage across it as a 50 ohm load.
Of course, the CC supply will not be able to increase output voltage forever, just as a CV supply cannot increase output current above a certain limit.
A CV supply will supply more power as the load resistance gets smaller, but a CC supply will supply more power as the load resistance gets larger.
A simple model of a real current source is an ideal source I_S in parallel with an internal resistance R_S. The current and voltage at the load R_L is as follows:
I_L = R_S/(R_S + R_L) * I_S and V_L = R_L*I_L = R_S*R_L/(R_S + R_L) * I_S = (R_S // R_L) * I_S
As long as the load resistance R_L is much smaller than the internal resistance R_S, the load receives most of I_S. In this case the equivalent resistance of R_S in parallel with R_L is approximately R_L, and the source voltage is approximately
I_S*R_L. In the extremely non-ideal case, the load resistance R_L is much larger than the source resistance R_S, and the load current I_L is then approximately zero. Also, the equivalent resistance in this case is approximately R_S, so the source voltage reaches its maximum of
I_S*R_S. To make a current source as ideal as possible, it needs a large internal resistance to be able to source a high voltage.