Can i Jog part program using MPG ?

More
5 years 9 months ago #194386 by marq_torque
Hello Everyone,

I am trying to setup hand wheel jog function to do program inching, is it possible to take control of program movement on hand wheel ?

What it will do is when i start program run, machine will check if handhweel mode is on or off, if its on then user will rotate handwheel and machine will continue program as per handwheel rotation, if user stops rotation program will hold and move further if handwheel is rotated. and if program is okay user will continue with program cycle and so on ...

marq

Please Log in to join the conversation.

More
5 years 9 months ago #194387 by andypugh
Not as a built-in behaviour, as far as I know.

But I think you could arrange to do it by manipulating the motion.adaptive-feed pin.

Send the handwheel _velocity_ to the adaptive feed pin in handwheel mode.

You can even go backwards.

Please Log in to join the conversation.

More
5 years 8 months ago #199239 by marq_torque
Hello Andy,


I tried to add below thread in my machine hal file ... it was throwing error "Scale is already linked to xhc wireless hal file"
I commented it for test, but MPG is not working now ....i'm sure i'm doing something very dumb :(


loadrt conv_s32_float
loadrt lowpass count=2
loadrt ddt
loadrt scale
addf conv-s32-float.0 servo-thread
addf lowpass.0 servo-thread
addf lowpass.1 servo-thread
addf ddt.0 servo-thread
addf scale.0 servo-thread

net jog-counts conv-s32-float.0.in
net jog-countf conv-s32-float.0.out

setp lowpass.0.gain 0.05
net jog-countf lowpass.0.in
net jog-countl lowpass.0.out

net jog-countl ddt.0.in
net jog-speedu ddt.0.out

setp lowpass.1.gain 0.05
net jog-speedu lowpass.1.in
net jog-speedx lowpass.1.out

setp scale.0.gain 0.0005
net jog-speedx scale.0.in
net jog-speed scale.0.out

net jog-speed motion.adaptive-feed

Please Log in to join the conversation.

More
5 years 8 months ago #199240 by marq_torque
I'm trying to get this working

Please Log in to join the conversation.

More
5 years 8 months ago #199245 by andypugh
You might need to add a second scale component.

What is the _exact_ error message?

Please Log in to join the conversation.

More
5 years 8 months ago #199246 by marq_torque
Attached here my hal files

I have commented 24to36 lines, 82to102 lines

Attachment not found

Attachment not found

Please Log in to join the conversation.

More
5 years 8 months ago #199247 by marq_torque
Exact message when i used xhc hal without comments


#MPG Adaptive Feed Start
loadrt conv_s32_float
loadrt lowpass count=2
loadrt ddt
loadrt scale
addf conv-s32-float.0 servo-thread
addf lowpass.0 servo-thread
addf lowpass.1 servo-thread
addf ddt.0 servo-thread
addf scale.0 servo-thread

net jog-counts conv-s32-float.0.in
net jog-countf conv-s32-float.0.out

setp lowpass.0.gain 0.05
net jog-countf lowpass.0.in
net jog-countl lowpass.0.out

net jog-countl ddt.0.in
net jog-speedu ddt.0.out

setp lowpass.1.gain 0.05
net jog-speedu lowpass.1.in
net jog-speedx lowpass.1.out

setp scale.0.gain 0.0005
net jog-speedx scale.0.in
net jog-speed scale.0.out

net jog-speed motion.adaptive-feed
#MPG Adaptive Feed End


Edit : Exact message after i put above lines in machine hal file

Attachment not found

Please Log in to join the conversation.

More
5 years 8 months ago #199356 by andypugh
"Scale" already exists.

You need to loadrt scale in only one place, with the number that you need.

So remove the "loadrt scale" from xhc-whb04b-6.hal, and have
"loadrt scale count=2" in the new (earlier in the sequence) HAL file.

Then use scale.1 in the new stuff, and leave scale.0 in the xhc HAL file.

Please Log in to join the conversation.

More
5 years 8 months ago #199374 by marq_torque
May be i'm missing something ?


#MPG Adaptive Feed Start
loadrt conv_s32_float
loadrt lowpass count=2
loadrt ddt
loadrt scale count=2
addf conv-s32-float.0 servo-thread
addf lowpass.0 servo-thread
addf lowpass.1 servo-thread
addf ddt.0 servo-thread
addf scale.1 servo-thread

net jog-counts conv-s32-float.0.in
net jog-countf conv-s32-float.0.out

setp lowpass.0.gain 0.05
net jog-countf lowpass.0.in
net jog-countl lowpass.0.out

net jog-countl ddt.0.in
net jog-speedu ddt.0.out

setp lowpass.1.gain 0.05
net jog-speedu lowpass.1.in
net jog-speedx lowpass.1.out

setp scale.0.gain 0.0005
net jog-speedx scale.1.in
net jog-speed scale.1.out

net jog-speed motion.adaptive-feed
#MPG Adaptive Feed End



Attachment not found



Attachment not found

Please Log in to join the conversation.

More
5 years 8 months ago #199376 by Aciera
You need to uncomment line 24.

Please Log in to join the conversation.

Time to create page: 0.105 seconds
Powered by Kunena Forum