• Hello ES! We could use some help to get us past the finish line on building the new knowledgebase for the forum.
    Can you donate? Please see our fundraising page. Thank you!

TSDZ8 OSF (open source firmware)

And do they have the same pulling power as the TSDZ8?
Sure and much more. This 250W continuos output power is just a number on the paper. The real power is much higher.

But the firmware can be good. How about this option?
I don't know. Normally the torque signal gets filtered, as the torque oszilates with the crank revolution. Of course this filter has to by bypassed to decrease the motor power immediately.
 
Last edited:
Sure and much more. This 250W continuos output power is just a number on the paper. The real power is much higher.
TSDZ8 continuous way more than 250W also... But no one disputes that Bosch/Yamaha has better operating algorithms and "software cooperation" with sensors. That is why we want to compensate for all this with the help of OSF and additional sensors.
 
Last edited:
Agree. But Alivio is on grade higher than Acera
View attachment 379792
Although Acera is also a good shifter (it's on my wife's e-bike, it has 7 speeds, mine - 9)
I guess the conclusion is not to buy the cheapest of the cheapest stuff.
I got a new bike frame and will be swapping the tsdz8 over to this new build while reusing parts from the old one.
Currently it's on an old bulls mtb frame.
I am gonna upgrade to a deore derailleur because i salvaged one from a trashed bike.
I am getting new wheels for it that support 11speed cassettes if I wanna upgrade in the future.
Right now the chainline is already barely acceptable with a 7 speed.

I have also finally ordered a jlink v9 with the premade cable because i found it for 20€ on aliexpress.
Let's see if it arrives before the weather get's to bad to ride.
 
Hey @mstrens
Do you know if the 860C display firmware is already at its limits with functions and menus?
I’ve been trying to add an autotune test that finds the cleanest window for measuring phase amps (lowest noise area in the PWM cycle), but I keep hitting build errors — flash overflow, .bss overflow, and a few weird linker warnings once I add the new logic.
Before I go too far down the rabbit hole, I’m trying to figure out if it’s even possible to fit more features in the existing build, or if I’d need to make a stripped-down debug/tuning firmware instead — basically remove all normal menus and replace them with tuning screens and test functions.
The plan was to run the autotune once, store the results (the best sample window offsets) either in display flash or the controller flash, and then hard-code them later for release builds. I thought that Every motor’s a little different, so it’d be handy if users could flash the display, run the test, and have it find its own ideal timing window automatically. But if there's no space for it I'd probably have to go down the special debug build route .
Just wondering if the display has any headroom left at all, or if it’s right up against flash/RAM limits now.
 
Hey @mstrens
Do you know if the 860C display firmware is already at its limits with functions and menus?
I’ve been trying to add an autotune test that finds the cleanest window for measuring phase amps (lowest noise area in the PWM cycle), but I keep hitting build errors — flash overflow, .bss overflow, and a few weird linker warnings once I add the new logic.
Before I go too far down the rabbit hole, I’m trying to figure out if it’s even possible to fit more features in the existing build, or if I’d need to make a stripped-down debug/tuning firmware instead — basically remove all normal menus and replace them with tuning screens and test functions.
The plan was to run the autotune once, store the results (the best sample window offsets) either in display flash or the controller flash, and then hard-code them later for release builds. I thought that Every motor’s a little different, so it’d be handy if users could flash the display, run the test, and have it find its own ideal timing window automatically. But if there's no space for it I'd probably have to go down the special debug build route .
Just wondering if the display has any headroom left at all, or if it’s right up against flash/RAM limits now.
I have no idea. I never really looked at the 860c firmware. You can ask mbrusa on his github site or on the TSDZ2 forum.
On my side, I have implemented and tested an autocalibration of positions of the hall sensors.
I am currently implementing a dynamic autoadaptation of the lead angle. Optionally, it would also be possibe to read the best lead angle on the display when the motor is stable for a specific speed and current. This would allow to collect some real data and to fill some table to get the best lead angle without the autotune. This will nor require changes to the 860c display firmware.
 
