CamBam gcode contains only positive coordinates!

Post Reply
Bluemetal
Posts: 13
Joined: Tue Apr 10, 2012 9:03 pm

CamBam gcode contains only positive coordinates!

Post by Bluemetal » Wed Sep 04, 2013 4:22 pm

I have finished my ShapeOko a while ago (I was in the first Kickstarter group) and got it to write the Shapeoko name on paper using the wiki file in the proper way.

I have now come back to it with renewed interest (and time) and tried my hand at generating some gcode with CamBam (beautiful software by the way). It still writes the 2D file from the wiki without problems.

Here is the interesting part - the gcode generated by CamBam has all coordinates with positive values, rather than all negatives like the file in the wiki (also generated by CamBam) and the Shapeoko follows that to the letter so it moves to the upper right corner (when the toolpaths were clearly showing it should go lower left and the start point was set to lower left) and up (when it should go down to remove material). It is clearly doing the exact opposite of what it should because the gcode is instructing it to do so.

Wiki file start

Code: Select all

M3 S1000
G0 X-3.0 Y-0.0451
G1 F10.0 Z-0.001
New CamBam file start for a 3D surface

Code: Select all

M3 S1000
G0 X56.0135 Y38.0965
G1 F60.0 Z9.6
Does anyone know what is the setting in CamBam that would cause that "inversed" behavior?
Proud owner of original Kickstarter Shapeoko #8 - still has original steppers, some end plates and screws but now looks like a Shapeoko 3.:)

bjbsquared
Posts: 102
Joined: Mon Nov 26, 2012 10:48 am

Re: CamBam gcode contains only positive coordinates!

Post by bjbsquared » Wed Sep 04, 2013 4:49 pm

Check to see where the origin is placed. It can be placed anywhere in the design as understand (haven't done it). Also CAMBam has a forum that might help as well.
#1016 - 1M x 1M Y: Dual Motor Drive w/Looped Belts, X:Dual Rail with wlanfox blocks, Z: Stock, Spindle:DW660

PsyKo
Posts: 430
Joined: Thu Aug 30, 2012 8:42 pm
Location: France

Re: CamBam gcode contains only positive coordinates!

Post by PsyKo » Thu Sep 05, 2013 6:11 am

bjb is right !

It depends where your 2D test is in the CamBam coordiante system. IF your text is in the lower left quadrant (top view), then value will all be negatice. Upper right, values will be positives (I4m not sure about the X & Y axis orientation, but you got the point).

If you want to use offset, you can adjust it in the parent of all your machining operation. If I remember correctly, there is a parameter called Machining Origin which allows you to set the offset with your machine origin. I use it all the time with home switches.

Besides, remember that there is not one single GCod efile for a task. Most likely, getting the exact setup as someone else is quite hard.

As long as the GCode give you the expected result, you should be fine.
I'm using CamBam as well and it's a great software. As suggested by CamBam, RTM :) Read the manual
Shapeoko #736
Kress 800, Z Axis upgrade, dual Y, 600mm X&Y rails, metal spacers and V Wheels, home switches, 4th axis
Goko - Free CNC Control Software - http://www.shapeoko.com/forum/viewtopic ... 380#p44380

Bluemetal
Posts: 13
Joined: Tue Apr 10, 2012 9:03 pm

CamBam produces mirror movements!

Post by Bluemetal » Thu Sep 05, 2013 4:13 pm

PsyKo wrote:bjb is right !

It depends where your 2D test is in the CamBam coordiante system. IF your text is in the lower left quadrant (top view), then value will all be negatice. Upper right, values will be positives (I4m not sure about the X & Y axis orientation, but you got the point).

If you want to use offset, you can adjust it in the parent of all your machining operation. If I remember correctly, there is a parameter called Machining Origin which allows you to set the offset with your machine origin. I use it all the time with home switches.

Besides, remember that there is not one single GCod efile for a task. Most likely, getting the exact setup as someone else is quite hard.

As long as the GCode give you the expected result, you should be fine.
I'm using CamBam as well and it's a great software. As suggested by CamBam, RTM :) Read the manual
Thanks both for the guidance. I have read more about it (RTM) and looked further into the issue and confirmed the origin as the reason for the positive coordinates. I should also have explained better the problem (I am picking up the language along the process).

The issue is that the Shapeoko is doing the opposite of what it should when I generate the gcode myself (rather than using the example in the wiki). It moves to the upper right corner and goes up slowly ("thinking"it is removing material) and down fast ("thinking" it is just moving), then it works its way toward the lower left. The gcode is telling it to do that. The file on the wiki produces the right moves, so I thought it had to be something within my setup for CamBam that inverted all the axis - that had nothing to do with the actual positive coordinates which you both pointed correctly out that is origin related.
Proud owner of original Kickstarter Shapeoko #8 - still has original steppers, some end plates and screws but now looks like a Shapeoko 3.:)

Post Reply