Funuc 5t Post Processor help needed

Funuc 5t Post Processor help needed

Anonymous
268 Views
2 Replies
Message 1 of 3

Funuc 5t Post Processor help needed

Anonymous
Not applicable

Hopefully I have posted this in the correct place.

 

  I need help with my Post Processor. The Fanuc 5t does not use decimals and uses the Tenth as a reference instead. Meaning code without the "descending zeros" becomes dangerous. I have searched a few threads and tried some proposed solutions but they either do not work or are still buggy.

 

  If I could at least have G code that doesn't omit the trailing zeros it would be easier to manually edit the decimals out.

 

I am currently trying to use a post processor Script from the linked (below) thread as it seems very close to my other needs.

https://forums.autodesk.com/t5/hsm-post-processor-forum/fanuc-6t-post-modification/m-p/6269859/highl...

 

The solution in this thread sort of works. But if there is a move, etc that has a trailing zero .030 for example it shortens it to .03 This makes for a very time consuming manual edit. As I have to make sure all 4 places past the decimal are inhabited and then edit out each decimal point. I hope that is clear and understandable? This is my second attempt at a post about this today. For some reason my other post was either deleted or failed to post to the forum.

 

https://forums.autodesk.com/t5/hsm-post-processor-forum/fanuc-5t-post-request/td-p/6358646

 

 

 

I have tried the following edits. They work other than some values are rounded up and also become only 3 past the decimal point. 

var xFormat = createFormat({decimals:0, scale:2000}); // diameter mode
var yFormat = createFormat({decimals:0, scale:1000});
var zFormat = createFormat({decimals:0, scale:1000});
var rFormat = createFormat({decimals:0, scale:1000}); // radius
var feedFormat = createFormat({decimals:0, scale:1000});

 

Any help would be greatly appreciated!

0 Likes
269 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable

I posted in a few places looking for help with this to no avail. I am going to try and update those threads for anyone this may help. Hopefully this is correct it seems to work as intended in preliminary tests

 

 

Ok so I have finally figured out how to assure that trailing Zeros are not dropped using a trim command, I have also added a forceDecimal command but for some reason it has no effect. I will say that I do not really know JavaScript so if you use the following edits please beware. I will just use the search and replace feature in note pad to delete the decimals. It would be nice if that were a user definable feature and I am sure it could be easily done. But I think I am happy for now. Hopefully this helps someone with a fanuc 5t or like machine.

  If anyone has any ideas for upgrades or edits I would be interested to hear.

 

var spatialFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false});

var xFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false}); // diameter mode

var yFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false});

var zFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false});

var rFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false});

var feedFormat = createFormat({decimals:(unit == MM ? 3 : 4), trim:false, forceDecimal:false});

0 Likes
Message 3 of 3

Anonymous
Not applicable

Attached is a copy (word doc) of the script I am currently in trials with. It looks like my out put g code will only need some light manual editing now (unless there is something I am missing.

 

 

0 Likes