Hi all. I have a question regarding brake activation signal to the controller. Has anyone done anything that blocks the brake signal if the throttle is engaged. I ask this because I've been riding most of my life and I commonly apply brake pressure while giving throttle (mostly on low speed maneuvers). Having the motor cut out in a slow turn could result in dumping the bike.
I've considered using a microcontroller to determine when to apply the brake signal and when not to. But I wanted to ask if anyone has thoughts about this. I actually don't know how production EV motorcycles behave in this regard....
You don't specify details about your project, vehicle, electronics, battery, etc., so I can't give you any specific advice, so some general thoughts you'll have to look up details, variations, etc on how all these things work, and find out which variations fit your project and parts, and then figure out what the consequences are for your parts and usage cases are.
First...do you need, or want, the "ebrake" at all?
If you have adequate mechanical brakes, those are perfectly reliable in every situation that braking will be needed, and you won't need special considerations under all the various conditions where electric braking can't be done normally or at all, without risk of damage to various parts of the system, or causing a crash, etc.
If you're using a direct drive hubmotor in a wheel, then motor braking (regen) is fairly straightforward but there are many variations of it, depending on your specific controller design, and if it has any options, how those are setup.
If you're not using a dd hubmotor, you probably don't want to do any form of motor braking, because it will have to pass all that braking force *backwards* thru your chain, belt, or shaft that your motor uses to drive the wheel, and yank on it and on your suspension, etc. If you have a transmission of any kind between them, it also has to slam the braking forces thru that, too, backwards. If you have a clutch then braking wont' even work unless that remains engaged to transmit all the braking torque backwards thru it into the motor.
If your battery's BMS doesn't control charging thru the same port as discharging, then it has no way to prevent use of regen recharging it even when the battery is in some fault condition that it should not be charged, etc..
If it does control it thru the same port, then if it does prevent charging you could blow up the controller and anything else on the battery bus from the spike in voltage resulting from regen still occuring when the battery disconnects itself from the bus.
If regen current under whateer braking conditions you ahve at the time exceeds what the BMS or cells can handle, it can damage them.
Regen is going to get you back a minimal amount of energy, probalby a couple of percent in a typical use case. You might get 5% if you are in a lot of stop/start traffic.
Etc.
Next, how does your controller work?
Many of them use the brake signal to turn on the regen, then use the throttle to modulate it. Note that this is a dangerous way to do it because it isnt how riders are already trained to operate their bikes, and wouldn't be how they would react in an unthinking situation (until htey had practiced it for as many years or more that they'd already done to ingrain the normal braking reflexes).
If yours has an analog input for the brake, then you'd use a separate throttle type control for it--most commonly something attached to an existing brake control. On the SB Cruiser trike (bicycle class, not MC) I use a cable-operated-throttle COT pulled by a regular brake lever (left side) to operate the rear variable-regen braking on the twin DD hubmotor wheels. You can do the same thing on yours if you add a cable-puller to your existing brake control. If you want this kind of system to generate the maximum recovered energy, I'd recommend setting it up to pull the COT for maximum braking before your mechanical brakes engage at all; this will change the way the whole system feels for braking. If you just want the regen for additional or backup braking force, just parallel the COT pull to the mehcnaical pull to give proportional regen resonse to the mechanlcl repsonse.
If yours has *no* analog brkaing at all (fairly common) but just on/off, it's probably not really safe for motorcycle speed/conditins if it actually creates useful braking forces, becuause you ahve no control with it, it'd be like just slamming on your brakes every tiem you use it. If your controller has an adjustable regen current then you should adjust it to your liking but I'd set it below the point at which it could break traction even under worst-case traction loss conditions, whihc makes other braking condition forces probably too low to be useful. If it has no adjustment, you can experiemnt with it, but personaly I thnk they don't have a useful place in this use case. But in this type of brkaing, you can just use a separte button to engage it, mounted on your brake lever or foot control, that you press only when you want to use it. There are a number of ways to do this depending on your specific usage methods.
If yours has no actual braking function and it's just a motor disable, you can just connect it to the run/stop line on your handlebar controls instead, or some other easily-reached switch in case of throttle malfunction (broken ground, etc).
I had other thoughts but JellybeanThePerfectlyNormalSchmoo interrupted them for playtime and attentionals....