New "TSDZ2 Torque Sensor Central Motor"

casainho said:
andyme said:
ok...so i do have the synaptic window like you. but from here i am lost: how do i get the source into the virtual machine, where do i execute make...you see: i am lacking the basic knowledge...you must consider me as someone who has to land a plane but has never flown before.....sorry....so maybe it is very simple and i am just 2 steps away or so, or maybe it is much more complex...i cannot judge it...it looks like i am almost there..but who knows...
To get the sources, is just standard git clone from a github project.

Install "git" on Synaptic and then do on a terminal:

Code:
git clone https://github.com/OpenSource-EBike-firmware/Color_LCD.git

ok....i can hardly believe it, but that worked also...actually i installed git from the terminal. anyway..so now, what is the next step? because i do not understand where to execute "make" and how....what is the syntax etc....no clue..
 
andyme said:
ok....i can hardly believe it, but that worked also...actually i installed git from the terminal. anyway..so now, what is the next step? because i do not understand where to execute "make" and how....what is the syntax etc....no clue..
Just run/execute this:
Code:
make
Must be on a terminal. Search on google how to open a terminal window on Ubuntu and navigate on folders. Make must be executed on src folder, look at the folder I posted before as example on my computer.
 
casainho said:
andyme said:
ok....i can hardly believe it, but that worked also...actually i installed git from the terminal. anyway..so now, what is the next step? because i do not understand where to execute "make" and how....what is the syntax etc....no clue..
Just run/execute this:
Code:
make
Must be on a terminal. Search on google how to open a terminal window on Ubuntu and navigate on folders. Make must be executed on src folder, look at the folder I posted before as example on my computer.

ok, done (maybe....).i now have many files ...what to do? i do not see a hex file...and once i will have it: how can i get hold of it? how can i get it out of the virtual machine into my pc?
 
andyme said:
ok, done (maybe....).and where ist the file now :lol: ? what do i need to look for and what do i need to do with it?

am i looking for a file 273 cc main.elf? if so: where should it be? and i just rename it from .elf to .hex? you see: i have no clue...
Well, if it did build correctly, main.hex file will be generated and stay on the same folder as all the others like the main.elf.

Then you can flash the main.hex file as you already know how to do it on Windows or you can do it using "stm32flash" (that you can install using Synaptic and need to google for the correct options to flash the file).
 
casainho said:
andyme said:
ok, done (maybe....).and where ist the file now :lol: ? what do i need to look for and what do i need to do with it?

am i looking for a file 273 cc main.elf? if so: where should it be? and i just rename it from .elf to .hex? you see: i have no clue...
Well, if it did build correctly, main.hex file will be generated and stay on the same folder as all the others like the main.elf.

Then you can flash the main.hex file as you already know how to do it on Windows or you can do it using "stm32flash" (that you can install using Synaptic and need to google for the correct options to flash the file).

oh no....where is it?????????? everything looks so nice...
 
andyme said:
oh no....where is it?????????? everything looks so nice...
You did it!! That screenshot shows that build went correctly!! Now you just need to use the main.hex file that is on that "src" folder.
 
casainho said:
andyme said:
oh no....where is it?????????? everything looks so nice...
You did it!! That screenshot shows that build went correctly!! Now you just need to use the main.hex file that is on that "src" folder.

IT IS NOT THERE!!!!!! can you believe this??????????????? is it hidden? i cannot see it..... :shock:



there is one thing i have done to make my life easier: i had moved the whole src folder to home so i would not have to go thru all this cd ordeal...but that cannot explain it...?
 
andyme said:
casainho said:
andyme said:
oh no....where is it?????????? everything looks so nice...
You did it!! That screenshot shows that build went correctly!! Now you just need to use the main.hex file that is on that "src" folder.

IT IS NOT THERE!!!!!! can you believe this??????????????? is it hidden? i cannot see it..... :shock:
Sorry, my mistake. It is the main.bin. The software you use to flash shoild also accept the main.bin file.
 
