Power supply with constant current