I want programme my very own G-Codecode generator for my final year electrical engineering project. I know that there are many open source G-Codecode generators out there, but I need a G-Codecode generator which generates a G-Codescodes for custom circuit designs drawn by the user and pass the G-Codecode serially to my 2 axis CNC machine. So currently I'm working on a Qt based GUI where I draw .dxf format circuit diagrams and electrical components (like resistors, capacitors) and when I press a "Generate G-Code"code" push button I should generate a text file with nice set of G-Codescodes for my designed diagram.So
So the problem here is, how do I generate the G-Codecode? Is there any specific algorithm to follow or adapt? I tried googling for G-Codecode generator algorithm but iI couldn't find any helpful stuff.