That’s a fascinating approach — I completely agree that the 860C firmware is getting quite tight in terms of memory headroom, and your idea of a dedicated tuning build sounds like the practical route. I’ve seen similar challenges in embedded projects where squeezing in new logic can easily trigger linker chaos. Having the right developers helps here, especially when it comes to Innovation and Competitive Advantage – having developers on your team allows you to create unique features, services, or platforms that differentiate you from competitors, and I’ve had a great experience finding such talent through Lemon.io. They can really help push these kinds of firmware projects beyond typical limits.
 
Last edited:
For info, I planned to calculated dynamically the best lead angle based on proposal of chatgpt but finally I think it is not really possible. I was trying to implement an hill-climbing algorithm but I am afraid that the automatic current regulation (trying to align on a current target will interfere with the algorithm. Furthermore, it is not clear what is the parameter to trace in the algorithm (current, current* volt, duty cycle, ...). So, I am afraid it will not be able to get it running. Currently Lead angle is proportional to the current (nearly like in TSDZ2). Still I do not find other example of project using this kind of formula. I find one or 2 code using a ratio (linear relation) based on RPM instead of current. If someone has idea's or references, I am interested.
 
Still I do not find other example of project using this kind of formula
See here, the idea is based on the paper of Shane Colton. The advance angle is mainly a function of the current I and the speed omega and the motor constants inductivity L and resistance R.

With the keywords "BLDC" and "advance angle" you can find many papers dealing with this topic.


Are you still working on "real" FOC? That's the most promising approach, I think. ;)
 
Last edited:
See here, the idea is based on the paper of Shane Colton. The advance angle is mainly a function of the current I and the speed omega and the motor constants inductivity L and resistance R.

With the keywords "BLDC" and "advance angle" you can find many papers dealing with this topic.


Are you still working on "real" FOC? That's the most promising approach, I think. ;)
Before trying to implement real foc, I first made changes in order to get more accurate rotor position and to reduce the cpu time spent in the ISR PWM. I think this is done. I do not have (currently) an accurate way to measure the 3 phase currents. I have only a basic code that request, at mid point, 2 samples of adc conversion for 2 fixed phases followed by 2 more samples of the 3rd phase and Idc. So I expect that id and iq will not be the most accurate. Perhaps will it be accurate enough when filtered on a whole rotation (or more) to calculate an error that could drive a lead angle correction. In the documentation that you sent me, I saw that getting accurate 3 phase current was more complex than expected. That is why I try an easier solution currently.
 
Hi everyone,
I have a strange problem with my 860C display and OSF. One day, the system just stopped working – it wouldn’t power on at all.

First, I thought maybe the wiring harness was bad, so I replaced it with a new one, but that didn’t help. Then I suspected the display itself, so I bought a new 860C. With the new one, I only got the first startup screen and then an error message appeared.

After all these attempts, I flashed the original firmware back to my TSDZ8 controller and connected an EKD01 display — and to my surprise, everything worked perfectly.

Then I connected my 860C (the one that didn’t work) to another bike — and there it works fine!
Honestly, I’m confused now. Maybe someone has an idea what could be the issue?

Thanks in advance for any su1000048463.jpgggestions!
 
I have no idea. I never really looked at the 860c firmware. You can ask mbrusa on his github site or on the TSDZ2 forum.
On my side, I have implemented and tested an autocalibration of positions of the hall sensors.
I am currently implementing a dynamic autoadaptation of the lead angle. Optionally, it would also be possibe to read the best lead angle on the display when the motor is stable for a specific speed and current. This would allow to collect some real data and to fill some table to get the best lead angle without the autotune. This will nor require changes to the 860c display firmware.
I see you have been quite busy lately, so I have some good info for you

Once again my controller go poof (rain this time, controller isn't seal properly because of the pin that slides the controller on wasn't pressed in, like the actual hole so it was a build defect 😬) it was only a phase fet I pinched one off my old board , soldered it in and potted controller. Good as new. While it was down I was messing with my vesc controller , so I ran the foc tests, now we have the juicy motor info 😁 the pictures were with 150 wattage waste max. I ran a test that allowed up to 400 watts wastage and got
Motor current: 71.38 A
Motor R: 51.70 mΩ
Motor L: 211.11 µH
Lq − Ld: 121.45 µH
Flux linkage: 13.25 mWb
But idk where the pic for that one is
 

Attachments

  • Screenshot_20251109-131747.png
    Screenshot_20251109-131747.png
    262.3 KB · Views: 17
  • Screenshot_20251109-131737.png
    Screenshot_20251109-131737.png
    247.5 KB · Views: 17
Last edited:
I've
Hi everyone,
I have a strange problem with my 860C display and OSF. One day, the system just stopped working – it wouldn’t power on at all.

First, I thought maybe the wiring harness was bad, so I replaced it with a new one, but that didn’t help. Then I suspected the display itself, so I bought a new 860C. With the new one, I only got the first startup screen and then an error message appeared.

After all these attempts, I flashed the original firmware back to my TSDZ8 controller and connected an EKD01 display — and to my surprise, everything worked perfectly.

Then I connected my 860C (the one that didn’t work) to another bike — and there it works fine!
Honestly, I’m confused now. Maybe someone has an idea what could be the issue?

Thanks in advance for any suView attachment 380262ggestions!
Literally just been smashing my head off the table with this issue
ill upload the bin for you to test
if it works for you also then we have a confirmed fix
fingers crossed!
 

Attachments

  • main.bin.zip
    60.4 KB · Views: 9
I have a sw102 Display and flashed the firmware. Seems to work (bike is not on the streets at this point) but battery is limited to 22A. Is this also the case with a 860C Display? (I have one on my running TSDZ2 bike) PAS mode is working btw (which safed me a few times when i broke the torque axle and waited for a replacement). BMS is a 50A - battery should be able to deliver 40A continously


be careful what you wish for :D



github.com



Release TSDZ8 — Motor Launch Yes / Rider Launch Yes · 8hodgsonkh/OSF_860C


v4.1whydiditouchpwm.zip 🧩 Summary A meme-grade performance firmware for the TSDZ8 mid-drive that somehow survived QA. It rethinks the FOC angle, duty-ramp logic, and launch behaviour — delivering s...

github.com



(860c display only)
 
Is it a problem? 22A on charged 48V batt. = ~1200W... and TSDZ8 = 750W
No. But ;) ..
Here mbrusa writes "Update July 28, 2025 - v20.1C.5-1-1 Increased power and current limits for TSDZ8"
As the same Version was published for the sw102, I will try this one.

Edit: Found it. The battery limit is bypassed. Thats why you should flash the mentioned motor firmware only if your battery can deliver 30A. That makes sense to me. With the new firmware for the SW102 it has the same limits as the 806C (1.500W for motor & bike). Both displays are very good.
 
Last edited:
There are some reports here that the stock firmware is more powerful. The 750W of the TSDZ8 also refers to continuous power; the parked power can certainly be higher. So far, it also seems that the motor can handle a lot and doesn't tend to overheat. I also hope that by the next session, i.e., from May onwards, other displays will also support the higher power output.
 
There are some reports here that the stock firmware is more powerful. The 750W of the TSDZ8
There are also reports that the stock firmware drains the battery twice as fast.
on 17.5ah samsung pack I did 90km easy on tsdz8.
 
Last edited:
I don't understand what your goal is. There are people here who want more performance. Even if it's implemented, you could always reduce it back to the current level.
 
I don't understand what your goal is. There are people here who want more performance. Even if it's implemented, you could always reduce it back to the current level.
I don't know what firmware you have, but on OSF my TSDZ8 works much better/quieter/more-economically/more-powerfully than on the stock one. If you like the stock one, you can always go back to it.
 
Last edited:
Back
Top