Hi Flo, Currently I am programming about 4h a day on a c++ tool to manipulate gcode. It will support to map two original points to different two other points, by uniform scaling, rotating, and shifting, with the option to scale by 1 (and fitting as good as possible). This would be usefull to mill double sided PCBs. You do the drilling of the top surface, note two opposing drill coordinates, isolate the top surface. Then you flip the PCB, and mount it somehow, measure the flipped drill locations, use my tool, and get a correctly shifted/rotated bottom layer isolation gcode. [Mounting in some fixture is either not accurate enough, or you loose board space due to mounting holes. At least to my trials. The workflow starting from the eagle .brd file is 100% automatized already by scripting eagle and visolate] The tool currently supports shifting, aligning to bounds (either g1 or g0, no arcs), mirroring, counter- and clockwise rotation. Free rotation around Z-Axis I am currently working on, it requires to insert new X and Y words, as a sole X word transforms into X and Y. Also, interpretation of variables and is performed, []-expressions currently not. IJ-Arcs are working already, however I still need to test with Rs. Absolute and Relative moves are supported, as are switches between units. However, the limit for the first version will be three axis.
Maybe something like this could solve your problems? If you have an urgent need, I could mail you a pre-version. Most operations actually can be described by a multiplication of a matrix (2x2 in my xy case) and a shift. However, if you don't consider special cases, the gcode gets really messy if there are variables used. The tool will be GPLed. However I don't know when it will be finished. However its more in the region of a couple of days than weeks. At least I hope that, because the time that flows into it is subtracted from my sleeping time :) greetings, Bernhard from Vienna PS: For the long-term readers, yes it is an much improved version of the old filtering tool. I decided to do it properly. And I don't want to start any more discussions on the flame-bait filtering menu.. On 7/22/2010 12:28 AM, Florian Rist wrote: > Hi, > this is a off-topic question, but I'm sure someone here will be able to > gibe a hint: > > I'm trying to understand how to do the necessary coordinate > transformations to transform local coordinates from an off-setted an > rotated local coordinate system to the global coordinate system. > > Unfortunately I have to do these calculations sine the CNC does not > support G92 an the related commands. > > I have the x, y, z offset and the A, B, C rotation of the local > coordinate system, but I'm not sure how to rest these A, B, C angels. I > tried to interpret them as roll, pitch, yaw as well as as simple > rotations around the x, y, z-aces but non of my approaches seems to work. > > Can someone explain what A, B, C angles usually indicate in CAM? Does > someone have the transformation matrix ready for that kind of problem? > Does anyone have any suggestion where to find good explanation on the > various kinds to express a rotation/direction in space an how they are > used in CAM usually? > > See you > Flo > ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ Emc-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-users
