Digital Current limiting with MCU












4












$begingroup$


All current limiting circuits I've found until now use some sort of analog Logic with Op-Amps to limit/control the current.



(Why) is no digital current limiting used?
I would imagine a shunt resistor for measurement and a MOSFET for controlling being a flexible solution, when you already have a MCU in your build.










share|improve this question







New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$












  • $begingroup$
    What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
    $endgroup$
    – frarugi87
    yesterday
















4












$begingroup$


All current limiting circuits I've found until now use some sort of analog Logic with Op-Amps to limit/control the current.



(Why) is no digital current limiting used?
I would imagine a shunt resistor for measurement and a MOSFET for controlling being a flexible solution, when you already have a MCU in your build.










share|improve this question







New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$












  • $begingroup$
    What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
    $endgroup$
    – frarugi87
    yesterday














4












4








4





$begingroup$


All current limiting circuits I've found until now use some sort of analog Logic with Op-Amps to limit/control the current.



(Why) is no digital current limiting used?
I would imagine a shunt resistor for measurement and a MOSFET for controlling being a flexible solution, when you already have a MCU in your build.










share|improve this question







New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$




All current limiting circuits I've found until now use some sort of analog Logic with Op-Amps to limit/control the current.



(Why) is no digital current limiting used?
I would imagine a shunt resistor for measurement and a MOSFET for controlling being a flexible solution, when you already have a MCU in your build.







current-measurement current-limiting constant-current






share|improve this question







New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question







New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question






New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked yesterday









Hendrik410Hendrik410

254




254




New contributor




Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Hendrik410 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












  • $begingroup$
    What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
    $endgroup$
    – frarugi87
    yesterday


















  • $begingroup$
    What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
    $endgroup$
    – frarugi87
    yesterday
















$begingroup$
What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
$endgroup$
– frarugi87
yesterday




$begingroup$
What do you mean by "current limiting circuits"? isn't a PWM LED dimmer limiting the current through a LED digitally? Isn't an H-Bridge circuit limiting the current in the motor digitally? Isn't a Current mode switching supply controlling the current in the load digitally?
$endgroup$
– frarugi87
yesterday










2 Answers
2






active

oldest

votes


















4












$begingroup$

If that is all the MCU is doing, then maybe. Otherwise it is not fast enough. Even an inexpensive op amp may be found that will be faster. Besides, no buggy software to worry about (if it works once, it will work every time).



The shunt resistor and series element (bjt or mosfet) has to be there, whether you have op amp or MCU. Hooking up an op amp to that is simpler than hooking up a MCU. [And you might end up with one or two op amps anyway if the MCU has no DAC.]



The analog and digital system does not differ in whether the series element is controlled with an op amp. Both use an op amp to control the BJT/mosfet. The difference is in the way the reference input to the op amp is provided. In analog, the reference is a manual potentiometer. In digital control, it is usually a DAC. A digital pot can be used, but is hardly ever done (they are expensive, and less flexible). This DAC can be substituted with PWM and a low pass filter. Depending on the accuracy vs speed required, the low pass filter may be a simple RC filter, or an active 2nd or 4th order butterworth filter (which requires one op amp for every 2 stages).






share|improve this answer











$endgroup$













  • $begingroup$
    Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
    $endgroup$
    – Dave Tweed
    10 hours ago





















6












$begingroup$

