Router Forums banner

GRBL - M98 Command Error

3923 Views 8 Replies 3 Participants Last post by  PhilBa
Dear All,

I have tried to repeat the whole process via the M98 P0 L2 command. But I got below error msg.



''An error was detected while sending 'M98P0L2': (error:20) Unsupported or invalid g-code command found in the block. Streaming has been paused
''

GRBL version: 1.1
Software : UGS

Anyone Help me out.
1 - 9 of 9 Posts
GRBL doesn't support O-codes (subprograms) so it's not a surprise that M98 is unsupported. You'll need to make your G-Code to do the operations inline.
GRBL doesn't support O-codes (subprograms) so it's not a surprise that M98 is unsupported. You'll need to make your G-Code to do the operations inline.
Thanks a lot. Could you please tell me how to repeat the whole program up to a certain time (Example: 40 times) with GRBL command?
GRBL doesn't support O-codes (subprograms) so it's not a surprise that M98 is unsupported. You'll need to make your G-Code to do the operations inline.
Thanks a lot. Could you please tell me how to repeat the whole program up to a certain time (Example: 40 t
imes) with GRBL command?
Well, if you are writing G-Code by hand you just write the operations 40 times. If you are using CAM then it depends on what you are using. Also, you will need to select a GRBL post processor.
Well, if you are writing G-Code by hand you just write the operations 40 times. If you are using CAM then it depends on what you are using. Also, you will need to select a GRBL post processor.
You mean to say, repeat the whole program by 40 times?

Sorry, I am new, my understanding below. Is it correct?

My Program - I have repeated 2 times ... IS it like that I have to repeat 40 times?

G90
$H
M3S0
Z0
X -42.5
Y - 35.5
Z 4
Y -37
Y -37.1
Z4.5
M3S45
Z1
Y0
X0
M3S0
Z0


G90
$H
M3S0
Z0
X -42.5
Y - 35.5
Z 4
Y -37
Y -37.1
Z4.5
M3S45
Z1
Y0
X0
M3S0
Z0
.....
..
...
..
...
See less See more
Yes.

But, are you actually coding by hand? You should really be using CAD and CAM. Coding by hand for anything but ultra simple things is going to get old very very fast.

And, just looking briefly at your G-Code, I suspect you are missing some key points like for the Z axis, down/lower is usually negative. And M5 is a better way to turn off your spindle than M3S0. Have you watched any tutorials?
Are you wanting to cut 40 items at a time? If so you would also need to add code to move to each location of the items. Why not design the job with the number of desired items allowing for bit size then run Cam on the job?
Yes.

But, are you actually coding by hand? You should really be using CAD and CAM. Coding by hand for anything but ultra simple things is going to get old very very fast.

And, just looking briefly at your G-Code, I suspect you are missing some key points like for the Z axis, down/lower is usually negative. And M5 is a better way to turn off your spindle than M3S0. Have you watched any tutorials?
Thanks for your reply. This is a mini CNC router. I am using my Z-axis as a gripper with a servo motor. M3S0 is Opening the gripper and M3S45 closing the gripper.
Ah, that makes more sense. Though to be honest, your use is pretty far from what we normally see 'round these here parts, pardner. What is this for? Some sort of chess machine?
1 - 9 of 9 Posts
This is an older thread, you may not receive a response, and could be reviving an old thread. Please consider creating a new thread.
Top