Announcement

Collapse
No announcement yet.

Master power switch for E-bike ideas

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

    Master power switch for E-bike ideas

    Good day folks. I recently upgraded my bike with a sketchy motor and battery set I picked up from Ali. I say "sketchy" because the motor is rated 1.5kW (at least on paper), so such a retrofit is borderline illegal here and would require registration and possibly a type-A driver's license to operate on public roads, but looking past all that, it's a lot of fun and does go very fast....so fast in fact that the thing does wheelies on its own if I gun it hard enough

    There's one thing I'm looking to improve: no master kill-switch on this thing at all. The 48v battery pack is permanently connected to the control box via an XT60 connector. Of course, I could just disconnect the connector when it sits unused for long periods of time, like during winter now, but I noticed there's a big spark inside the connector upon re-connection, which would ruin the connector pretty quickly. This tells me the control box must have some large-ish caps in it and no inrush limiter, so I thought I could combine an on-off feature and an inrush current limiter.

    A while ago, I briefly discussed such a circuit in my thread HERE, when I was dealing with an amplifier board which also exhibited arcing upon power-up and someone suggested a simple circuit based around a MOSFET which I actually built and tested and it appeared to work relatively well, so I thought I could adapt this circuit and beef it up enough to work with my bike.

    Here's the schematic I adapted from the other thread: the values for the components may not be correct (in fact I'm certain they're not and will require adapting), but the concept should be the same. The 48v battery is on the left and the rest of the bike, the load (control box + motor) is on the right. With SW1 open, the gate of M1 is pulled low to the GND of the battery by R2, so it is "open" - no spark can occur upon connection. Afterwards, SW1 closes and the C1 charges up slow-ish via R1, initiating the "soft-start" state, thus limiting the current should SW1 already be in the "closed" state upon insertion of the XT60 connector. D1 clamps the maximum possible voltage to the gate of M1, since 48v would immediately destroy it. I was told D2 discharges C1 through the "load" when the switch is opened or the battery is unplugged, so the soft start operates upon the next power-up, otherwise M1 would still be on, nullifying the soft-start effect. Alternatively, I could make SW1 a SPDT so it throws the cap either to the "charge-up" resistor when "on" or to a "discharge resistor" when "off" to drain it...that's the theory at least. M1 would have to be pretty beefy AND as low an RDSon as possible to withstand both the high inrush current of the cap when it's in that linear region when it turns on AND THEN pass the required current to the motor when running, which although I haven't measured myself, I estimate to be around 30-40A according to the control box's max specs, upon take-off from a standstill, when the rotor is at 0 RPM and the current draw is at its maximum.

    There's another thing I haven't taken into account and it just occurred to me: this thing has a regenerative braking feature which uses the battery as a load to slow the motor down (yes, I tested it and it actually works - not just marketing BS ).....would this cause issues when pushing current back INTO the battery through the FET ?

    Let me know if you have any suggestions and whether this is a viable way of switching a high current DC circuit....
    Attached Files
    Wattevah...

    #2
    Re: Master power switch for E-bike ideas

    thats not a kill switch.
    if the fet shorts your fucked.

    get a battery disconnect for a car/trailer and put some discharge resistors across the load side to dump the caps slowly when it's off.


    with a knob:
    https://uk.banggood.com/100A-Battery...p-1008959.html

    or a key:
    https://www.altecautomotive.co.uk/ba...00-12013-p.asp

    or encased:
    https://uk.banggood.com/12V-48V-200A...p-1866299.html

    plenty of styles/variants
    Last edited by stj; 10-24-2021, 08:42 AM.

    Comment


      #3
      Re: Master power switch for E-bike ideas

      btw, XT60 is only rated at 30A per pin, you probably need something bigger!!
      maybe XT90

      at 48v your 1500w = 30A continuous!!!

      Comment


        #4
        Re: Master power switch for E-bike ideas

        Ok, NVM the terminology - it's not a kill switch...it's a power switch.

        I WAS thinking of something mechanical, but couldn't find anything suitable, though I didn't dig too deep....
        Wattevah...

        Comment


          #5
          Re: Master power switch for E-bike ideas

          Originally posted by stj View Post
          at 48v your 1500w = 30A continuous!!!
          I'm sure there do exist FETs which can go even higher

          EDIT: In the meantime, I actually managed to find some photos of the inside of this controller without having to take mine apart. Assuming it's the same thing, it seems there are two 470uF caps on the input there, so there is that...
          The layout of the website is completely screwed, so what worked for me was to right click on the images and open them in a new tab
          Last edited by Dannyx; 10-24-2021, 10:41 AM.
          Wattevah...

          Comment


            #6
            Re: Master power switch for E-bike ideas

            Got a couple of these in my junk drawer....the specs would seem adequate, unless I'm completely missing something. I'm still weary about the regenerative braking feature pushing current back into the battery. It's not like the polarity reverses, but the direction does: S becomes the "output" and D becomes the "input", whereas normally it's the other way around, with S being the GND connection...
            Wattevah...

            Comment


              #7
              Re: Master power switch for E-bike ideas

              Originally posted by Dannyx View Post
              Got a couple of these in my junk drawer....the specs would seem adequate, unless I'm completely missing something.
              Might be OK... though I do suggest as well to use an actual physical switch/solenoid/contactor, as stj suggested... because if the motor controller shorts a MOSFET, you may not have a fun time on that bike anymore.

              Also, you may not be able to do a slow turn-ON (soft start) with that MOSFET, even though it is rated for 75 Amps. Reason why: look on page 7 at the Maximum SOA (Safe Operating Area) curves to understand why. So long as you use the MOSFET as an actual switch (that is, instantly turn On without trying to do any kind of soft-starting), then the maximum current is pretty much limited by the R_ds(on) resistance. But as V_ds increases, you start using the MOSFET as a linear regulator, and that will start to give limitations on the current you can pass through it. For example, with 50V difference (48V of the battery with a bit of over-estimation ) between Drain and Source, the current the MOSFET can pass becomes limited to about 2.5 Amps DC. That is, if you try to pass more than that, you will overheat the die and blow the MOSFET. However, if your soft-start circuit is active for only about 1 ms before the MOSFET is fully turned On afterwards, then the maximum current you can pass though it is about 20 Amps.

              That said, may I suggest a possibly simpler solution to your circuit: instead of doing a soft-start with a MOSFET, how about use a solenoid/contactor or a switch to connect/disconnect the batteries. But to prevent sparking in the switch/contactor, check how much "idle" current the motor controller uses when it is connected to the battery and the motor on the bike not running. Let's say it's just a few mA, like less than 10. Then you can install something like a 1 KOhm, 3-5 Watt resistor across the switch/contactor contacts to allow the caps inside the controller to charge up slowly as you connect the battery. Once they charge high enough, you can engage the switch/contactor, and there would be no or very little sparking in the contactor/switch, because the voltage difference between the almost fully charged caps and the battery should be very small... hence smaller currents.
              Last edited by momaka; 10-28-2021, 05:55 PM.

              Comment


                #8
                Re: Master power switch for E-bike ideas

                I considered a mechanical switch of some description initially but it became apparent there aren't any rated for such high DC amps (at least not at a reasonable price !) although I'm not entirely sure what the maximum current draw during normal operation IS (not counting capacitor charge inrush), since I have no way of measuring it, at least not easily.

                I could measure the draw with my clamp meter on the battery leads by lifting the wheel off the ground and letting it rip, but that would only give me a no-load reading which is sure to double upon riding, especially during take-off and hills. I'd have to somehow secure the meter to the bike to measure while riding and the worst part is it doesn't have a MAX feature to freeze the maximum instantaneous reading, so I'd have no way to read it, other than to maybe ask a buddy to run behind me

                Taking the maximum rating of the controller as a (loose) reference, 40A, I expect it to be 20-30A tops, which is STILL higher than what most contactors I found can tolerate, which is why I switched to a FET.

                I was hoping the "slow-ish" turn-on time wouldn't be destructive because the charge-up time of the caps SHOULD be brief enough to "escape" the linear region before it overheats, plus I'd use a heatsink...I guess I should just try it. Worse-case scenario I kill the FET...
                Wattevah...

                Comment


                  #9
                  Re: Master power switch for E-bike ideas

                  Actually, a mechanical switch approach may be attainable after all. I may have overestimated the currents involved, which albeit high, are manageable even with mechanical switches/relays, especially since I'd use an inrush limiter to lower it even further upon startup so it's within the rating of the contacts.

                  Looking through a list of relays, I'm not entirely sure how to interpret their DC ratings. Some will say something like "max 20A/400vDC Resistive"....can we assume that if it handles 20A at 400vDC it SHOULD handle 20A at 48v as well ? True, in my case, it'd be a capacitive load and the contacts would still go *BANG* if the caps are discharged. To mitigate this, I'd have it so the NC connection is wired through a resistor (small lightbulb maybe ?) to charge the caps and THEN have it switch over via a time-delay to the NO connection for the the "ON" state...that's the theory at least....
                  Wattevah...

                  Comment


                    #10
                    Re: Master power switch for E-bike ideas

                    wondering if you can get contactors for DC . bit more manly than relays . might use more juice to hold them in though .

                    Comment


                      #11
                      Re: Master power switch for E-bike ideas

                      Originally posted by petehall347 View Post
                      wondering if you can get contactors for DC . bit more manly than relays . might use more juice to hold them in though .
                      They might be expensive/bulky. Already relays rated for high-ish DC are already outside my price range ! Also yes, there's the power consumption issue. I'm thinking to ditch the relay idea and have some sort of large mechanical switch with 3 positions: one "off" position, a second "inrush limit" position and one "ON" position. To get to the ON position, you'd have to go through the intermediary one first which charges the caps. Of course, there would be nothing preventing the average idiot from attempting to ride the bike on the actual inrush limit resistor if they don't turn the switch all the way......trying to figure out a way to mitigate this.
                      Wattevah...

                      Comment


                        #12
                        Re: Master power switch for E-bike ideas

                        maybe a bit related . looks fun anyway .. https://www.youtube.com/watch?v=DyrG4yb_P5s

                        Comment


                          #13
                          Re: Master power switch for E-bike ideas

                          i still have a pretty old electric bike .so old the motor is in the front wheel .well i think it is .might be in the back . i wanted to use some sort of a mechanical speed controller as the electronic one is no good and likely missing now .

                          Comment


                            #14
                            Re: Master power switch for E-bike ideas

                            Can't you just make a mechanical knife switch out of some copper bar? Steampunk aesthetic and some cool sparks.

                            Comment


                              #15
                              Re: Master power switch for E-bike ideas

                              Originally posted by diif View Post
                              Can't you just make a mechanical knife switch out of some copper bar? Steampunk aesthetic and some cool sparks.
                              that's the way .big and serviceable . my sort of electrickery

                              Comment


                                #16
                                Re: Master power switch for E-bike ideas

                                Originally posted by diif View Post
                                Can't you just make a mechanical knife switch out of some copper bar? Steampunk aesthetic and some cool sparks.
                                Too big to fit on there, plus it'd look kinda ugly for my build
                                Wattevah...

                                Comment


                                  #17
                                  Re: Master power switch for E-bike ideas

                                  Not if you made it look like a Raleigh Chopper gear selector.
                                  One here for reference. https://www.ebay.co.uk/itm/324856946839

                                  Comment


                                    #18
                                    Re: Master power switch for E-bike ideas

                                    Looking back at my FET idea, mostly for learning stuff, I was looking at that SOA graph for the FET I proposed and tried to follow along with this tutorial here, though I'm not entirely sure I got it.

                                    What does the horizontal axis, VDs Drain-Source voltage, represent in practice ? Does this mean the potential difference between D and S ? Taking my 48v battery as an example, with the FET "off", am I expected to see 48v if I measure across the FET ? Whereas with it "on" (saturated ?), there should be very little drop across it, since that's what you want a FET to do when fully on, so it dissipates as little power as possible, at least that's how I remember things.

                                    That being said, when I slowly ramp up the gate voltage, I'm keeping the FET in its linear region where it dissipate a lot of power instead of being open...and eventually pops...
                                    Wattevah...

                                    Comment


                                      #19
                                      Re: Master power switch for E-bike ideas

                                      Let's kick it up a notch with one of THESE I was having trouble coming up with a feasible way of actually attaching whatever transistor I'd be using to the fairly fat wires of the bike, so I discovered these things which have mounting holes already on them. Trouble is: CRAZY expensive, considering it's still a goddamn FET inside ! If I blow it, I'll be crying....
                                      Wattevah...

                                      Comment


                                        #20
                                        Re: Master power switch for E-bike ideas

                                        Ok, I'm currently looking to grab one of those big FETs for this project along with some other stuff from a supplier I often order electronic stuffz from. I mean it's not like there's any urgency to it since it's friggin' winter and the bike is out of service for half a year...

                                        I WAS gonna do that, but then I thought I should take a step back and analyze what it is that I really need....and it's also here I discovered I don't know a lot of things about FETs, or at least some things I THOUGHT were clear ended up getting confusing.

                                        For instance this: I'm not sure what Vds means for my simple switch application. For the same price, I have a choice of two of those beefy boyz: THIS one which does 60v Vds and 400A or THIS one which does 100v Vds, but only 320A AND has a higher RdsOn. Realistically, I don't think I'll EVER draw that much current, unless maybe in very sharp pulses, so I aimed for the one with the lowest RdsOn. What does Vds mean in practical terms ? I tried reading about it as much as possible and I'm pretty sure it refers to the drop across D-S of the FET, regardless of whether it's on or off. In practice, which is what I care most about, I put my meter probes across D-S: if the FET is off (Vgs is 0), then Vds=VBat (?) because it's like an open switch ? If the FET is "on", Vds drops to nearly 0 because the "switch" is closed and conducting, having very little resistance of its own (RdsOn)?

                                        This makes sense and I understand it, but I'm struggling to interpret the SOA graphs. Take my soft-start circuit I'm trying to create, does this mean that Vds starts off high at Vbat when the FET is off, no matter what, and slowly goes down as the transistor opens up more and the caps charge ? Based on the SOA graph, what happens AFTER the transistor is on ? Since Vds is now low, does this mean I can safely draw up to 100A through it ?

                                        Then there's that high gate capacitance I need to address, but let's start with the basics. Feel free to enlighten me, as I feel ashamed for not being able to figure this out
                                        Wattevah...

                                        Comment

                                        Working...
                                        X