It is done sometimes (I've done it). The issue, as Indraneel has said is that it's not very fast; so for example if your load becomes a dead short, something may blow up in the microseconds it takes for the current limiter to trip.



For the purpose of preventing overloads and other conditions that can be tolerated for a short time, MCU current limiting is very useful. I think it's done fairly often.



Most practical current limiters (like circuit breakers) have 2 limits. A slow limit which will trip if a slight overload is sustained for many seconds, and a second limit which trips very fast in response to shorts and extreme overloads. This keeps things from blowing up during shorts, and also doesn't erroneously trip due to motor starts or capacitor inrush currents.



In a home circuit breaker this is literally 2 separate mechanical systems, one is a bi-metalic strip, and the other (the fast one) is magnetic.



Basically your MCU current limiter is the slow type. Depending on the application it may need to be paired with another faster limiter.






share|improve this answer









$endgroup$













    Your Answer





    StackExchange.ifUsing("editor", function () {
    return StackExchange.using("mathjaxEditing", function () {
    StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
    StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["\$", "\$"]]);
    });
    });
    }, "mathjax-editing");

    StackExchange.ifUsing("editor", function () {
    return StackExchange.using("schematics", function () {
    StackExchange.schematics.init();
    });
    }, "cicuitlab");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "135"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });






    Hendrik410 is a new contributor. Be nice, and check out our Code of Conduct.










    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2felectronics.stackexchange.com%2fquestions%2f419609%2fdigital-current-limiting-with-mcu%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    4












    $begingroup$

    If that is all the MCU is doing, then maybe. Otherwise it is not fast enough. Even an inexpensive op amp may be found that will be faster. Besides, no buggy software to worry about (if it works once, it will work every time).



    The shunt resistor and series element (bjt or mosfet) has to be there, whether you have op amp or MCU. Hooking up an op amp to that is simpler than hooking up a MCU. [And you might end up with one or two op amps anyway if the MCU has no DAC.]



    The analog and digital system does not differ in whether the series element is controlled with an op amp. Both use an op amp to control the BJT/mosfet. The difference is in the way the reference input to the op amp is provided. In analog, the reference is a manual potentiometer. In digital control, it is usually a DAC. A digital pot can be used, but is hardly ever done (they are expensive, and less flexible). This DAC can be substituted with PWM and a low pass filter. Depending on the accuracy vs speed required, the low pass filter may be a simple RC filter, or an active 2nd or 4th order butterworth filter (which requires one op amp for every 2 stages).






    share|improve this answer











    $endgroup$













    • $begingroup$
      Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
      $endgroup$
      – Dave Tweed
      10 hours ago


















    4












    $begingroup$

    If that is all the MCU is doing, then maybe. Otherwise it is not fast enough. Even an inexpensive op amp may be found that will be faster. Besides, no buggy software to worry about (if it works once, it will work every time).



    The shunt resistor and series element (bjt or mosfet) has to be there, whether you have op amp or MCU. Hooking up an op amp to that is simpler than hooking up a MCU. [And you might end up with one or two op amps anyway if the MCU has no DAC.]



    The analog and digital system does not differ in whether the series element is controlled with an op amp. Both use an op amp to control the BJT/mosfet. The difference is in the way the reference input to the op amp is provided. In analog, the reference is a manual potentiometer. In digital control, it is usually a DAC. A digital pot can be used, but is hardly ever done (they are expensive, and less flexible). This DAC can be substituted with PWM and a low pass filter. Depending on the accuracy vs speed required, the low pass filter may be a simple RC filter, or an active 2nd or 4th order butterworth filter (which requires one op amp for every 2 stages).






    share|improve this answer











    $endgroup$













    • $begingroup$
      Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
      $endgroup$
      – Dave Tweed
      10 hours ago
















    4












    4








    4





    $begingroup$

    If that is all the MCU is doing, then maybe. Otherwise it is not fast enough. Even an inexpensive op amp may be found that will be faster. Besides, no buggy software to worry about (if it works once, it will work every time).



    The shunt resistor and series element (bjt or mosfet) has to be there, whether you have op amp or MCU. Hooking up an op amp to that is simpler than hooking up a MCU. [And you might end up with one or two op amps anyway if the MCU has no DAC.]



    The analog and digital system does not differ in whether the series element is controlled with an op amp. Both use an op amp to control the BJT/mosfet. The difference is in the way the reference input to the op amp is provided. In analog, the reference is a manual potentiometer. In digital control, it is usually a DAC. A digital pot can be used, but is hardly ever done (they are expensive, and less flexible). This DAC can be substituted with PWM and a low pass filter. Depending on the accuracy vs speed required, the low pass filter may be a simple RC filter, or an active 2nd or 4th order butterworth filter (which requires one op amp for every 2 stages).






    share|improve this answer











    $endgroup$



    If that is all the MCU is doing, then maybe. Otherwise it is not fast enough. Even an inexpensive op amp may be found that will be faster. Besides, no buggy software to worry about (if it works once, it will work every time).



    The shunt resistor and series element (bjt or mosfet) has to be there, whether you have op amp or MCU. Hooking up an op amp to that is simpler than hooking up a MCU. [And you might end up with one or two op amps anyway if the MCU has no DAC.]



    The analog and digital system does not differ in whether the series element is controlled with an op amp. Both use an op amp to control the BJT/mosfet. The difference is in the way the reference input to the op amp is provided. In analog, the reference is a manual potentiometer. In digital control, it is usually a DAC. A digital pot can be used, but is hardly ever done (they are expensive, and less flexible). This DAC can be substituted with PWM and a low pass filter. Depending on the accuracy vs speed required, the low pass filter may be a simple RC filter, or an active 2nd or 4th order butterworth filter (which requires one op amp for every 2 stages).







    share|improve this answer














    share|improve this answer



    share|improve this answer








    edited yesterday

























    answered yesterday









    IndraneelIndraneel

    1,275514




    1,275514












    • $begingroup$
      Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
      $endgroup$
      – Dave Tweed
      10 hours ago




















    • $begingroup$
      Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
      $endgroup$
      – Dave Tweed
      10 hours ago


















    $begingroup$
    Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
    $endgroup$
    – Dave Tweed
    10 hours ago






    $begingroup$
    Comments are not for extended discussion; this conversation has been moved to chat. Any conclusions reached should be edited back into the question and/or answer(s).
    $endgroup$
    – Dave Tweed
    10 hours ago















    6












    $begingroup$

    It is done sometimes (I've done it). The issue, as Indraneel has said is that it's not very fast; so for example if your load becomes a dead short, something may blow up in the microseconds it takes for the current limiter to trip.



    For the purpose of preventing overloads and other conditions that can be tolerated for a short time, MCU current limiting is very useful. I think it's done fairly often.



    Most practical current limiters (like circuit breakers) have 2 limits. A slow limit which will trip if a slight overload is sustained for many seconds, and a second limit which trips very fast in response to shorts and extreme overloads. This keeps things from blowing up during shorts, and also doesn't erroneously trip due to motor starts or capacitor inrush currents.



    In a home circuit breaker this is literally 2 separate mechanical systems, one is a bi-metalic strip, and the other (the fast one) is magnetic.



    Basically your MCU current limiter is the slow type. Depending on the application it may need to be paired with another faster limiter.






    share|improve this answer









    $endgroup$


















      6












      $begingroup$

      It is done sometimes (I've done it). The issue, as Indraneel has said is that it's not very fast; so for example if your load becomes a dead short, something may blow up in the microseconds it takes for the current limiter to trip.



      For the purpose of preventing overloads and other conditions that can be tolerated for a short time, MCU current limiting is very useful. I think it's done fairly often.



      Most practical current limiters (like circuit breakers) have 2 limits. A slow limit which will trip if a slight overload is sustained for many seconds, and a second limit which trips very fast in response to shorts and extreme overloads. This keeps things from blowing up during shorts, and also doesn't erroneously trip due to motor starts or capacitor inrush currents.



      In a home circuit breaker this is literally 2 separate mechanical systems, one is a bi-metalic strip, and the other (the fast one) is magnetic.



      Basically your MCU current limiter is the slow type. Depending on the application it may need to be paired with another faster limiter.






      share|improve this answer









      $endgroup$
















        6












        6








        6





        $begingroup$

        It is done sometimes (I've done it). The issue, as Indraneel has said is that it's not very fast; so for example if your load becomes a dead short, something may blow up in the microseconds it takes for the current limiter to trip.



        For the purpose of preventing overloads and other conditions that can be tolerated for a short time, MCU current limiting is very useful. I think it's done fairly often.



        Most practical current limiters (like circuit breakers) have 2 limits. A slow limit which will trip if a slight overload is sustained for many seconds, and a second limit which trips very fast in response to shorts and extreme overloads. This keeps things from blowing up during shorts, and also doesn't erroneously trip due to motor starts or capacitor inrush currents.



        In a home circuit breaker this is literally 2 separate mechanical systems, one is a bi-metalic strip, and the other (the fast one) is magnetic.



        Basically your MCU current limiter is the slow type. Depending on the application it may need to be paired with another faster limiter.






        share|improve this answer









        $endgroup$



        It is done sometimes (I've done it). The issue, as Indraneel has said is that it's not very fast; so for example if your load becomes a dead short, something may blow up in the microseconds it takes for the current limiter to trip.



        For the purpose of preventing overloads and other conditions that can be tolerated for a short time, MCU current limiting is very useful. I think it's done fairly often.



        Most practical current limiters (like circuit breakers) have 2 limits. A slow limit which will trip if a slight overload is sustained for many seconds, and a second limit which trips very fast in response to shorts and extreme overloads. This keeps things from blowing up during shorts, and also doesn't erroneously trip due to motor starts or capacitor inrush currents.



        In a home circuit breaker this is literally 2 separate mechanical systems, one is a bi-metalic strip, and the other (the fast one) is magnetic.



        Basically your MCU current limiter is the slow type. Depending on the application it may need to be paired with another faster limiter.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered yesterday









        DrewDrew

        1,8241513




        1,8241513






















            Hendrik410 is a new contributor. Be nice, and check out our Code of Conduct.










            draft saved

            draft discarded


















            Hendrik410 is a new contributor. Be nice, and check out our Code of Conduct.













            Hendrik410 is a new contributor. Be nice, and check out our Code of Conduct.












            Hendrik410 is a new contributor. Be nice, and check out our Code of Conduct.
















            Thanks for contributing an answer to Electrical Engineering Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            Use MathJax to format equations. MathJax reference.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2felectronics.stackexchange.com%2fquestions%2f419609%2fdigital-current-limiting-with-mcu%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            "Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

            Alcedinidae

            Origin of the phrase “under your belt”?