Benbox Laser Machines/CO2 Lasers/3D Printers

Software => T2 Engraving => Topic started by: pedwards2932 on October 22, 2018, 04:43:33 AM

Title: Size/Resolution
Post by: pedwards2932 on October 22, 2018, 04:43:33 AM
I think I had asked about this before but still need some clarity.   I was designing a decal sheet in Inkscape and had the decals precisely sized for the airplane I am building.  When I printed it from Inkscape it was exactly the correct size.  When I pulled it into T2 and traced for cutting out the decals the cut was much smaller than the print.  I remembered from before that I had to change the DPI.  The last time I did I had to bump it to 256 dpi.  On this one 256 was not large enough it turns out it was about 500 dpi so I am guessing by multiples it should be 512.  I found that Inkscape allows you to change the DPI on a png pretty easily.  My question is how do you know what factor of resolution you need.  I just did this by guessing then running the cut to see if it was correct.  Also is there any "undo" function in the trace function on T2.....occasionally you need to undo and retry but I couldn't figure out how....I don't think control Z works.
Title: Re: Size/Resolution
Post by: Zax on October 22, 2018, 05:17:44 AM
T2Laser supports 2 different ways of dealing with images, the default is to use the pixels.

So if you export an image with 254dpi and import it to T2Laser at 0.1 resolution the size would be correct (since 10 dots per mm is the same as 254 dots per inch). If you are using a different resolution then you would set the export dpi to match, e.g. 127dpi for 0.2 resolution.

The other method (when Use Image DPI is enabled) sets the resolution automatically to match your image, so if your image is exported at 300 dpi the resolution would be changed to 0.085 which results in the image being the same size as it was saved. Of course this probably won't engrave very well since the laser would be repeating over the same area. This works if you export at a valid resolution for the engraver rather than the typical defaults which are for laser printers or screen resolution.

In most cases you can just click the trace icon again to "undo" it and start over, if using manual trace the delete key removes the last trace (you can press it multiple times to keep stepping back and erasing the traced lines).
Title: Re: Size/Resolution
Post by: ggallant571 on October 22, 2018, 05:54:34 AM
I do everything at 256dpi. My host software is more primitive than T2 and does not provide and option to do otherwise.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 22, 2018, 06:34:28 AM
When I did it at 256 it was about 1/2 the size of the Inkscape print.  500 dpi was about the same as the print so figuring in multiples probably should be 512.  I need precision since I am using the trace to cut these out exactly on their outlines. In the svg file in Inkscape I can export as a png and pretty much select any DPI.  So what I did was try different resolutions then print the png until the size was correct.  On T2 it is set to default 0.2.   When I made the decal set I just pulled in an insignia that was an svg and resized it to fit the plane.  The lettering and numerals were just from a military font.  I guess I just am not getting why if I print them from Inkscape they are exactly correct and when I pulled them into T2 it was so different that I had to play around with the resolution to get it right.

I can work with it the way it is......also be interested to know how you get exact registration on the cut so it will cut exactly on the decals.  I usually zero the laser by moving it fully down and to the left until it stops....I haven't set up zeroing switches.  Is there a way to put in markers on the page that you line the laser up with?
Title: Re: Size/Resolution
Post by: Zax on October 22, 2018, 07:17:11 AM
The reason it prints correctly in Inkscape is because it has physical dimensions, when you save an image it is stored as pixels (sometimes with an embedded DPI which can be used to translate back to the physical size, which is what T2Laser does if you enable that option - not recommended).

T2Laser / Grbl uses metric units, so a DPI of 254 = 10 DPmm = Resolution of 0.1mm.

If you are using 0.2 resolution then save the image at 127 DPI and it will load the correct size. If this isn't working as expected then the problem is with the export from Inkscape, load the image back to Inkscape or another image viewer and check the pixel count.

Since you are going to trace these you could also do that in Inkscape and save a DXF, this format uses physical dimensions (mm) and doesn't rely on scaling.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 22, 2018, 07:57:11 AM
Ok I pulled the decal.svg into Inkscape and set resolution to 254 dpi and the size is 2100 x 2970 and created a png.  I pulled this into GIMP and verified size and resolution and it is 10px/mm.  So now I will set T2 to 0.1 and it should work.  Will try it when I get home.  If that works then all should be okay except figuring out the best way to check that I have the alignment correct.
Title: Re: Size/Resolution
Post by: Zax on October 22, 2018, 08:03:58 AM
T2Laser will load it as 210 x 297 mm if you use 0.1 resolution, since it needs 10 pixels to make 1 mm.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 22, 2018, 09:32:50 AM
So if I want it to load in T2 at the exact size then I should use 1.0 resolution? or should I change the png resolution?  I need T2 to be the same dimensions as the png.
Title: Re: Size/Resolution
Post by: Zax on October 22, 2018, 09:47:08 AM
You need to export and import at the same resolution.

Physical size is irrelevant as images are based on pixels (not real world dimension). If you specify the same resolution those pixels will be the same size and thus the resulting image will the the same size.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 22, 2018, 10:41:01 AM
I'm going to just try it when I get home and see what it does.....the math makes my head hurt
Title: Re: Size/Resolution
Post by: pedwards2932 on October 23, 2018, 10:05:19 AM
Ok I think I have it figured out.....I was setting the size of the paper to 8 x 11.5 and this was causing some issues in Gimp.  I set the size to the content and exported the png to Gimp at 256 dpi and according to print output it is 186.10 mm by 128.2 mm resolution 10 px/mm and when I brought it into T2 at 0.1 resolution the size was identical.

