On Saturday 25 July 2009, Haberler Michael wrote: >a while ago I described how I added a simple optical encoder wheel to >my lathe. Meanwhile, I eventually got it to work with G33 threading, >but it wasnt as straightforward as I would have believed, so I thought >I'd describe my experience. > >My first attempt was to use the encoder component as described in the >Spindle Feedback example (User Manual chapter 34). Trying that with >the threading.ngc example failed miserably - the synced-motion >threading part was everything but synchronized - heavy speed >variations in the Z axis (see http://www.youtube.com/watch? >v=efiNyzhGFbQ , starting around second 27). > >I traced the problem to serious noise on the encoder.0.velocity signal >(red signal in http://mah.priv.at/gallery2/main.php?g2_itemId=69102). >I first tried to feed it through a lowpass (white signal) but that a) >didnt work either and b) massaging a feedback signal would be >counterproductive to start with. > >I admit that the codewheel finish left to be desired - I managed to >glue it onto the pulley with maybe 0.5mm runout (the outer diameter is >18cm). And the disk isnt perfectly flat on the pulley - too much glue >here and there, so the disk-sensor distance varies as well. These >inaccuracies cause periodic fluctuations in the index signals, the >relation to the spindle revolution can clearly be seen (note blue >index pulse). So that introduced some phase noise on the signal, and >that in turn causes the position estimate to fluctuate wildly, hence >causing the strange Z move pattern. > >Adjusting the sensors and pulley brought some improvement but not >sufficient. So I played around with encoder options. > >The fix was finally to turn off x4-mode and use encoder.0.position- >interpolated instead of encoder.0.position to feed into motion.spindle- >revs. > >The noise is pretty much gone > (http://mah.priv.at/gallery2/main.php?g2_itemId=69105 ) - except for the > wobble introduced by the runout of the codewheel (which btw can be clearly > heard from the Z stepper during the >threading run :-). > >The setup works fine for threading now, but I'll eventually change >this to a more precise encoder wheel. > There is a bit of python code on the wiki that when fed to a 3 axis mill, will carve a quite good encoder wheel from a sheet of alu, say about 16 to 18 gauge. I took that and modified it to fit the much smaller spindle, trapped between the bearing adjuster nuts at the left end of the spindle of my 7x12. I also reduced the number of holes so the hole to space was about 50%, I think in half from that code. And used a 1/16" diameter end mill and several passes so as not to push the light alu out of shape or out of flat. It is on the lathe now, and I might have it working but when I built the interrupter opto assembly, I thought I would hook it up and test it while laying on the table, and due to a lack of docs on the opto unit, apparently hooked it up in reverse polarity & blew all 3 of them. So now I need to get some fresh ones, with a smaller air gap, and make it again. Bummer. So many projects, so little time left.
>hal of test setup is at: > http://mah.priv.at/cgi-bin/viewvc.cgi/emc-drehbank-test/drehbank-k12a.hal?r >evision=1.6&root=CVS&view=markup > > >out of curiosity - anybody got spindle-synced motion with *just* an >index puls (1ppr) to work? Work, maybe. Reliably? Very doubtful. >-Michael > > >btw - I'm stunned by EMC2's capabilities - great piece of work, folks! So am I, amazed at what it can do if I can just write the code, but I'm usually yelling for help on IRC. Dunno what I'd do without these guys. > > >---------------------------------------------------------------------------- >-- _______________________________________________ >Emc-users mailing list >[email protected] >https://lists.sourceforge.net/lists/listinfo/emc-users -- Cheers, Gene "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) The NRA is offering FREE Associate memberships to anyone who wants them. <https://www.nrahq.org/nrabonus/accept-membership.asp> Human kind cannot bear very much reality. -- T.S. Eliot, "Four Quartets: Burnt Norton" ------------------------------------------------------------------------------ _______________________________________________ Emc-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-users
