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

Electric Motors and Controllers
Yungyakz   10 mW

10 mW
Posts: 31
Joined: Feb 03 2019 7:09am

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

Post by Yungyakz » Feb 26 2020 2:10pm

Hi,I just recieved my 18 mosfet controller in the post and noticed its different to the other boards posted on the forum and seems like a later version. It looks as if i can add a phase current sensor. Could anyone tell me how to hook up the programming, regen throttle and add a current sensor. Im planning on beefing up the traces, Changing caps, adding shunt from another dead kt controller and running 100a peak with this controller with K150E09NE mosfets.
Untitled-cvv.jpg
Untitled-cvv.jpg (208.8 KiB) Viewed 915 times
Untitled-22222 c.jpg
Untitled-22222 c.jpg (140.29 KiB) Viewed 915 times

fratto   10 µW

10 µW
Posts: 5
Joined: Jan 17 2020 2:18am

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

Post by fratto » Feb 26 2020 7:01pm

Yungyakz wrote:
Feb 26 2020 2:10pm
Hi,I just recieved my 18 mosfet controller in the post and noticed its different to the other boards posted on the forum and seems like a later version. It looks as if i can add a phase current sensor. Could anyone tell me how to hook up the programming, regen throttle and add a current sensor. Im planning on beefing up the traces, Changing caps, adding shunt from another dead kt controller and running 100a peak with this controller with K150E09NE mosfets.
Untitled-cvv.jpg
Untitled-22222 c.jpg
I would say the programming interface is THE OTHER ONE labelled "SOFT" in your second photo .
You can also check with a digital multimeter if your programming connector has the usual pin order ( from left to right, as showed in your photogragh ) : 5V, SWIM , GND, RST.

For more info:
https://opensourceebikefirmware.bitbuck ... eader.html
https://github.com/stancecoke/BMSBatter ... e-hardware

Regards and success :wink:
Last edited by fratto on Feb 26 2020 9:02pm, edited 1 time in total.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

KT motor controllers - Torque Sensor

Post by silentguy » Feb 26 2020 8:40pm

duplicate post. Deleted
Last edited by silentguy on Feb 27 2020 11:26am, edited 2 times in total.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 26 2020 8:42pm

I’m attempting to install the open source firmware on a KT24/36 SVPR - HRD01 controller and use a Sempu T4 Torque Sensor.


There is a throttle connector , speed sensor , and a PAS sensor.

How do I wire both the throttle and the torque sensor

There are 5 wires on the Sempu torque sensor.

I read in the thread about DC/ DC step down , and using pad x4 but I’m not sure how to do either of these.

Any help appreciated

Thanks.
B8A2275D-8C53-45DB-AB24-535D87197938.jpeg
B8A2275D-8C53-45DB-AB24-535D87197938.jpeg (177.98 KiB) Viewed 900 times

fratto   10 µW

10 µW
Posts: 5
Joined: Jan 17 2020 2:18am

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

Post by fratto » Feb 26 2020 8:49pm

kristof645 wrote:
Feb 20 2020 4:39am
Hello,
Fratto does use it with a ZWS sensorless controller after disabling FOC/interpolation.
I don't understand your answer.

EDIT : OK, I didn't see previous answer of Stancoke, but I still don't understand how it could work with Fratto's ZWS which is sensorless controller without adding sensor module.

Regards,
Christophe
Hi Christophe,

As Valopallo already explained, my motor DO HAVE the 3 signals from the motor hall sensors , which serves as feedback for the rotor position, necessary condition if you want to run the open source firmware. It is the connector labelled "motor-hall sensors" in this picture:
Controller-connections.png
Controller-connections.png (472.78 KiB) Viewed 899 times
You can read more about hall sensors here :
https://opensourceebikefirmware.bitbuck ... steps.html
https://opensourceebikefirmware.bitbuck ... tions.html

What I DO NOT HAVE in my KT motor controller board is the phase current sensor ( its place in my ZWS PCB is empty ), so that's why (before compiling and writing the firmware ) I had to disable the simplified FOC, as instructed by Stancecoke .

Hope now things would seem more clear
Regards

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 12:56am

silentguy wrote:
Feb 26 2020 8:42pm
I’m attempting to install the open source firmware on a KT24/36 SVPR - HRD01 controller and use a Sempu T4 Torque Sensor.