The precision for making these cuts pretty much has to be spot on or the decals won't be cut out correctly.  Is there any way to use the laser to accurately align the paper so it will be in the correct alignment for the cut?
Title: Re: Size/Resolution
Post by: ggallant571 on October 23, 2018, 11:51:23 AM
Homing switches and alignment braces. I set the back off for the homing switches to 5mm. That way  it can go slightly negative. Then I screw a piece (or pieces) of scrap 3mm wood to the waste-board. Then set machine at the HOME position and use the laser to cut the X & Y axis. After a while this edge gets ruined and I do it again.  Thinking about it, I should start with a 10mm offset and just re-cut the axis with a smaller offset.

On a machine without homing switches I use a right angle aluminum rod on just the Y-axis. Not as exact but this machine can handle long pieces of wood that slide under the X rails.

For etching slate I have a 100x100mm (4x4 inch) square etched in the waste-board. Then I eyeball center the tile and jog the laser to the lower left corner and call that 0,0. Works good enough.

Title: Re: Size/Resolution
Post by: Zax on October 23, 2018, 04:18:46 PM
I use home switches which set an accurate 0,0 and then the preset locations menu for different "jigs".

These jigs are alignment marks or fixtures to hold different items you commonly engrave. A basic straightedge or square (90 degree ruler) would probably be sufficient in your case. You could manually move to this start point but it's less accurate and more time consuming than having home switches.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 25, 2018, 03:40:06 AM
I am going to look into getting homing switches but that may take a while.  I have a couple of questions that may solve this for me.  What are the units of measure in the x/y T2 in the laser control page?  Pixels or mm?  What are the increments of motion for the jog? mm?  Is it possible to move the laser to an exact coordinate in the controls or do you just have to use jog to get it where you want it?

My thought here is I can put a graphic plus sign at specific points on the decal image then when I move the laser to those coordinates I could use a weak laser pulse to make sure it is dead center on the plus sign.  If I put 3 plus signs in the image and align all three it should be dead on aligned.  This is the way it is done in the craft cutter software that I have.
Title: Re: Size/Resolution
Post by: Zax on October 25, 2018, 05:28:35 AM
Everything is in mm as that's what Grbl uses.

You can use the custom buttons or presets to set specific moves but without home switches there's no reference. In this case you would need to jog to the start position and set 0,0 manually, there's no way you can click on the graphics and move to a location when the laser doesn't know where it is now. I suspect your craft cutter homes itself or has some other method to know it's position.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 25, 2018, 06:18:32 AM
Ok I was just thinking that wherever I have the laser when I open the laser controls it is set as 0,0 which I use by making sure it is all the way to the right and all the way to the bottom....that would be 0,0 then if I put a cross hatch at 5,5 and  5,600 and 600,5.  I have been able to use the 0,0 position by putting it against the stops and it has worked fine for me.  Does that make sense?
Title: Re: Size/Resolution
Post by: Zax on October 25, 2018, 08:04:37 AM
You could do that, but to ensure it's straight a ruler fixed to a base that is aligned with your gantry is the better method.

It's fairly easy to set a 0,0 but if it's rotated slightly the alignment becomes more difficult.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 25, 2018, 08:12:55 AM
What I am thinking is when I align the 5,5 mark with the laser I will stick a pin in the paper using foam backing board.  Then move to 5,600 mark pulse the laser and rotate the paper until the laser is aligned with the mark then stick a pin in it.  Then check again at the 600,5 mark to make sure it is correct.  I am relying on the fact that the first pin is in the correct location and I am rotating the paper on that axis.  It may not work but in my head (I have wild ideas occasionally) it seems like it would work.
Title: Re: Size/Resolution
Post by: Zax on October 25, 2018, 09:09:00 AM
That sounds reasonable (if a little involved) and should work. Having a fixed ruler / square as a jig and just placing the paper against the edges seems easier to me.

It sounds like you are moving the laser to the limits (left and front) before connecting so you have some "reference". In that case you can setup the custom buttons to automatically make these moves; one for the 5,5 position, another to move to 5,600 and a final one at 600,5.

You may want to move to the 5,5 and then reset it as 0,0 which can be done with a custom button, then the others would reference that new 0,0 instead and your job would align correctly to the lower left of the paper.

Title: Re: Size/Resolution
Post by: pedwards2932 on October 25, 2018, 10:20:59 AM
I'm probably over thinking it but if this works I will make a template in Inkscape for doing decals that will allow me to align them pretty quickly.  I don't want to use my cutting waste board for this because of the metal grating makes it hard to work with paper.  When I cut balsa it doesn't have to be as accurate.  I did this before for a single decal and what I did was made a cut out first then I aligned my printed paper with the cut out and it came out pretty good but that was just one decal and the sheet I am working on has multiples.
Title: Re: Size/Resolution
Post by: pedwards2932 on October 26, 2018, 06:09:17 PM
I think I was trying to get too many decals at once.  I did find a method that works pretty well after about 8 failures.  I taped down a blank piece of paper and then cut the trace of the decals.  Then I removed the cut away decals outlines and slid the printed sheet of decals under the paper with the cut outs and aligned it and taped it down.  It cut most of it out perfectly but I think some inaccuracies in either belt tension or something makes it pretty difficult to be that precise.  I have decided to do fewer decals at once.  Also the black lettering I am going to cut out of a black background so alignment isn't as important.