Author Topic: 'Simulate with CAMotics' plugin  (Read 147374 times)

Offline Lou van Wijhe

  • Ewok
  • *
  • Posts: 45
    • View Profile
    • Lou's Homepage
Re: 'Simulate with CAMotics' plugin
« Reply #105 on: November 13, 2017, 11:33:29 am »
The updated plugin works. However, there are some peculiarities:

I have a project named CS Rudder and within it 2 machining parts named Registration Holes and Front Side. When I produce G-code it is placed in a file called CS Rudder.nc and CAMotics starts a project CS Rudder.xml. So far, so good.

1. When I want to produce different G-code files for each part, say for Registration Holes, I click on the [...] button in its Properties panel and CamBam creates a file named {$cbfile.name}-Registration Holes.nc (i.e. CS Rudder-Registration Holes.nc). However, when I then use the Simulate with CAMotics (Part) routine, the dash character is replaced by a full stop character and the simulation doesn’t work. When I manually replace the dash character in the Out-File name by a full stop character, it does work.

2. When I use these unique Out-File part names, I can no longer run a simulation for the entire project because all G-code output goes into the Out Files per part. I suppose this is as designed by CamBam. When I want to review the entire project, I must erase the Out-File part names first.

All in all, the updated plugin works well, with a proviso for the peculiarities.

Thank you!!
Lou

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 5332
  • Made in England
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #106 on: November 13, 2017, 11:40:42 am »
With my testing I have nothing in the Parts 'outfile' text box, it's just blank.
I can see how the method you are using inserts a dash though.

The problem arises because CamBam uses a "." if a right click method is used but uses a "-" if the outfile method is used  ???
« Last Edit: November 13, 2017, 14:09:19 pm by EddyCurrent »
Filmed in Supermarionation

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 4585
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
Re: 'Simulate with CAMotics' plugin
« Reply #107 on: November 13, 2017, 15:32:40 pm »
If I have some time I'll do some testing, but I simulate parts of jobs all the time.  I just name them differently when I get to that point.  Am I missing the point? 

Usually I have a TEST.nc file I use whenever I am doing CAMotics simulations.  I just keep over writing it since I don't cut from it anyway. 
Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline Lou van Wijhe

  • Ewok
  • *
  • Posts: 45
    • View Profile
    • Lou's Homepage
Re: 'Simulate with CAMotics' plugin
« Reply #108 on: November 13, 2017, 20:39:12 pm »
With my testing I have nothing in the Parts 'outfile' text box, it's just blank.
I can see how the method you are using inserts a dash though.

The problem arises because CamBam uses a "." if a right click method is used but uses a "-" if the outfile method is used  ???

I'm still pleased with the updated plugin, despite the peculiarities. I know where I have to pay attention to. By the way, where did you use the "right click method".

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 5332
  • Made in England
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #109 on: November 13, 2017, 20:48:26 pm »
Right mouse click on a Part name in the tree view.
Then use produce gcode, note the outfile box is empty.
Filmed in Supermarionation

Offline Lou van Wijhe

  • Ewok
  • *
  • Posts: 45
    • View Profile
    • Lou's Homepage
Re: 'Simulate with CAMotics' plugin
« Reply #110 on: November 13, 2017, 20:49:50 pm »
If I have some time I'll do some testing, but I simulate parts of jobs all the time.  I just name them differently when I get to that point.  Am I missing the point? 

Usually I have a TEST.nc file I use whenever I am doing CAMotics simulations.  I just keep over writing it since I don't cut from it anyway. 

I sometimes create different G-code files per part and do cut from them. So, I thought this would be convenient. Nevertheless, I'm curious about the outcome of your tests.

Lou

Offline Lou van Wijhe

  • Ewok
  • *
  • Posts: 45
    • View Profile
    • Lou's Homepage
Re: 'Simulate with CAMotics' plugin
« Reply #111 on: November 13, 2017, 20:52:13 pm »
Right mouse click on a Part name in the tree view.
Then use produce gcode, note the outfile box is empty.

I see, I just leave the Out-File text box empty, use the right click method and everything works fine!

I do like the update!
Lou
« Last Edit: November 13, 2017, 21:05:55 pm by Lou van Wijhe »

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 5332
  • Made in England
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #112 on: November 14, 2017, 10:51:17 am »
Okay, this version is more civilised. v1.5.3

PLEASE NOTE: This information applies to the option; "Simulate with CAMotics (PART)" only.


1. It automatically uses the correct character "-" or "." by looking to see if "outfile" has been populated.
so the outfile box can be empty or populated whichever method you prefer.

2. It now uses the SELECTED PART rather than the 'active part'
just select ONE part from the Treeview before running the plugin, it need not be the 'active part'

There are so many ways in CamBam to do the same thing it makes life a little difficult sometimes, so try the plugin yourself and let me know if it is not doing something you expect.

Suffice to say that whichever work flow you use, a gcode file must exist before CAMotics can simulate.

Instructions for use.

if cb2cm.config has, <regen_gfile_before_post>false</regen_gfile_before_post>
do this exactly,

1. start cambam, open your cb file
2. Machining->Produce gcode (i.e. for ALL the file)
3. select and right click the part required to simulate
4. select, produce gcode, from the context menu
5. with the part still selected choose, Tools->simulate with camotics (part)

