implemented angle error-correction