Xcarve_JTech_grbl (usage notes)

For those of you that use multiple programs to send your g-code to the X-carve remember that the grbl settings are persistent even through a power off cycle. Be careful to make sure that you have the correct parameters loaded into grbl when you start a laser or spindle job.

If you use PicSender exclusively, all you need to do is to select the applicable mode and PicSender will take care of loading the proper grbl parameters for that job. If you leave PicSender to use an alternate method of sending your g-code be sure to select the correct mode for the new job in PicSender before you leave (the easiest way to change the grbl parameter set).

Here are the grbl parameter files that I use for testing with my 500mm X-carve.

For PicSender:
Laser.txt (1.1 KB)
Spindle.txt (1.1 KB)

For plain text versions:
Laser_plain_text.txt (1.0 KB)
Spindle_plain_text.txt (1.0 KB)

To select laser mode set the following grbl parameters as shown below:
$30=255.
$31=0.
$32=1
remember to change your other settings as appropriate

If you use a variable speed spindle controlled by the PWM signal from the Arduino/gShield or X-controller then to select spindle mode with a spindle that has an RPM range from 10000 to 30000 rpm use the following grbl settings:
$30=30000.
$31=10000.
$32=0
remember to change your other settings as appropriate

Tip

If you use the PWM signal to control a solid state relay for turning a spindle/router on/off and you do not use a variable speed spindle you can use $30=255. and $31=0. for both spindle and laser. For the spindle any S value greater than or equal to 255 (with M3 active) will turn the relay full on and an S value of 0 (zero) will turn the relay off. M3 and M5 work normally.

5 Likes

thanks Larry

what $30 $31 $32 settings should users of De Walt and Makita type trim routers with manual on/off use ?

cheers

GC

For that case I would use $30=255. and $31=0. for all setups. That way it doesn’t need to change with a mode switch.

$32=0 for spindle $32=1 for laser.

Use spindle mode for carving.

Use laser mode for vector laser (engraving — S0 laser off S255 laser full on) and raster laser (images — S varies from S0 off to S255 full on with intermediate values based on gray scale image).

3 Likes

Hi Larry, just to clear up my confusion…With your grbl hex files I have to use your laser file only for laser then override with your spindle file to use the spindle each time? Or if I want to switch from easel / spindle to picsender / laser can I just upload one of the codes and for ever be happy?.. I’m using the cnc with both spindle and laser in a school setting and want to keep it as simple as possible for me and the students.

@MikeKaplan
Just to expand a little on what Robert said, grbl has a set of internal parameters that “tune” the performance of grbl to the machine that you are using. There is only one set of the parameters inside grbl. These parameters are saved in EEPROM, which retains the information even when there is no power to the Arduino.

The tuning parameters can be different for spindle work and laser work. When you change from spindle to laser or laser to spindle you need to reload the appropriate set for the work you are going to do.

If you use PicSender exclusively as your G-code sender then PicSender will take care of loading the correct parameter set (once you have set them up appropriately - a one time task) with the click of a single button.

To my knowledge, no other G-code sender has this functionality, so if you want to use a different G-code sender then you have to make sure that the appropriate set of parameters is loaded into grbl prior to running your job.

If you use a mix of G-code senders then the easiest way to change the parameters is to load in the set you want to use next (by clicking on spindle or laser) within PicSender before you close it out to use the other G-code sender.

Let me know if you need further clarification.

Larry

2 Likes

Thanks to both Robert and Larry for your clarification. The laser is only used in the school situation when I have free time with only a couple of students. Most of the machine use will be with Easel. So I guess I will just ensure at the end of each laser session I take responsibility for switching Picsender back to spindle. But I am curious what Robert means by a Lock out tab.