There is a throttle connector , speed sensor , and a PAS sensor.

How do I wire both the throttle and the torque sensor

There are 5 wires on the Sempu torque sensor.

I read in the thread about DC/ DC step down , and using pad x4 but I’m not sure how to do either of these.

Any help appreciated

Thanks.

B8A2275D-8C53-45DB-AB24-535D87197938.jpeg

Ok I think I’ve successfully flashed the KT 36 SVP controller with a open source torque sensor firmware.

Now I just need to figure out how to wire the 5 wires from the sempu torque sensor to the PAS 3wires / throttle 3 wires / speed sensor 3 wires ?

I have pics of the sempu wiring
Voltage is actually 8-60v on the T4 sempu torque sensor.
CED91DB4-672F-475D-AA76-2EF8BA167A1F.png
CED91DB4-672F-475D-AA76-2EF8BA167A1F.png (314.57 KiB) Viewed 890 times

Thanks for Any help

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 1:06am

I saw stancecoke replied in this thread
8BCB3A73-0F0C-41EC-B154-994E227D05AD.png
8BCB3A73-0F0C-41EC-B154-994E227D05AD.png (171.06 KiB) Viewed 885 times
What is the DC/DC step down ?

I have 5 wires on the sempu Torque Sensor , Including a yellow direction/speed wire.

Do I need all 5 wires ?

I found the x4 pad inside the KT 36svp controller
If I wire a length of wire and connect I to a thumb throttle will it work. ? 3 wires are needed
I use the other 2 wires from the throttle connector ?
Last edited by silentguy on Feb 27 2020 11:28am, edited 2 times in total.

User avatar
stancecoke   100 kW

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

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

Post by stancecoke » Feb 27 2020 3:48am

silentguy wrote:
Feb 27 2020 1:06am
I found the x4 pad inside the KT 36svp controller
You only need the x4 pad if you want to use a thumb throttle in parallel. Otherwise you can connect the torque signal to the throttle connector.
See the german wiki:
https://www.pedelecforum.de/wiki/doku.p ... einbindung

Image

regards
stancecoke

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 10:48am

Thanks for the link and Diagram.
This helps a lot

The fifth torque sensor wire ,Yellow wire speed / direction is not needed.
There a 6th blue wire for programming the torque sensor that is not used either.

Yes I want to use a thumb throttle and torque sensor in parallel.

Do I Keep the throttle controller connector white wire to the Torque sensor white wire. ?

So I would just add a wire to X4 and connect to the physical thumb throttle white wire?

What about the other 2 thumb throttle wires , red , black ,
I just connect those to 5v and ground ?

That means 3 wires are going to white throttle connector on the controller ; 1 White wire from Torque sensor and 1 wire from X4 and 1 wire from the thumb throttle.


Or is it as simple as this :
White wire from Torque Sensor goes to pad X4 inside the KT controller.
White, Red, Black wire From the thumb throttle on the handlebars go to the white ,red , black wires of the Throttle connector that is wired outside the KT controller ?

Regarding the DC-DC step down circuit.
I am using the newer Sempu T4 which has voltage rating of 10v - 60v.
I don’t think I need the DC-DC step down voltage circuit then ? The Sempu T4 can handle the 36v from the battery or display directly ?

Thanks for the help.
Last edited by silentguy on Feb 27 2020 11:36am, edited 3 times in total.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 11:10am

I’m still not clear on the wiring of X4 and the white torque sensor wire from the Sempu T4

I wire the white sensor from the Sempu T4 to X4 ?
I wire the White, Red, Black wires from the thumb throttle to the controller throttle connector ?

Sorry for all the questions.

Here’s the English translation from the German forum . :

Here it is described how a torque sensor can be connected. General information on torque sensors can be found here: Torque sensors for pedelecs

The torque sensor typically provides a pulsed speed signal like a PAS and an analog torque signal like a thumb throttle. The connection is correspondingly simple. If you want to operate a thumb gas parallel to the torque sensor, the torque signal must be connected to connection X4, see Chapter 2 at the bottom. The torque sensors usually require their own power supply, which can be provided from the battery voltage via a DC / DC converter.

Here is an example of an E-Rider T9 sensor

