Could be you have the Step pulse active on the falling edge rather than rising edge. Basicly it's timing issue and the Step pulse is happening before the Dir so your losing a position with every direction change.

Try changing the Step Active pin state and see if it makes difference.?