G76, Troubleshooting needed!

More
28 Oct 2018 21:24 #119571 by PCW
Replied by PCW on topic G76, Troubleshooting needed!
I mean using halscope to see if the encoder position or velocity are noisy

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

More
28 Oct 2018 21:28 #119572 by Victor
Replied by Victor on topic G76, Troubleshooting needed!
Ok! I will check tomorrow and make a screenshot!

Br Victor

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

More
29 Oct 2018 19:29 #119609 by Victor
Replied by Victor on topic G76, Troubleshooting needed!
Ok, So i did a Hal-Scope of the Input-A signal and the Input-index signal.

Picture HAL-Scope-1, HAL-Scope-2, HAL-Scope-3 is when just running the spindle at 1200rpm-ish.

Picture HAL-Scope-4, HAL-Scope-5, HAL-Scope-6 is taken during the stuttering that occurs when using G76/G33 with 1200rpm / 1rev per turn in feed.

Br Victor

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

More
29 Oct 2018 21:00 #119624 by PCW
Replied by PCW on topic G76, Troubleshooting needed!
Yeah those are pretty lumpy

I suspect you will need to low pass filter the spindle encoder position to get
clean tracking (say 20-50 ms time constant)

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

More
30 Oct 2018 09:09 #119638 by Victor
Replied by Victor on topic G76, Troubleshooting needed!
Ok, My initial thought was some additional hardware?
But after a bit of Googling i came across this: linuxcnc.org/docs/html/man/man9/lowpass.9.html

If you meant the loadrt lowpass [count=N|names=name1[,name2...]] way how would i configure that? unfortunately my coding skills are pretty much 0.

Br Victor

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

More
30 Oct 2018 10:32 #119639 by andypugh
You can try this in your custom.hal
# Disconnect motion.spindle-revs from the signal in the main HAL file
unlinkp motion.spindle-revs
loadrt lowpass count=1
addf lowpass.0   servo-thread
setp lowpass.0.gain 0.05
# This signal needs to be the one from your main HAL file. 
# This is a guess...
net spindle-revs lowpass.0.in
net spindle-revs-filt lopass.0.out => motion.spindle-revs
The following user(s) said Thank You: Victor

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

More
30 Oct 2018 17:51 #119650 by Victor
Replied by Victor on topic G76, Troubleshooting needed!
Ok, Andy i put your code in my custom.hal and I got the following error message:
Debug file information:
Note: Using POSIX realtime
iptables: No chain/target/match by that name.
lowpass: already exists
./custom.hal:21: waitpid failed /usr/bin/rtapi_app lowpass
./custom.hal:21: /usr/bin/rtapi_app exited without becoming ready
./custom.hal:21: insmod for lowpass failed, returned -1
3393

Looked in my .HAL file and yes i have the lowpass in a bunch of places.
loadrt lowpass names=lowpass.spindle
addf lowpass.spindle          servo-thread

#  spindle-velocity bounces around so we filter it with lowpass
setp     lowpass.spindle.gain 1.000000

net spindle-fb-rpm-abs           abs.spindle.out         =>   lowpass.spindle.in
net spindle-fb-rpm-abs-filtered  lowpass.spindle.out  

Tried commenting out the first ones but got stuck at the last ones.

What does filter setting below do?
# ---Encoder feedback signals/setup---

setp    hm2_7i76e.0.encoder.00.counter-mode 1
setp    hm2_7i76e.0.encoder.00.filter 1
setp    hm2_7i76e.0.encoder.00.index-invert 0
setp    hm2_7i76e.0.encoder.00.index-mask 0
setp    hm2_7i76e.0.encoder.00.index-mask-invert 0
setp    hm2_7i76e.0.encoder.00.scale  [SPINDLE_9]ENCODER_SCALE

I'll attach complete debug info and also .HAL file.

Br Victor
Attachments:

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

More
30 Oct 2018 18:04 #119651 by andypugh
Ok, make the first loadrt say something like "names=lowpass.spindle,lowpass.spindlepos" instead and use lowpass.spindlepos in your custom.hal

You don't have to use custom.hal, of course, but if you edit the main hal you can't use pncconf again without losing your changes. This probably isn't a problem, it is sensible to conclude that pncconf has done its job once the machine runs.
The following user(s) said Thank You: Victor

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

More
30 Oct 2018 18:23 #119652 by Victor
Replied by Victor on topic G76, Troubleshooting needed!
Hmm pretty sure i did not understand you correctly.

Should i change "loadrt lowpass names=lowpass.spindle" that is in my main .hal file to
"loadrt names=lowpass.spindle,lowpass.spindlepos" ?

Got this error code:
Debug file information:
Note: Using POSIX realtime
names=lowpass.spindle,lowpass.spindlepos: dlopen: /usr/lib/linuxcnc/modules/names=lowpass.spindle,lowpass.spindlepos.so: cannot open shared object file: No such file or directory
./Emco-120P.hal:13: waitpid failed /usr/bin/rtapi_app names=lowpass.spindle,lowpass.spindlepos
./Emco-120P.hal:13: /usr/bin/rtapi_app exited without becoming ready
./Emco-120P.hal:13: insmod for names=lowpass.spindle,lowpass.spindlepos failed, returned -1
4514

Agreed that Pncconf has done it's job but since i lack the coding skills, if i want to add something or change an input I'm lost without it so i have to use Pncconf and then replace all the custom bits i have added after.

Br Victor

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

More
30 Oct 2018 18:59 #119653 by andypugh
It looks like you left out the "loadrt lowpass" ?
The following user(s) said Thank You: Victor

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

Time to create page: 0.101 seconds
Powered by Kunena Forum