Another Octoprint plugin: line tracer

And there goes Ryan’s bandwidth for the day. :slight_smile:

4 Likes

Well, if the camera were mounted on LR2 (which should be simple enough) then I think it could do exactly what you are describing, since that machine can do full 4x8 sheets. I’m interested, what are you seeing as the shortcoming?

It might be a bit overkill for big rectangles though, and it’s more intended for organic shapes that are a headache to get into CAD/CAM.

3 Likes

When I’m doing construction, overkill is trying to hire and train a helper who can accurately measure and cut a piece of sheetrock with more than 1 outlet. If I can sharpie up a complex set of cutouts and throw it on a machine to CNC for me and let it do the work, I will know I have a good fit when it is done.

I wanted to point out that I had read the article and recognize the program as written is for closed blobs. Multiple sharpie lines either closed, or open to the edge on a 4x8 sheet is a different modeling problem. However, I really like the principle of surface line - openCV - CNC toolpath because ov the accessability of a pen and the common need for better cutting.

3 Likes

Ah, got it. Thanks!

2 Likes

Upping the plan now!

Who knew you made a different kind of digital apprentice! Pair that with a fairly portable full sheet CNC and boom, one guy can do the work of two.

1 Like

It looks like this project already includes openCV for calibration of a maslow: github - WebControlCNC

Perhaps this would be an easy-ish integration. I’ll have to dig in a little.

1 Like

I think @madgrizzle is involved with the Maslow web control. I thought it was more about keeping tabs on which part of the sheet you’ve already used. But I haven’t tried it myself.

1 Like

You won’t get much out of webcontrol’s optical calibration. What @jamiek has done is way more advanced (and so frickin cool). What I was trying to do was to just move the Maslow’s sled directly on top of a regular array of squares printed on a 4x8 sheet of vinyl. I didn’t use aruco markers but it might have made things a bit easier if I had. What I was trying to do was basically to create the equivalent of mesh bed-levelling (to better account for chain length calculation issues).

Oh, and webcontrol is pretty much abandon-ware are this point since I moved on to a lowrider. No one wanted to take over the project.

3 Likes

I think for your application, being able to take a photograph of the entire sheet with a decently high res camera and then feed that into a processor to generate gcode would work best. Otherwise, you are moving a camera all over the sheet just to find where there are lines to be drawn and that would be painfully slow. Since you don’t need extreme accuracy, it might work ok.

2 Likes

I was thinking something like this too. Perhaps a dual-camera setup can cover the entire area with a smaller number of shots from a wide-field camera and precise locations with another narrow-field camera. There could be additional tags for poly-lines or common features like outlet panels.

And a wide-field camera would also make multiple contours possible. With only a narrow field of view, performing a search is not really feasible, but with wider coverage, you would just need multiple tags to indicate multiple contours.

1 Like

Yes, I think that would work as long as you aren’t overly concerned about accuracy… and since its for hand sketches, you probably aren’t. You may get by with a stationary camera with a fish-eye lens mounted above everything and then just perform a mesh warp on it to “straighten” it out. If you include some markers in the corner of your frame, you could put the camera on a swing arm if you want so it’s not always there. Calibrating the camera to do that mesh warp would probably be the trickiest part, but even that is not so tricky.

A side benefit is that you can use an RPI connected to the camera and run a fire/smoke detection neural network that controls an extinguisher, a shutdown switch, and a siren. Fun times!

1 Like

With all that processing, the pi itself is the fire danger!

1 Like

From a fellow Maslowian, I can say there are a few that are still tinkering with it, and it is still being published on the Maslow forums as the “go to” for use. The basic interface works great and there are not a lot of issues with it, so (IMHO) there hasn’t been a huge need to constantly update it. I do want to thank you for your efforts in getting it put together. I still use it on my rig. On another note, EastBaySource has also picked up GroundControl and are providing updates for that.

4 Likes

I’m a webconrol fan… and still working on it, just not owning it.

2 Likes

You might want to consider going the other direction as well and bring the machine to the workpiece. I could see a bunch of uses for this if you had a portable primo with no spoil board that could make cuts on in place pieces or on the jobsite.

The ideal platform would be the Origin Shaper, imagine hand drawing your path and being able to hand route it accurately. I bet those guys would love something like this.

1 Like

