CauldronDevelopmentLLC / CAMotics

Open-Source Simulation & Computer Aided Machining - A 3-axis CNC GCode simulator
Other
602 stars 140 forks source link

Support GCode processors which require decimal points in all numbers. #298

Closed Leviathan3DPrinting closed 5 years ago

Leviathan3DPrinting commented 5 years ago

There is no cutter compensation. Even bigger of an issue is that the software doesn't put decimal points after each X, Y, Z. This makes the software completely unusable as I have to manually correct every line of G-Code the software prints out. Idk what file is used for translation, but if someone would let me know I'll fix it myself.

Seriously though I'll implement these things myself or at the very least try to. If someone can point me to the write file.

So to better describe the issue here. All feed rates coordinates, spindle speed, basically any value set by the user, MUST have a decimal point at the end. If they do not the machine will default to the slowest possible metric on the machine. So for instance I was using this program output.txt. The machine will move to X0.0005 and Y0.0003 without a decimal point. I can manually add them in sure but at that point why am I using TPL to begin with. Also this is a copy of the file used to create the output of gcode minus the alterations I made afterwards(G20 instead of G21)(M8,M9) nothing major.

jcoffland commented 5 years ago

CAMotics follows the GCode conventions used in LinuxCNC and vicariously RS274/NGC. In section 3.3.2.1 of the RS274/NGC spec, it says:

A number consists of an optional plus or minus sign, followed by zero to 
many digits, followed, possibly, by one decimal point, followed by zero to 
many digits - provided that there is at least one digit somewhere in the number.

So trailing decimal points are not required. What machine are you using that requires this?

The lack of cutter compensation support is documented in #296.

Leviathan3DPrinting commented 5 years ago

This would be a Haus VF-3 possibly a different model but I believe all Haus machines work this way. I guess I can write a bit of code to just cycle through and add a decimal point but it would be better if I could just create something to build into camotics. Well really all I use use is the cmd tools to convert my .tpl files into usable .nc files for the Haus machines we use where I work, or at least that was the idea. I really like the camotics software btw. The Haus has a built in simulator which I use before running anything anyway to check for errors, so I rarely use camotics but if I were to do this at home I definitely would want to pick up a buildbotics kit to play with.

Leviathan3DPrinting commented 5 years ago

Like basically without tpl I would have to hand write hundreds of lines of G-Code for things. If it becomes too much then MasterCam would be used. I think tpl is a great middle ground though as you can easily write a reusable function to simple contours, or drilling, or litterally anything. Without the decimal point I'm afraid I wont have much of a use for it though. At least till I can afford to get my own machine based on buildbotics. :'(

Leviathan3DPrinting commented 5 years ago

Mazak machines also work this way. Just about every production CNC I can think of works this way. I have never used LinuxCNC. I have not met anyone who has ever used it. Is it just a toy used for hobbyist. Is it incompatible with other CNC machines. I have to have a decimal point though. Like I said I'll implement it myself if even for my installation alone. I just need pointed to the correct file. Even if I cannot do this myself I still love the software. I will continue it for whatever I can honestly. Handwriting things seems very archaic after using tpl once even if it doesn't implement all the G-Codes and standards (for different G-Code processors).

jcoffland commented 5 years ago

Ok, you've convinced me.

I've made the necessary changes. You will have to compile the code yourself or wait for the next official release.

Leviathan3DPrinting commented 5 years ago

Wonderful, this is great news. I have compiled from source and tested the application. I can say that it works flawlessly. I really appreciate this and will get to using it right away. Thank you, so much.