Ok. Spent the day yesterday trying to wrap my head around this servo control issue between LB and OpenBuilds BlackBox (BB). LB broke 2 servos (good ones - metal geared) before I finally figured out the cause. Understand I’m speaking from only a cursory knowledge of the workings of Grbl and gcode.
I have no problem with the sync and the range of servo movement when using OpenBuilds CAM to generate the gcode. That’s bc BB issues a string of Grbl commands immediately upon serial connection to the BB. Openbuilds Control settings.txt (2.8 KB) Among these settings is $30=255, $31=0. The max/min spindle range. Apparently OpenBuild (OB) uses these parameter boundaries, in combination with a servo wizard tool, to help the user find the optimum hi and low servo values numbers to use. For the case of my custom pen holder the values are S201=up and S153=down. For the case of LB however, I don’t have the benefit of these settings so irrespective of misplacing the M3s as i did, the servo moves to the extremes at times during the plot, and out of sync, and thus breaking it. (2 of them).
So my questions are - do I have this right? If so, what among the Grbl settings you see do i need to implement and how do I do it? Your LB Grbl 1.1e device dialog offers “Edit” but that feature is mostly limited to a fixed set of values to pick from. Important to note, like BB the servo must be protected against traveling beyond the designated up/down values at all times. Not just when a gcode script is loaded. The servo can easily break if mishandled.
As for the workaround for inserting M3s in the LB generated gcode script, I obviously did not get it right by simply replacing the M3 and M5 “placeholders” generated in the LB script with M3 S201 and M3 S153 servo values when you exam the before and after changes I made in the txt files included here.LB first test before.txt (438 Bytes) LB first test after.txt (481 Bytes). Where did I go wrong? In the real application there will be hundreds if not a thousand or more open ended vectors, each requiring the proper servo command before and after. This can only be done via find-and-replace in a proper text editor with “zero” margin for error. As such, can you pls edit the “before” version to show me how it should be done?
As for the added “pause” value you noted, thx for pointed that out. That is a must now that I think about it. It takes a finite amount of time for the pen holder to change its mechanical position so that must be included in the “find-and-replace” method I envision - unless of course you can suggest a better way to implement it. BTW - that pause statement is inserted by OB’s CAM software, not at the BB control level. There is a “dwell” parameter I was not aware of in CAM that inserts this value in the gcode whenever the user selects “pen plotter” as the gcode tool in CAM.
Finally, it has been suggested the laser “power” be adjusted to “60%” in the gcode, which equates to S201. I do not own or operate a laser so sorry I have no idea what you are talking about, in words or the line of gcode you offered. Can you be move specific and/or offer an example with explanation?
Finally, on a similar note, I have read in the forum something about using LB’s laser Z axis layer to signal a servo value change for those with a desire to use LB for pen plotting. Would that be a better way to go than to repurpose the Grbl spindle parameter method - in the context of LB software?
Thx