Papercraft and Pepakura

Funny, I posted an idea about this over in the Ask Glowforge area as a response to tracing options:

2 Likes

The trouble is scanning and identifying the cut lines is extremely hard to do, there are probably programs already out there to do it but if the paper model is black and the cut lines are black most things are going to struggle.
It’s much easier to tell the machine what the registration mark looks like and where the cut lines are, not to mention it’ll be significantly faster and you already have that data calculated anyway.

@m_raynsford: I posted your blog to our internal “project inspiration” channel and boy, did it get a lot of love from the team at Glowforge. (Good to see you on the board btw; really enjoyed our conversations at Maker Faire!)

@fablab_elpaso: We already do fiducial detection, so it’s definitely workable. Fun fact: the Glowforge logo on the head isn’t just decorative. The camera sees it and uses it to align the head with the lid image. You wouldn’t believe the custom lens needed to focus 20x12 from 6" away, and also stay in focus 1" away…

4 Likes

If the model is black, and the cutlines are black, then I’m guessing a person would have nearly as much difficulty figuring it out too – detection would only streamline what already takes eyeballing.

If you happened to have a file that already included separate layers for graphics (appearance) and cutlines (form), then would make sense to just go ahead and print a registration mark ahead of time; but a lot of the files to be found on the net are flat PDFs without cutline information, so etching a registration mark would be a convenience bonus if a multi-page “scan > cutline markup > cut” workflow were done.

So the lid camera used for homing too. Does the 1" focal length enable any other functionality?

I ask because it sounds like the custom lens might have been expensive (in cost, time, or both) and I am hoping it isn’t just for homing when it seems like a traditional approach (limit switches, I guess) would have been both simple and cheap.

The lid camera is used for scanning, positioning, homing, and many other tricks we’re still working on.

1 Like

I was trying to ask specifically about the (difficult to obtain) 1" focal length capability.

Interesting.

The projects I’ve worked on where there is a camera as part of an embedded system you need a custom lens - there is no way around it. Unless you happen to have an engineer with a lot of lens design experience you contract it out. The additional cost of a somewhat more complex lens is relatively trivial compared to the minimum NRE of a custom lens. And the time of course is not borne by your engineers so it really isn’t relevant. We were always able to have our lenses molded (as opposed to ground glass), so the per lens cost was pretty small. Considering the cameras are key to what they want to do now and in the future it would seem a wise investment.

I can’t comment on what they paid, but if I remember correctly, the last lens we did cost $15k in NRE, plus a mold of 5-10k and a dollar or two for each production lens. You may also need a second mold for a lens holder, but while the mold will be roughly the same amount, the cost of the part should be cheap and the engineering not that much. Double those numbers, divide by 10,000 glowforges and it’s $5-10 per unit and they’re probably well past the 10,000 unit mark.

2 Likes

Thanks for the detailed response!

If it’s basically a wash, I don’t understand why Dan said it was difficult.

Using a camera with a custom lens attached to the center of a hinged door only to be forced to write machine-vision software to visually “watch” for a logo which might get scratched or covered in soot or dust on the top of the laser head only to avoid using the tried and true practice of using limit switches seems like an odd choice to me, especially if there is no other reason for the camera to need to focus on objects 1" away.

My Nexus 6 doesn’t have the best camera in the world, but at 6" its field of view is 7", the Glowforge lens needs to be nearly three times wider. The closest it can focus is about 2.5", the Glowforge needs to be about 2.5 times better. Obviously, the Glowforge camera doesn’t have to fit inside a cell phone case, but it seems like it might have been a bit of a challenge to satisfy either of these criteria by themselves, much less both with the same optics. … and JUST to avoid limit switches?

When engineers speak of difficult they can often times mean, “that was a challenge, but we overcame it and we’re feeling great about it.” That is how I took it.

Generally, I consider avoiding switches a good thing. They’re mechanical, their contacts degrade and wear out, if you’re counting on them for some sort of precision application you have to make sure the mechanical housing cannot somehow leave alignment and their throw length can’t change over time. Not only does a dirty glowforge logo only need a quick wipe to fix, but you can detect the error condition and inform the user to take action.

When designing a new system you make a lot of choices for a lot of varied reasons. Different teams come to different conclusions. My personal biases are pretty much running with their choices, but I can understand where others might have gone a different route.

2 Likes

Watch out for them worn out limit switches! A couple million clicks after they’re new and BAM! you gotta spend another $4 on a new one. Why, they’re only going to last 5000 years at that rate.

This begs the question: do cameras work forever?

Limit switches do not have to be mechanical. They do have solid states ones i.e. inductive sensors. Which I use on all my CNC’s. They tend to be more accurate than the mechanical ones (over time) and extremely repeatable.

2 Likes

I know that there are photographers on one of my flickr groups still using cameras manufactured as far back as the 1890s (1896 Rochester Empire 8X10, 1898 Western Cyclone No. 5 ) and many of the kodak brownies have survived, even though they are made essentially of cardboard. There are certainly a decent number of 100+ year-old cameras that still work.
Also, there are 12 beautiful Hasselblad cameras just sitting up there on the moon for the taking. Doesn’t get too wet up there, they probably still work just fine!
My oldest digital camera still takes pictures, actually. a whopping 1.3 megs. Viewfinder is shot and they don’t make the battery anymore, and it takes a second or two from when you press the shutter button to when the thing actually fires, but… works!

