[As you set out to serve G-d,] do not be overly exacting in all you do. [To do so] is but a contrivance of the
yetzer [hara] (the negative drive) to make you apprehensive and depressed at the thought of not having fulfilled your obligation [perfectly]. Depression, in turn, is an immense obstacle to one's service of the Creator.
Even if you did commit a sin [Heaven forbid], do not be overly depressed, lest this stop your worship. Do feel saddened by the sin [and feel ashamed before the Creator, and beg Him to remove the negativity you have drawn upon yourself]; but rejoice in the Creator, because you have fully repented and resolved never to repeat your folly.
Even if you are certain that you did not fulfill some obligation because of a variety of obstacles, do not feel depressed. Bear in mind that the Creator "searches the hearts and minds" (Psalms 7:10). He knows that you wished to do the best, but were unable to do so. Thus strengthen yourself to rejoice in the Creator.
rsip: Tzava'at HaRivash, The Testament of Rabbi Israel Baal Shem Tov, p. 15