RC switching using MOSFETS question

Discussion in 'General Electronics Chat' started by Kkein, Apr 27, 2014.

  1. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Hi Guys,
    Need your help. I'm trying to switch on and off two MOSFETS to charge and discharge a capacitor. The problem is the capacitor does not charge to full voltage of 30V for some reasons. Instead it charges to 2.93V and discharges when the other transistor is on. Circuit is shown. But when I use only one mosfet, the capacitor charges to 29.7V which is close to 30V. What is the problem here. Can anyone help please. Appreciate.
     
    • rc1.png
      rc1.png
      File size:
      157.8 KB
      Views:
      41
    • RC2.png
      RC2.png
      File size:
      63.3 KB
      Views:
      28
  2. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    PE0 voltage is equal to ??
    And replace Q3 into P-channel MOSFET (source at RCS ; drain to CL)
    Also move RC resistor from Q4 source to Q4 drain. And connect Q4 source directly to ground.
     
  3. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Hi Jony130,
    PE0 is a 0/5V square wave
    PE1 too is 0/5V square wave
    Sorry about that.
     
  4. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
  5. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Oh I see. Thanks, Jony130. So the solution is to use a P-channel mosfet for Q3 and N-channel mosfet for Q4?
     
  6. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Yes, but using P-channel mosfet will complicate the "driver". Because you also need to add NPN transistor.
     
  7. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Jony130, Thanks. I finally got it working with your suggestion. However, something doesn't seem right with the current (see attached). As the voltage across the fully charge capacitor is 30V and the discharging resistor being 20ohms and Mosfet Rds_on of 0.03 ohms, I would expect that the current flowing through the RC circuit to be 1.5A, thus a voltage of 1.5V across a 1ohm resistor connected in series i.e. I=V/(RL+Rds_on+Rs). But that's not what I'm getting. Instead I'm getting for 0.11A. Why is that? Anyone experience this before?
    Appreciate your help.
     
  8. Alec_t

    AAC Fanatic!

    Sep 17, 2013
    5,773
    1,103
    The Rdson of 0.03 Ohms is for a Vgs of 10V. You have only 5V Vgs, so the FET won't be switched fully on and will have a higher Rdson.
    You need either 'logic-level' FETs or a level-shifting driver stage for the gates.
     
  9. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    As I told you already you need moved RL and Rs resistor to Q4 drain.
    And connect Q4 source directly to ground
     
  10. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Notice that RL RS is connected between Q4 source and ground.
     
  11. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Gentlemen,
    Thanks for your help. However, I couldn't get it working due to "time step too small" error when I moved RL & Rs to Q4 drain. I tried building a non inverting driver circuit and use a switch to switch ON & OFF, but the annoying error won't go away. However, when I leave both resistors on the source side of Q4, the error goes. What's the problem? Help please!!! Appreciate it.
     
  12. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Can you upload the simulation file ? Try zip it first or change .DNS into txt.
     
  13. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Jony130,
    Here it is mate. Thanks for your help.
     
    • RC3.zip
      File size:
      14 KB
      Views:
      24
  14. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Simply change Q1 to BUZ10 and error will magically disappears.
    Also notice that MOSFET Vgs_max = 24V but in your circuit from post 7 Vgs is 30V because you skipped one resistor connected between Q2 gate and Q3 collector.
     
  15. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Many thanks Jony130 and those who have assisted. It's kinda working now.
     
  16. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Glad to hear, but don't forget about this additional resistor. Because otherwise P-MOSFET will die ( Vgs must be less than 24V).
     
  17. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Hi Jony130,

    Yes I have included the resistor as suggested - here is the circuit attached.

    Also, is there a solar pv cell model that I can use instead of the battery to do the simulation in Proteus ISIS. I was trying to make one with diode and control current source but it won't work. The idea is to charge the capacitor using a solar pv model and then discharge the capacitor.

    Thanks.
     
  18. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    Looks good.

    Try this circuit (Q5, R9 , R13, D3)

    http://www.electro-tech-online.com/threads/simulation-of-maximum-power-point-circuit.140616/
    This circuit wont work because you don't use F1 properly and D1 model is not right.
     
  19. Kkein

    Thread Starter Member

    Jun 10, 2011
    46
    0
    Jony130, Thanks once again. I tried that circuit but for some reasons, I could not get hire voltages.

    I have tried another solar pv circuit as attached. It works but the current and voltages are negative! How I can reverse things to positive?
     
  20. Jony130

    AAC Fanatic!

    Feb 17, 2009
    3,957
    1,097
    You need to change the the direction of 1A current source.
    And also try to use this diode model
    .model PV_Panel D(Is=10n Rs=.5 N=77.06 Cjo=10n M=.5 Eg=85 Xti=230 BV=30 IBV=.001 Vj=.4 Iave=1 Vpk=30 mfg=Generic type=PV)
     
Loading...