Can this be done using UCCNC? Targets...

If you have a question about the software please ask it here.

Can this be done using UCCNC? Targets...

Postby motogeek » Fri Aug 18, 2017 1:22 am

I have an application that we do quite frequently, it goes like this...

We print things on a full 4' x 8' sheet of acrylic. When we set up the print file, we create 4 "targets" or fiducials or crosshairs, in the four corners of the material. We use the same file to create the "cut out" file that will be run on a router. We have the bit drill these same 4 targets onto the surface of the router. Then we align the targets on the sheet to the drilled holes on the table and secure it. Now we know that the sheet is lined up and we can proceed to cut out the multiple shapes that are printed, out of the sheet and things line up pretty good.

Is it possible to do something like this...

If I mount a camera to the spindle mount and know what the x and y offset of the camera to the bit is, is it possible to lay the sheet down on the router bed, jog the camera over the 4 targets and somehow log their position and somehow use these points to adjust the cut file gcode to adjust for the actual position on the bed to be able to cut out the pieces on the sheet? And if this is possible, would it matter if the sheet is not placed perfectly square to the bed? Is this something that can be a macro or some kind of "pre-processor" event that can be programmed into UCCNC?

Or... am I dreaming a bit too big with this one?
motogeek
 
Posts: 12
Joined: Tue Jun 27, 2017 12:07 am

Re: Can this be done using UCCNC? Targets...

Postby dezsoe » Fri Aug 18, 2017 5:37 am

Yes, it is possible. If you know the exact offset of the camera and the four measured point then it need only some math to calculate the position and rotation. But! The latest official version of UCCNC is 1.2037 and that version doesn't contain the rotation. It was first in the 1.2038 test release, so first you should wait for the next official release. Anyway, you can start developing the positioning and calculating macro or plugin, because you can test it with the latest test release.
dezsoe
 
Posts: 2093
Joined: Sun Mar 12, 2017 4:41 pm
Location: Csörög, Hungary

Re: Can this be done using UCCNC? Targets...

Postby motogeek » Fri Aug 18, 2017 10:19 am

Thank you for that info dezsoe! That is exciting news. I will try to at least map this out on paper to see the "flow" of what has to happen and then see if I can give it a shot. Hope I don't fry my brain...
motogeek
 
Posts: 12
Joined: Tue Jun 27, 2017 12:07 am

Re: Can this be done using UCCNC? Targets...

Postby cncdrive » Fri Aug 18, 2017 11:26 am

As Dezsoe described it is possible to write a plugin like that.
How it could work is:

- Read the camera image in a plugin.
Because a plugin can implement any C# functionality it is not hard to do it.
- Make an object recognition to detect the fiducial shapes.
Again, there are premade libraries to do it, for example Aforge : http://www.aforgenet.com/articles/shape_checker/
You can import the library into the C# project and then call the functions as nessessary.
- Make a procedure to detect all the fiducials and so recognise the position of the fidus, so you can calculate the missalignment angle and even shrinkage.
- Execute a G68 rotation with the calculated angle around the reference point. Execute a G51 if the shrinkage is not 1:1

And thats all I think. :)
cncdrive
Site Admin
 
Posts: 4887
Joined: Tue Aug 12, 2014 11:17 pm


Return to Ask a question from support here

Who is online

Users browsing this forum: Bing [Bot] and 25 guests