Welcome to Our Community

Some features disabled for guests. Register Today.

C02 Laser Controll

Discussion in 'Laser Cutters' started by Andreas Ritter, Sep 12, 2019 at 11:22 AM.

  1. Andreas Ritter

    Builder

    Joined:
    Thursday
    Messages:
    2
    Likes Received:
    0
    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.
     
  2. David the swarfer

    David the swarfer OpenBuilds Team
    Staff Member Moderator Builder

    Joined:
    Aug 6, 2013
    Messages:
    1,288
    Likes Received:
    645
    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.
     
    Peter Van Der Walt likes this.
  3. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Resident Builder Project Maker Builder

    Joined:
    Mar 1, 2017
    Messages:
    1,746
    Likes Received:
    894
    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
     
  4. Andreas Ritter

    Builder

    Joined:
    Thursday
    Messages:
    2
    Likes Received:
    0
    So could I still have power control over the laser?
     
  5. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Resident Builder Project Maker Builder

    Joined:
    Mar 1, 2017
    Messages:
    1,746
    Likes Received:
    894
    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)
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice