Hello everyone:
I've been disconnected from this topic for a few days but I haven't had time!!! remodeling at home!!! hehe housework.
Just yesterday I returned to linuxcnc, my ec500 hardware and the nema 34 closed loop stepper motors and DM860H drivers to perform a small closed loop test. I must say that I would have preferred motors with lower resolution encoders but all the closed loop motors from ebay and aliexpress have 1000 pulses or 4000 counts per revolution, another difficulty has been the voltage level of the encoders is 5V so I have used the free pins of the MPG port +/-WHA +/-WHB which are 5V tolerant (they are differential, something really good because all the closed loop motor encoders that I saw also have differential outputs), I don't know what quality level the differential driver connected to the MPG port will have, I haven't even looked at it, on the other hand, there are the basic configurations for the *.ini and *.hal files that Scott provides us, first I have done certain tests in open circuit and the motors truly reach incredible speeds, this is where I have found problems because the speeds in the sample *.ini file are of the order from 125 <-> 166 mm/s = 7500 <-> 9000 mm/min; which from my ignorance, depending a lot on the construction of the machines, it is quite difficult to reach these speed values, now the problems have been in terms of the relationship between speed and loss of steps since, for example, above 1500mm/min I lose counts in the encoder, my calculations would be the following, you can correct me if I'm wrong: for a spindle with a 4mm pitch it would be 1500mm/min / 4mm = 375 rpm, 375rpm/60 = 6.25rps and 6.25rps*4000 = 25000 counts/sec, which I already say from my ignorance seems quite little to me but I lose counts above this speed, otherwise it has been gratifying to be able to perform a closed loop control using Linuxcnc I was able to adjust the pid without problems, I have seen a pretty good video on the Youtuber size83 very well explained by the way and based on Remora's notes for a closed loop configuration.
Hello Scott, I have made some changes to the qdc module since I had not used the MPG port pins and I had incorrectly configured dir signal continues to occur, I tested your changes in the bugfix branch and I have not seen any improvement in this regard, then I will upload the *.ini and *.hal files since now I am from the phone.
I don't understand why the editor doesn't allow me to add a video, I did it a while ago and it worked, it doesn't matter, I'll leave you a link to the
test video