We are well aware that torque sensing motors acts as power/torque amplifier. An annoying effect though, at least for the TSDZ2 motor that I normally use, is that it follows just exactly the force measured instantly which, even if we are pedaling constantly, changes significantly according to the position of the pedals and I find this wave effect annoying.
Below is an example of a graph that shows the trend of the torque impressed by the cyclist based on the position of the pedals.

The shape changes from cyclist to cyclist and also for the same cyclist it changes according to the pedaling style you are using, if you are more or less tired, etc.
To overcome this problem, I have seen that other firmware use an average of the measured torque value which, however, has the effect of reducing the responsiveness of the motor to changes in the effort impressed on the pedals.
So I asked myself if there is a way to overcome this problem while maintaining a good reactivity of the motor and I came up with the following method which is very simple and in the tests I did it proved to be effective.
The idea is the following:
The PAS of the TSDZ2 supplies 80 impulses for every crank revolution (one every 4.5 degrees) the Software detects the value of the torque at every impulse of the PAS and keeps in memory the last 80 values.
When the Software has to calculate the target motor power, the SW detects the torque value on the pedals and compares it with the value detected in the same pedal position at the previous pedal revolution. If the difference is lower than a configurable threshold, the average of the last 80 samples is used (moving average over 360 degrees), otherwise the instantaneous value is used.
In addition, to ensure an immediate stop, if the instantaneous torque value is lower than another configurable threshold, it still applies the instantaneous value instead of the moving average.
From the first tests I did it seems to me that it works well and when you pedal constantly in my opinion you can feel the difference and in the same way, as soon as you change the effort, the motor still reacts instantly as before.
The operation is confirmed by my monitoring Android application which shows now also the percentage of time in which the average is used instead of the instantaneous value and when I pedal regularly the value is almost always at 100%.
I wonder if others also detect this annoying wave effect or if it is just my impression, or if others have faced this problem and have adopted different solutions.
Soon, as always, I will publish an update of my Firmware with this change on Github as I am curious to hear other opinions.
Below is an example of a graph that shows the trend of the torque impressed by the cyclist based on the position of the pedals.

The shape changes from cyclist to cyclist and also for the same cyclist it changes according to the pedaling style you are using, if you are more or less tired, etc.
To overcome this problem, I have seen that other firmware use an average of the measured torque value which, however, has the effect of reducing the responsiveness of the motor to changes in the effort impressed on the pedals.
So I asked myself if there is a way to overcome this problem while maintaining a good reactivity of the motor and I came up with the following method which is very simple and in the tests I did it proved to be effective.
The idea is the following:
The PAS of the TSDZ2 supplies 80 impulses for every crank revolution (one every 4.5 degrees) the Software detects the value of the torque at every impulse of the PAS and keeps in memory the last 80 values.
When the Software has to calculate the target motor power, the SW detects the torque value on the pedals and compares it with the value detected in the same pedal position at the previous pedal revolution. If the difference is lower than a configurable threshold, the average of the last 80 samples is used (moving average over 360 degrees), otherwise the instantaneous value is used.
In addition, to ensure an immediate stop, if the instantaneous torque value is lower than another configurable threshold, it still applies the instantaneous value instead of the moving average.
From the first tests I did it seems to me that it works well and when you pedal constantly in my opinion you can feel the difference and in the same way, as soon as you change the effort, the motor still reacts instantly as before.
The operation is confirmed by my monitoring Android application which shows now also the percentage of time in which the average is used instead of the instantaneous value and when I pedal regularly the value is almost always at 100%.
I wonder if others also detect this annoying wave effect or if it is just my impression, or if others have faced this problem and have adopted different solutions.
Soon, as always, I will publish an update of my Firmware with this change on Github as I am curious to hear other opinions.