if cb2cm.config has, <regen_gfile_before_post>true</regen_gfile_before_post>
do this,
1. start cambam,  open your cb file
2. select and right click the part required to simulate
3. select, produce gcode, from the context menu
4. with the part still selected choose, Tools->simulate with camotics (part)

« Last Edit: November 15, 2017, 14:26:14 pm by EddyCurrent »
Filmed in Supermarionation

Offline lloydsp

  • CNC Jedi
  • *****
  • Posts: 9086
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #113 on: November 14, 2017, 13:41:37 pm »
When I run the "simulate with CAMotics", everything is fine.

When I select a Part (with all MOps enabled), and use the "part" plugin, I get no display, and this error:

"Opening C:\Documents and Settings\LLoyd\Desktop\Evo Projects\Evo 22mm dipper\CAMotics test.Dip-wax mold - reworked.xml
Computing surface bounded by ((-1.79769e+308,-1.79769e+308,-1.79769e+308), (1.79769e+308,1.79769e+308,1.79769e+308)) at 0 grid resolution
Time: 2.05 secs Triangles: 0 Triangles/sec: 0.00 Resolution: 0"

I see, further, that it has created an illegal filename for XP when the part plugin is used.

One other thing... I have an engraving tool working to put nomenclature on the mold, and it never shows any contact having occurred between that tool and the lowered work surface (but it works in 'real life' on my mill).

Example attached.

Lloyd
"Pyro for Fun and Profit for More Than Fifty Years"

Offline EddyCurrent

  • CNC Jedi
  • *****
  • Posts: 5332
  • Made in England
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #114 on: November 14, 2017, 14:01:52 pm »
Lloyd,
Thanks for the example file.

Regarding the geometry errors, I've done nothing other than play about with filenames for this modification.

I tried it (win7, CamBam v1.0) and it all works for me.

What is the illegal filename for XP ? I don't have XP so can't test that.

This next bit has nothing to do with the plugin, purely CamBam, I created gcode for the part using two methods,

1. Right click the part then 'produce gcode' (the Part outfile text is empty)

Result; CAMotics test.Dip-wax mold - reworked.nc

1. Right click the part then 'produce gcode' (the Part outfile text populated)

Result; CAMotics test-Dip-wax mold - reworked.nc

Is one of those an illegal filename for XP ?
« Last Edit: November 14, 2017, 14:34:20 pm by EddyCurrent »
Filmed in Supermarionation

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 4585
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
Re: 'Simulate with CAMotics' plugin
« Reply #115 on: November 14, 2017, 14:49:07 pm »
Part names (and MOP names) can have punctuation that would create illegal file names.  Its not a fault of your plugin other than using a field that can store data not suitable for a file name.  You could write a string data filter, but that is far beyond the scope I think.
« Last Edit: November 14, 2017, 14:51:29 pm by Bob La Londe »
Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline lloydsp

  • CNC Jedi
  • *****
  • Posts: 9086
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #116 on: November 14, 2017, 15:11:42 pm »
Eddie,

This: "Cambam.testfile.cb" is illegal unless the entire path is passed to the OS in quotes.

I can fool with my filename and/or Part names.  It appears the plugin substitutes a "." for "-" wherever one appears.

Lloyd
"Pyro for Fun and Profit for More Than Fifty Years"

Offline Bob La Londe

  • CNC Jedi
  • *****
  • Posts: 4585
  • ^ 8.5 pounds on my own hand poured bait.
    • View Profile
    • CNC Molds N Stuff
Re: 'Simulate with CAMotics' plugin
« Reply #117 on: November 14, 2017, 15:20:39 pm »
You know... I very much appreciate this plug-in and I really respect you for going so far beyond to facilitate people who use the plug-in.  

But...  I started out writing individual MOP files.  Each one had a unique name.  Such as:

1 Surface Plate.nc
2 Rough Cavities.nc


When saving code it ASKS if you want to overwrite the last file name you used.  Just enter a new file name.  
Getting started on CNC?  In or passing through my area?
If I have the time I'll be glad to show you a little in my shop. 

Some Stuff I Make with CamBam
http://www.CNCMOLDS.com

Offline lloydsp

  • CNC Jedi
  • *****
  • Posts: 9086
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #118 on: November 14, 2017, 15:43:50 pm »
Eddy,
I renamed everything so that there were no 'special' characters, only spaces.

The plugin re-names the outfile as "mastername.partname.cb".  That's an illegal filename for XP unless special path-passing means are used.  Apparently CAMotics doesn't do that in the older XP version (the most-recent version that will work on XP).

Lloyd
"Pyro for Fun and Profit for More Than Fifty Years"

Offline lloydsp

  • CNC Jedi
  • *****
  • Posts: 9086
    • View Profile
Re: 'Simulate with CAMotics' plugin
« Reply #119 on: November 14, 2017, 16:00:49 pm »
Nope.... sorry, I was completely mistaken about filename compatibility.  I'm running the latest POS (point of sale, not the OTHER POS!!) version of XP.

Those names ARE legal in this version.  But I found the problem.


When I run the 'part' plugin, it names the project .xml according to the filename and partname... Like "CAMotics test.Dip wax mold.xml"  And that CAN be found by my system.

But it names the .nc file only as CAMotics test.nc.  And that's not the .nc file referenced in the project file.  What shows in the project is "CAMotics test.Dip wax mold.nc".

If I change either the actual filename OR the filename referenced in the project, it works fine.

???

Lloyd
"Pyro for Fun and Profit for More Than Fifty Years"