I understand this is a common issue amongst English native speakers since we would normally translate both as "when". But don't worry, they are actually quite easy to differentiate and once you'll get the hang of it, it will just come automatically. Simply enough, present and future tense always require the use of 'wenn', so you don't have to worry about that. It is with the use of the past tense, that you have to be more attentive. The rule is simple: when talking about any type of repeated action, always use "wenn", and when referring to a single event in time, use "als". For instance, you'd say, "Wenn ich mit Oma spazieren ging, fühlte ich mich immer froh." It is appropriate to use "wenn", since you want to convey the meaning, that you felt happy every time you went on a walk. Whereas, say, "Als ich mit Oma spazieren ging, haben wir einen süßen Hund gesehen." In this case, you are referring to a specific event that happened only once, while you were on your walk. Does this make sense? Great, let's look at some other examples.