Welcome! Log In Create A New Profile

Advanced

Help with Marlin Laser Alter

Posted by DistortedDesigns 
Help with Marlin Laser Alter
March 24, 2015 12:51PM
Hey all,

I needed some help to make sure I got the coding right on my altered marlin. I am making a 2 watt laser engraver (cnc style). I started a project on openbuilds (Link). I plan on doing full 8-bit laser engraving with pic engrave. Pic engrave uses the output from the Z axis runs it through a DAC to change the signal to analog then to the laser driver to change the intensity of the laser.

I am running everything with a ramps 1.4, A4988 drivers, and the reprap discount controller (red ebay version). I am using the “buildlog-lasercutter-marlin” firmware. The only crappy thing is that it is based on marlin 1.0.0 and has not been updated in 2 years. It is nice because the lcd is setup for laser engraving, and has other laser stuff in the code.

I think I got most everything changed but I don’t know much about code. I found a good post on the shapeko forums on changing the code for dual Y steppers (Link). The only issue was some of the code changes he referred to looked different because he was modifying a later version of marlins. I am not sure if I got all of the changes. I added a write command every time Y was written to I also wrote to E1.

Here is what I need help with

1.) Duplicate Y-axis to E1 (Make sure I got all of the needed changes)

2.) E1 output should be reversed/mirrored from the Y output.
(Question: Instead of writing in a bunch of inverse commands, can’t I just unplug the E1 stepper motor from the ramps rotate 180 degrees and plug it back in?)

3.) Disable Z-axis endstops, and homing. ( I still need the steps output but only for the DAC no homing or endstops needed).

4.) Make sure none of the heatbed / therm settings will interfere with operation.

5.) Homing and limits? I have NC limits on Min and Max for X and Y. I should be able to use the Min – Y and Min – X switches for Homing as well? Do I need to alter anything to make that happen?

I marked all of my changes with a //JM at the end of the line. I have only made changes to Config.h / Marlin.h / Stepper.cpp if I remember correctly.

I attached the whole program because it is a bit unusual with the added laser stuff.

Anything else you can see would be helpful as I know very little.

Thanks Jason
Attachments:
open | download - Marlin_Laser_alter.zip (435.7 KB)
Re: Help with Marlin Laser Alter
March 24, 2015 04:33PM
Here are the altered files. Hopes this makes it easier.
Attachments:
open | download - Config.h.doc (62 KB)
open | download - Marlin.h.doc (34.5 KB)
open | download - Config.h.doc (62 KB)
Re: Help with Marlin Laser Alter
March 25, 2015 08:03AM
Anyone?? I just need someone to look through my code and make sure I got everything. I am a noob and marlins is pretty complicated place to start.
Re: Help with Marlin Laser Alter
March 28, 2015 08:10AM
Ok I really need help. There is something wrong with my code. I am not getting anything on E1.
Re: Help with Marlin Laser Alter
March 30, 2015 12:52PM
I figured out the E1 output duplication issue. I had E0 on two of the fields. Also figured out that you don't have to add INVERT to code so the E1 will run in the correct direction. Just have to plug motor in backwards.

Thanks for the help........
Re: Help with Marlin Laser Alter
April 10, 2015 02:45PM
Did you get it working? I'm trying to do the exact same thing.

I have a Prusa i3 and bought a Chinese 1.6w 455nm blue diode laser and a TTL driver.

I'm trying to figure out what to change in Marlin to run PicLaser.

Have you seen this post at Jtech? Laser with a RAMPS 1.4

PicLaser Lite outputs G-code to use PWM on terminal D9, ie M106 Sxxx, I'm going to try connecting my laser controller TTL input to D9 and give it a try.

Maybe no changes are necessary to Marlin. Have a look at the attached PicLaser gcode file (I had to remove many lines to upload it here), I'll let you know later if it worked on my Prusa i3.
Attachments:
open | download - TestBurn - Copy.gcode (18.2 KB)
Re: Help with Marlin Laser Alter
April 12, 2015 06:30PM
I did get the dual Y working fine via my reprap discount controller but I couldn't get marlin to talk to any kind of software like pronterface or repetier. Sorry I didn't reply I didn't get notification.
Sorry, only registered users may post in this forum.

Click here to login