Lathe Macros

More
3 years 11 months ago #256630 by Masiwood123
Replied by Masiwood123 on topic Lathe Macros
ok it's still early, I just tried this without the workpiece, away from the headstock..but the program won't start to execute, i.e. it does something but the axes stand still. on the 7i96s I have an encoder input, but the servo motor connected to the headstock has its own encoder that gives feedback to the driver, so I don't use the one on the card. from the card, I only take the analog output 0-5v to the servo motor driver, the driver also has the possibility of position mode, so I use the head as the A axis, also changing the mode of operation between A and S. there is a DRO on the driver that shows the actual speed of the spindle.. and it is accurate almost in a couple of revolutions. what should I do in order for the macros to work at all?

Please Log in or Create an account to join the conversation.

More
3 years 11 months ago #256635 by Masiwood123
Replied by Masiwood123 on topic Lathe Macros
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

More
3 years 11 months ago #256637 by andypugh
Replied by andypugh on topic Lathe Macros
Do you have connections to spindle.0.revs and spindle.0.speed-in?

Check that they show the right numbers with halmeter.

Please Log in or Create an account to join the conversation.

More
3 years 11 months ago - 3 years 11 months ago #256643 by Masiwood123
Replied by Masiwood123 on topic Lathe Macros
I can check tomorrow on the spot, although I only used the halmeter once to tune the servo motor..this is what I have in Hal as a link. by the way, I only use the spindle in one direction, I think the driver would require a range from -10 to +10v for the reverse M4 (if that is important at all in this case)


# ---setup spindle control signals---

net spindle-vel-cmd-rps <= spindle.0.speed-out-rps
net spindle-vel-cmd-rps-abs <= spindle.0.speed-out-rps-abs
net spindle-vel-cmd-rpm <= spindle.0.speed-out
net spindle-vel-cmd-rpm-abs <= spindle.0.speed-out-abs
net spindle-enable <= spindle.0.on
net spindle-cw <= spindle.0.forward
net spindle-ccw <= spindle.0.reverse
net spindle-brake <= spindle.0.brake
net spindle-revs => spindle.0.revs
net spindle-at-speed => spindle.0.at-speed
net spindle-vel-fb-rps => spindle.0.speed-in
net spindle-index-enable <=> spindle.0.index-enable
Last edit: 3 years 11 months ago by Masiwood123.

Please Log in or Create an account to join the conversation.

More
3 years 11 months ago #256646 by andypugh
Replied by andypugh on topic Lathe Macros
I don't see anything driving the signals spindle-revs and spindle-vel-fb-rps

Ideally those would be connected to a spindle encoder.

Do you have threading working? I assume not?

Please Log in or Create an account to join the conversation.

More
3 years 11 months ago #256648 by Masiwood123
Replied by Masiwood123 on topic Lathe Macros
in general, everything is still in the final stage of lathe construction, I will use the lathe mainly for some smaller wooden pieces, but since I already have a knife holder on the other side and a slightly stronger motor, I want to perform some basic operations on metal as well(these macros are just ideal for that, because a lot of time is wasted if I had to program everything in solidworks) (I often need some smaller parts of metal) I will also try tomorrow to see if the threading works.. these are good lessons for me to learn, since I didn't know anything, I understand little by little how things fit together:) and thank you very much for your help

Please Log in or Create an account to join the conversation.

Time to create page: 0.453 seconds
Powered by Kunena Forum