1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

buck converter

Discussion in 'Mathematics and Physics' started by PG1995, Apr 4, 2014.

  1. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Hi

    I was trying to find a buck converter module to use with maximum power tracker for a solar panel. Perhaps it's just me but I don't see the modules which accept PWM from some outside device, such as microcontroller, to adjust the duty cycle. I found this one but I don't even know if it could work with the power tracker and moreover its PWM frequency is just 100-300 Hz. Please help me. Thanks.

    Regards
    PG
     
    Last edited: Apr 4, 2014
  2. misterT

    misterT Well-Known Member Most Helpful Member

    Joined:
    Apr 19, 2010
    Messages:
    2,697
    Likes:
    368
    Location:
    Finland
    That is because the idea of a buck controller is to generate the PWM signal to keep the output voltage constant.. that is basically its only purpose, so it does not make sense for it to accept any external PWM signals that overrides the whole purpose of the chip. If you want to generate the PWM on your own, then you only need a FET driver circuit (or IC). Google "mosfet driver buck converter".
    If you need a variable output using buck controller chip, then you could use a microcontroller to control the reference voltage that sets the buck converters output voltage.

    Edit: Oh, I just noticed that you are looking for modules, not chips.. well, the same idea applies I think. Maybe you can modify an "adjustable buck converter module" so that you can adjust the output voltage with a microcontroller. Should be relatively easy.
     
    Last edited: Apr 4, 2014
    • Like Like x 1
  3. ronsimpson

    ronsimpson Well-Known Member Most Helpful Member

    Joined:
    Apr 17, 2007
    Messages:
    7,253
    Likes:
    961
    Location:
    Loveland, CO USA
    ONLINE
    The buck PWM you are looking at on ebay are built to do two jobs.
    example: output 12 volts OR 10 amps. There are likely two loops. One to keep the current below 10A. The other to keep the voltage at 12 volts.

    You need a different function. Get the maximum power from the solar panel.

    Define: battery is a car (RV) 12V 100A battery. Panel is 100W. While charging Vbat should not get above 14.5V OR 100A.

    Set the PWM to output 14.5V and 10A. (you will never get to 100A)

    Your 100W panel will never give you 100W! I live at high altitude and low humidity and could only get 95W on a very clear day, at noon.

    Knowing you a little; I would get a micro processor with two analog inputs and one analog output.
    Measure the voltage of the panel. (input to the buck pwm)
    Measure the current from the panel.
    Power = VxI
    Connect a PNP emitter follower to the output of the error amp on the PWM.
    E=output of amp
    C=gnd
    B=analog voltage from micro.
    This way the micro can pull down on the error amp to reduce the duty cycle. It can not pull up.
    New formula: duty cycle is effected by 14.5V OR 10A OR Micro_DAC
    (There are other ways to connect the DAC but no time now)

    At power up set the DAC so the duty cycle is low. Maybe 10% wait one tick in time (10mS to 1S)??
    Measure I and V to get power.
    Increase the duty cycle wait and get power.
    Each time you will get more power until you go too far and the power starts down.
    Reverse; drop the duty cycle a little.
    >You have a variable for UP/DOWN and a variable for LastPower and ThisTimePower.
    Keep this loop going all the time.
    You can start out with big steps like 10% then drop to 1% or even 0.1%. (depends on noise level and ADC/DAC step size)

    It is OK for the loop to look a little unstable.
    80W, 80.1, 80, 80.1, 80, 80.1, 80.2, 80.3, 80.2, 80.1, 80.0, 80.1........

    The ebay buck modules are a good place to start. Try to find out what IC they are using and determine if there is a way to reduce the duty cycle.
    If riding the duty cycle does not work you can modify the buck so the micro sets the current out OR the voltage out (as how to reduce the power).
    The loop could look like this:
    Output to the battery 1A, 2A, 3A, 4A, 5A (power went down) 4.9, 4.8, 4.7, 4.6, 4.5, 4.4 (power went down) 4.41, 4.42, 4.43................etc
    I think regulating on the output voltage will be hardest, because the battery voltage changes very little with power input.
     
    • Like Like x 1
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13

    Thank you, misterT, ronsimpson.

    ronsimpson: You have just described how to design an mppt for a solar panel. Actually, I'm already working on it as a school project. I just need a buck converter module (or, whatever you want to call it, I'm just using the word "module" in general sense) so that I don't have to make one myself. This is what I want to design; also have a look here. Thanks.

    Regards
    PG
     
  6. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Thank you, misterT, ronsimpson.

    ronsimpson: You have just described how to design an mppt for a solar panel. Actually, I'm already working on it as a school project. I just need a buck converter module (or, whatever you want to call it, I'm just using the word "module" in general sense) so that I don't have to make one myself. This is what I want to design; also have a look here. Thanks.

    Regards
    PG
     
  7. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    I agree with MisterT that you'll be better off assembling it from descrete components. You only need a capacitor, mosfet, diode and inductor.

    Start from the requirements. How much power you want it to produce (more power will be more expensive)? What is your battery voltage? Then select a panel that will be suitable for the application (enough power and good Vmp). This give you a starting point to figure out the size of the parts that you need.

    Then select sensors, decide on the switching frequency.

    Once this is done, select a controller that is fast enough and has all the necessary modules - you will need at least 4 ADC channels, may be a CPP/PWM module, enough pins for all of this plus whatever user interface you want.
     
    • Like Like x 1
  8. ronsimpson

    ronsimpson Well-Known Member Most Helpful Member

    Joined:
    Apr 17, 2007
    Messages:
    7,253
    Likes:
    961
    Location:
    Loveland, CO USA
    ONLINE
    The ebay modules are a good place to start.
    Those that I got are copied from the example in the data sheet.
    There were some questionable part substitutions.
    I can not get the raw parts for the price of the module.
    $12.00 of parts (plus $7.00 of shipping) on a $20.00 board (plus shipping) for $10.00. (Including shipping).
     
    • Thanks Thanks x 1
  9. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Thank you, NG, ronsimpson, for the suggestions.

    Would it be a right choice to use a 6V sealed lead acid battery with 12V, 50W solar panel? This way I can save some money on battery and the panel. After all, it's going to be just a school project.

    But isn't there a single buck module here whose duty cycle is adjustable and hence which can be used in maximum power tracker? I'm more of a curious now. Thanks.

    Regards
    PG
     
  10. ronsimpson

    ronsimpson Well-Known Member Most Helpful Member

    Joined:
    Apr 17, 2007
    Messages:
    7,253
    Likes:
    961
    Location:
    Loveland, CO USA
    ONLINE
    The LM2596 module does not let you get to the error amp.
    The ebay boards do not post the parts list. When you get the board you may find the part numbers have been removed. There will be no manual/data sheet.
     
    • Thanks Thanks x 1
  11. steveB

    steveB Well-Known Member Most Helpful Member

    Joined:
    Jan 16, 2009
    Messages:
    1,297
    Likes:
    629
    I see no reason why you can't save as much money as you want by using smaller panels and smaller batteries. The use of a converter gives more freedom to mix and match different specs on these two components. If you directly connect a solar panel to a battery with a diode and wires only, you need to be more careful, otherwise the efficiency would suffer. The converter allows tracking at the maximum power point and automatically adjusts for a wide range of output voltage, as long as the battery voltage is lower than the panel voltage (only because you are using a buck converter).

    Still you will want to be careful that the battery can accept the charging rate that the solar panel power will provide. If anything, undersize the panel so that charging the battery at full power is no problem.
     
    • Like Like x 1
  12. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    You actually can go smaller than this. Smaller parts will cost less. What are you going to use as a load? If something like a light or a small DC motor is ok, 50W is too much. 50W is quite a big panel.
     
    • Like Like x 1
  13. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Thank you, ronsimpson, Steve, NG.

    I think 20W, 12V panel would be okay. It can easily be carried.

    I'm sorry for asking this again. I believe ronsimpson in post #9 is saying that duty cycle of the modules which use LM2596 can not be adjusted. I have noticed that a lot of modules use LM2596. Does that mean there is no way to get a ready-made module?!

    Don't I need 2 ADC channels - one for current sensor and the other for voltage sensor? I believe many microcontrollers come with built-in CCP/PWM module.

    Regards
    PG
     
    Last edited: Apr 5, 2014
  14. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    If you're going to measure voltage at the panel, current at the panel, voltage at the battery, and current at the battery - that is 4.

    Most of them do, but not all of them.
     
    • Like Like x 1
  15. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Thank you.

    But I had thought that if I'm not going to implement battery charging algorithm then I can do away with those sensors. I could use this circuit between the output terminal of buck converter and the battery. You can see that the circuit uses dummy load. Could that circuit be used? Thanks.

    Regards
    PG
     
  16. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    As you know, in the buck converter Vout = Vin*d, where d is a duty cycle. If you do not have a stable Vout, you cannot use d to control Vin, therefore the easiest way is to connect the output to the battery. In this case you have to implement some sort of battety protection, because the maximum power that you generate with MPPT tracking has to go somewhere. Where would it go?

    Instead of battery, you can connect some different kind of load, e.g. resistive load capable of handling varying voltage, such as water heater. Howeverm, this will make Vout variable and it will be much harder to regulate Vin with d, which will make your MPPT algorithm more complicated. But even in this case, you need to provide some sort of protection mechanism to prevent overheating the load.
     
    • Like Like x 1
  17. steveB

    steveB Well-Known Member Most Helpful Member

    Joined:
    Jan 16, 2009
    Messages:
    1,297
    Likes:
    629
    PG,

    Yes, and I also pointed out previously, you need to monitor the capacitor voltage as well, even if the charger is separate. I see your charger seems to have a dummy load capability which would allow you to maintain some drain on the capacitor of the buck converter. This is a good step, but it is never a good idea to leave things uncertain like this. What if your calculations for worst case conditions are off for some reason and you did not anticipate a condition that allows the voltage to rise uncontrolled? Or, what if the dummy load burns out and opens up? For the small cost of voltage and current sensor circuits, and a trivial amount of coding, you can monitor the output voltage and current and add additional protection features to your design. There is such a thing as simplifying too much in engineering. Cutting corners where safety is concerned is never a good idea. Further, your design will be more adaptable to design changes that might be required when you find issues when building this thing. And, I can tell you the odds of not encountering some issues is almost nil.
     
    • Like Like x 1
  18. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    Absolutely right.

    And in addition to that, having extra sensors will allow you to monitor your creature better. Since this is a learning project, more monitoring is very valuable because you'll learn more!
     
    • Thanks Thanks x 1
  19. PG1995

    PG1995 Active Member

    Joined:
    Apr 18, 2011
    Messages:
    1,645
    Likes:
    13
    Thank you, NG, Steve.

    Let's talk about it in little detail. Yes, you have talked about it before but I didn't really get your point then. Moreover, I understand that my queries are somewhat confusing but that's the best I can do at this moment. Seriously this part is really baffling me. I would request you to read my queries at least twice so that you can understand my confusion at least to some degree. Thanks.

    Q1: To start with, I don't even understand this circuit. I have assumed that when a battery is being charged up and the current flowing into the battery is above certain value, the relay keeps connection to the battery bank. When the current falls below a certain below which would mean battery is fully charged then the relay makes connection with the dummy load. Is that how it works? What's about those LEDs? When will yellow LED be lit?

    Q2: Now I will try to understand what you have been trying to warn me about. Let's say that the 12 V battery has entered Stage 2. In stage 2, the voltage remains constant but current flowing into the battery gradually starts decreasing. The battery limits the current flowing into it or the system should be able to regulate the flow of current into the battery. I think if the voltage is kept constant then the battery can limit the current itself. Right?

    Q3: I have assumed that the battery is limiting the current flowing into it. Please have a look on this figure. The tracker which is functioning at maximum power is continuously pumping current into the converter. Let's say that the voltage at the input terminal of the converter is 17V which will be Vmp because the tracker is working at MPP and the voltage at output terminal is almost 14.4V. If the MPP tracker is continuously pushing more energy (in form of current) then this energy needs to go somewhere. But where does it go? It looks like that this continuous throwing of energy into the converter will tend to increase the overall voltage until the voltage of the converter is also 17 V. Let's see how. Let's suppose the tracker is continuously supplying an average of one ampere into the converter. This might force more current into the battery than is actually allowed or recommended, and further this might raise the overall voltage of converter by raising the voltage of the battery little by little until the voltage of 17 V is reached. This might lead to two things. The battery gets damaged or capacitor gets exploded or both gets damaged. Do you agree with me, at least to some degree?

    Q4: Okay. The battery might be damaged but why the capacitor would explode. The Cin of the tracker doesn't explode when it is charged up to Voc which is greater than Vmp; in this case Vmp is 14.4 V. Further, when the voltage of converter is reached 17 V, the whole system will stop functioning assuming the battery is not present at the output terminal because when the voltage of Cout is 17 V, the tracker is no longer able to throw in any more energy. Do I have it correct?

    Q5: You can notice once a battery enters stage 3, its current falls to zero and its voltage also falls somewhat. Does this voltage falls on its own, or, we need to reduce it to that level for some reason?


    Regards
    PG
     

    Attached Files:

    Last edited: Apr 6, 2014
  20. steveB

    steveB Well-Known Member Most Helpful Member

    Joined:
    Jan 16, 2009
    Messages:
    1,297
    Likes:
    629
    I didn't study that circuit in great detail, but my quick look at it says that it monitors the battery voltage and charges when the voltage is in the specified range. Comparitors are comparing the voltage to threshold set points. If the battery is out of range, the charging is shut off and the dummy load is switched in by the relay.

    I still don't know what battery you intend to use. But, if the one you use has a complicated charge profile or limits on voltages and currents, the the charger has to be programmed to obey the restrictions. If MPPT will overcharge or overstress the battery, you need to disable MPPT. This is one reason why we keep saying to monitor the output voltage and current. You need to monitor and limits those values to be in the safe range. If safe, MPPT can proceed. If not safe, MPPT is disabled and the limiting function can be performed.

    Yes, exactly. The battery could get damaged or a capacitor could explode if you don't design it correctly and put in multiple safeguards.

    OK, the capacitor may be safe, depending on your design. You are free to choose the working voltage of the capacitor and make it high enough. Also, the buck converter can only charge to the input voltage. But, again you have not specified anything yet, so how can I know you will do what needs to be done? You might use a 18 V solar cell and drive a 5 volt charger, and you might put a 10 V capacitor on the output. In that case, "capacitor may go boom!".

    It's your job to design it so that the requirements are met. But, choosing a battery that is too restricted on the charging is going to be harder to code and might prevent you from demonstrating MPPT. Imagine that you limit the output current for charging. This then limits the charging power. If the charging power is limited, then MPPT is not the function you want. If power input is below the required charging power, you can't even charge at that current. And if input power is above that power, you will want to deliberately operate at the lower power point not the maximum power point. Why not choose a battery with a simple charging requirement and oversize the battery so that it can accept just about any power the cell might deliver. Then you only need to shutdown MPPT when the voltage on the battery is near its maximum value.
     
    • Like Like x 1
  21. NorthGuy

    NorthGuy Well-Known Member

    Joined:
    Sep 8, 2013
    Messages:
    1,218
    Likes:
    206
    Location:
    Northern Canada
    Q1. Sorry, I didn't look at the circuit before. My bad. It probably would work, but it's an overcomplication. It switches the source to a dump load when battery voltage goes high. This is commonly used with wind turbines because if you remove a load from wind turbine it'll run away. It is not needed for solar panels because disconnecting a load will not harm anything. If you use a buck converter, you already have a mosfet which you can use to disconnect load therefore you do not need this circuit.

    Q2. Commonly used lead-acid batteries will limit the current if you limit charging voltage. This works well when battery is somewhat charged. If it is heavily discharged, you may be able to overcurrent it, but you cannot come anywhere close to dangereous currents when charging with reasonably sized solar panel.

    Q3. I think capacitor should be Ok (because it won't go above Voc amd you would size it somehow above this), but the battery will be damaged beyond repair. Li-ion will explode fairly quickly. If you want to explode lead-acid battery, it'll take a while and it may never explode, but will be damaged anyway. It'll boil out or it will short and melt. That's why you need to limit battery voltage. You do it by rising panel voltage above MPPT point.

    Q5. You limit it. With lead-acid, on stage 2 (commonly called absorption) you limit it at 2.45V/cell (vary slightly by the mnifacturer). But, when you enter stage 3 (float) you drop the voltage to 2.2V/cell or so. This will produce nearly no current into the battery. You effectively disconnect the battery, but it is still connected. If you have any loads connected (such as your demonstration loads) they continue to get power from your solar panel while battery is mostly unaffected. It is much more difficult with li-ion.

    I agree with Steve that you need to select an easy-to-work-with battery, such as lead-acid. It won't explode and is easy to control. The best way would be to get a flooded one because it is more difficult to damage it, but I don't think that you can get a flooded battery small enough for the purpose. Sealed lead-acid is the next best thing.

    Another important point is to get a battery of correct size.
     
    • Like Like x 1

Share This Page