this was due to incorrect macro NORMALIZE_ANGLE (was the same as NORMALIZE_ANGLE_POS), now modified and renamed NORMALIZE_ANGLE_360