Arduino: 1.8.9 (Windows Store 1.8.21.0) (Windows 10), servo error

Arduino: 1.8.9 (Windows Store 1.8.21.0) (Windows 10), Board: “Arduino/Genuino Uno”

C:\Users\SAI SATHWIK\Documents\Arduino\servo1\servo1.ino: In function ‘void loop()’:

servo1:16:9: error: assignment of read-only variable ‘th_i’

th_i=i;

^

servo1:18:6: error: assignment of read-only variable ‘i’

i=i+th_i

^

servo1:19:6: error: expected ‘;’ before ‘}’ token

}

^

exit status 1
assignment of read-only variable ‘th_i’

This report would have more information with
“Show verbose output during compilation”
option enabled in File → Preferences.

TOPIC SPLIT
DO NOT HIJACK !

Could you take a few moments to READ THIS.
It will help you get the best out of the forum.

Bob.

th_i is probably declared as const.

For the rest, post your code; before doing so, read the link above.