User avatar
stancecoke   100 kW

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

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

Post by stancecoke » Feb 27 2020 2:28pm

silentguy wrote:
Feb 27 2020 11:10am
I wire the white sensor from the Sempu T4 to X4 ?
I wire the White, Red, Black wires from the thumb throttle to the controller throttle connector ?
Yes, but you have to use the Torque_from_X4 branch for this setup.

The T4 sensor works directly with 36V, so you don't need a DC/DC converter in this case.

regards
stancecoke

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 3:41pm

Thanks again stancecoke.

I will try it with the Torque from T4 branch of the firmware you have linked.

I was using a different branch.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 27 2020 6:19pm

I flashed the kt36svpr with torque T4 branch of the firmware
It said program memory succeeded.

Update : couldn’t get the torque sensor working.

I’ve wired everything correctly I think but the throttle doesn’t work nor the motor turn at all.

I switched to just trying to get thumb throttle and PAS magnet sensor working first to confirm that the controller works.
I’m using known KT 36 firmware from the Master branch

The throttle turns the motor to about 10mph for a brief time then stops.
The PAS speed/ cadence sensor at the crank does the same thing

I think I need to adjust the hall phase angles now ?
I saw someone just did this , I’ll look at that post but any advice appreciated as well.

Also I am using a KT lcd5. I assume this is same as KT lcd3 for using the OSEC parameter configurator GUI , since there is no choice for lcd5, only lcd 3.

Is there some specifics I’m missing about lcd5 ?

I’ll post a pic of the firmware settings I am using.

Thanks
C5B05107-ED9B-4E42-A7DD-C1E571E54963.jpeg
C5B05107-ED9B-4E42-A7DD-C1E571E54963.jpeg (91.99 KiB) Viewed 815 times

This is the ini file

12
40
3125
1375
40
80
185
116
150
500
0
237
76


30
45
60
80
100
50
50
50
1500
0.5
0.1
106

1.9
false
64000
40
127


true
false


false
1
43
86
128
false
false
171
213
0.0
12930
69
128
225

szkuba   10 µW

10 µW
Posts: 6
Joined: Nov 26 2018 2:56pm

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

Post by szkuba » Feb 28 2020 8:56am

My own experience is that T4 output voltage is variable across different supply voltage. IT means that at max battery voltage IT will produve higher output values. While at lowest battery voltage it will produce lower output values at the same torque level. That is why i have used DC/DC converter to provide stable 12or 24V where T4 works stable. Best would be test you sensor output voltage at max and minimum battery voltage supply so could see for yourself

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 28 2020 10:13am

szkuba wrote:
Feb 28 2020 8:56am
My own experience is that T4 output voltage is variable across different supply voltage. IT means that at max battery voltage IT will produve higher output values. While at lowest battery voltage it will produce lower output values at the same torque level. That is why i have used DC/DC converter to provide stable 12or 24V where T4 works stable. Best would be test you sensor output voltage at max and minimum battery voltage supply so could see for yourself

Thanks for that advice. I’m using 36V battery
So it varies from 41 to 31v
I’ll look into the dc-dc later.
For now I’ve just bypassed the T4 Sempu and will try to get PAS and throttle working on the same KT36svpr controller.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 28 2020 10:17am

szkuba wrote:
Feb 28 2020 8:56am
That is why i have used DC/DC converter to provide stable 12or 24V where T4 works stable. Best would be test you sensor output voltage at max and minimum battery voltage supply so could see for yourself
Do you have link or recommendation for a good dc-dc step down circuit.
I think I’ll try to find both a 40v and 60v one.

User avatar
stancecoke   100 kW

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

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

Post by stancecoke » Feb 28 2020 2:56pm

silentguy wrote:
Feb 27 2020 6:19pm
Update : couldn’t get the torque sensor working.
Hm, it would be helpful to connect a USB-TTL converter or a Bluetooth module and flash the firmware in debug mode to see what's going wrong.

If the motor is not running properly, you have to adjust the motor specific angle first.

regards
stancecoke

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 28 2020 8:19pm

I got it to work with the torque sensor Sempu T4

I had to change gear ratio to 50 when using internal speed sensor.

Its a single fixed gear on the rear , 52tooth chain ring at the front.

