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

Electric Motors and Controllers
casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 8:10am

geofft wrote:
Jan 10 2018 8:06am
Just been out for a short test ride and have to say that the firmware is working really sweetly now, a credit to you guys. Still one or two details to tidy up but the major stuff all works well.
I don't have much time for this today but will ride some more and feedback later this week.
Later, when you write your feedback, please include what you value that you get with this firmware, comparing to original one.
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 8:28am

honya96 wrote:
Jan 10 2018 6:22am
I have the start compiling. bat edited with timeout /t -1 /nobreak but It does not work with java tool. It needs to be added in the app? :shock:
Sorry, I think there's some confusion with our two java tools again. We have two Start_Compiling.bat-files. One in the firmware folder, that is used by the OSEC Parameter Configurator.jar and by eclipse, if you edit the sourcecode. This Start_Compiling.bat can be used to compile and flash just by doubleclicking it, also.

The firmware_configuration_tool.jar uses the Start_Compiling.bat file that's located in the configuration_tool/windows_scripts folder. Double clicking on this will not work properly.
So if you want to use the firmware_configuration_tool.jar, you have to edit the configuration_tool/windows_scripts/Start_Compiling.bat to avoid the immedeadly closing of the cmd-window :?

Regards
stancecoke

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 11:59am

I found another way to calculate FOC_READ_ID_CURRENT_ANGLE_ADJUST.
I measured with my Q85 and Q11 motors and the values are really different:
- Q85: 143
- Q11: 114

The value measured with my Q85 gave near results by the vale I measured using the other process: 137 VS 143.

Read here: https://opensourceebikefirmware.bitbuck ... DJUST.html

Image
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

geofft   1 kW

1 kW
Posts: 346
Joined: Nov 09 2012 9:41am
Location: Berkshire UK

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

Post by geofft » Jan 10 2018 12:45pm

casainho wrote:
Jan 10 2018 11:59am
I found another way to calculate FOC_READ_ID_CURRENT_ANGLE_ADJUST.
I measured with my Q85 and Q11 motors and the values are really different:
- Q85: 143
- Q11: 114

The value measured with my Q85 gave near results by the vale I measured using the other process: 137 VS 143.

Read here: https://opensourceebikefirmware.bitbuck ... DJUST.html

Image
This looks like a candidate for the "Advanced Options" menu in your confiurator..... :D

Seriously though, I may actually try this sometime, I still have my old oscilloscope in the back of the shed somewhere.
Last edited by geofft on Jan 10 2018 1:41pm, edited 2 times in total.
BBS02 V2 48v 750w, 12s lipo.
Q128H (36v 201rpm), KT36/48SVPR, LCD3, 48v 12s lipo.

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 12:55pm

The firmware configuration tool already supports defining that variable value.

I documented FOC tests here: https://opensourceebikefirmware.bitbuck ... rison.html

You just need to find the correct value for that variable.

I wonder if no one cares with original firmware.........
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 1:09pm

casainho wrote:
Jan 10 2018 12:55pm
I wonder if no one cares with original firmware.........
We just don't know. If the motor starts in classical six steps, you can read the BEMF from the floating phase (as sensorless block commutation does) and compare it with the hall signal... The user won't recognize it.

We can check this with the original firmware and the oszi....

regards
stancecoke

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 1:17pm

stancecoke wrote:
Jan 10 2018 1:09pm
We just don't know. If the motor starts in classical six steps, you can read the BEMF from the floating phase (as sensorless block commutation does) and compare it with the hall signal... The user won't recognize it.
That would be great, but S06S harware can't read the phases voltage/BEMF. It only reads battery voltage.
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 2:06pm

I think, it has to be able to read the BEMF, as the sensorless KT36-ZWS is exactly the same controller just without the phase current sensor....

regards
stancecoke

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 2:11pm

Do you have pictures of that controller?? I can't believe...
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:14pm

I Think sensorless has external board which reads BEMF and feeds signal into hall pins.

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:15pm

So the controller gets clasic hall signal

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:34pm

Still not running. looks like communication with controller works, but the firmware compiling does not. new log should be same as first, there is still a lot of "nelze najít" which means "Cant find".
Attachments
log2.txt
(10.86 KiB) Downloaded 41 times

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 2:38pm

honya96 wrote:
Jan 10 2018 2:14pm
I Think sensorless has external board which reads BEMF and feeds signal into hall pins.
may be, but I have seen no picture with an additional PCB (only for light switch) and in this offer it's written, that it's suitable for sensor- and sensorless mode...
http://dragonbike.de/bike/ebike-control ... s-15a.html

regards
stancecoke
Last edited by stancecoke on Jan 10 2018 2:46pm, edited 1 time in total.

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 2:41pm

honya96 wrote:
Jan 10 2018 2:34pm
Still not running.
Looking at the log-file, the compiling and flashing was OK. Which settings did you use?
Please try in simple throttle mode and with correct battery setting (to avoid undervoltage shut off) first.

regards
stancecoke

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:44pm

