I have been working on a co2 laser cutter and its now about time to start testing it. Its running off of an arduino uno and a cnc shield with grbl and that works fine with the total of 3 nema 17 motors(1x, 2y). Now i want to connect the co2 laser. The power supply I have will take a pwm input but i am not quite sure how to do that with the uno+shield. Also, what free software is there that i could use? Here are the links to what I have: arduino + shield- Arduino CNC Kit w/ UNO + Shield+ Stepper motors DRV8825 Endstop GRBL laser power supply- 50W CO2 MYJG Series Power Supply (Green Shell) MYJG-50W 110/220V I don't have very much experience with arduino so any help would be greatly appreciated.
so that power supply has simple on/off control via one of the input pins at TTL level (that means 5v for on and 0v for off). you can connect that enable pin to the spindle output on the shield. here is the complication ... older versions of GRBL used a different pinout to the newer version and most cnc shields use the old pinout and just a few use the new pinout. so you need to follow the Arduino pin 11 into the shield and see where it comes out. if it is a new shield it will be labelled Spindle PWM , if it is an old (common) shield it will be labelled Z-limit. GRBL defaults to being able to output a PWM signal on that pin 11, this means it turns the 5v on and off rapidly at varying spacing to achieve a varying output voltage form 0 to 5v. This would be used to set the speed of a router or the brightness of the laser if your power supply could do variable power. but it cannot so you have to do off and on and make sure your Gcode does not try to set something like half power which may damage the PSU. GRBL defaults to a speed range of 0 to 1000. So what you want in your Gcode is 'M5' for laser off and 'M3 S1000' for laser on. (at the simplest level) However, GRBL has a special laser mode where it does some clever stuff for you. set $32=1 and now GRBL only needs one M3 S1000 at the beginning of the code and one M5 at the end of the code. Now GRBL will turn the laser on or off depending on the motion code used, so off for rapid motion (G00) and on for G1/2/3 'cutting' codes. CAM software like OpenBuilds CAM Gcode Creator - Public Beta can do this for you, no need to write Gcode yourself, but understanding it will help you fix any problems you may have. but the important bit is the that S1000 which tells GRBL to turn the laser full on. any lower number may damage the PSU.
Also, checkout Advice on CO2 Laser Build where I explain what to do with IN, and WP. You can usually PWM into TH though even if the PSU doesnt say so. They tend be standardised
Tentatively yes, 90%+ of the chinese PSUs I've worked with happily worked with PWM into TH, to modulate the power, with manual override potentiometer on IN instead (also thats how the K40 and K50s are wired from the factory)
Sorry for the late response, I have been busy with school. So I should be able to connect the Z-axis limit to TH, connect the cnc shield ground to the power supply G, and hook up the laser tube itself and it should work? Do I need a water detection, or do I need to bridge it, or just leave it alone? Also, what software is easiest to configure with my setup?
Worth testing yes WP to GND bridge or a flow switch needed, I wouldn't risk a bridge, $3 flow switch is cheaper insurance than replacing a cracked tube because the water stopped flowing from a little kink in the hose (;
cam.openbuilds.com with OpenBuilds CONTROL > OpenBuilds Software - FREE Software for CNC Control: OpenBuilds CONTROL and OpenBuilds CAM or LaserWeb4: LaserWeb/LaserWeb4-Binaries
Don't forget what @David the swarfer said; "here is the complication ... older versions of GRBL used a different pinout to the newer version and most cnc shields use the old pinout and just a few use the new pinout. so you need to follow the Arduino pin 11 into the shield and see where it comes out. if it is a new shield it will be labelled Spindle PWM , if it is an old (common) shield it will be labelled Z-limit." Alex.
I am pretty sure that my shield is an older one, there is no spindle PWM. I will check my board later but do i need to change anything in the GRBL config? I think I have the newest version of GRBL
Nah you already had it before Alex made you doubt yourself. Use the z limit as pwm pin, only difference is the two pins swopped. V3.5 shield got knocked off by China, but the v3.5.1 and up has the right pinout (not cloned by china, only available from the original designer, Protoneer (Bertus Kruger)) The CNC shields all has issues with only supporting small motors due to pololu footprint drivers (allegro, tmc drivers max 0m6-0.8a before cooling issues, drv88xx drivers max 1-1.2a before thermal shutdown BlackBox has 4A drivers that runs big nema23s if it has to, or properly and speedily anything smaller, which for lasers is important, maximum acceleration needed to prevent charring and get even grayscale engraving