Arduino Pin | Active level | |
---|---|---|
2 | hi | X step |
3 | hi | Y step |
5 | hi+ | X direction |
6 | hi+ | Y direction |
8 | lo | stepper enable |
12 | x wire relay as needed | cutter enable
D12 was active lo on default grbl build. e.g. default state hi, which is relay TRIGGERED. Problem is that an unpowered or uninitialized arduino would return relay to "normal" state, and fire the plasma. M3 or M4 would put the relay in "normal" state, hence fire the plasma. M5 would put the relay in "triggered" state, and turn the plasma off. Normal use is that M3 is spindle enabled forward, M4 is spindle reverse (i think), M5 is definately spindle off. I changed an INVERT_SPINDLE... setting in config.h. This has allowed me
to connect the plasma to "Normally Open" position, and the plasma now seems to remain
off unless M3 or M4 is issued.
|
settings expected to be altered/calibrated:
$0=10 | Step pulse microseconds | |
---|---|---|
$100 $101 | [X,Y] steps/mm | nominally about 63 at 400 steps/turn setting on controllers. (half stepping?) If the screws are 1/4" per turn, 400 steps/turn == 62.992 steps/mm. By measurement, X seemed a bit different at 63.45. Need to tripple check this measurement. |
$110 $111 | [X,Y] Max rate mm/min | Not sure how to test. seems like at least 5000-6000. I would guess that Y will be a little slower as long as it is underpowered with the 20v 5A supply. Might go faster with a 36-40v 10A supply |
$120 $121 | [X,Y] Acceleration mm/sec^2 | not sure how to test. I would guess that these should be able to get up to full speed in around 0.5 seconds. Hence, a good guess would be max rate * .2 to .6 or so. |
M3 (Turn plasma on) G4 P0.3123 (pierce time)Again, oddly specific to make it easier to search-and-replace in gcode if my guess is bad.
M5 (plasma off) G4 P0.2398 (time to complete cut)Try to keep this different from pierce time to facilitate search-and-replace incase it needs to be changed.
M5 (make sure plasma is off) G21 (positions in mm) G90 (absolute position mode) G92 X0 Y0 (set current position to 0,0. our plasma has no home) S1200 (arbitrary high spindle rate. make sure M3 or M4 activate pin 12 to trigger plasma relay on)This assumes your drawing has 0,0 at the LLC. You may want to alter the G92 command if this is not the case.
M5 (make sure plasma off) G0 X0 Y0 (return to origin)These are both optional. The plasma should be off after the last cut, but the extra M5 makes sure. It is often convenient to return to where you started when done, ready for the next cut.