Farfle said:
so, got the regen button hooked up today, and it ran great, lots of stopping power. the only problem i am seeing, is that it is dumping ALOT of energy into the batteries at once as it brakes about 40-50% of what the disks can do. the voltage limit on the ebraking seems to be what is determining it, as when i put it on 60v, you cant tell if the button is being pushed or not, but on 70v it almost locks up the back tire it brakes so much. is there any other way to adjust this? i have a lyen 18fet controller.
Well, you could change the resistor that alters the regen voltage (like you have already to 70v from 60v) to one of those digipots, then control the digipot from an analog sensor on your ebrake handle. Set up the digipot range (with external series or parallel resistors) so that squeezing the brake lever just a little bit starts at a regen voltage just a few volts above your pack voltage, and the harder you squeeze the higher the voltage goes, which increases the current dumped into your pack and increases the braking force. This is an experiment I'd like to try eventually, as it should work on any controller that allows this. (in theory you could just change the resistor to a pot and wire that up to your ebrake handle, but it may react badly to having such long wires in the circuit--the digipot eliminates that by putting the pot at the physical location the resistor(s) were, but controls the digipot from your brake levers).
Other than that, no other way that I've found so far, although I have a theory that PWMing the ebrake line *might* modulate the braking. The PWM signal would come froma throttle sensor used in place of the ebrake sensor/switch, and a magnet on the brake lever, so that it would give an analog braking signal.
If the controller has the "throttle braking" option, then you could enable that and then I think that engaging the brake and modulating the throttle does the same thing as what I want to do with just the ebrake lever.
The catch with PWMing the ebrake input is that at least with the Lyen (and probably the other Infineon) 6FET controllers, AFACT there is a delay from the time ebrake is let go and the time the controller kicks back on, of at least half a second. I don't see a way to disable that in the software. It's possible there is an RC filter on the ebrake line coming in, and I'll have to figure out the schematic for that portion to see if it does. If so, I could simply remove the capacitor or change it to a very tiny one, or decrease the resistance, or both, so that it doesn't do this. If there's no RC filter then it's being done inside the MCU, and the only way to change that is to have someone in China rewrite the program so that it does not do this (unless someone here can do this, which I doubt, without source code/etc., or rewriting the entire controller program from scratch).
Older analog regen-capable controllers probably can be PWMed for the ebrake input to do this, easily. I have one I need to repair and try that out, one of these days.