Rapid over ride percentages

More
24 Oct 2013 13:25 #40239 by JR1050
Im having a hard time wrapping my head around the maximum velocity concept of halui. My goal is to use a BCD rotary selector to select 10,25,50,75 and 100% rates of rapid travel. I would like to direct set them similar to this

if(((modesel_pos)==1||(modesel_pos)==2)&&(rapid_or_pos)=1)
{
rapid_or_en=1;
rapid_or_dir=1;
rapid_or_per=.1
}


with the following hal connections
pin in s32 rapid_or_pos; // connected to wsum.0.sum = controlpanel.0.rapid-or=pos
pin out bit rapid_or_en ; //halui.max-velocity.count-enable = controlpanel.0.rapid-or-en
pin out bit rapid_or_dir; // halui.max-velocity.direct-value = controlpanel.0.rapid-or-dir
pin out s32 rapid_or_per; // halui.max-velocity.counts = controlpanel.0.rapid-or-per //percentage of maximum rapid

the modeselect and rapid or pos are connections to actual bcd selectors that are w summed , and used for setting conditions.

Is there a way to simply direct set the max value of rapid travel with out using the increase decrease pins? The manual and man pages are short on info. Would I be better off using halui.max-velocity.counts or halui.max-velocity.scale. It seems as this is set up more for a rotary encoder. All and any help is always appreciated.

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

More
24 Oct 2013 17:14 #40243 by BigJohnT
Here is what I used on my Hardinge. You should be able to use mux8.
# Feed Override
setp mux16.0.suppress-no-input true
setp halui.feed-override.count-enable true
setp halui.feed-override.direct-value true
setp halui.feed-override.scale 0.01
setp mux16.0.in00 0
setp mux16.0.in01 0
setp mux16.0.in02 10
setp mux16.0.in03 20
setp mux16.0.in04 30
setp mux16.0.in05 40
setp mux16.0.in06 50
setp mux16.0.in07 60
setp mux16.0.in08 70
setp mux16.0.in09 80
setp mux16.0.in10 90
setp mux16.0.in11 100
setp mux16.0.in12 110
setp mux16.0.in13 120
net ext-fork0 mux16.0.sel0 <= hm2_5i20.0.gpio.062.in_not
net ext-fork1 mux16.0.sel1 <= hm2_5i20.0.gpio.060.in_not
net ext-fork2 mux16.0.sel2 <= hm2_5i20.0.gpio.058.in_not
net ext-fork3 mux16.0.sel3 <= hm2_5i20.0.gpio.056.in_not
net ext-fork halui.feed-override.counts <= mux16.0.out-s

JT

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

More
24 Oct 2013 20:25 #40250 by andypugh

Is there a way to simply direct set the max value of rapid travel with out using the increase decrease pins?


Yes, it is the halui.feed-override.direct-value parameter that appears in JT's sample code.

It is probably easiest to connect the BCD bits directly to mux selectors. (no need for the wsum component).

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

More
25 Oct 2013 00:53 #40261 by JR1050
Replied by JR1050 on topic Rapid over ride percentages
Thank you bunches. Im pretty sure what I have is gonna work. Who I send a suggestion to for some minor modifications to the documentation? I have a small log of things that might be helpful to other folks. Thanks again.

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

More
25 Oct 2013 02:52 #40265 by BigJohnT

Who I send a suggestion to for some minor modifications to the documentation? I have a small log of things that might be helpful to other folks. Thanks again.


Me

JT

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

More
25 Oct 2013 09:46 #40270 by cmorley
Replied by cmorley on topic Rapid over ride percentages
One little detail about this suggestion is that Max-velocity is not in percent.
it is 0 to MAX_VELOCITY in the INI file.

if you choose the values in the mux correctly you can get percentage divisions,
but if you change the max velocity in the INI file you will need to adjust the mux values.

Chris M

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

More
25 Oct 2013 10:17 #40271 by JR1050
Replied by JR1050 on topic Rapid over ride percentages
Chris ,

Id like to bug you some about this. In johns example he is assigning what appear to be percentages to halui.feed-override.counts. That being the case, it would stand to reason that 10 would produce 10% of rapid travel, or a rate of 40ipm on a 400 ipm rate. Is this correct?

I approached this differently, I simply am looking for 5 rates of rapid travel which are assigned by a bcd selector. My stuff is written a component, for my whole operator panel. It has a section for the rapid over ride. Using Johns feed over ride example, if I assign a value of 10 to halui.max-velocity.counts with a scale of .01 assigned to halui.max-velocity.scale, on a 400 ipm max rapid, I should get 40 ipm? If not what about this am I missing?


I was planning on using analog pots for feed and spindle override, and was curious how to go about getting this to work. Thanks...

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

More
25 Oct 2013 11:18 - 25 Oct 2013 11:23 #40272 by cmorley
Replied by cmorley on topic Rapid over ride percentages
yes feed override and spindle override are in percentage
..well actually 1 is full speed (notice that John scaled feed override by .01 to account for that.

Max velocity is not done that way - I don't know why it was chosen to be like that. it is in user units per second as an absolute value

setting counts 10 with .01 scale = 0.1 unit per second or 6 units per minute

So to get counts to be percent:

divide max velocity in units per second by 100
400 / 60 = 6.6667
6.6667 / 100 = .066667

Then counts will be in percent.
If you change the INI file max velocity then you must recalculate this.

HALUI looks for MAX_VELOCITY= under [TRAJ], if it can't find it there it looks under [AXIS_0]
any other max velocity settings in the INI are either wrong and ignored or used for the GUI.

By the way Max velocity is NOT rapid override.
If you turn max velocity down enough it affects feed rate also.

Chris M
Last edit: 25 Oct 2013 11:23 by cmorley. Reason: math was wrong

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

More
25 Oct 2013 11:27 #40273 by JR1050
Replied by JR1050 on topic Rapid over ride percentages
Thanks for clearing that up, which brings a new question, what is available for backing down rapid travel and at what percent of max velocity does adjusting the max velocity affect feed rates? I wouldnt ask if I didnt have to....and thanks

JR

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

More
25 Oct 2013 11:41 #40274 by cmorley
Replied by cmorley on topic Rapid over ride percentages
There is a reason they named it max_velocity_override instead of rapid_override.

It sets the absolute max velocity linuxcnc will allow, in any mode but homing.

So if you set max_velocity_override lower then your current feed rate it will limit that feed rate.

Note that setting feed_override affects rapids also - annoying.

in linuxcnc 2.5.x that is how it is.
in 2.6 feed override will not affect rapids but max_velocity_override will still limit feed rate (not quite so annoying)

How were you going to get the analog signal into linuxcnc for your feed and spindle override?

Chris M

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

Time to create page: 0.157 seconds
Powered by Kunena Forum