I did a little more precise estimation on what could be possible with the USB power supply as a little competition to Dave's design
It goes the comlpex and expensive route
This is what I got so far:
My imaginary design has two isolated voltage outputs, one fixed 5V and one variable 0-20V with total combined output power of roughly 1.3W, and an isolated logic level RS-232. I may even provide some GPIO to allow for creation of i.e. a simple GAL programmer.
Both DC-DC converters are powered from the USB side to avoid double conversion loss.
I have put ATmega32U4 on the USB side to handle 2 3digit 7segment LED displays (found nice low current ones which take only 2mA@2.1V per segment) and some controls (not decided yet, buttons for now, probably will attempt two capacitive sliders but I/O is getting scarce on the USB side).
It does have capability to do a proper USB handshake and thus negotiate power consumption, has USB remote control interface for the supply and provides virtual serial port that goes to the isolated side as isolated 5V TTL level RS-252.
There is an isolated serial bus between the two microcontrollers that 1) controls the PWM that sets voltage and current levels on the isolated side, 2) provides for data path of the measured voltage/curent back to the ATmega32U4 for display on the LED displays and communication over USB to the optional control panel application, 3) allows configuration of the baud rate on the isolated serial bus to the device and 4) passes serial data from the virtual serial port to second UART of the ATmega164A on the isolated side.
ATmega164A on the isolated side is doing current and voltage measurements with the internal ADC and sends data back and forth over the middle bus (which runs faster than the virtual serial to allow for internal communication in addition to the user data).
I have two 78S40 on the USB side to do the power conversion, voltage is measured on the isolated side with comparators and result is passed back thru two optocouplers (on=too high). Variable voltage is compared against PWM generated threshold voltage generated by the isolated side MCU. This part is too simple and imprecise for now, need to find a way to generate PWM based on a reference not just output of the MCU which depends on its supply fluctuations. Maybe I will just power whole MCU from a voltage reference of some sort.
What I'm currently missing is a current limiter on the 5V output. It will be necessary so I dont starve out the isolated side MCU by excessive current.
Also I need to figure out how to combine the current limitation of the two converters together into a common power budget without limiting them both to a fixed current value. I'll probably just stick a current limiter between the USB power and the rest of the circuit for some loss in available power.
I'm also thinking of a 5V wall adapter connector to allow standalone operation without USB and with more power.
So, what do you think, overcomplicated?