1
\$\begingroup\$

I am planning on building my own lab bench power supply which should be software controlled and have two outputs. I am considering using the ATMega2560 due to its large amount of I/O pins, but I don't know how to read/write analog voltages to/from the two outputs. I think that they need to be isolated if I wan't to hook them up in parallel for more current which means that I can't just connect them both directly to the microcontroller.

Am I right or can the two outputs share the negative ground rail and just have the positive rails regulated?

If they need to be isolated, how would I go about reading and writing analog voltages to them (setting and measuring output voltage/current)?

\$\endgroup\$
1
  • \$\begingroup\$ It depends if you only ever want to use them with a common return them they do not need to be isolated from eachother but if you still want mains isolation. What voltage and current do you require? It may be easier to buy one as this is not going to be an easy beginners project. You need to read ADCs and write to DACs for each output, possibly two for each output in you want to measure or control current as voltage. \$\endgroup\$ – Warren Hill Apr 12 '20 at 13:04
1
\$\begingroup\$

I would recommend that you isolate the digital control input from the logic in your power supply. This way you will be able to series or parallel connect the PSUs. It will add some complexity but prevent any surprises on your controller or laptop USB port should it be connected.

schematic

simulate this circuit – Schematic created using CircuitLab

Figure 1. A pair of opto-isolators allows complete separation of all circuit grounds.

Just watch your PWM frequency and how the opto-isolators will respond at that frequency. Some will have a slower turn-off time than turn on so the pulse widths may be wider on the receiver than on your transmitter. Check the datasheets.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.