Animate sketchfab API utilityrotateOnAxis questions

Hello all, I am using the Sketchfab API Utility and the rotateOnAxis to animate the rotation of some parts. Below is my current simple code that will animate the parts in a positive rotation but I cannot get them to rotate in a negative movement. Example… I can animate the rotation +15 but am unable to animate the rotation back to 0. It jumps back to zero and animates back to +15.

If I set the for loop like ---- for (let i=0; i<=15; i++) it will animate forward but if I change the for loop to ---- for (let i=15; i>=0; i–) I get the same animation as the before

for (let i=0; i<=15; i++) {
    thisDir= sketchfabAPIUtilityInstance.vectorUp
    rotateIt(i,thisDir);
    console.log('loop value = '+i)
};



function rotateIt(d,dir) { 
        setTimeout(function() { 
            // Add tasks to do
            console.log('move '+d +' in '+dir)
            sketchfabAPIUtilityInstance.rotateOnAxis("PivotArm",d,dir);
        }, 100 * d); 
    }

Any help would be appreciated. This is my last hurdle on this project.

It’s not using @shaderbytes API Utility though, but here is sample to do it directly with Sketchfab API Viewer API - Examples - Sketchfab