casainho said:
andyme said:
casainho said:
andyme said:
oh no....where is it?????????? everything looks so nice...
You did it!! That screenshot shows that build went correctly!! Now you just need to use the main.hex file that is on that "src" folder.

IT IS NOT THERE!!!!!! can you believe this??????????????? is it hidden? i cannot see it..... :shock:
Sorry, my mistake. It is the main.bin. The software you use to flash shoild also accept the main.bin file.

oh...ok... but is it not a bit large?and how do i "get physical hold of it"?
 
andyme said:
oh... but is it not a bit large? and so what do i need to do now: rename the bin to hex and how do i "get physical hold of it"?
The file should be ok. You should not rename because a bin file is really different from a hex file.

When you use that file to flash, it must be flashed starting at address 0x08000000 -- it is crucial that you flash the file starting at that address on the flash memory of the microcontroller or the firmware will not run -- search on google how to flash STM32F103.
 
casainho said:
andyme said:
oh... but is it not a bit large? and so what do i need to do now: rename the bin to hex and how do i "get physical hold of it"?
The file should be ok. You should not rename because a bin file is really different from a hex file.

When you use that file to flash, it must be flashed starting at address 0x08000000 -- it is crucial that you flash the file starting at that address on the flash memory of the microcontroller or the firmware will not run -- search on google how to flash STM32F103.

OMG...after killing myself trying to convert .bin to .hex (because st-link visual programmer does NOT support .bin)...i found out that ST-Link utility does support .bin... :oops: AND: it does not need any setup...it will autodetect the target..so it is much easier to use than visual programmer.... :roll: so now i have flashed it, and it seems to be ok, provided you can confirm the following:

the display will not switch on when only connected to a battery. it needs to be connected to the controller as well ??????????????

because: it does not switch on just with the battery....nothing is happening, unless there is a very special key combination required..just pressing the power button for a couple of seconds (like with original 850C firmware) does not do anything..

good or bad?...... :?:

and besides this: a big thank you for guiding me this far...i went much further than i ever thought i would be able to....so thanks for the support and for the challenge.... :bigthumb:
flash.jpg
 
andyme said:
the display will not switch on when only connected to a battery. it needs to be connected to the controller as well ??????????????
Firmware waits for communication with TSDZ2 and will keep black until that happens. Comment the next lines on firmware, build and them flash again:
Code:
//  if (first_time_management())
//    return;
 
casainho said:
Comment the next lines on firmware, build and them flash again:

on what file? ( you understand that i have never before written a line in any software, firmware or whatsoever... :lol: )
 
andyme said:
casainho said:
Comment the next lines on firmware, build and them flash again:

on what file? ( you understand that i have never before written a line in any software, firmware or whatsoever... :lol: )
lcd.c file.
 
casainho said:
andyme said:
casainho said:
Comment the next lines on firmware, build and them flash again:

on what file? ( you understand that i have never before written a line in any software, firmware or whatsoever... :lol: )
lcd.c file.

ok..i did it (at least i think so....)

should this have lead to the lcd lighting up without the controller? if so, so far it it not the case...


but actually: how could it since it is only a comment....so: what was the purpose of it? just lection 1 in programming? :shock:
 
The site www.electricbike.com has a review of TSDZ2 (I consider that some information are incorrect and I gave my view to the manager of the site):

TSDZ2, mini 750W mid-drive with torque sensing: https://www.electricbike.com/tsdz2-750w-mid-drive-torque-sensing
 
andyme said:
but actually: how could it since it is only a comment....so: what was the purpose of it? just lection 1 in programming? :shock:
You need to find that code lines that exist on lcd.c file and comment that lines!! Not add the lines to the file!!

That lines wait for the communication from TSDZ2 and will quit executing the code while there is no first communication.
 
