Luban adding weird moves to cnc

after generating toolpaths and importing svg file luban displaysmy toolpaths that at first look good but closer inspection finds weird begining toolpaths.

; G-code for laser engraving
; Generated by Snapmaker Luban
; G-code START <<<
G90
G21
G0 Z10.00 F1500
G0 X-31.46 Y-12.06
G0 Z5.00
M3 P100
G1 Z-0.18 F100
G1 X-17.57 Y-7.67 F300
G0 Z5.00
G1 Z-0.18 F100
G1 X-12.57 Y-7.67 F300
G0 Z5.00
G0 X16.95 Y-7.21
G1 Z-0.18 F100
G1 X17.97 Y-7.13 F300
G0 Z5.00
G0 X-3.04 Y-7.21
G1 Z-0.18 F100
G1 X-4.98 Y-7.13 F300

it goes on like that for 50 more lines then starts what toolpaths i really wanted generated:

G0 Z5.00
G0 X-27.74 Y7.92
G1 Z-0.18 F100
G1 X-27.51 Y7.92 F300
G1 X-27.47 Y7.92
G1 X-27.43 Y7.91
G1 X-27.39 Y7.90
G1 X-27.36 Y7.88
G1 X-27.32 Y7.87
G1 X-27.29 Y7.84
G1 X-27.26 Y7.82
G1 X-27.23 Y7.79
G1 X-27.21 Y7.76
G1 X-27.18 Y7.73
G1 X-27.17 Y7.69
G1 X-27.15 Y7.66
G1 X-27.14 Y7.62
G1 X-27.13 Y7.58
G1 X-27.13 Y7.54
G1 X-27.13 Y7.34
G1 X-24.52 Y7.34
G1 X-24.50 Y7.37
G1 X-24.43 Y7.44
G1 X-24.33 Y7.53
G1 X-24.23 Y7.60
G1 X-24.14 Y7.66
G1 X-24.11 Y7.68
G1 X-24.01 Y7.72
G1 X-23.91 Y7.76
G1 X-23.87 Y7.77
G1 X-23.79 Y7.79
G1 X-23.77 Y7.80
G1 X-23.73 Y7.80
G1 X-23.77 Y7.81
G1 X-23.79 Y7.81
G1 X-23.87 Y7.83
G1 X-23.91 Y7.84
G1 X-24.01 Y7.88
G1 X-24.11 Y7.93
G1 X-24.14 Y7.95
G1 X-24.23 Y8.00
G1 X-24.33 Y8.08
G1 X-24.43 Y8.16
G1 X-24.50 Y8.24
G1 X-24.52 Y8.27
G1 X-27.39 Y8.27
G1 X-27.44 Y8.19
G1 X-27.54 Y8.09
G1 X-27.64 Y8.00
G1 X-27.74 Y7.92
G0 Z5.00
G0 X28.52 Y7.80
G1 Z-0.18 F100

thats just a small part of the code and its only the begining that it does the weird stuff. this happens every time on every project except its different weird stuff each time.

i am trying to do isolation routing on pcbs and them first lines are a pain to go in and figure out and edit them to be correct. i use fritzing to design pcb and i have tried exporting in svg into luban and have the problem and i have tried exporting gerber files to flatcam and the exporting svg from flatcam but have same results. any ideas?

Luban isn’t a very good CAM application, so it’s unsurprising that you’re seeing some weirdness. Fusion 360 is the most commonly suggested replacement for Luban in generating gcode for CNC.

fusion 360 for pcb isolation routing? i dont really know fusion that well so i cant really say how well it would routing pcbs. what extension does fusion use? i feel very mislead with the way this machine dont support the run of the mill .nc file extension. fusion 360 you have to log into which means my data is not private and is used in who knows what ways.i dont use facebook for the same reasons. i hope someone has a real solution to my question. i thank you for letting me know one work around and hopefully someone might have another option that i can use that wont require me giving up my privacy rights.

Fusion uses EAGLE for PCB, I think.

i think your right because i have read that somewhere i am pretty sure. my issue with that is fusion 360 is a company that uses the same business model as meta [facebook]. i find it odd that with all the kickstarter funding snapmaker has gotten you would think snapmaker would have put a little effort towards the software they provide with their product. the machine is really awesome and i was so happy when it arrived and as i was putting it together i kept thinking this machine is 1000x better than the $150 cnc router that i had. then i go to use it to find the software is worthless (it wont even fit on my screen right and to click the lower buttons i have to change my display settings and no other program i have does that). its like i bought a brand new lamborgina for alot of money and when i step on the gas pedal it barly goes 10 mph because under the hood is a 5 hp lawn mower motor. they charge $60 for a button to stop the machine! when that should have been a part of the machine for safety reasons. they are making alot of money and yet the software is bad and they want you to go get software thats free and use that. riding on other peoples coattails and not programming the software and making it useless really makes me feel i got tricked out of my money. i make minimum wage and it took a long time to save that much money and the solution is use software that wasnt built specifically for that machine really is sad. sorry i am frustrated. now ill probablly get banned for this post

Did you actually run the CNC and see the output? Does the SVG source file look right? I can’t say that I’ve ever had Luban generate anything odd that wasn’t in the SVG file or user error.

You can use ncviewer.com to check your gcode.

Because it’s a 3 in 1 they’ve set it up so it uses 3 different file extensions: .gcode for 3D, .nc for laser and .cnc for cnc.
If you’re using a CAM program like Easel, or Carbide Create, or Fusion 360, you just have to change the file type to .cnc.

-S

It’s actually far more like you were buying a Pontiac but thought you were buying a Cadillac. SM has lots of gloss, far less function than it would have you believe. Now you know.

Only other software I can think of that might be useful is FlatCAM, and I have no idea whether its gcode output is compatible with Snapmaker or not (I’ve never tried). It’s open source, though, so there’s unlikely to be any tracking code.

that is what the file looked like after using luban using a .svg. let me know if you dont see the lines i am talking about.

i understand all that but luban is generating tool moves that i dont know what they are or why they are there.

flatcam is my go to program. it imports into luban and luban adds toolpaths and i dont know why or where they come from.

all the g code i have seen over the last 20 years (ran cnc machines for years ) had a .nc extension. what extension is the 3d module use for its g code? do you mean the extension is.gcode?

also i had to take the c off to view file in camtronics. when looking at the code there are a bunch of garbage lines at the beginning thats several hundred lines for a header then it says its for the laser module and then starts the code that starts off with the lines that came from no where. it almost looks like those lines are what the toolpath is when moving above z and it somehow is making those lines tool paths?

As I said before, because of this being a 3 in 1 machine it needs 3 different file types. So for cnc it’s .cnc, laser is .nc and 3d printing is .gcode.

Can you share your original artwork? The lines I think you’re referring to are just moves. It should be lifting up and moving to the next point. Luban isn’t very smart about moves or paths.

-S

That’s my thought as well (just moves, not cuts). Luban is NOT very smart when it comes to optimized paths. That’s why I asked previously if the OP actually RAN the file. Just looking at lines on a screen is useless.

Any time you’re running a cnc path that you’re not sure of what it’s going to do, just set the z origin well above the workspace and any fixtures. Then it will just run in the air and you can watch and see what it’s doing. Also keep your hand on the power switch (or emergency stop) whenever starting something you’re unsure of.

-S

What happens if you generate gcode from FlatCAM (or other program of your choice) and then import the gcode into Luban (change the file extension first if you need to)? Can it parse the movements and display what looks like a sane representation? If so, you can just use Luban as a dumb transfer program for FlatCAM’s output. But I’d guess that the other posters are correct and it’s just adding silly unoptimized travel moves.