Experiences with Open Source Firmware on the Tongsheng TSDZ2

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,124
8,224
60
West Sx RH
Unless one is manually checking cells groups voltages or using a balance charger then it is strongly advised to use batteries with BMS. Not all BMS have a switch (sw) option but those that do will have an external sw on the battery case. All the time the sw is on the BMS remains live and will draw mili-ohms in current from the battery, simply relying on the display to turn off only stops the bike operation but doesn't turn off the battery.
My batteries with no sw I always disconect them from the controller.
 
Last edited:

Bikes4two

Esteemed Pedelecer
Feb 21, 2020
894
395
Havant
I'm agreed that powering up in street mode is a oorr intro to the firmware, and unless you learn how to switch modes from the display, you're stuck there unless you can configre power up in other modes.
The 'Enable on startup' might help you out on this one?

49514
 

kiwisibk

Pedelecer
Oct 6, 2022
27
6
Hello all,

For a 48 V 750 W battery, what value should I enter in "Battery power max (W)" under "Basic settings" when using a 500 W motor?

54093

Thanks
 

Attachments

matthewslack

Esteemed Pedelecer
Nov 26, 2021
1,623
1,207
Hello all,

For a 48 V 750 W battery, what value should I enter in "Battery power max (W)" under "Basic settings" when using a 500 W motor?

View attachment 54093

Thanks
Your battery is not 750W. That's the wrong unit. W is watts, meaning power. Battery capacity is stated in 'watt hours', written Wh. These units are frequently confused, but are not interchangeable. Power is not capacity.

If you check the label or spec, you will likely find your battery is 48V, 750Wh.

The motor power setting has nothing to do with the battery capacity. Unless there is some other reason to change it, then leave it as it is.
 

kiwisibk

Pedelecer
Oct 6, 2022
27
6
Your battery is not 750W. That's the wrong unit. W is watts, meaning power. Battery capacity is stated in 'watt hours', written Wh. These units are frequently confused, but are not interchangeable. Power is not capacity.

If you check the label or spec, you will likely find your battery is 48V, 750Wh.

The motor power setting has nothing to do with the battery capacity. Unless there is some other reason to change it, then leave it as it is.
Sorry, this is nonsense in my opinion. For the Wh you mentioned there is a separate field in the Parameter Configurator and it is calculated from battery voltage x capacity in Ah:

54094
 

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,124
8,224
60
West Sx RH
The battery ' W' rating wil depend on the cells used and their specs.
 

saneagle

Esteemed Pedelecer
Oct 10, 2010
4,117
2,045
Telford
Sorry, this is nonsense in my opinion. For the Wh you mentioned there is a separate field in the Parameter Configurator and it is calculated from battery voltage x capacity in Ah:

View attachment 54094
Did you check the specification of your battery in the seller's listing? Most are around 25 amps, which would be 1200w. A 750w one would be only 15A, which is very low unless it's a very low capacity one or uses crappy cells. Your battery may well be 750w, but Mathewslack was right about you needing to check what the max current is to calculate it's power.
 

kiwisibk

Pedelecer
Oct 6, 2022
27
6
Did you check the specification of your battery in the seller's listing? Most are around 25 amps, which would be 1200w. A 750w one would be only 15A, which is very low unless it's a very low capacity one or uses crappy cells. Your battery may well be 750w, but Mathewslack was right about you needing to check what the max current is to calculate it's power.
This is the battery specification:

HAILONG-PLUS 48V 12.5AH Specification: (Include 2A Charger)
The battery pack fits 48V 250W/350W/500W/750W motor,If your motor power over 750W,we can't provide warranty for this battery
Rated capacity: 12.5AH
5P13S Li-ion 2.5Ah 65 pcs 18650 battery cells (china battery cells)

HAILONG-PLUS 48V AH Specification:
1. Rated capacity:AH
2. Voltage: 48V
3. Charging Voltage: 54.6V
4. Discharge cutoff voltage: 36.4V
5. Continuous discharge current: 30A
6. Pulse/Max discharge current 50A
7. Max charging current : 5A
8. Charging temperature: 0~45°C
9. Dischargeing temperature: -20~55 °C
10.Operating voltage:36.4V~54.6V
11.Diamesion: 90*109*362mm
12.Weight of battery pack About kg
13.It has no usb power output
 

Bikes4two

Esteemed Pedelecer
Feb 21, 2020
894
395
Havant
A couple of notes for those looking to use OSF for the first time:
EDIT: an update on older versions of SDCC below

> I've just got a Win11 laptop and wanted to be able to program my TSDZ2 which until now I've been doing using my Win10 laptop.
> I revisted the Github page (by Embrusa - link) to remind myself on what I needed to do. So some files like the previously downloaded OSF from the github repository I simply transferred from the Win10 to the Win11 laptop.
> Other items such as Java Runtime, ST Visual Development (by ST Microelectronics, and the Small Device C Compiler (SDCC) would be fresh downloads.
> Issue No1 - the Visual Programmer STM32 has now been replaced the STM32CubeProgrammer and initially it was the latter I installed - don't do that as Cube doesn't support the STM8 (the processor in the motor controller) SWIM protocol. Fortunately the original Visual Programmer STM32 is still available on their website.
> Issue No 2 - On running the configurator (that's the very useful series of dialogue boxes you're given to set up the various motor parameters) I noticed in the black dialogue box that subsequently runs as the necessary files are 'compiled', that the 'c' file named ebike-app.c was reporting errors e.g. "warning 283: function declarator with no prototype" (as per pic below) - all gobbledegook to me but I was guessing that something was amiss on the 'C' compiler side of life?
> I've no clue as to 'C' programming etc and after doing the obvious 'file checking' things, I wondered if the SDCC (the 'C' compiler) was a different version to what was originally used. Unfortunately I wasn't able to determine the version of SDCC on my Win10 machine but what ever version it is, it was installed in Oct 2021, so likely an earlier version than the current one. So to be on the safe side I copied all the SDCC files on the Win10 machine to the Win11 machine and BINGO, everything worked as expected.
--------------------------------​
EDIT: an update on older versions of SDCC below
> So opening a CMD (command) window and navigating to the SDCC directory and issuing the command sdcc.exe --version reveals that the version on the Win10 machine is V4.1.0 whereas the one I'd loaded onto the Win11 machine is V4.4.0
> V4.1.0 can be found at sourceforge.net HERE.

----------------------------------------​
I'm sure there will be readers of this post who understand exactly what was initially amiss and so please add to this thread so that others can benefit.

Happy (TSDZ2) pedlling, B4t

57072
 
Last edited:

kiwisibk

Pedelecer
Oct 6, 2022
27
6
Hello everyone,
if you have a 48V 750W motor, is it possible to limit the power assist mode to 250W? So that you are legally OK in the EU with max. 250W and 25kmh?
Many thanks for your feedback!
 

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,124
8,224
60
West Sx RH
Hello everyone,
if you have a 48V 750W motor, is it possible to limit the power assist mode to 250W? So that you are legally OK in the EU with max. 250W and 25kmh?
Many thanks for your feedback!
Simply no, no matter what you do to the settings the motor remains illegal.
It is rated for 750w and that is it's designated rating , one can't simply fudge the figures to suit your needs.
 

Advertisers