- Posts: 49
- Thank you received: 0
Laser Control by Spindle PWM
I started with the M67 command but later changed to the M68 command(instant), I am actually trying both to see if there is an appreciable difference.
In the M68 code guild it says:- not synchronized with movement, and they will break blending. ???What is break blending??
Is this a good reason to use the M67 over M68 or would either do??
Yes, I will be editing the Cam Post to accommodate these changes.
Am now working on putting in the DE-bounce coding into the .hal file. have found the entries necessary for this with 3 limit/home switch input pins, eg 10,11+12 the challenge i have is that i only use 1 input for the 3 axis IE pin13. all limit/homes are strung together.
i understand the coding for 3 independent limit/home switches but I'm not even sure it's possible to do this with only 1 pin as the coding seems to be axis specific eg for X axis ...debounce.0.0.out etc . Have tried several variations but no results yet. have you come across this 1 Pin setup with de-bounce before??
Thanks again for the guidance.
Doug
Please Log in to join the conversation.
wl888 wrote: I started with the M67 command but later changed to the M68 command(instant), I am actually trying both to see if there is an appreciable difference.
In the M68 code guild it says:- not synchronized with movement, and they will break blending. ???What is break blending??
Movement will be smooth through an M67 command, but the change of the HAL pin value won't happen until the move starts.
If you use M68 at the beginning then they may be a burned spot at the start of the path as the laser turns on before the axis starts to move.
If you use an M67 at the end without a following move then there probably will be a burned spot at the end, because the laser won't turn off.
So, ideally you would use M67 except for the final laser-off command which should be M68.
Please Log in to join the conversation.
Any thoughts on the 2nd part . IE:
Am now working on putting in the DE-bounce coding into the .hal file. have found the entries necessary for this with 3 limit/home switch input pins, eg 10,11+12 the challenge i have is that i only use 1 input for the 3 axis IE pin13. all limit/homes are strung together.
i understand the coding for 3 independent limit/home switches but I'm not even sure it's possible to do this with only 1 pin as the coding seems to be axis specific eg for X axis ...debounce.0.0.out etc . Have tried several variations but no results yet. have you come across this 1 Pin setup with de-bounce before??
It may be that I have to use 3 independent limit/home pins instead of just the one.
Thanks again
Doug
Please Log in to join the conversation.
wl888 wrote: Am now working on putting in the DE-bounce coding into the .hal file. have found the entries necessary for this with 3 limit/home switch input pins, eg 10,11+12 the challenge i have is that i only use 1 input for the 3 axis
In that case just use one single-channel debounce.
(you could drive the input of three debounce channels from the same input pin, but that seems like a waste of CPU)
Please Log in to join the conversation.
will be away with work for a couple of days , will implement when i get back.
Thanks Doug
Please Log in to join the conversation.
I would like to adjust diode laser power with M67 too - but as it is called analog output do I need additional hardware like a DAC? Or is there an easier way to get PWM out of a parallel port pin without slowing the step planner?
EDIT: Ah, it is hal slang isn't it? I am supposed to net the analog output to a pwmgen and then that to an actual physical parallel output pin right? Any examples where something similar is done?
Am I on the right track with something like this in custom.hal?
Please Log in to join the conversation.
You HAL looks right, from a cursory glance.
Please Log in to join the conversation.
I have tried it now and it seems to work great. By omitting the frequency and scaling I get
Attachment not found
from M67 E0 Q0.5
Please Log in to join the conversation.
