[chbot] Draw Algorithm

Marshland Engineering marshland at marshland.co.nz
Tue May 17 11:22:05 BST 2011


Part of getting a solution is to start with the correct question. The answers were correct but what I forgot to add is that I don't know how many nested loops there are ?

The drill hole is a CNC (of a form) instruction. 

I have an old CNC mill that is conversational. I.e. no Gcode. 

By conversational I mean it has set instructions only. To do a circle, you enter the Center and radius on the console and it does the rest. 

I have (through many hours) reverse engineered the machine code that comes out the serial port to get an external interface going. The serial interface was only used for loading and saving machine code.   

I have written a program to take G Code and turn it into machine code. I'm now trying to draw the machine code to check if I have got everything correct. I have it all working and it works very well except for the repeat instruction. I can take a DXF drawing, turn it into G-Code and the my software convert that to machine code. 

The machine code is in a sequential database and when a repeat is encountered, it needs to flick back to the start of the repeat command and do the drawings with the offset until the end of the repeat is encountered.   

it looks like I need to declare an array and then fill in the parameters as each repeat is encountered. 

(Thank goodness I'm not doing this in assembler code which the machine has to).

The mill is an excellent jobbing machine. It can be driven both manually and via a PC. It is ideal for modifying existing jigs, molds or one off prototypes. 


Cheers Wallace
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ourshack.com/pipermail/chchrobotics/attachments/20110517/6aab8875/attachment.htm 


More information about the Chchrobotics mailing list