CM Error Trying to load a File

Hi there. I am using the Neil F PP for Vcarve pro and when I try to load a gcode with a tool change, CM throws this error:
Error in Line 10: P value not set

The bitsetter is all setup and works when using CC, but not the Shapeoko Tool Change_mm or the GRBL_ToolChange_mm PP

Any help is appreciated!

2 Likes

Can you post the first ~15 lines of that G-code file ? (or more simply the g-code file itself)

Sure, I have tried each of Neils PP and everyone throws the same error. This happens in both CM 5 and CM 428

G17
G21
G90
M6 T1
S12000M3
G0Z20.0000
G0X0.0000Y0.0000
G0X13.8333Y-8.9784Z5.0000
G1Z-2.5500F508.0
G04 1
G0Z5.0000
G0X54.8334Y-8.9668
G1Z-2.5500F508.0
G04 1
G0Z5.0000
G0X44.3334Y-9.0638Z5.0000
G1Z0.0000F508.0
G1Z-2.6000
G3X44.4334Y-8.9638I0.0000J0.1000
G3X44.3334Y-8.8638I-0.1000J0.0000
G1X24.3334Y-8.8596
G3X24.2334Y-8.9595I0.0000J-0.1000
G3X24.3334Y-9.0596I0.1000J0.0000
G1X44.3334Y-9.0638
G1X44.3332Y-9.9638
G3X45.3334Y-8.9640I0.0002J1.0000
G3X44.3336Y-7.9638I-1.0000J0.0002
G1X24.3336Y-7.9596
G3X23.3334Y-8.9594I-0.0002J-1.0000
G3X24.3332Y-9.9596I1.0000J-0.0002
G1X44.3332Y-9.9638
G0Z5.0000
M5
M6 T97
M3S12000
G0X1.5676Y-8.9226Z5.0000
G1Z-2.5500F508.0
G2X11.8351Y-0.0464I8.9862J-0.0182
G1X11.8544Y-0.0494
G3X33.9994Y-1.8425I22.0040J134.1083
G1X34.0015Y-1.8425
G3X56.1753Y-0.0468I0.1383J136.0950
G1X56.2002Y-0.0430
G2X66.4329Y-8.9569I1.2327J-8.9152
G2X56.2028Y-17.8738I-9.0000J-0.0013
G1X56.1779Y-17.8700
G3X34.0013Y-16.0807I-21.9978J-134.3212
G1X33.9987
G3X11.8220Y-17.8685I-0.1878J-136.1104
G1X11.7970Y-17.8723
G2X1.5676Y-8.9235I-1.2295J8.9156
G1X1.5676Y-8.9226
G0Z5.0000
G0Z20.0000
G0X0.0000Y0.0000
M02

If I am not mistaken, those “G04 1” lines should be “G04 P1” , the G4 command expects a delay in seconds or milliseconds specified after a “P” value (hence CC’s error message)

Looking at @neilferreri’s post, it gets the value from [DWELL] value, which I understand is used when a “Dwell move” is generated in the G-code. But I don’t know where this is set in VCarve. I just tried a sample file of mine using this post in VCarve, and I don’t have those G04 commands generated in the output file.

I’m sure Neil will chime in soon to explain, in the meantime you should be able to remove those “G04 1” lines (the only thing they do is wait 1 second) and run that safely.

Awesome, thanks! I will give that a try.

Ha, I may have found it: by any chance do you having drilling ops in your project ?
The “[DWELL]” seems to be set in drilling toolpath:

Who knows, we MAY have found a small bug in @neilferreri’s post, it’s possible that nobody used a drilling operation with that post before, OR that other G-code senders are more permissive and e.g. CNCjs would accept “G04 1”, I’ll check that too :slight_smile:

So rather than hand-editing the G-code file you may want to uncheck that box until this is fixed.

2 Likes

Yes, I am using drilling as I make a ton of wholes
 I can uncheck that and see if it works :slight_smile:

Ok, mystery solved then.
I just tried with CNCjs, and it does not like “G04 1” either (which is normal).

So actually, a much better workaround until Neil fixes this is to replace “G04 [DWELL]” by “G04 P[DWELL]” yourself in the post processor file, then it should be all good and you can keep your dwell option.

2 Likes

Very cool :slight_smile: Testing is good lol I will make the change and see what happens


2 Likes

Ok, so I saved one tool path with the dwell removed and I saved another after altering the PP to add a ‘P’ next to the dwell
 Both loaded fine.

3 Likes

Great, thanks for the confirmation.
Have fun drilling drilling drilling :slight_smile:

1 Like

LOL thanks, lots of holes in carbon fiber
 I appreciate the help in tracking this down
 guess I need to learn GCODE better.

3 Likes

I don’t know what you’re talking about. :woozy_face:

(Fixed)

Thanks for catching that. I don’t know how programmers keep track of versions. Somehow, that’s been missing for a while. I checked my PC and I have the P (I have a slightly different version because I don’t want a toolchange on the first tool).

2 Likes

No problem
 as a programmer myself, just making sure all changes are in version control, and or saved as different versions (one with an initial tool change and one without)
 but it can still get messy in a sense.

I’d like the version without the initial tool change :wink:

2 Likes

PM incoming


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.