EBiCS firmware compatibility and Bafang support

jussike

1 µW
Joined
Nov 8, 2024
Messages
4
Location
finland
Hi

I have LSW772-64-9F controller (from old yosemite bike) and I guess it's compatible with EBiCS, right? I checked steps described here: Home
I guess my display manufacturer is Bafang and now I'm confused because this text has been since Jun23 on EBiCS readme "Caution, the Bafang Display protocol is recently not running in the master branch!" Is it really still broken? There is a fix commited after that: Bafang protocol now working properly · EBiCS/EBiCS_Firmware@527c1c3

So, Will it work with this controller and display? I'm a professional programmer so I think I can do some debugging if needed but I don't want to brick it because I don't have a spare.

@stancecoke
 
It works again, I have to update the ReadMe :D

I wasn't aware, that there is this disclaimer.

regards
stancecoke
 
Thanks for the reply.

It seems that your code assumes there is a hall sensor attached to three gpio pins. My sensor has only three wires: voltage, ground and signal. So I may have to analyze the protocol and write a function for decoding the signal. Am I on the right way? @stancecoke
 
Oh, crap. It seems that my bike has no hall sensor at all. The hub motor has one sensor which seems to be a speed sensor. So should I write sensorless motor control? :(
 
So should I write sensorless motor control?
There is a sensorless implementation already. It uses a variant of the old observer algorithm from the VESC. But you have to tune it manually, there is no detection function for resistance, inductivity and flux.
https://github.com/EBiCS/EBiCS_Firmware/tree/Sensorless_VESC

This branch is not used very often, so there is not much experience with different motors.

regards
stancecoke
 
Thanks for you reply @stancecoke :)

That's cool that there is already an implementation. I tried it and did resistance and inductivity measurements. How should I get the flux parameter and gamma? I didn't found datasheet for the motor. Is there any other parameters to tune for adaptating algorithm? OFFSET_A for instance?
Currently the motor is not spinning almost at all.
 
The factors in the config.h are not in physical units. I found them just by trial and error.
 
Back
Top