I don’t have any CNC machines but I am trying to learn as much as I can, especially trying to understand how the Glowforge will function out of the box. You refer to limit switches. As I understand it, they ensure that the business end of the tool doesn’t go too far in any one axis. Makes sense. But then there is the whole homing function routine to establish 0,0,0, or however you designate the coordinate. It seems to me that the two cameras eliminate the need to have six homing switches (again, just assuming as I don’t have any practical experience in CNC design.). The cameras also allow you to establish a starting point wherever the beam is in relation to whatever is in the tray set to be engraved or cut.

1 Like

It does seem like the camera feature set would enable it to be aware of where the machine parameters live, with maybe mechanical limiting as a redundant safety.
Switches that aren’t, or are rarely used would have an indefinite service life.

Your assumptions are correct regarding how the limit switches work on a typical “CNC machine” (like a CNC router or a CNC mill). To confirm what you said, the switches will typically be placed in a way that they are activated (“switched”) if the machine attempts to move too far.

OK, there are a lot of ins and outs with this. I’m going to try to give the basics for clarity, but I’m also going to skip some detail for brevity.

The following block of text is only about lost steps, if you know what they are already, skip to the stuff after the line…



The reason a machine like a CNC router may “attempt to move too far” is because of something called “lost steps”. Lost steps happen when the machine controller commands the machine to move somewhere it is physically unable to and are a potential problem for (virtually) any machine that uses stepper motors (like I am assuming is the case for the Glowforge).

Lost steps a big problem for CNC routers as the force required to perform a cut can vary wildly. As you can imagine, a 1/8"-deep cut is going to be considerably easier on the machine than a 2"-deep cut. Similarly, a 1/2"-deep cut made at 5 inches per minute is going to be considerably easier than a 1/2"-deep cut made at 50 IPM. And, of course, cutting through foam is going to be considerably easier than cutting through steel. This variability in difficulty may lead the (human) operator of the machine to try to exceed the capabilities of the machine. If the operator does this, one of two things are likely to happen: the bit will break or the machine will stall. If the bit breaks, the machine will have no way of knowing and will continue its job as if everything is fine. When it stalls is when you get lost steps. Unfortunately, a stepper-driven machine will also have no way of knowing it lost steps, so it will continue along as if everything is fine. Machines are dumb like that. The problem is: although the machine doesn’t know it, after losing steps, the cutting head is physically in a different place than it thinks.

Imagine someone starts a router at the “bottom-left” of the table and attempts to make a diagonal cut to the opposite corner. Now imagine the machine isn’t strong enough to make this cut and ends up stalling. If this happens, the machine will continue to try to move to the opposite corner for as long as it normally would have taken if it was successfully cutting, but since it’s stalled-out, the head isn’t moving away from the bottom-left corner. When it thinks it’s done it thinks the head is at the top-right corner. If, then, it is told to go back to the bottom-left it’ll attempt to move the head farther “down” and farther left than it should. If you don’t have limit switches to stop the machine, it’ll plow into the “physical limits” of the machine. This collision can damage the machine and cause parts to become misaligned.



OK, sorry for the long description of lost steps! I hope that, if it didn’t give you any new information, @marmak3261, it is informative to anyone else who may be curious!

Fortunately, the Glowforge won’t really have to worry about lost steps. This is because the only resistance to movement it will typically experience is the friction between the linear rails and the rotation of the belts. This lack of variability means that motors with the “perfect” amount of power can be chosen, which keeps costs down and can also lead to better performance (generally speaking, fast motors aren’t strong and strong motors aren’t fast).

Since lost steps aren’t really a concern for a laser cutter, the machine can use a concept called “soft limits”. In a nutshell, soft limits basically dictate that a machine with 20" of X travel and 12" of Y travel will never attempt to move to the coordinates X21 Y13. Of course, it will also never attempt to move to X20.001 Y12.001.

Since it can use soft limits, it really only needs limit switches when the machine is homed, which is when it establishes where 0, 0, 0 (XYZ) is. So, instead of six switches, a machine like this will only need three. And those three switches aren’t likely to see a lot of use. I suspect you’ll only need to home a machine like this once per power cycle (and even that may not be all that necessary) and any time you move the head by hand, either accidentally or on purpose.

A quick eBay search found some $4 limit switches that claimed they could be clicked 30 MILLION times. So, if you homed your machine 10 times every single day for the next 80 centuries you might have to start worrying about wearing out your switches. These $4 switches might not be the IDEAL switch… There are also 40¢ switches, $40 switches, and , I’m sure, $400 switches. There exists, somewhere, an ideal limit switch.

Actually, with clever design and programming, it would probably be possible to only have a single switch, and just make sure only one axis is capable of “clicking” it at a time. I’d say taking the time to make that clever design and program is not worth the minuscule savings of eliminating two exceptionally inexpensive switches.

1 Like

Of course it’s always possible that they use linear encoder tapes like that used in most desktop printers in which case they may not need any sort of limit check.

1 Like

Wow. Thanks for that in-depth and clear explanation. The lost steps issue is something I can understand but never would have thought ahead of time without a machine. Coupling this discussion with the Skydog thread and an orphaned Glowforge indicates that we might be adding some type of orientation/ position indicators since the cameras would be useless. This all makes me respect the tremendous amount of knowledge through study and experience so many folks are bringing to the forum. I am so grateful.

1 Like

It is my understanding that the “missed steps” issue is solved with servos instead of steppers?