Path simulator bug?

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!
Post Reply
Giulio Buccini
Posts: 541
Joined: Fri Aug 26, 2016 9:07 pm
Location: Munich - Gemany

Path simulator bug?

Post by Giulio Buccini »

I was just playing with the "Linear2D" array command to duplicate some circular pockets on a plane.
I noticed that if I try to simulate the path then only the milling ops on the first pocket are executed, the other pockets are ignored.

I missing something? :?
(I attach my file.)
working table MDF 1.0.FCStd
(142.39 KiB) Downloaded 23 times
---------------------------------------------------------
OS: Ubuntu 16.04.7 LTS (XFCE/xfce)
Word size of FreeCAD: 64-bit
Version: 0.20.25065 (Git) AppImage
Build type: Release
Branch: master
Hash: 4de2ad46b2b9c78ac2721a0dbea7c19306261095
Python version: 3.9.4
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.2
Locale: English/United States (en_US)
Attachments
Selection_7431.jpg
Selection_7431.jpg (29.71 KiB) Viewed 1145 times
Russ4262
Posts: 941
Joined: Sat Jun 30, 2018 3:22 pm
Location: Oklahoma
Contact:

Re: Path simulator bug?

Post by Russ4262 »

Giulio Buccini wrote: Sat Jul 10, 2021 9:15 pm ... I noticed that if I try to simulate the path then only the milling ops on the first pocket are executed, the other pockets are ignored.

I missing something? :? ...
Afternoon from the sunny state of Oklahoma in the United States of America. I am taking a look at your file and the issue you are reporting. First test confirms your reported issue. I am now looking into the code for the cause.

Russell
Russ4262
Posts: 941
Joined: Sat Jun 30, 2018 3:22 pm
Location: Oklahoma
Contact:

Re: Path simulator bug?

Post by Russ4262 »

Me again.
The problem appears to be that the `Array` object lacks the `Active` property that other operations possess. I will see if I can identify a proper solution for this issue. Feel free to create a bug tracker ticket for this issue.

I currently have an open PR that refactors the `PathArray` module. If I identify a solution to this issue, I may append it to that PR.

Thanks for reporting the matter. Have a great afternoon.

Russell
Giulio Buccini
Posts: 541
Joined: Fri Aug 26, 2016 9:07 pm
Location: Munich - Gemany

Re: Path simulator bug?

Post by Giulio Buccini »

Hi Russel, 3:30 AM here in Germany.

Anyway the generated g-code seems ok to me. So it seems a problem of the simulator only. Can you confirm?

P.S.
Following the link you posted I read: "IMPORTANT: POST ONLY 0.19 BUG REPORTS"
I'm using version 0.20 ... :?
Russ4262
Posts: 941
Joined: Sat Jun 30, 2018 3:22 pm
Location: Oklahoma
Contact:

Re: Path simulator bug?

Post by Russ4262 »

Giulio Buccini wrote: Sun Jul 11, 2021 1:44 am ... So it seems a problem of the simulator only. Can you confirm? ...
Good early German morning!
I can confirm the issue is isolated to the simulator.

I have added a simple fix, adding the `Active` property to the Array object, to the existing PR #4818, [Path] Refactor path array algorithm into independent PathArray class. I tested the fix and it does allow the simulator to include the Array object in the simulation. I also added the Path Array operation to the recognized list for the `Active` toggle in the Path WB toolbar since it will now have the dependent `Active` property for the toggle process.

Giulio Buccini wrote: Sun Jul 11, 2021 1:44 am ...
P.S.
Following the link you posted I read: "IMPORTANT: POST ONLY 0.19 BUG REPORTS"
I'm using version 0.20 ... :?
The bug does exist in 0.19 also. You are simply a very astute individual that uses the latest and greatest version. ;)

Have a great day. Thanks for making FreeCAD better.

Russell
Attachments
Simulator including the Array object
Simulator including the Array object
Snip macro screenshot-a07149.png (246.93 KiB) Viewed 1072 times
Newly added `Active` property for `Array` objects
Newly added `Active` property for `Array` objects
Snip macro screenshot-deea19.png (268.64 KiB) Viewed 1072 times
Giulio Buccini
Posts: 541
Joined: Fri Aug 26, 2016 9:07 pm
Location: Munich - Gemany

Re: Path simulator bug?

Post by Giulio Buccini »

Post Reply