Toolbits. SERIOUS EFFORT NEEDED

Here's the place for discussion related to CAM/CNC and the development of the Path module.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by GeneFC »

sliptonic wrote: Tue Nov 10, 2020 6:52 pm This is still a draft PR. If you can build from source, you can pull my branch or checkout the PR branch and build it.
I finally got around to compiling and testing. Mostly seems to work fine, but a couple of quirks.

1. As noted above, a warning is thrown if both parts of an endmill are the same diameter. I am not sure if the upper shank diameter currently matters for FreeCAD, although in the future there might be some undercut feature for a smaller shanks or some collision avoidance feature for larger shanks.

2. The naming in the Job tree is definitely weird. I get a label that takes part of the tool name and adds to it. I do not understand why there are two levels in the tree for each tool. Is it not possible to include all of the parameters in a single tree entry?

3. I struggled for quite a while to get the tool dock to recognize my preferred custom locations for saving tool bits, shapes and libraries. I finally needed to edit my user.cfg file to make the links work. Using the "Store absolute paths" and "Remember last library" in the FC Preferences dialog did not seem to be effective.

4. Creating a new tool seems a bit awkward. The first thing that happens is to ask for a shape. The next is to ask for a tool name. It would seem that the first item would be to ask for parameters rather than a tool name. The shape would be the first item in the parameters. The current order works, but I predict that new users will have the same questions I did.

5. The "dock" always opens up locked in a fixed position rather than floating like I left it when I previously closed FC. I liked the behavior of the old tool library, and don't want the dock to consume a permanent location on my screen.

6. The default drill bit tip angle comes in as 119 degrees. This should be 118 degrees to match typical industry practice.

Overall this seems like a nice approach, and it appears to work quite well. A couple of tweaks would be nice, but otherwise looks good.

Gene
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by sliptonic »

Thanks Gene,
Good feedback. I'll try to incorporate my answers into the wiki pages too. If someone gets there first, thank you.
GeneFC wrote: Wed Nov 11, 2020 5:24 pm
1. As noted above, a warning is thrown if both parts of an endmill are the same diameter. I am not sure if the upper shank diameter currently matters for FreeCAD, although in the future there might be some undercut feature for a smaller shanks or some collision avoidance feature for larger shanks.
ok. Investigating.
2. The naming in the Job tree is definitely weird. I get a label that takes part of the tool name and adds to it. I do not understand why there are two levels in the tree for each tool. Is it not possible to include all of the parameters in a single tree entry?
Naming can certainly be improved. I'll work on that.

There are two levels to the tree because there are two objects. The Tool Controller is the same as it always was but the tool referenced by the TC is now a first-class document object. You can select it and toggle visibility to see the solid model of the tool. You can also edit the toolbit in the tree without changing the version on disk. This means you can share files that have custom tools without having to also share the toolbit and shapefiles. Right click on the toolbit in the tree and you'll have menu items to save it to disk if you want your own local copy.
3. I struggled for quite a while to get the tool dock to recognize my preferred custom locations for saving tool bits, shapes and libraries. I finally needed to edit my user.cfg file to make the links work. Using the "Store absolute paths" and "Remember last library" in the FC Preferences dialog did not seem to be effective.
'store absolute paths' has nothing to do with your preferred locations. If checked, the tool library will refer to the toolbit with a full absolute path and the toolbit will do the same to reference the shapefile. If unchecked, it will assume the toolbit and shapefile are located in Bit/Shape directories relative to the library location. I'm not sure if 'remember last library' does anything anymore. I think it's deprecated with legacy tools and I will probably remove it entirely.
4. Creating a new tool seems a bit awkward. The first thing that happens is to ask for a shape. The next is to ask for a tool name. It would seem that the first item would be to ask for parameters rather than a tool name. The shape would be the first item in the parameters. The current order works, but I predict that new users will have the same questions I did.
After picking the shape file, you're actually setting the filename where the tool will be persisted. This is a little different than the tool 'name' property. There might be a better way to do the workflow but if I don't ask for the filename first, then the dialog has to prompt the user when they click 'ok' at the end and this seems confusing.
5. The "dock" always opens up locked in a fixed position rather than floating like I left it when I previously closed FC. I liked the behavior of the old tool library, and don't want the dock to consume a permanent location on my screen.
The dock can be made to float like any other dock. Its state probably isn't retained between restarts. That's something we can work on. The idea here is to use a non-modal panel when 'using tools' (rather than managing your collection of tools). In the past, the tool library was modal which really kinda sucks. A non-modal dock lets the user keep it open continuously as they add/configure operations. A modal dialog interrupts the user workflow.

For example, have you ever been configuring an operation and realize you don't have a TC for the right tool? You have to either cancel the operation, create the TC, and restart, or assign the wrong tool, exit, create the TC, and edit the operation again. It should be possible to just add the TC from the dock while you're editing the operation. As of this writing, you can add TCs while editing operations, but the list of available TCs in the operations doesn't update yet. Gotta leave something to fix in the future :)

