John,

Changed the scale to 50. 1 turn of the spindle increases the spindle-pos
by 1 now. I thought the phase-Z was responsable for counting the spindle
revs.

Running eg G33 Z10 K.1 (assuming .1 mm per turn) moves very "shocky".

Also, running G33 Z10 K.2 seems to go up at full speed.

Another strange behaviour: running the same command moves in the same 
"shocky" velocity till Z7, then stands there waiting for some time 
before continuing...

Is there something else I would need in the config?

Geert

John Kasunich wrote:
> Geert De Pecker wrote:
>> Hi,
>>
>> I've mounted a spindle encoder to the mill and was trying to use G33, 
>> but this always seems to move at the same speed.
>>
>> The spindle encoder has 50 ppr (pin 11) and an index signal (pin 10).
>>
>> This is my hal setup:
>>
>> ...
>> loadrt encoder num_chan=1
>> ...
>> addf encoder.update-counters base-thread
>> addf encoder.capture-position servo-thread
>> ...
>> setp encoder.0.counter-mode true
>> setp encoder.0.x4-mode false
>> setp encoder.0.position-scale 1
> 
> ^^^ this is saying that one count = one position unit
> for a spindle, one position unit is one revolution
> 
> If your encoder has 50 PPR, then you should be using 50 for the scale.
> 
>> net spindle-phase-A <= parport.0.pin-11-in => encoder.0.phase-A 
>> encoder.0.phase-Z
>> net spindle-index-enable motion.spindle-index-enable <=> 
>> encoder.0.index-enable
>> net spindle-pos encoder.0.position => motion.spindle-revs
> 
> Confirm that the scale is correct by turning the spindle one revolution
> by hand, while looking at net spindle-pos with halmeter - it should
> increase by 1.00
> 
> Regards,
> 
> John Kasunich
> 
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
> 

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to