Hi, astanapane ...

the problem is Pauseus 1 gives a ... 24µs pulse @ 4Mhz !!! ( see manual p.185 ) - I found 23µs @ scope !
so, you might need to use ... assembler and absolutely avoid the Stepit sub ...!

so, try this piece of code ...

Code:
ROTATION:
    for i = 0 to (stepM - 1)
        @ bsf PORTB,2 ; This gives ON pulse for 1µs ...
        @ bcf PORTB,2 
pauseUS delay
    next
    return
Alain