Announcement

Collapse
No announcement yet.

Whats this ripple?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Whats this ripple?

    So this is the PWM signal coming off on ATTiny85 MP the pin is connected to the base of a MOSFET that is driving some LEDs... When I disconnect the base from the pin, the ripple goes away so I'm assuming it has something to do with the nature of the MOSFET ... but I don't know exactly why its there.

    Im talking about the ripple at the low side of this signal...



    Can someone explain to me what I'm looking at here?

    Thank you,

    #2
    Re: Whats this ripple?

    try putting a ferite bead on the gate pin - i'v seen that done in psu's
    i think it's the gate pin capacitance discharging

    Comment


      #3
      Re: Whats this ripple?

      Originally posted by stj View Post
      try putting a ferite bead on the gate pin - i'v seen that done in psu's
      i think it's the gate pin capacitance discharging
      You mean like ... one of these?

      Comment


        #4
        Re: Whats this ripple?

        Originally posted by stj View Post
        try putting a ferite bead on the gate pin - i'v seen that done in psu's
        i think it's the gate pin capacitance discharging
        I just saw this too ... check out what its doing at the top edge of the wave.

        Comment


          #5
          Re: Whats this ripple?

          what am i seeing, are you driving high to low, or just driving one way and using a resistor the other way?
          because i think the tiny can sink and source atleast 25mA

          Comment


            #6
            Re: Whats this ripple?

            Not sure if this would help but a lot of power supplies I see have a small value resistor (10~22Ω) in the gate circuit, and some also have another resistor and diode across this gate resistor as well to control the turn on & turn off of the mosfet
            Attached Files

            Comment


              #7
              Re: Whats this ripple?

              What you are seeing is called "ringing", like when you tap something resonant like a bell, it oscillates at a frequency while the amplitude fades out.
              There are many resonances in electronic circuits, it can be long wiring, the breadboard, components, the place where you ground the scope probe.
              I see ~4 cycles for 5usec or 1.3MHz and it starts about 2usec after the MCU output goes low (mosfet and led off). It seems weird for that delay.

              It can be the power supply recovering (along with the cable inductance) or the mosfet oscillating a bit from the ground, source to MCU, even the LED wiring inductance can cause it. Slowing down the mosfet turn on and turn off by adding a gate resistor or ferrite bead can help and is what is usually done when you don't need nsec switching times.

              You would have to also scope the mosfet drain and compare that to the gate drive waveform to really figure it out. The scope is two channel, work it.

              Best to use a single-point grounding strategy, where the MCU, mosfet source and power supply, scope connect to a star point.

              Comment


                #8
                Re: Whats this ripple?

                Originally posted by stj View Post
                what am i seeing, are you driving high to low, or just driving one way and using a resistor the other way?
                because i think the tiny can sink and source atleast 25mA
                Driving three LEDs in parallel. Should be getting like 800 ma to the LEDs but I'm only getting like 225. do have a resistor on the emitter of the mosfet to ground and when i change its value, it affects that ripple.

                Comment


                  #9
                  Re: Whats this ripple?

                  post your circuit

                  Comment


                    #10
                    Re: Whats this ripple?

                    Originally posted by stj View Post
                    post your circuit


                    LEDs are rated at 3.3V 280ma each
                    Last edited by EasyGoing1; 02-20-2021, 09:22 PM.

                    Comment


                      #11
                      Re: Whats this ripple?

                      move the resistor to the positive rail after the leds.
                      it's raising the fet above ground in relation to the mcu

                      Comment


                        #12
                        Re: Whats this ripple?

                        The ringing I don't think is much of a problem.
                        It's the low 3.3V drive to the mosfet. IRF510N would really like at least 5V gate-drive to turn on to the 1A level. Adding the 1R source resistor lowers the gate-drive from 3.3V to even less, 2.3V at 1A.

                        To improve the circuit:
                        -Move the 1R resistor from the source up to the power (+) for the LED's but the mosfet is still only weakly turning on. It would get hot doing mushy PWM.
                        -Change to a logic-level mosfet, something that can switch 1A with 3.3V drive. Or use a BJT.
                        Last edited by redwire; 02-22-2021, 02:01 AM.

                        Comment


                          #13
                          Re: Whats this ripple?

                          Originally posted by redwire View Post
                          The ringing I don't think is much of a problem.
                          It's the low 3.3V drive to the mosfet. IRF510N would really like at least 5V gate-drive to turn on to the 1A level. Adding the 1R source resistor lowers the gate-drive from 3.3V to even less, 2.3V at 1A.

                          To improve the circuit:
                          -Move the 1R resistor from the source up to the power (+) for the LED's but the mosfet is still only weakly turning on. It would get hot doing mushy PWM.
                          -Change to a logic-level mosfet, something that can switch 1A with 3.3V drive. Or use a BJT.
                          I will be experimenting with different transistors to replace this mosfet when I get some time to do so. I did try a BC337 and it actually did quite well in this circuit, though it wouldn't be suited for long-term use since this circuit drives its current ratings pretty hard. Although it didn't even get hot when I tried it so it might be a viable option. Not sure yet which way I'll go. I should have some time in a week or so to start playing with it again.

                          Comment

                          Working...
                          X