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

I wish that same could happen with KT motor controllers firmware but I understand it is much more complex because TSDZ2 hardware combinations are way smaller and so less complex firmware and configurations...

This is a historic mark:

Time to time I get some donations, which I am being using to buy resources for my investigations and developments. I have not been grateful publicly or privately the donations because I have so little time that is not enough for the developments that are needed to be done.

This days I got a donnation with the following message:
Sold a few FOS firmware products on my Website http://www.electrifybike.com/store/c37/TSDZ2_Flexible_Open_Source_Firmware_Products.html I will be contributing 10% of sales to the developers for a period of time.

I am spreading this because this shop because other than being friendly for the developent of our OpenSource firmware for TSDZ2 (that can be applied for other ebike motor controllers, or any BLDC motor controller), this shops sells the needed TSDZ2 and LCD3 already programmed with our firmware and connections!!!
I will link to this shop on wiki as this may be very important for some users!!



https://www.electrifybike.com/store/c37/TSDZ2_Flexible_Open_Source_Firmware_Products.html#/
 
casainho said:
this shops sells the needed TSDZ2 and LCD3 already programmed with our firmware and connections!!!

Wow, that's brave... hopefully he has a good legal expenses insurance for product liability issues. :shock:

wrobi said:
This is a special edition for wheelchairs, because it have "-1" gear level for reverse.

I think, that our firmware could work with your controller, but of course we have no reverse function implemented.
I'm not sure if you could use your KT-LCD5 with an obviously "special" firmware. Perhaps you would have to buy a "normal" one.
Be aware, that all you are doing is at your own risk and that there is no way back to stock firmware, once you flashed the custom one.

wrobi said:
Tried original KT app, and some BLE terminal. is it possible to use it only for factory setting?

As written before, I have no experience with the original KT-BT-Module...

regards
stancecoke
 
kotofos said:
Hi
in repo readme it is written
What doesn't work:
Block commutation during start-up

But what that actually mean? Isn't it normal to start motor in 6 step mode?
No it is not.

When I had 6 steps working and then switching the PWM for next mode, I got an issue with the current controller, were it would fail and keep increasing and then burn mosfets.
 
kotofos said:
So, what is current startup procedure? Can motor start from standstill?
Please give a look at the source code to understand.
 
stancecoke said:
Offroad mode can be activated by the brake lever as known or by a "magic" touch to the smarthphone screen

More info about the "magic" touch please if it's still implemented into the app. Thanks. ;)
 
I'm planning to put another motor to the front. I have S06S -controlling the rear DD motor and KT36ZWS controlling the front geared hub. I want to use separate batteries for each of them and share the signal wires from throttle, PAS and brake for both controllers. The instructions state that KT36ZWS controller cannot use FOC so it must be disabled. I cannot seem to find anything from the java tool so I assume this must be done straight from the code. How?
 
Valopallo said:
I cannot seem to find anything from the java tool

Just uncheck the checkbox "enable rotor angle correction" This will disable FOC.

68747470733a2f2f7777772e706564656c6563666f72756d2e64652f77696b692f6c69622f6578652f66657463682e7068703f773d36303026746f6b3d666265663234266d656469613d656c656b74726f746563686e696b3a63726f6d652d625f626c756f7365632e706e67


regards
stancecoke
 
Hello,

I would like to ask regarding the offroad mode.

Does the controller give the same power for the road and offroad mode? Or is it posibble to have road mode with 250w and offroad with more?

Best regards
 
Bash1303 said:
Does the controller give the same power for the road and offroad mode?

Yes, the offroad mode disables the speed limit only. The power depends on your battery-current settings. The 250W limit is only relevant for the long-term capacity of the motor.

regards
stancecoke
 
stancecoke said:
DarkDD said:
I am using a 1000W direct drive motor and not an S series controller but rather a KT48ZWSRMT...

The "ZWS"-type is the block commutating one. In this, the phase current sensor is missing. You have to solder in the sensor or you have to buy a "SVP"-type. Or you can disable the "simplyfied FOC" and work with a static advance angle, but this will cause some losses and will heat up the controller and the motor unnecessarily.

regards
stancecoke

Hi, will it have losses about same as in stock fw, or more than stock?
 
Hi!

I have KT26 (ZWS) controller without plug to the connect for the LCD3. Now I want to use KT-LCD3 with it. I'm disassembled it and pulled out 4 wires for the connection LCD3 (Power+, GND, Rx, Tx). Can i reprogramming this controller (used STM8S105C6T6) with java application? LCD3 will be worked with him? Thank you.
 
kipper28 said:
Hi!

I have KT26 (ZWS) controller without plug to the connect for the LCD3. Now I want to use KT-LCD3 with it. I'm disassembled it and pulled out 4 wires for the connection LCD3 (Power+, GND, Rx, Tx). Can i reprogramming this controller (used STM8S105C6T6) with java application? LCD3 will be worked with him? Thank you.

It should work.
You should have ordinary LCD3 with generic firmware. Please be cautious about wiring to not fry display.
And see FAQ about ZWS controllers.
Btw, do LCD3 works now, on stock firmware?
 
kotofos said:
It should work.
You should have ordinary LCD3 with generic firmware. Please be cautious about wiring to not fry display.
And see FAQ about ZWS controllers.
Btw, do LCD3 works now, on stock firmware?

I don't know firmware version of my LCD3, but it has P, C and L (?!) parameters. About ZWS - I already know that I must disable FOC. Is there anything else I should do? LCD3 doesn't work now (controller has stock firmware). If it was working, I wouldn't be writing this in the first place. :)
My pacient:
 

