Search found 455 matches

by stancecoke
Feb 22, 2018 2:14 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Does this work also with mid-drive motors like the Bafang BBSHD? I'd like to buy the S12S for a 48V battery pack. I think Stancecoke is the only one that tested on such motors. The firmware works with a Shengyi 48V Middrive Motor (used in 2016 "Fischer" - E-Bikes ). The testing with a yamaha middri...
by stancecoke
Feb 22, 2018 4:03 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I will consider that I read battery and motor currents. "motor current" is a much better wording than "phase current" :-) But I don't know, if it helps to avoid burning FETs, as we still don't know the phase current.... (except Phase B, where we have the additional ACS711/712 sensor). Regards stanc...
by stancecoke
Feb 20, 2018 3:34 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I've no suggestion, as I'm struggling myself at this topic. A quite interesting plot from the discussion linked above: http://vedder.se/forums/download/file.php?id=499 As you can see, the current in one phase can be quite high, while the current in the other two phases is negative... So I don't unde...
by stancecoke
Feb 20, 2018 3:06 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

The S06S has 2 signals from shunt, one filtered (battery current) and other not filtered (motor phase current). I'm not happy with this wording at all. It's not the real battery current, as the shunt is placed between the gnd of the MOSFETs and the big capacitors. And it's not the real phase curren...
by stancecoke
Feb 20, 2018 8:25 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

... 3. The mathematical model says that: battery current = duty_cycle * motor phase current. As the duty_cycle was 33%, so the motor phase current should be (battery current / 0.33) = 2.5/0.33 = 7.6 amps <--- the measured values seems to be inline with the mathematical model. To be honest, I don't ...
by stancecoke
Feb 18, 2018 1:38 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Yes, I am really being testing the ebike with our firmware and this bicycle is really strong :-) -- that was yesterday and everything went ok: Is stuntman you second profession? :-) I remember your video with testing regen... Great, that the PI-controller works satisfying now! Are you using human p...
by stancecoke
Feb 18, 2018 8:21 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

casainho wrote:
Feb 18, 2018 7:04 am
Does anyone knows if is possible to reset all the options on LCD??
Have you tried Parameter C10 for resetting?
casainho wrote:
Feb 18, 2018 7:04 am
Note that I configured this LCD to used the latest protocol, just like the other LCD5 that works well.
What is your setting at Parameter C11?

regards
stancecoke
by stancecoke
Feb 17, 2018 12:55 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

casainho wrote:
Feb 17, 2018 11:37 am
Can be other way, simple, to indirectly measure the motor current?
I think, that can be only done by a mathematical model.

Image

A simple ramp like honya96 suggested will be easier.

regards
stancecoke
by stancecoke
Feb 15, 2018 11:08 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Go ahead an show the results on a similar graph as I don't believe will be a big difference. OK, I'll do some logging of the raw ADC-values on a real ride, but this will take at least two weeks to prepare. I can try the "thumb-brake" with the BionX in "real life" then, too :wink: regards stancecoke
by stancecoke
Feb 15, 2018 9:09 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Seems you missed my new code -- you can see on the commits diffs: Ah, yes, I didn't recognize the changes in the motor.c :-) You will get less scatter with the averaged values, but of course it will work with the single maximum value of one crank revolution also. But you get a new torque value only...
by stancecoke
Feb 15, 2018 8:16 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I can't imagine being less scatter using the average. Do you have a link were I can read more about it for a similar situation? I had a closer look to you code now. As far as I understand, you are averaging the torque-signal over four AD-conversions, in the fixed frequency of the slow loop. So you ...
by stancecoke
Feb 14, 2018 12:39 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Hmm, I don't understand your latest code in detail... I can't see the typical sinusoidal shape in the torque-curve?! Why don't you average the torque signal over a crank revolution? This would avoid the scatter. I think you are doing many things much more complicated than necessary, e.g. a reset of ...
by stancecoke
Feb 13, 2018 12:28 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

We've already exercised the procedure to get the right calibration factors for the battery current measurement successfully! :)
https://endless-sphere.com/forums/viewt ... 8#p1352618

This can be easily repeated for different shunt/OP-gain values of any controller...

