On Monday 03 May 2021 19:25:48 Jon Elson wrote: > On 05/03/2021 02:34 PM, Gene Heskett wrote: > > Friction will of coarse vary, but assume the amplitude of > > the jitter is constantly reset to zero by a passing edge > > from the encoder, but it times out in 2 millisecs. Leaving > > the pwmgen outputing a very low duration pulse in one > > direction or the other because the combo of friction and a > > d term combines to coast it to a friction stop, some 30 > > arc-seconds from where the gcode sent it. Now, because the > > jitter control has timed out, a counter watching each > > direction pulse is free to increment its count. That > > counter is added to the control signal in the direction to > > reduce the error. And its incremented by the pulse from > > that pwgmen's dir+ or dir- output. And in a few > > milliseconds the motor will move enough to output an > > encoder edge. That resets the counters, and the motor will > > not have enough to keep moving. But the pwmgen isn't > > satisfied yet so it keeps on outputting a 1% duty pulse on > > one or the other of its dir signals, Wash, rinse repeat, > > the motor is constantly being tickled enough by a 1 count > > move in the wanted direction until the pwmgen sees a match > > and stops tickling the motor. > > Well, this is sort of what the I and D are supposed to > accomplish. I creeps up the command to make it move toward > the null point, but D backs it off as soon as it moves past > an encoder edge. > Thanks Jon, I hadn't thought of it in that exact manner, and it makes perfect sense. So I'll likely give it a shot in the next few days.
Does there seem to be a golden ratio that works well consistently? Take care and stay well. > Jon Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) If we desire respect for the law, we must first make the law respectable. - Louis D. Brandeis Genes Web page <http://geneslinuxbox.net:6309/gene> _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users