Attachments

  • IMG_20190223_153801_resize.jpg
    IMG_20190223_153801_resize.jpg
    87.1 KB · Views: 2,603
Don't you guys want to help develop the firmware for SW102 Bluetooth graphic LCD so it will work for KT motor controllers and connect to mobile app?? -- I just got the information needed to drive this LCD and here are my tecnhical notes about this LCD: https://github.com/OpenSource-EBike-firmware/Color_LCD/wiki/SW102



casainho said:
Bafang 850C color LCD and Bafang SW102 LCD with Bluetooth
I decided to give a try on the Bafang SW102 LCD with Bluetooth, following the same approach I did to make working the 850C LCD.

Men, my eyes are hurting!! The PCB traces are so small!! But victory, I was able to solder 4 tiny wires and record the LCD signals. Seems to be like SPI communication and I got always a repetition of data so I think we can now replicate the LCD initialization and drawing of pixels (this LCD has 64X128 pixels).

Wires I had to solder to connect to logic analyzer:
2019-03-26-10-51-37-1.jpg


Initialization data:


Drawing pixels data:


Next step is to create a project using Nordic samples for GCC compiler. Test flash and debug session and finally initialize and wrote something on the LCD.
 
casainho said:
Don't you guys want to help develop the firmware for SW102 Bluetooth graphic LCD

I still admire your ambition when it comes to displays. I just find it boring, I don't want to have any frills on the handlebars. :)
Perhaps, Xnyle is interested...

regards
stancecoke
 
stancecoke said:
casainho said:
Don't you guys want to help develop the firmware for SW102 Bluetooth graphic LCD

I still admire your ambition when it comes to displays. I just find it boring, I don't want to have any frills on the handlebars. :)
Perhaps, Xnyle is interested...
That one is ver small and has the Bluetooth. With the Bluetooth chip it has, should be able to communicate wit mobile app AND the smart bms that also has Bluetooth, so we could integrate the bms on the system.
 
There are some new features in development / beta:

The first is a new option:
Idle disables offroad (60s)

Function should be clear, disables after 60 sec without wheel rotation!

The second feature is a passcode:

There is a new virtual switch in the controller. This switch can currently only be seen in the app in the left-hand debug panel, it's called lockStatus. 255 is the value when the controller is locked, the actual function - to prevent power output - is still disconnected, as long as the feature is in beta. Not that anyone gets stranded.

It works like this:

In the app you can set a 4 digit passcode.
1000 means that the protection is off, that is the default value.
Every other value is written to the EEPROM
Every now and then the app sends this value to the controller.
If the controller has not heard anything in 60 seconds -> lockStatus 255, controller locked.

Of course, you can only change the value if the app has previously sent the correct value and therefore has unlocked the controller, so you have to set the old value correctly in the app, wait a bit, then you can change it (because then the controller is unlocked ofc)

If you have forgotten the code, you can only flash again and wipe the eeprom (checkbox in the Java Tool)

This is of course not cryptographically hardened, you can also hack and try all 9k combinations.

The third feature is a GPS based Hill Climb Assist:

Can be set in the app (Hill climb assist factor).
Of course, GPS must be enabled (another app setting)
The value is +% / dm / s.
Meaning the app adds X% additional power per dm / s vertical speed (positive)
Of course, 100% is the maximum, it won't fly ;)
Since GPS is pretty noisy for altitude determination, the value is slightly smoothed, so it takes a couple of meters to kick in.
 
I have an S06S flashed with this firmware, and when I turn on the kit, the motor starts going at a moderate speed and doesn't stop until it's turned off again. I have attached the settings file that I'm using.

The attached hardware is:
KT-LCD1
PAS Sensor
Q100H Motor

The display works fine, but no setting I change on it has any effect on the behaviour of the kit.
 
I hope you do not seriously expect anyone to do the debugging for you.

You can use the app or diagnostics mode to see what's going on.

Read the Wiki about that (mode) and probably throttle calibration, if that doesn't help, show at least some effort and write us what the PAS is doing, what the current calibration is, the current target, setpoint state and so on.

Sorry for being that harsh (or rather not :), but this is a hobbyists and not a commercial project where you just shout "doesn't work" at some poor customer support representative.
 
Xnyle said:
I hope you do not seriously expect anyone to do the debugging for you.

Hardly, and I think it's an unreasonable leap to make that assumption from my post.

I've run into an issue that I couldn't find a previous example of when searching the thread, so I posted basic information about my setup to see if anyone could point me in the direction of where to look next.

If people are going to jump down the throat of anyone who needs help but doesn't know where to start trying to help themselves, perhaps a stickied post setting out the minimum information level required for effective troubleshooting could save everyone's blood pressure. The documentation for this being spread across at least 3 different places doesn't help matters much, either.

I'll dig out the necessary hardware and see if I can get the diagnostic output from the controller.
 
gutyex said:
I'll dig out the necessary hardware and see if I can get the diagnostic output from the controller.
I try to add all issues, that are reported more than one time, to the FAQs at github.
You can add your findings there, too. Everybody with a github-account can edit the Wiki.

regards
stancecoke
 
stancecoke said:
gutyex said:
I'll dig out the necessary hardware and see if I can get the diagnostic output from the controller.
I try to add all issues, that are reported more than one time, to the FAQs at github.
You can add your findings there, too. Everybody with a github-account can edit the Wiki.
I understand the reaction of Xnyle. I also feel like that and I usually simple do not answer because I do not feel the obligation to do it. I think users should help themselves.

And I try to do the same Stancecoke says, update the wiki.
 
Back
Top