Sad new user: can't get past "error:20 Unsupported or invalid g-code command found in block"

Hello,

I’m an absolute beginner and I can’t help but think I’ve missed something obvious. I haven’t found any resolved questions on the forum that cover “error:20 Unsupported or invalid g-code command found in block”.

I don’t know where to start to explain the problem.

Here is the text I get in the consol:
Starting stream
Layer C00
error:20
Unsupported or invalid g-code command found in block.
On or near line 4:
Job halted
Stream completed in 0:00
error:20
Unsupported or invalid g-code command found in block.

Thanks for any feedback or help with this!

In LightBurn, click ‘Save GCode’ and save the gcode to a .txt file. Attach that file here so we can have a look.

2021-12-23 error 20.txt (704 Bytes)
Thanks for the reply!! I hope I did this correctly

Are you attempting to use the rotary? Try disabling rotary function as well as Z axis and try again.

1 Like

Nope, no rotary.

I mean have you configured rotary to be on? Can you check Tools->Rotary Setup?

The “Enable Rotary” button is green. I guess that means it is configured to be on.
Capture d’écran 2021-12-23 153509

So disable that. Also disable your Z-axis in Edit-Device settings. Test and report back.

1 Like

Looks like this did the trick! I’ve completed two tests successfully!
I didn’t get the desired result, but that appears to be a question of speed and power settings. I have more testing to do…

Thanks a million for your help!

error:20

Comando g-code no compatible o no válido encontrado en el bloque.

En o cerca de la línea 0:

Trabajo detenido

Transmisión completada en 0:00

Comenzando transmisión

Capa C00

error:20

Comando g-code no compatible o no válido encontrado en el bloque.

En o cerca de la línea 0:

Trabajo detenido

Transmisión completada en 0:00

Grbl 1.1h [‘$’ para obtener ayuda]

Comenzando transmisión

Capa C00

error:20

Comando g-code no compatible o no válido encontrado en el bloque.

En o cerca de la línea 0:

Trabajo detenido

Transmisión completada en 0:00

Grbl 1.1h [‘$’ para obtener ayuda]
error:20

Unsupported or invalid g-code command found in block.

En o cerca de la línea 0:

Job halted

Transmisión completada en 0:00

Grbl 1.1h [‘$’ for help]

ok

Can you click ‘Save Code’, save the file to a .txt file, open it in Notepad, and then copy the first ten lines here so I can see?

Hello there,

I have the same issue.

I am adding these 10-12 lines of my txt file:

; LightBurn 1.2.03
; iLaser device profile, current position
; Bounds: X-0.05 Y0.12 to X49.95 Y29.82
M101 P5730
G00 G17 G40 G21 G54
G91
M4
; Image @ 3000 mm/min, 20% power
M8
G0 X3.65Y0.122
; Layer C00
G1 X14.2F3000S200

I can cut a line, but when I select an image, then I get the mentioned error.

I have tried with those 2 tricks, but It didn’t work for me.

Thank you

You have setup your laser with the “iLaser” device type. Edit your device and switch this to “GRBL”.

  1. push “Devices” button in Laser window
  2. select your laser and then click “Edit”
  3. Change your device type and accept other settings

Retest.

2 Likes

yes! It worked for me.

Thank you @berainlb

1 Like

i am having trouble. error 20. unsupported g code line 0

2021-12-23 error 20.txt (704 Bytes)

I’m going to guess you have the Rotary enabled but don’t want it. Disable the rotary and retry.

If that’s not it can you describe the actual problem you’re experiencing? Then please upload a full screenshot of LightBurn as well as the full content of Console.

I’m not sure if that if it is enabled. When I do something as simple as type hello and do the frame and then hit start it will start for 1 second and stop.

Can you take a full screenshot of LightBurn and post here? Also, copy and paste the contents of Console.

1 Like

Hello i also have problem. It starts to work for a few seconds and then it stops and I get this message. I tried everything here what you suggested but it don’t work.
Lightburn.txt (217.2 KB)