Re: [Emc-users] M62/M63 with a pwm output possible?
That got it. With the info in the thread I found a posting on the LightBurn forums from someone trying to make a laser work on his Probotix machine. He had the find/replace strings in the final post. I was using the spindle pwm pin generated by Stepconf for laser power control. I checked my HAL file and found that the spindle was set up on pwmgen.0 like his example. First try didn't fire the laser so I guessed that the pwmgen for the spindle wasn't active until the spindle was started. I put in a M3 S10 before the first laser power command in the file (an off) and things started working. I haven't decided if I am going to edit the HAL to add another pwmgen just for the laser or if I can find a simple way to always have the pwmgen.0 enabled. is Now I just need to zero in on some parameters for the burn. I was doing a photo of our dog and cat. Dog came out reasonable but the black cat was very light. I think I need to back down the velocity as it is moving over the pure black area too fast to do anything. Dave On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher wrote: > You might need to use M67 to set the PWM value and M62 to turn it on/off. > > Todd Zuercher > P. Graham Dunn Inc. > 630 Henry Street > Dalton, Ohio 44618 > Phone: (330)828-2105ext. 2031 > > -Original Message- > From: Dave Matthews > Sent: Friday, August 13, 2021 4:16 PM > To: Enhanced Machine Controller (EMC) > Subject: [Emc-users] M62/M63 with a pwm output possible? > > [EXTERNAL EMAIL] Be sure links are safe. > > I recently started playing with lightburn and want to do photos. Using > M3/M5 Sxxx for laser control works fine for following lines but not for > photos. I think that I want to use M62 along with an Sxxx for laser on and > power setting. The laser power is controlled by PWMing the on/off pin. > > Lightburn likes to use M106 and an S number for laser control. I think it > is coming from M106 being used for fan on a Marlin 3d printer board. > Find/Replace M03 in place of the M106 sort of works but It does a laser > on, move, laser off so there is a lot of overburn. > > Sample gcode from Lightburn: > ; Image @ 2500 mm/min, 20% power > M8 > M106 S0 > G0X1.8487 Y0.8204 F0 > ; Layer C01 > M106 S0 > G1X0.041 F98.425 > M106 S20 > G1X0.29 > M106 S0 > G1X0.041 > M106 S0 > > From the docs it looks like M62 would do the job if I can also use the > Sxxx to set the pwm. > > Questions > > - Is it possible to set up the digital pin associated with the M62 to be a > PWM output? > - Is there an example of how to do this? > > Dave > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
I use something like this to control the heater on my 3d printer hot end. Power transistors run high-current DC through a big resistor in a heater cartridge in the hot end. The power transistors are driven by a low-power PWM control signal (3.3V logic, low current, 2kHz). The duty cycle of this PWM signal controls how much current runs through the resistor, which controls how much heat it adds to the hot end. The low-power PWM control signal comes from a Teensy PWM output: https://www.pjrc.com/teensy/td_pulse.html The duty cycle of the PWM signal is controlled by a PID component in HAL (which gets temperature feedback from a thermistor in the hot end). The temperature command input to the PID component comes from one of the `motion.analog-out-NN` pins coming out of the LinuxCNC motion controller ( http://linuxcnc.org/docs/2.8/html/man/man9/motion.9.html#MOTION%20PINS). I use M67 (http://linuxcnc.org/docs/2.8/html/gcode/m-code.html#mcode:m67) to set the temperature command to the PID controller. Your situation with the laser seems simpler, since you don't need the PID loop. You'll set desired laser power with M67, and connect the `motion.analog-out-NN` pretty much directly (maybe after some scaling) to a physical PWM output pin. This physical pin will connect to the control input of the laser power supply. -- Sebastian Kuzminsky On Sat, Aug 14, 2021 at 6:40 AM Les Newell wrote: > On 13/08/2021 22:25, Dave Matthews wrote: > > I come from an electronics background and am used to looking at a scope > so > > have always considered PWM as a digital control mode. I'll take a look > for > > examples of how to set up a pwm pin in HAL. My initial setup was done > with > > StepConf so I let it do all of the work to set up a spindle pwm pin. > > > > Thanks. > > > > Dave > > The PWM pulse is digital (on or off) but the pulse width is analog. The > pulse width is the parameter you are changing. > > Les > > > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
On 13/08/2021 22:25, Dave Matthews wrote: I come from an electronics background and am used to looking at a scope so have always considered PWM as a digital control mode. I'll take a look for examples of how to set up a pwm pin in HAL. My initial setup was done with StepConf so I let it do all of the work to set up a spindle pwm pin. Thanks. Dave The PWM pulse is digital (on or off) but the pulse width is analog. The pulse width is the parameter you are changing. Les ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
I am just an old technician that started out fixing stuff off of Nike Hercules sites. I ended up going back to school to be a software type and gave that up for retirement a few years ago.. I looked it up in the docs and I think that I can probably just use the pin and pwmgen stuff that StepConf generated. I will just need to dig around for the number to use with the M67. Dave On Fri, Aug 13, 2021, 18:28 Ralph Stirling wrote: > I'm also an EE. Class D audio amplifiers are filtered PWM. A motor > inductance also filters pwm to an analog value. Your laser modulation > input likely low pass filters the pwm as well. > > -- Ralph > > On Aug 13, 2021 2:25 PM, Dave Matthews wrote: > CAUTION: This email originated from outside the Walla Walla University > email system. > > > I come from an electronics background and am used to looking at a scope so > have always considered PWM as a digital control mode. I'll take a look for > examples of how to set up a pwm pin in HAL. My initial setup was done with > StepConf so I let it do all of the work to set up a spindle pwm pin. > > Thanks. > > Dave > > On Fri, Aug 13, 2021 at 5:21 PM Ralph Stirling < > ralph.stirl...@wallawalla.edu> wrote: > > > PWM *is* analog (0 to 1.0). In hal, you would connect motion.analog_out > > (syntax likely wrong, going by memory) to a pwm value input. That would > > feed the M67 value to your pwm. > > > > -- Ralph > > > > On Aug 13, 2021 2:09 PM, Dave Matthews wrote: > > CAUTION: This email originated from outside the Walla Walla University > > email system. > > > > > > I saw a lot of references to using the M67 but couldn't see how it would > > apply as it is for analog outputs. I thought that would be for something > > like the 0-10 volt spindle control. I was looking at the M62 because I > > thought a PWM output would be considered a digital pin. Am I looking at > it > > wrong? The laser is PWM between 0 and 5v. > > > > Dave > > > > On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher > > wrote: > > > > > You might need to use M67 to set the PWM value and M62 to turn it > on/off. > > > > > > Todd Zuercher > > > P. Graham Dunn Inc. > > > 630 Henry Street > > > Dalton, Ohio 44618 > > > Phone: (330)828-2105ext. 2031 > > > > > > -Original Message- > > > From: Dave Matthews > > > Sent: Friday, August 13, 2021 4:16 PM > > > To: Enhanced Machine Controller (EMC) > > > > Subject: [Emc-users] M62/M63 with a pwm output possible? > > > > > > [EXTERNAL EMAIL] Be sure links are safe. > > > > > > I recently started playing with lightburn and want to do photos. Using > > > M3/M5 Sxxx for laser control works fine for following lines but not for > > > photos. I think that I want to use M62 along with an Sxxx for laser on > > and > > > power setting. The laser power is controlled by PWMing the on/off pin. > > > > > > Lightburn likes to use M106 and an S number for laser control. I think > > it > > > is coming from M106 being used for fan on a Marlin 3d printer board. > > > Find/Replace M03 in place of the M106 sort of works but It does a laser > > > on, move, laser off so there is a lot of overburn. > > > > > > Sample gcode from Lightburn: > > > ; Image @ 2500 mm/min, 20% power > > > M8 > > > M106 S0 > > > G0X1.8487 Y0.8204 F0 > > > ; Layer C01 > > > M106 S0 > > > G1X0.041 F98.425 > > > M106 S20 > > > G1X0.29 > > > M106 S0 > > > G1X0.041 > > > M106 S0 > > > > > > From the docs it looks like M62 would do the job if I can also use the > > > Sxxx to set the pwm. > > > > > > Questions > > > > > > - Is it possible to set up the digital pin associated with the M62 to > be > > a > > > PWM output? > > > - Is there an example of how to do this? > > > > > > Dave > > > > > > ___ > > > Emc-users mailing list > > > Emc-users@lists.sourceforge.net > > > > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7Cc049983552324009948d08d95ea0e3c7%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644867391671331%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=BlMQs4lcF0qlyR
Re: [Emc-users] M62/M63 with a pwm output possible?
I'm also an EE. Class D audio amplifiers are filtered PWM. A motor inductance also filters pwm to an analog value. Your laser modulation input likely low pass filters the pwm as well. -- Ralph On Aug 13, 2021 2:25 PM, Dave Matthews wrote: CAUTION: This email originated from outside the Walla Walla University email system. I come from an electronics background and am used to looking at a scope so have always considered PWM as a digital control mode. I'll take a look for examples of how to set up a pwm pin in HAL. My initial setup was done with StepConf so I let it do all of the work to set up a spindle pwm pin. Thanks. Dave On Fri, Aug 13, 2021 at 5:21 PM Ralph Stirling < ralph.stirl...@wallawalla.edu> wrote: > PWM *is* analog (0 to 1.0). In hal, you would connect motion.analog_out > (syntax likely wrong, going by memory) to a pwm value input. That would > feed the M67 value to your pwm. > > -- Ralph > > On Aug 13, 2021 2:09 PM, Dave Matthews wrote: > CAUTION: This email originated from outside the Walla Walla University > email system. > > > I saw a lot of references to using the M67 but couldn't see how it would > apply as it is for analog outputs. I thought that would be for something > like the 0-10 volt spindle control. I was looking at the M62 because I > thought a PWM output would be considered a digital pin. Am I looking at it > wrong? The laser is PWM between 0 and 5v. > > Dave > > On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher > wrote: > > > You might need to use M67 to set the PWM value and M62 to turn it on/off. > > > > Todd Zuercher > > P. Graham Dunn Inc. > > 630 Henry Street > > Dalton, Ohio 44618 > > Phone: (330)828-2105ext. 2031 > > > > -Original Message----- > > From: Dave Matthews > > Sent: Friday, August 13, 2021 4:16 PM > > To: Enhanced Machine Controller (EMC) > > Subject: [Emc-users] M62/M63 with a pwm output possible? > > > > [EXTERNAL EMAIL] Be sure links are safe. > > > > I recently started playing with lightburn and want to do photos. Using > > M3/M5 Sxxx for laser control works fine for following lines but not for > > photos. I think that I want to use M62 along with an Sxxx for laser on > and > > power setting. The laser power is controlled by PWMing the on/off pin. > > > > Lightburn likes to use M106 and an S number for laser control. I think > it > > is coming from M106 being used for fan on a Marlin 3d printer board. > > Find/Replace M03 in place of the M106 sort of works but It does a laser > > on, move, laser off so there is a lot of overburn. > > > > Sample gcode from Lightburn: > > ; Image @ 2500 mm/min, 20% power > > M8 > > M106 S0 > > G0X1.8487 Y0.8204 F0 > > ; Layer C01 > > M106 S0 > > G1X0.041 F98.425 > > M106 S20 > > G1X0.29 > > M106 S0 > > G1X0.041 > > M106 S0 > > > > From the docs it looks like M62 would do the job if I can also use the > > Sxxx to set the pwm. > > > > Questions > > > > - Is it possible to set up the digital pin associated with the M62 to be > a > > PWM output? > > - Is there an example of how to do this? > > > > Dave > > > > ___ > > Emc-users mailing list > > Emc-users@lists.sourceforge.net > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7Cc049983552324009948d08d95ea0e3c7%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644867391671331%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=BlMQs4lcF0qlyREAutYk9V18ssqfk0ecl3nS24iuDVg%3D&reserved=0 > > > > > > ___ > > Emc-users mailing list > > Emc-users@lists.sourceforge.net > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7Cc049983552324009948d08d95ea0e3c7%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644867391681328%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=wlHYwF2Kum9DJ3dgfxlzZN8ZO3TgIW3pyF7FkfSKjQo%3D&reserved=0 > > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7Cc0499835523240099
Re: [Emc-users] M62/M63 with a pwm output possible?
I think Ralph is talking about the HAL pin on the PWM generator wich is an analog one. There you can send your M67 analog value to control the intensity of the laser. El vie, 13 ago 2021 a las 18:28, Dave Matthews () escribió: > I come from an electronics background and am used to looking at a scope so > have always considered PWM as a digital control mode. I'll take a look for > examples of how to set up a pwm pin in HAL. My initial setup was done with > StepConf so I let it do all of the work to set up a spindle pwm pin. > > Thanks. > > Dave > > On Fri, Aug 13, 2021 at 5:21 PM Ralph Stirling < > ralph.stirl...@wallawalla.edu> wrote: > > > PWM *is* analog (0 to 1.0). In hal, you would connect motion.analog_out > > (syntax likely wrong, going by memory) to a pwm value input. That would > > feed the M67 value to your pwm. > > > > -- Ralph > > > > On Aug 13, 2021 2:09 PM, Dave Matthews wrote: > > CAUTION: This email originated from outside the Walla Walla University > > email system. > > > > > > I saw a lot of references to using the M67 but couldn't see how it would > > apply as it is for analog outputs. I thought that would be for something > > like the 0-10 volt spindle control. I was looking at the M62 because I > > thought a PWM output would be considered a digital pin. Am I looking at > it > > wrong? The laser is PWM between 0 and 5v. > > > > Dave > > > > On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher > > wrote: > > > > > You might need to use M67 to set the PWM value and M62 to turn it > on/off. > > > > > > Todd Zuercher > > > P. Graham Dunn Inc. > > > 630 Henry Street > > > Dalton, Ohio 44618 > > > Phone: (330)828-2105ext. 2031 > > > > > > -Original Message- > > > From: Dave Matthews > > > Sent: Friday, August 13, 2021 4:16 PM > > > To: Enhanced Machine Controller (EMC) > > > > Subject: [Emc-users] M62/M63 with a pwm output possible? > > > > > > [EXTERNAL EMAIL] Be sure links are safe. > > > > > > I recently started playing with lightburn and want to do photos. Using > > > M3/M5 Sxxx for laser control works fine for following lines but not for > > > photos. I think that I want to use M62 along with an Sxxx for laser on > > and > > > power setting. The laser power is controlled by PWMing the on/off pin. > > > > > > Lightburn likes to use M106 and an S number for laser control. I think > > it > > > is coming from M106 being used for fan on a Marlin 3d printer board. > > > Find/Replace M03 in place of the M106 sort of works but It does a laser > > > on, move, laser off so there is a lot of overburn. > > > > > > Sample gcode from Lightburn: > > > ; Image @ 2500 mm/min, 20% power > > > M8 > > > M106 S0 > > > G0X1.8487 Y0.8204 F0 > > > ; Layer C01 > > > M106 S0 > > > G1X0.041 F98.425 > > > M106 S20 > > > G1X0.29 > > > M106 S0 > > > G1X0.041 > > > M106 S0 > > > > > > From the docs it looks like M62 would do the job if I can also use the > > > Sxxx to set the pwm. > > > > > > Questions > > > > > > - Is it possible to set up the digital pin associated with the M62 to > be > > a > > > PWM output? > > > - Is there an example of how to do this? > > > > > > Dave > > > > > > ___ > > > Emc-users mailing list > > > Emc-users@lists.sourceforge.net > > > > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > > > > > > > > > ___ > > > Emc-users mailing list > > > Emc-users@lists.sourceforge.net > > > > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJ
Re: [Emc-users] M62/M63 with a pwm output possible?
I come from an electronics background and am used to looking at a scope so have always considered PWM as a digital control mode. I'll take a look for examples of how to set up a pwm pin in HAL. My initial setup was done with StepConf so I let it do all of the work to set up a spindle pwm pin. Thanks. Dave On Fri, Aug 13, 2021 at 5:21 PM Ralph Stirling < ralph.stirl...@wallawalla.edu> wrote: > PWM *is* analog (0 to 1.0). In hal, you would connect motion.analog_out > (syntax likely wrong, going by memory) to a pwm value input. That would > feed the M67 value to your pwm. > > -- Ralph > > On Aug 13, 2021 2:09 PM, Dave Matthews wrote: > CAUTION: This email originated from outside the Walla Walla University > email system. > > > I saw a lot of references to using the M67 but couldn't see how it would > apply as it is for analog outputs. I thought that would be for something > like the 0-10 volt spindle control. I was looking at the M62 because I > thought a PWM output would be considered a digital pin. Am I looking at it > wrong? The laser is PWM between 0 and 5v. > > Dave > > On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher > wrote: > > > You might need to use M67 to set the PWM value and M62 to turn it on/off. > > > > Todd Zuercher > > P. Graham Dunn Inc. > > 630 Henry Street > > Dalton, Ohio 44618 > > Phone: (330)828-2105ext. 2031 > > > > -Original Message----- > > From: Dave Matthews > > Sent: Friday, August 13, 2021 4:16 PM > > To: Enhanced Machine Controller (EMC) > > Subject: [Emc-users] M62/M63 with a pwm output possible? > > > > [EXTERNAL EMAIL] Be sure links are safe. > > > > I recently started playing with lightburn and want to do photos. Using > > M3/M5 Sxxx for laser control works fine for following lines but not for > > photos. I think that I want to use M62 along with an Sxxx for laser on > and > > power setting. The laser power is controlled by PWMing the on/off pin. > > > > Lightburn likes to use M106 and an S number for laser control. I think > it > > is coming from M106 being used for fan on a Marlin 3d printer board. > > Find/Replace M03 in place of the M106 sort of works but It does a laser > > on, move, laser off so there is a lot of overburn. > > > > Sample gcode from Lightburn: > > ; Image @ 2500 mm/min, 20% power > > M8 > > M106 S0 > > G0X1.8487 Y0.8204 F0 > > ; Layer C01 > > M106 S0 > > G1X0.041 F98.425 > > M106 S20 > > G1X0.29 > > M106 S0 > > G1X0.041 > > M106 S0 > > > > From the docs it looks like M62 would do the job if I can also use the > > Sxxx to set the pwm. > > > > Questions > > > > - Is it possible to set up the digital pin associated with the M62 to be > a > > PWM output? > > - Is there an example of how to do this? > > > > Dave > > > > ___ > > Emc-users mailing list > > Emc-users@lists.sourceforge.net > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > > > > > > ___ > > Emc-users mailing list > > Emc-users@lists.sourceforge.net > > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
PWM *is* analog (0 to 1.0). In hal, you would connect motion.analog_out (syntax likely wrong, going by memory) to a pwm value input. That would feed the M67 value to your pwm. -- Ralph On Aug 13, 2021 2:09 PM, Dave Matthews wrote: CAUTION: This email originated from outside the Walla Walla University email system. I saw a lot of references to using the M67 but couldn't see how it would apply as it is for analog outputs. I thought that would be for something like the 0-10 volt spindle control. I was looking at the M62 because I thought a PWM output would be considered a digital pin. Am I looking at it wrong? The laser is PWM between 0 and 5v. Dave On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher wrote: > You might need to use M67 to set the PWM value and M62 to turn it on/off. > > Todd Zuercher > P. Graham Dunn Inc. > 630 Henry Street > Dalton, Ohio 44618 > Phone: (330)828-2105ext. 2031 > > -Original Message- > From: Dave Matthews > Sent: Friday, August 13, 2021 4:16 PM > To: Enhanced Machine Controller (EMC) > Subject: [Emc-users] M62/M63 with a pwm output possible? > > [EXTERNAL EMAIL] Be sure links are safe. > > I recently started playing with lightburn and want to do photos. Using > M3/M5 Sxxx for laser control works fine for following lines but not for > photos. I think that I want to use M62 along with an Sxxx for laser on and > power setting. The laser power is controlled by PWMing the on/off pin. > > Lightburn likes to use M106 and an S number for laser control. I think it > is coming from M106 being used for fan on a Marlin 3d printer board. > Find/Replace M03 in place of the M106 sort of works but It does a laser > on, move, laser off so there is a lot of overburn. > > Sample gcode from Lightburn: > ; Image @ 2500 mm/min, 20% power > M8 > M106 S0 > G0X1.8487 Y0.8204 F0 > ; Layer C01 > M106 S0 > G1X0.041 F98.425 > M106 S20 > G1X0.29 > M106 S0 > G1X0.041 > M106 S0 > > From the docs it looks like M62 would do the job if I can also use the > Sxxx to set the pwm. > > Questions > > - Is it possible to set up the digital pin associated with the M62 to be a > PWM output? > - Is there an example of how to do this? > > Dave > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 > ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Femc-users&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C3238ddc4b6c94263281d08d95e9e9caf%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637644857614191059%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=MjV%2B79wjOL0LMVoS6nL6BNu%2FVTYEUMxf172qiHZOfs4%3D&reserved=0 ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
I saw a lot of references to using the M67 but couldn't see how it would apply as it is for analog outputs. I thought that would be for something like the 0-10 volt spindle control. I was looking at the M62 because I thought a PWM output would be considered a digital pin. Am I looking at it wrong? The laser is PWM between 0 and 5v. Dave On Fri, Aug 13, 2021 at 4:34 PM Todd Zuercher wrote: > You might need to use M67 to set the PWM value and M62 to turn it on/off. > > Todd Zuercher > P. Graham Dunn Inc. > 630 Henry Street > Dalton, Ohio 44618 > Phone: (330)828-2105ext. 2031 > > -Original Message- > From: Dave Matthews > Sent: Friday, August 13, 2021 4:16 PM > To: Enhanced Machine Controller (EMC) > Subject: [Emc-users] M62/M63 with a pwm output possible? > > [EXTERNAL EMAIL] Be sure links are safe. > > I recently started playing with lightburn and want to do photos. Using > M3/M5 Sxxx for laser control works fine for following lines but not for > photos. I think that I want to use M62 along with an Sxxx for laser on and > power setting. The laser power is controlled by PWMing the on/off pin. > > Lightburn likes to use M106 and an S number for laser control. I think it > is coming from M106 being used for fan on a Marlin 3d printer board. > Find/Replace M03 in place of the M106 sort of works but It does a laser > on, move, laser off so there is a lot of overburn. > > Sample gcode from Lightburn: > ; Image @ 2500 mm/min, 20% power > M8 > M106 S0 > G0X1.8487 Y0.8204 F0 > ; Layer C01 > M106 S0 > G1X0.041 F98.425 > M106 S20 > G1X0.29 > M106 S0 > G1X0.041 > M106 S0 > > From the docs it looks like M62 would do the job if I can also use the > Sxxx to set the pwm. > > Questions > > - Is it possible to set up the digital pin associated with the M62 to be a > PWM output? > - Is there an example of how to do this? > > Dave > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > > > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] M62/M63 with a pwm output possible?
You might need to use M67 to set the PWM value and M62 to turn it on/off. Todd Zuercher P. Graham Dunn Inc. 630 Henry Street Dalton, Ohio 44618 Phone: (330)828-2105ext. 2031 -Original Message- From: Dave Matthews Sent: Friday, August 13, 2021 4:16 PM To: Enhanced Machine Controller (EMC) Subject: [Emc-users] M62/M63 with a pwm output possible? [EXTERNAL EMAIL] Be sure links are safe. I recently started playing with lightburn and want to do photos. Using M3/M5 Sxxx for laser control works fine for following lines but not for photos. I think that I want to use M62 along with an Sxxx for laser on and power setting. The laser power is controlled by PWMing the on/off pin. Lightburn likes to use M106 and an S number for laser control. I think it is coming from M106 being used for fan on a Marlin 3d printer board. Find/Replace M03 in place of the M106 sort of works but It does a laser on, move, laser off so there is a lot of overburn. Sample gcode from Lightburn: ; Image @ 2500 mm/min, 20% power M8 M106 S0 G0X1.8487 Y0.8204 F0 ; Layer C01 M106 S0 G1X0.041 F98.425 M106 S20 G1X0.29 M106 S0 G1X0.041 M106 S0 >From the docs it looks like M62 would do the job if I can also use the Sxxx to >set the pwm. Questions - Is it possible to set up the digital pin associated with the M62 to be a PWM output? - Is there an example of how to do this? Dave ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
[Emc-users] M62/M63 with a pwm output possible?
I recently started playing with lightburn and want to do photos. Using M3/M5 Sxxx for laser control works fine for following lines but not for photos. I think that I want to use M62 along with an Sxxx for laser on and power setting. The laser power is controlled by PWMing the on/off pin. Lightburn likes to use M106 and an S number for laser control. I think it is coming from M106 being used for fan on a Marlin 3d printer board. Find/Replace M03 in place of the M106 sort of works but It does a laser on, move, laser off so there is a lot of overburn. Sample gcode from Lightburn: ; Image @ 2500 mm/min, 20% power M8 M106 S0 G0X1.8487 Y0.8204 F0 ; Layer C01 M106 S0 G1X0.041 F98.425 M106 S20 G1X0.29 M106 S0 G1X0.041 M106 S0 >From the docs it looks like M62 would do the job if I can also use the Sxxx to set the pwm. Questions - Is it possible to set up the digital pin associated with the M62 to be a PWM output? - Is there an example of how to do this? Dave ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users