casainho said:
andyme said:
but actually: how could it since it is only a comment....so: what was the purpose of it? just lection 1 in programming? :shock:
You need to find that code lines that exist on lcd.c file and comment that lines!! Not add the lines to the file!!

That lines wait for the communication from TSDZ2 and will quit executing the code while there is no first communication.

sorry, i am not getting it....what do i want to achieve by commenting? you understand: i have no clue of programming....
 
andyme said:
casainho said:
andyme said:
but actually: how could it since it is only a comment....so: what was the purpose of it? just lection 1 in programming? :shock:
You need to find that code lines that exist on lcd.c file and comment that lines!! Not add the lines to the file!!

That lines wait for the communication from TSDZ2 and will quit executing the code while there is no first communication.

sorry, i am not getting it....what do i want to achieve by commenting? you understand: i have no clue of programming....
When you comment the lines by putting "//" at begin of the line, that piece of code is not executed anymore. Search on google.
 
casainho said:
andyme said:
casainho said:
andyme said:
but actually: how could it since it is only a comment....so: what was the purpose of it? just lection 1 in programming? :shock:
You need to find that code lines that exist on lcd.c file and comment that lines!! Not add the lines to the file!!

That lines wait for the communication from TSDZ2 and will quit executing the code while there is no first communication.

sorry, i am not getting it....what do i want to achieve by commenting? you understand: i have no clue of programming....
When you comment the lines by putting "//" at begin of the line, that piece of code is not executed anymore. Search on google.
oh....ok....now i am getting you....sorry...it is difficult to search if you don't know what and why...haha...anyway. now i have a chance..you may believe me or not: but i am already quite proud of my achievement so far...haha. it always depends where you are coming from...and i come from somewhere -100...

ok....here you go.....


i can hardly believe i made it...and i am really very grateful for your support!!!

last question so far: where do i need to connect the cable of the brake sensor?
 
andyme said:
last question so far: where do i need to connect the cable of the brake sensor?
The brake sensors are connected just like on KT-LCD3. Read the wiki instructions.

Please take screenshots and notes on how to flash the firmware on Windows and write a wiki page on you github account. Then show to us that page and I will copy to wiki of the project.
 
casainho said:
andyme said:
last question so far: where do i need to connect the cable of the brake sensor?
The brake sensors are connected just like on KT-LCD3. Read the wiki instructions.

Please take screenshots and notes on how to flash the firmware on Windows and write a wiki page on you github account. Then show to us that page and I will copy to wiki of the project.

I will.
 
My clutch failed yesterday and I had to search on google about it, luckily, I found the excellent work/videos from jbalat!!

I decided to wrote an entry on TSDZ2 FAQ about the clutch: https://github.com/OpenSource-EBike-firmware/TSDZ2_wiki/wiki/FAQ

Clutch

TSDZ2_main_gear_clutch.jpg


The sprag clutch is a one way bearing in the tsdz2 ebike torque sensing motor that transfers your pedal torque to the main gear which is attached to the chain ring. After some time, this gear may began slipping/failing. Here is a video from jbalat showing how it happens when sprag clutch is failing: https://www.youtube.com/watch?v=PWlz4xw3pI8

How to repair clutch
1. Buy a new main gear (includes the sprag clutch bearing)
You can buy a new main gear, that includes the sprag clutch bearing, on PSWPower(about 30 euros) or in any other shop.

2. Install the new main gear
See this video from jbalat showing how to remove and install the main gear: https://www.youtube.com/watch?v=u-SY0rGMEMo
 
Casainho, I kind of understand that the bearing is press fit on the big gear, how did you pull it out from its housing?
Hammer?
Thanks!
 
thineight said:
Casainho, I kind of understand that the bearing is press fit on the big gear, how did you pull it out from its housing?
Hammer?
Thanks!
That videos are not mine. For my motor, I will just replace the main gear from another motor I have to be used for repair spare parts.

I would prefer to buy a new main wheel for 30 euros if needed.
 
Back
Top