Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
rsreed
in reply to: daniel_lyall

Thank you for the quick input, but just changing axis values wasn't working. Then I ran into this thread. > https://forums.autodesk.com/t5/hsm-post-processor-forum/updating-cps-code-for-laguna-hhc-4th-axis-co.... Once I made all of the changes shown in red below my generated g-code looked like it should.

 

if (true) { // note: setup your machine here
    var aAxis = createAxis({coordinate:0, table:true, axis:[0, 1, 0], range:[-360, 360], preference:1});
    // var cAxis = createAxis({coordinate:2, table:false, axis:[0, 0, 1], range:[-360, 360], preference:1});
    machineConfiguration = new MachineConfiguration(aAxis);

    setMachineConfiguration(machineConfiguration);
    optimizeMachineAngles2(1); // TCP mode

Here you can see that all of the values are now Y, Z, and A, with the exception of the initial positioning of the X axis at the part origin.

 

N10 M03
(2D POCKET1)
N20 G0 X0.000 Y138.472 Z58.824
N30 G0 A-11.905
N40 G0 Z48.824
N50 G1 Z46.324 F2336.8
N60 G1 Y182.965 Z42.431
N70 G1 Y183.191 Z42.409 A-11.77
N80 G1 Y183.285 Z42.387 A-11.444
N90 G1 Z42.269 A-9.5
N100 G1 Z42.151 A-7.556

 

Frustrating to say the least but once it was tweaked and generating G-code that looked like it should, I realized there were values in my DSP that were also complicating my results. I had been jumping from Post Process to testing on the cnc without looking at the g-code carefully enough. It was only after I spent a good amount of time scratching my head that I went back to trouble-shoot each step to see where the problems lie. Without these forums I'd have given up on Fusion since I don't know Java and don't have the time to learn for this one instance where I really needed it.