stancecoke wrote:
Jan 10 2018 2:38pm
honya96 wrote:
Jan 10 2018 2:14pm
I Think sensorless has external board which reads BEMF and feeds signal into hall pins.
may be, but I have seen no picture with an additional PCB (only for light switch) and in this offer it's written, that it's suitable for senor- and sensorless mode...
http://dragonbike.de/bike/ebike-control ... s-15a.html

regards
stancecoke
I have seen that. But I dont know where and cant find it.

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:46pm

stancecoke wrote:
Jan 10 2018 2:41pm
honya96 wrote:
Jan 10 2018 2:34pm
Still not running.
Looking at the log-file, the compiling and flashing was OK. Which settings did you use?
Please try in simple throttle mode and with correct battery setting (to avoid undervoltage shut off) first.

regards
stancecoke
I get no throttle, pas, or brake icon response. at 13s setting 50.2v battery voltage 4x12v for testing on table.

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:48pm

just an interesting find when looking for the sensorless board. My 18fet controllers pcb is ready for this.
Attachments
dual-controller.png
dual-controller.png (135.07 KiB) Viewed 1196 times

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 2:49pm

honya96 wrote:
Jan 10 2018 2:44pm
I have seen that. But I dont know where and cant find it.
I've seen that only on very old Lishui controllers...
regards
stancecoke

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 2:52pm

honya96 wrote:
Jan 10 2018 2:46pm
I get no throttle, pas, or brake icon response. at 13s setting 50.2v battery voltage 4x12v for testing on table.
Hmm, perhaps your different board layout has a different pinning for the perpherals on the µC?!

regards
stancecoke

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 2:53pm

stancecoke wrote:
Jan 10 2018 2:49pm
honya96 wrote:
Jan 10 2018 2:44pm
I have seen that. But I dont know where and cant find it.
I've seen that only on very old Lishui controllers...
regards
stancecoke
maybe thats it.... but I think its the same case here beacuse there are 3 pins labeled NOHALL

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 2:59pm

honya96 wrote:
Jan 10 2018 2:46pm
I get no throttle, pas, or brake icon response. at 13s setting 50.2v battery voltage 4x12v for testing on table.
Please confirm the LCD version you are using.
Does it show any battery bar signal? Any speed value? Any brake or throttle symbol?
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

User avatar
stancecoke   100 kW

100 kW
Posts: 1019
Joined: Aug 02 2017 2:56pm

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

Post by stancecoke » Jan 10 2018 3:03pm

honya96 wrote:
Jan 10 2018 2:53pm
maybe thats it.... but I think its the same case here beacuse there are 3 pins labeled NOHALL
funny, casainho has a detailed picture of the S06P with the additional circuit board at bitbucket :-)
https://opensourceebikefirmware.bitbuck ... _S06P.html

regards
stancecoke

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 3:41pm

stancecoke wrote:
Jan 10 2018 3:03pm
honya96 wrote:
Jan 10 2018 2:53pm
maybe thats it.... but I think its the same case here beacuse there are 3 pins labeled NOHALL
funny, casainho has a detailed picture of the S06P with the additional circuit board at bitbucket :-)
https://opensourceebikefirmware.bitbuck ... _S06P.html

regards
stancecoke
sooo.. thats where I saw it :lol:

honya96   1 kW

1 kW
Posts: 328
Joined: Mar 05 2015 9:38am
Location: Czech Republic

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

Post by honya96 » Jan 10 2018 3:44pm

casainho wrote:
Jan 10 2018 2:59pm
honya96 wrote:
Jan 10 2018 2:46pm
I get no throttle, pas, or brake icon response. at 13s setting 50.2v battery voltage 4x12v for testing on table.
Please confirm the LCD version you are using.
Does it show any battery bar signal? Any speed value? Any brake or throttle symbol?
s-lcd3 v3,0 72v ( works down to 50v with all my 36,48v controllers)
now I am back with another kt-lcd3 v3.0 0.6F 24-48v and another controller but it has the same board... maybe I will try the 12fet now. its the bmsbattery 40A same as yours.

edit: no brake icon, as i mentioned before. empty battery.

casainho   1.21 GW

1.21 GW
Posts: 3584
Joined: Feb 14 2011 2:43pm

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

Post by casainho » Jan 10 2018 4:38pm

honya96 wrote:
Jan 10 2018 3:44pm
s-lcd3 v3,0 72v ( works down to 50v with all my 36,48v controllers)
now I am back with another kt-lcd3 v3.0 0.6F 24-48v and another controller but it has the same board... maybe I will try the 12fet now. its the bmsbattery 40A same as yours.

edit: no brake icon, as i mentioned before. empty battery.
Rotate de motor by hand and see if it is hard to push, when comparing to the controller poweered off.

See that no one ever tested the 72v controller version.

I would say it has different power resistors to measure the battery voltage and so the firmware triggers undervoltage -- try to increase number of cells and there should be a value where it does not trigger.

Even better, measure with a multimeter your battery voltage and also the voltage at STM8 pin, then I can update the firmware for 72v version. Try also to read the resistors value.
Developer of the Flexible OpenSource firmware for EBike motor controllers (TSDZ2 and KT) and LCDs (KT-LCD3 and Bafang 850C color LCD).

If you like my work, please consider making a donation. I am being using the donations to buy needed resources for my developments. My paypal: casainho AT gmail.com.

Post Reply