For external speed sensor I adjusted the throttle voltages and it seemed to mostly work.

I had some other problems. , I think a short, as the mosfet started smoking. Heat sink got very hot.

It was getting too hot. I did limit the current and voltage but I think the 7A rating on this KT was not enough.

I’ll need to order a 9 mosfet KT now.

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

LSW 675 51ohm resistor or fuse ?

Post by silentguy » Feb 29 2020 2:04am

What is the 51ohm resistor doing.?
There’s a heat resistant heat shrink tube on one of the leads.
See mouse arrow in the pic near the blue wire , it pointing at the resistor

Is it a fuse ?

Reason I ask is mine is burnt out.

What should I replace it with ?
Fuse of some value ?
I can find a 51 ohm resistor but I’m not sure about the other lead side.

It came that way from the seller.
Used controller I think.
F8CD3DF5-33D5-4E7F-8861-CBDA13DC8119.jpeg
F8CD3DF5-33D5-4E7F-8861-CBDA13DC8119.jpeg (115.89 KiB) Viewed 758 times

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 29 2020 1:03pm

Ok I found that it’s just a resistor with a heat resistant tube.

I ordered a 6 watt resistor as it’s a bit stronger.

5FFC4757-4E10-4D49-86CB-78DB78534303.jpeg
5FFC4757-4E10-4D49-86CB-78DB78534303.jpeg (73.32 KiB) Viewed 725 times

szkuba   10 µW

10 µW
Posts: 6
Joined: Nov 26 2018 2:56pm

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

Post by szkuba » Feb 29 2020 1:56pm

silentguy wrote:
Feb 28 2020 10:17am
Do you have link or recommendation for a good dc-dc step down circuit.
I think I’ll try to find both a 40v and 60v one.
mine was kind of high power but i found this https://www.ebay.com/itm/DC-DC-Buck-Ste ... SDj8N-CL7g on Wiki Pedelec forum : https://www.pedelecforum.de/wiki/doku.p ... einbindung

User avatar
stancecoke   100 kW

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

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

Post by stancecoke » Feb 29 2020 2:00pm

silentguy wrote:
Feb 29 2020 2:04am
See mouse arrow in the pic near the blue wire
Can you post some more photos of the pcb (processor, opamps, shunts?)
I'm wondering if my open source firmware for Lishui controller would run on the LSW 675 (where the 675 stands for the Lishui-customer, BMSBattery, I think)

regards
stancecoke

szkuba   10 µW

10 µW
Posts: 6
Joined: Nov 26 2018 2:56pm

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

Post by szkuba » Feb 29 2020 2:15pm

I have went through last 20 pages of the thread but did not found the answer what is behind to those perimeters:
1. Dynamic assist level?
2. Speed influences Tq Sensor?
can someone explain would be great to understand :)
3. I was wandering how the cadence is being calculated? Is this the number of impulses in defined perios of time like 0,5 sec or any other way is this calculated
4. Would the KT-LCD4 work with open firmware?

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 29 2020 9:36pm

szkuba wrote:
Feb 29 2020 1:56pm
silentguy wrote:
Feb 28 2020 10:17am
Do you have link or recommendation for a good dc-dc step down circuit.
I think I’ll try to find both a 40v and 60v one.
mine was kind of high power but i found this https://www.ebay.com/itm/DC-DC-Buck-Ste ... SDj8N-CL7g on Wiki Pedelec forum : https://www.pedelecforum.de/wiki/doku.p ... einbindung
Thanks

silentguy   100 W

100 W
Posts: 158
Joined: Sep 15 2009 6:07pm

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

Post by silentguy » Feb 29 2020 9:40pm

stancecoke wrote:
Feb 29 2020 2:00pm
silentguy wrote:
Feb 29 2020 2:04am
See mouse arrow in the pic near the blue wire
Can you post some more photos of the pcb (processor, opamps, shunts?)
I'm wondering if my open source firmware for Lishui controller would run on the LSW 675 (where the 675 stands for the Lishui-customer, BMSBattery, I think)

regards
stancecoke
1270EEE4-EE02-4380-BCDC-ADF269693854.jpeg
1270EEE4-EE02-4380-BCDC-ADF269693854.jpeg (102.54 KiB) Viewed 708 times

Post Reply