Mach 3 5 axis table/table bc post

Mach 3 5 axis table/table bc post

splintWFYFX
Participant Participant
4,543 Views
4 Replies
Message 1 of 5

Mach 3 5 axis table/table bc post

splintWFYFX
Participant
Participant

Hi,

 

I'm trying to get a Mach 3 5 axis post and I'm having some trouble getting it to produce b and c code for the fourth and fifth axes which tilt around y and rotate around z respectively. The text in red has been added but nothing else has been changed and all code prior to the onopen statement is the original code downloaded from https://cam.autodesk.com/hsmposts. This code produces A and B axis but I require B and C for my machine. Apart from that the code runs without any problems in Mach.

 

Thanks

David

 

function onOpen() {
if (properties.useRadius) {
maximumCircularSweep = toRad(90); // avoid potential center calculation errors for CNC
}
if (true) {
var bAxis = createAxis({coordinate:0, table:true, axis:[0, 1, 0], preference:0});
var cAxis = createAxis({coordinate:1, table:true, axis:[0, 0, 1], preference:0});
machineConfiguration = new MachineConfiguration(bAxis, cAxis);

setMachineConfiguration(machineConfiguration);
optimizeMachineAngles2(1); // 0= Enabled, 1=disabled TCP enabled (eg. M128, TRAORI, G43.4, G243)
}

if (properties.fourthAxisAround != "none") {
var aAxis = createAxis({coordinate:0, table:true, axis:[(properties.fourthAxisAround == "x") ? -1 : 0, (properties.fourthAxisAround == "y") ? -1 : 0, 0], cyclic:true, preference:0});
machineConfiguration = new MachineConfiguration(aAxis);

setMachineConfiguration(machineConfiguration);
optimizeMachineAngles2(1); // map tip mode
}

if (!machineConfiguration.isMachineCoordinate(0)) {
aOutput.disable();
}
if (!machineConfiguration.isMachineCoordinate(1)) {
bOutput.disable();
}
if (!machineConfiguration.isMachineCoordinate(2)) {
cOutput.disable();
}

if (!properties.separateWordsWithSpace) {
setWordSeparator("");
}

sequenceNumber = properties.sequenceNumberStart;

if (programName) {
writeComment(programName);
}
if (programComment) {
writeComment(programComment);
}

 

 
0 Likes
Accepted solutions (1)
4,544 Views
4 Replies
Replies (4)
Message 2 of 5

AchimN
Community Manager
Community Manager
Accepted solution

Please have a look here at Step #2:
https://forums.autodesk.com/t5/hsm-post-processor-forum/how-to-set-up-a-4-5-axis-machine-configurati...

coordinate: Specifies the coordinate used in the ABC vectors (ie. "X", "Y", or "Z"). The given number will define the letter for the axis:
0 = “A”
1 = “B”
2 = “C”



Achim.N
Principal Technology Consultant
Message 3 of 5

splintWFYFX
Participant
Participant

Thanks,

That did the trick. I also notice that you can use 0, 1 and 2 or upper case X, Y and Z in the coordinate variable and it produces code correctly. I've attached a copy of the Mach3mill 5 axis table table BC post if anyone want's it.

 

David

Message 4 of 5

Anonymous
Not applicable

Hello, 

I designed a DIY 5 axis which is basically a tall router with a forth axis that mounts on the table and a fifth that can be replaced wit a chuck on the forth axis. it is basically a XYZ and BC type of a machine running with Mach 3

I am taring t use the post  attached above, but an error about the offsets comes out. Any Idea how to get it going?

0 Likes
Message 5 of 5

bob.schultz
Alumni
Alumni

Hello @Anonymous,

 

Can you provide the log file that contains the error message that you are getting.



Bob Schultz
Sr. Post Processor Developer

0 Likes