I understand that having a dock open all the time isn't desirable for everyone, especially those with smaller monitors which is why I'm doing everything I can to keep it small and to make it easy to toggle. The hot-key sequence (P,T) will toggle the state as will pressing the toolbar button. Having used this for a couple weeks, I can say it grows on you fast!
6. The default drill bit tip angle come in as 119 degrees. This should be 118 degrees to match typical industry practice.
I think this is problem with a toolshape or maybe a floating point error. Not related to the toolbit workflow though.
spanner888
Posts: 326
Joined: Tue May 28, 2019 10:51 am

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by spanner888 »

Should Tool names be forced to be unique, or it it entirely up to user to manage?
duplicate Tool names.png
duplicate Tool names.png (36.33 KiB) Viewed 1612 times


Some additional comments on above dialog:
Would be very useful to at least also display tools cutting diameter & maybe length & shank diameter.
Need some hint that you double click to edit, or an edit button.
Not critical, but also not up to rest of FC "niceness" is the way the Library window flashes as change to edit mode


OS: Debian GNU/Linux 10 (buster) (XFCE/xfce)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.22895 +9 (Git)
Build type: Unknown
Branch: sliptonic/toolbits_tidyup
Hash: f2d7979b3fc8c07f8890a0b6dce11c22603f81b1
Python version: 3.7.3
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/Australia (en_AU)
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by sliptonic »

spanner888 wrote: Fri Nov 13, 2020 2:28 am Should Tool names be forced to be unique, or it it entirely up to user to manage?
Toolbits are forced to be unique by virtue of being files on the file system. The display name is just a property and is user assigned. We can suggest something but I think it's up to the user.
Would be very useful to at least also display tools cutting diameter & maybe length & shank diameter.
I totally agree that we need to show more - the question is what to show? Diameter and shank pre-suppose rotary tools and the dialog needs to support lathe tools as well. There are other kinds of tools that lack specific properties so the dialog has to work in every case. I actually had diameter in and removed it for that reason. This is an area that needs some creative thinking.
Need some hint that you double click to edit, or an edit button.
Not critical, but also not up to rest of FC "niceness" is the way the Library window flashes as change to edit mode
OK. I'll look at those things. Good feedback. Thank you!
herbk
Veteran
Posts: 2660
Joined: Mon Nov 03, 2014 3:45 pm
Location: Windsbach, Bavarya (Germany)

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by herbk »

Hi sliptonic,
sliptonic wrote: Fri Nov 13, 2020 4:18 am I totally agree that we need to show more - the question is what to show?
may be a picture, which pops up if the mouse is over the tool name, would be good.
Espacially for woodworking are a lot of toolshapes usual which are not easy to describe with words...
Gruß Herbert
User avatar
Wsk8
Posts: 182
Joined: Fri Dec 07, 2018 6:24 pm

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by Wsk8 »

I think preview images like here would be really helpful: https://makerbyheart.com/billeder/week1 ... libery.jpg
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by sliptonic »

herbk wrote: Fri Nov 13, 2020 7:48 am may be a picture, which pops up if the mouse is over the tool name, would be good.
Espacially for woodworking are a lot of toolshapes usual which are not easy to describe with words...
Wsk8 wrote: Fri Nov 13, 2020 9:11 am Espacially for woodworking are a lot of toolshapes usual which are not easy to describe with words...
There are two kinds of pictures possible.
First is the thumbnail image of the toolshape. We already generate this and use it for the icon in the tree. It's easy to get but not representative of the users's actual tool. All endmills look the same. I think these images work fine for icons but will cause confusion if we try to show them in a larger size for a toolbit.

The second would be an image of the user's actual tool. This means either a) building the image in realtime which means loading the toolshape file. (not something you want to do on a mouse-over since it will be very slow) or b) building the images when the tool is edited and storing them on the disk someplace.

The best solution would be a hybrid. It looks for a stored image and if not found builds one in the background, ideally in a separate process. I think this is possible but not for a 0.19 release.
User avatar
Wsk8
Posts: 182
Joined: Fri Dec 07, 2018 6:24 pm

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by Wsk8 »

I don't think a picture of the actual tool is necessary. Just a generic image of the tool type should be enough, And the parameters should be shown like in the picture.
Youn don't create tools everyday, but then you do it's very helpful
Attachments
v-bit.png
v-bit.png (28.72 KiB) Viewed 1489 times
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by GeneFC »

We may be overthinking this.

I added descriptions in all the tool labels. No pictures needed, since I have a pretty good idea what I have available in my workshop.

If there are hundreds or thousands of tools it might be necessary. But I would guess that the overwhelming majority of FC users are not in that class.

Just apply a descriptive name.

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

Re: Toolbits. SERIOUS EFFORT NEEDED

Post by herbk »

Like sayd above: Carpenter have a lot of endmills with different shapes, here 2 examples:
shapemill.jpg
shapemill.jpg (29.15 KiB) Viewed 1391 times
For tools like that a pic would be very helpfull to find it... ;)
Last edited by herbk on Sat Nov 14, 2020 8:25 am, edited 1 time in total.
Gruß Herbert
Post Reply