There are some laser engravers that have a removable floor for doing things like engraving on a table top. You could build the megapixel image with this, and then lay out an svg or DXF where you wanted it, and then create the matching gcode. You would have to leave the motors enabled while doing the alignment though, or else have a precise dual endstop setup.

Definitely a lot of possibilities.

Just swinging in here… I do have a Shaper Origin CNC router in my workshop. It can be used on any size workspace you want and “scan” your piece before placing designs and stuff. There is a (big or little) endian encoded tape applied to the workpiece and then you just move the machine around to have it have a look at all parts you want to be your workpiece later. They have also heavily expanded the on-tool CAD capabilities. After the scan you have a visual approximate representation of your workpiece on-tool, also with any markings you might have applied by hand beforehand. Maybe this could offer some inspiration into further progress of your super awesome project.

There is also an on-tool grid function that allows to touch on 2 x and 1 y edge and drop a grid onto the workpiece which is then used to really precisely position designs (it eats SVG).

(you dont need to watch all of it, but maybe the section around minute 9 is interesting for you, at minute 13+ they cut a shape that he has sharpie’d onto the plate minutes earlier… amazing)

In the shaper forums there is also this thread (in german, sorry) of mine and others using an online shapertape generator (written in python) to produce meter-lengths of the tape.

For most of what I use it in quick and dirty mode, this is pretty much what I do: I place a printout of a technical drawing (sometimes i just rip it out of the manual) at correct scale on my workpiece, include it in the scan and use on-tool shapes (circels and rectangles and point-to-point curves) to approximate it. And then I cut. It’s not hyper exact but you can drop in a SVG file any time if you need more accuracy than hand-drawing. So it’s already nearly there :slight_smile:

I bring the tool to the workpiece all the time, since most of my customers are event-based and up until the last minute they do not know where they want their logo, text, cutout etc and I can build the counter beforehand, leave the tape on (so I can return to the previous state), position design on-premise and cut. Remove tape, done.

It’s several orders of magnitude above my level of expertise but I’m looking at your plugin in awe and admiration. I don’t know if you can make anything of my input, but if you have any questions on how getting visuals into the machine works with Shaper Origin, I can probably advise :slight_smile:

Keep it up, it is amazing :slight_smile:

1 Like

That’s pretty cool, and the Shaper Origin was (indirectly) an inspiration for this, in that it connects the physical cut to the abstract CAD by way of the workpiece, instead of by way of the fixturing and machine coordinates, which is the traditional CNC method. (Touching off the workpiece and using G92 without homing is somewhere in between.) Operating off the workpiece gives it a more intuitive feel for the human, while giving the computer more work to do.

In my mind the Shaper Origin performs the ‘inverse’ operation from the plugin, very loosely speaking. Given a CAD model, and where the CAD model is not registered to the workpiece, perform the registration and then make the cut. The plugin is for the situation where you have registration but you don’t have a CAD model, to then build the CAD model from the lines on the workpiece.

In principle it should be possible for the Shaper Origin to do the same thing, where it cuts out a shape that it has traced. For example, if I have an irregularly shaped plate that I want to copy, I could lay it down on my workpiece and trace around it with a pen. I could cut it with a jigsaw following the line by eye, but can the Shaper Origin extract the perimeter and then cut it? That would be cool. I don’t see any reason why it couldn’t, I’m just not aware whether it has that capability or not. Maybe you can suggest it to them, if it’s not already in their roadmap.

1 Like

There are a LOT and very heated discussions on this in the forums, mostly it ends with: the cost (computational, hardware, etc.) of doing it VERY precise is higher than drawing it up in CAD. It is absolutely possible to do this by hand already and I wish that they would finally update the tool with the possibility to somewhat automate this. Example: When I do foam cut outs for my barista tools and espresso machine accessories I install into the roadcases of our machines, I place the parts on a piece of paper glued to some foamboard, scan the workpiece with shapertape applied, then remove the parts and trace the cutline point to point with the shaper (on tool, kinda like drawing a bezier curve) and cut away. Already fantastic and saves a lot of time. Of course it would be awesome to automate that, but all the more reason to finally finish my MPCNC and use your plugin for this <3

1 Like

If your competition is a jigsaw, it should be no contest at all. But I can understand it’s hard to let go of the precision mindset.

I assume the software is totally closed, so an outsider can’t hack in the feature. Unless you built a robot that sat on the tool and observed and manipulated the touchscreen to draw the beziers for you. Now that would be something.