Theory:

Simple past tense is used to express an action that happened at some time in the past. The time of the action may or may not be indicated, and it does not make a difference.
    Example:
  1. We watched a Superman movie.
  2. I bought a new mobile phone.
  3. My legs ached a lot.
Simple past tense is also called as "before now" past.
Past Perfect tense is used to express an action completed before a certain, said time in the past, or an event which also happened in the past.
    Example:
  1. I had gone out when my father came.
  2. Mahesh had finished his dinner by the time his wife called.
  3. Raghu had changed his profession before the recession started.
Past Perfect tense is also called as "earlier past".
  
Important!
If two events had happened in the past, it is important to express which event happened first and which event happened next. Simple past tense is used for one clause, and the past perfect is used for the other clause.
Example:
In the above illustrations,
  1. "I had gone out" is the first event, and "when my father came" is the second event. Simple past - came; Past perfect - had gone.
  2. "Mahesh had finished his dinner" is the first event and "by the time his wife called" is the second event. Simple past - called; Past perfect - had finished.
  3. "Raghu had changed his profession" is the first event and " before the recession started" is the second event. Simple past - started; Past perfect - had changed.