regards
stancecoke
by stancecoke
Feb 13, 2018 11:11 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I believe the phase current controll at zero/near zero speed is not ok yet. We are not controlling the max value of the phase current. The phase current is only used for doing the simplyfied FOC. Even this control is not active at very low speed. if (ui16_motor_speed_erps > MOTOR_ROTOR_ERPS_START_I...
by stancecoke
Feb 10, 2018 11:30 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Stancecoke, I am thinking how to improve the torque sensor code -- do you have suggestions? The main issues is that value fluctuates a lot every cadence... I would like to detect a good value from start.. The torque-signal is a kind of sinusoidal whithin one crank revolution, that's physics. So I s...
by stancecoke
Feb 09, 2018 10:40 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

casainho wrote:
Feb 09, 2018 6:36 am
Added notes about the original mobile app
Hmm, so it seems, that the bluetooth system is really poor.... I think we can do it much better. But we need to know, where the wires from the BT-Module are connected to on the controller PCB :wink:

regards
stancecoke
by stancecoke
Feb 07, 2018 12:05 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I took a closer look to your PI-controller code now. There are two questions: 1. Why do you set the integral part to zero immediately, if the target is zero? This will cause massive regen on a direct drive and even with a freewheeled motor this will cause high inertia forces on the rotor. 2. Why do ...
by stancecoke
Feb 07, 2018 10:12 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Stancecoke option should be the best but even like that, seems far from ideal since with negative errors on PI controller, the pwm will be immediately set to zero. ??? I don't understand your argumentation... The output (= duty cycle) is the sum of the proportional part and the integral part. The d...
by stancecoke
Feb 07, 2018 4:27 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Fine to hear, that it's working! Can you log the communication on your smartphone and upload the logfile, please? This would be great!! Where are the blue, green and the yellow wires connected on the PCB of the controller? https://www.pedelecforum.de/forum/index.php?attachments/kt-ble01-jpeg.153973/...
by stancecoke
Feb 06, 2018 3:28 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Does this mean, that you can't connect the app with the module? The connection works for me, the Bluetooth Symbol is highlighted in blue colour in the upper right corner of the home screen. But there must be a handshake protocol, as the app sends "0x57" to the module in recent time intervals. If I s...
by stancecoke
Feb 06, 2018 2:35 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

The Bluetooth version of S06S, because I hope to start play with it when the firmware is stable. Great! Can you check the name of the BT-module that is shown in connect screen of the Kunteng app? Here a screenshot with the Lishui BT-module (that doesn't work with the Kunteng App of course) Thanks s...
by stancecoke
Feb 03, 2018 2:24 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

honya96 wrote:
Feb 03, 2018 2:13 pm
12fet has no 100k to GND so maybe better to remove on 18fet also.
You can keep the 100k pulldown, it's good to have defined conditions, if x4 is left open!

regards
stancecoke
by stancecoke
Feb 03, 2018 2:02 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Done, 0.047v at x4 with 18fet Great!! Then the thumbthrottle should work now as a "break pedal" :-) I tried a 1K as pulldown between X4 and gnd, this works also, but shifts the voltage level a little... So the user can decide, which way he wants to go to use regen throttle... Is the motor running w...
by stancecoke
Feb 03, 2018 12:33 pm
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

Yes, that's the configuration on my S06ST. The problem is, that the linear hall-sensor is not able to pull down the voltage, pehaps we can pull it down with a e.g. 1k resistor from X4 to gnd, and the Hall sensor is able to pull it up against this resistor, I'll try... But maybe it is better to remov...
by stancecoke
Feb 03, 2018 6:30 am
Forum: Motor Technology
Topic: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)
Replies: 1768
Views: 47499

Re: Flexible OpenSource firmware for BMSBattery S/Kunteng KT motor controllers (0.25kW up to 5kW)

I checked the voltage on the open X4 at my 6FET again, there are 5V on it, too. With a ~10k Poti connected to gnd and +5V and the wiper to X4, it should work with the 18FET as well! Sorry for that confusion :oops: It works with the poti, but it doesn't work with the thumbthrottle, as it can't pull t...