>Did he knew about the Michelson-Morley experiment?  

He just knew the name of the experiment not any details. The experiment didn't play any role in the formulation of _STR_ by Albert einstein.   
The context is taken from the book :  
**Special Theory of Relativity 
by V. A.; Atanov, Yuri (Trans.) Ugarov (Author)**  
 
_Art: Was Michelson's experiment "decisive" for the creation οΙ 
the special theory οΙ relativity?_  
 
An article by R. Shankland, 
published in 1963, the following excerpt from his interview with 
Einstein dating back to 1950: 
  
"When Ι asked him how he had learned of the Michelson Morley experiment, he told me that he had become aware of it through 
'writings of Η. Α. lοrentz, but only after 1905 had ίΙ come to his 
attention! 'Otherwise" he said, Ί would have mentioned it in my 
paper!'" indeed, Einstein's 1905 paper contains no mention of Μichelson's experiment or references to Lorentz's papers."

A letter written by Albert Einstein:  

"Ιn my own development Michelson's result had not had a considerable influence. Ι even do not remember if Ι knew of it at all when I wrote my first paper on the subject (1905). Τhe explanation is that Ι was, for general reasons, firmly convinced how this 
could be reconciled with our knowledge οί electro-dynamics. One 
can therefore understand why in my personal struggle Michelson's 
experiment played no role or at least no decisive role...."