Yet another laser/camera confusion thread

I’ve read through all the threads I could find on using the camera with the laser module, but I’m still lost as to how to make it useful.

I’ve seen that people say if you send the job to the machine, the work origin gets changed. So I tried hooking the computer directly to the machine, but when I did that it disabled the camera entirely.

I then just connected via wifi, but did not send the job to the machine. I got the picture I wanted to engrave lined up with a test border I’d previously burned on the cardboard I’m using to test with. But when I run the boundary from within Luban, the toolhead moves to the opposite quadrant from the border.

This makes no sense to me - Luban should be completely aware of the Snapmaker’s bed coordinates, and so if I place a picture on a given part of the bed in Luban, this should reflect exactly to what the toolhead does, but that isn’t happening.

To compound the problem, a lot of the advice, as well as the laser/camera tutorial video, is for previous versions of Luban - the video, for instance, shows options that are either not present in my version or have been moved elsewhere.

What I’m looking for is advice for using the camera to properly orient a job on a 2.0 A350T with the latest firmware and version of Luban. Any help available?

Thanks all.

The trick is to set the work origin properly. Yes luban should just be able to generate gcode that the machine understands, but that doesn’t seem to be the case. Instead, you must think of how your work is oriented vs the work origin in luban, and then make sure you move the toolhead to that point in the bed and use the “set work origin” on the touchscreen to set the origin.

I eventually figured it out, not sure if you’ve seen my post, but I tried to go into super n00b detail (since I’m still a n00b in laser): How to: Laser cutting with camera capture

Also, once you get a single good run from luban, it might be worth considering lightburn. I spent a day or so learning the quirks of lightburn, and it was much easier than dealing with the quirks of luban.

Thanks for the reply, I really appreciate it.

Yeah, I saw that post, but since I’m trying to engrave rather than cut, I assume I’d have the height issues that others mentioned, especially if I’m trying to, say, print something on top of a box. Still, I’ll try to adapt it to what I’m doing.

I did use that method in experimenting with 2.5mm thick cardboard and it worked really well, though there’s one area I’m unclear on why it worked – you said to move the toolhead to the center of the bed (x160y175), but those coordinates have it distinctly off center especially in the X axis. It still worked in that the engraving showed up where it was supposed to, but I’m wondering why that’s considered bed-center?

I’ve been messing with Lightburn too, but that’s also slow going for similar reasons. I set up a USB camera in the enclosure and tried to do the calibration procedure, but I haven’t yet been able to even properly set the origin in Lightburn either - when I run the calibration, then trace the frame before the burn, the toolhead goes very far away from where it should, usually extending out past the edge of the bed. I’m sure there’s something I’m doing wrong there, but haven’t figured out what yet.

The workable space is 320x by 350y, so 160x175y is the center. The actual bed is a bit larger, but as far as the machine is concerned, that space doesn’t exist.

For lightburn, try using “print and cut”, it’ll work much more easily than trying to line up/calibrate a camera (lenses are hard math).

Yeah, I should have been more clear - I get why the coordinates are correct. What I don’t get is why those coordinates aren’t where the laser head goes.Here’s what I mean:

you can see that the laser is jogged off to the left of the actual board center.

How much is it off, its hard to see from that angle?

It’s just slightly to the right of the line between the first and second sections of the 4 laser bed plates.

That is a long way from centre. Have you power cycled/homed the machine again?

Yea, that’s not 160/175 despite what your machine thinks :stuck_out_tongue:. I agree it must be that you haven’t homed? I can’t imagine any reason why it would go there when asked to go to 160/175.

I assume by power cycle/homed you mean I turned it off, back on, then went into calibration where it says it first needs to move to the home position?

If so then yeah, I’ve done that. And it does go where you’d expect for the home position. But then when I manually move the head to the center coordinates, it still ends up off center. When I move the head to fairly close to the actual center of the bed, the displayed coordinates are x222, y175…

Did you perhaps flip your x/y plugs? 0,0 should be the “front left” (bed all the way back, head all the way to the side away from the camera in your shot)

I think we might be getting closer to understanding what’s going on here. Depending on what you mean by “all the way back,” I think it’s homing to the right location:

If that’s the right location, then it’s homing correctly, but if I understand how homing works, it’s not then properly updating the home coordinates. After it homes, the controller lists the machine coordinates as X40, Y347, Z334. That X40 coordinate particularly seems weird as I’d think it should either be 0 or something near 320, right? 40 doesn’t make sense to me.

Yea, mine actually reports X-19 when homed. Home position is actually what I’d call “all the way forward” so it sounds like your X is thinking it’s at a different position.

Did you perhaps mess with sending G92 at some point? I can’t think of any other reason why your X axis would be so off…

Also, I’ve got my 3dp head plugged in, so it might be that on the laser it sets x0 as whatever the last origin you used is, perhaps try plugging in the 3dp head and see if the machine still doesn’t know where x0 is (it should be exactly at the side of the bed on the side it parks during homing)