Units for feedrate

Here's the place for discussion related to CAM/CNC and the development of the Path module.
mlampert
Posts: 288
Joined: Fri Sep 16, 2016 9:28 pm

Re: Units for feedrate

Postby mlampert » Mon Feb 06, 2017 1:29 am

danielfalck wrote:I can eradicate all instances of "App::PropertySpeed" if no one objects :)


It's definitely a way to ease your pain right now.

There is one drawback to this though, and that is sharing your FC file with someone else. If they setup the feedrate in metric and give it to you - with it being a plain float you'll have 2.54 times their feed rate ...

Anyway, I think that's a less important feature right now than making Path working without annoyance for all imperial users - go for it.
herbk
Posts: 336
Joined: Mon Nov 03, 2014 3:45 pm
Location: Windsbach, Bavarya (Germany)

Re: Units for feedrate

Postby herbk » Mon Feb 06, 2017 6:35 am

Hi,
by talking about feedrate...: the shown units for the feedrate also on metric systems is wrong. FreeCAD shows mm/s but it should be mm/min.
http://www.linuxcnc.org/docs/2.7/html/gcode/machining-center.html#sub:feed-rate
Gruß Herbert
cox
Posts: 912
Joined: Wed Nov 26, 2014 11:37 pm

Re: Units for feedrate

Postby cox » Mon Feb 06, 2017 10:18 am

herbk wrote:Hi,
by talking about feedrate...: the shown units for the feedrate also on metric systems is wrong. FreeCAD shows mm/s but it should be mm/min.


True, but I somehow feel that mm/s is more intuitive, I can easier relate to the speed of the tool. (This is probably very individual)

My preferred solution would be to have it configurable and display an other just for reference.

When setting the federate you have the option to set it in mm/min, m/min, inch/sec, inch/min default is set in preferences.

You can also enable a alternate display unit in preferences, where you can choose from one of the above. So that you can see the alternate number besides your system default.
Need help? Feel free to ask, but please read the guidelines first
GeneFC
Posts: 67
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Units for feedrate

Postby GeneFC » Mon Feb 06, 2017 3:07 pm

LinuxCNC is a bit schizophrenic about the feed rate. The convention is units per minute in the GUI and units per second in the ini file.

I got tired of entering several digits in the property panel feed rate boxes in order to get round numbers in imperial units. I simply ignore the units and make the appropriate correction in my post-processor. My post-processor is largely the linuxcnc_post, with a few mods for units and formatting.

Almost any clarification or change in the property panel would be good. The current situation is not a problem for experienced users who can make the corrections, but it must be confusing for new or casual users.

Gene
herbk
Posts: 336
Joined: Mon Nov 03, 2014 3:45 pm
Location: Windsbach, Bavarya (Germany)

Re: Units for feedrate

Postby herbk » Mon Feb 06, 2017 3:42 pm

Hi Cox,
True, but I somehow feel that mm/s is more intuitive
mm/s would also more intuitiv for me, but if the shown unit is not the same as in the machine software, it's confusing.

First times i tried pathes made with Freecad i run in this situation:
I know that the x axis on my self made router is stalling by feed > 310mm/min, i know LinuxCNC "wants" mm/min and FreeCAD shows mm/s. So i set the feedrate in FreeCAD to 5, because 300mm/min / 60 = 5mm/s.
Feed the code to the machine, machine runs in rapid to the start point, - and... nothing...
OK not realy nothing, but the steps for 5mm/min are not easy to notice..
Wild looking at the machine, what made i wrong (you remember: it's the self made...) again...? Some time later, after a better look to the gcode i found the foult quickly. :o :?
Since that, i don't really note the units behind the field for the feedrate setting....


@ Gene
LinuxCNC is a bit schizophrenic about the feed rate. The convention is units per minute in the GUI and units per second in the ini file.
There i'm with you... :lol:
Gruß Herbert
mlampert
Posts: 288
Joined: Fri Sep 16, 2016 9:28 pm

Re: Units for feedrate

Postby mlampert » Mon Feb 06, 2017 6:16 pm

wow - this seems to be a mess - I think danielfalck's approach of just using a float might actually be the best and most useful thing to do ;)
cox
Posts: 912
Joined: Wed Nov 26, 2014 11:37 pm

Re: Units for feedrate

Postby cox » Mon Feb 06, 2017 8:38 pm

herbk wrote:Feed the code to the machine, machine runs in rapid to the start point, - and... nothing...
OK not realy nothing, but the steps for 5mm/min are not easy to notice..


I certainly would like the g-code to be made with the expected values for the machine. My thinking is more that while looking for feed and speeds online you find the numbers in all permutations, so it would be nice to just put in what you find, and skip the manual conversions. Even just looking at a video of a machining operation it is easier to relate to /s numbers, you can almost gauge it just by looking at it(not all videos disclose their numbers).
Need help? Feel free to ask, but please read the guidelines first
chrisb
Posts: 1668
Joined: Tue Mar 17, 2015 9:14 am

Re: Units for feedrate

Postby chrisb » Tue Feb 07, 2017 4:26 pm

mlampert wrote:wow - this seems to be a mess - I think danielfalck's approach of just using a float might actually be the best and most useful thing to do ;)

If the parameters of the post processor are stored in the FreeCAD file I will adapt the preprocessor accordingly. Then the drawback you mentioned with exchanging files wouldn't be serious at all.
marcuswolschon
Posts: 22
Joined: Thu Sep 26, 2013 1:52 pm

Re: Units for feedrate

Postby marcuswolschon » Thu Feb 09, 2017 9:28 am

Some machine control software use mm/min (e.g. MACH3) and some use mm/s. Some are configurable.
Problem is that due to the factor of 60 users of one system have absolutely no relation to numbers in the other system.
I know what 100mm/min are and I have no idea if 10mm/s is something very fast or very slow unless I take out a calculator.

Obviously seeing different numbers in CAM and in machine control also makes for some excellent confusion.
sliptonic
Posts: 597
Joined: Tue Oct 25, 2011 10:46 pm

Re: Units for feedrate

Postby sliptonic » Thu Feb 09, 2017 3:05 pm

I've played around with this a little bit trying to understand it better. Here's what I think I've learned.

A velocity is a derived unit from two base units, time and distance. So grepping for 'mm/s' probably wouldn't find anything.
A velocity unit is always going to be converted to and stored in FreeCAD base units (mm/s). But the user can input in any format and it'll be converted. So '25 in/min' becomes 10.5833 mm/s'

There's no FreeCAD preference for storing a derived unit. User can choose metric or imperial but not how velocity will be expressed. In fact, there's no preference for time units at all. So velocity always appears in mm/s.

The desired output is achieved with

Code: Select all

>>> cutspeed = FreeCAD.Units.Quantity('25 in/min')
>>> cutspeed
10.5833 mm/s
>>> displayspeed = cutspeed.getValueAs('in/min')
>>> displayspeed
25


I think the postprocessors need a property for the desired format. The property would store a string like 'in/min'
It would assume that the value it's processing is always in the FreeCAD base unit for velocity (mm/s) and act accordingly.

To summarize if I understand correctly.

Unit handling internally works fine.
Unit output through the post could be made to work fine quite easily.
Displaying the units on the screen in the same format the user entered is a problem because the current unit schemas don't do derived units/time.

In my opinion, solving the last one would solve everything and make the Path velocity much more flexible and maybe we shouldn't purge the App::PropertySpeed at all.