Yes - AS hates Malhar so much that she would have not waited 5 years for Kalyani to come back to take revenge. She must have done many things to make his life miserable along the way.
He must have been taking these meds for quite some time now. Not recently.
And though AS said she had a role to play in his demotion, logically even the police department would have sent him for psychiatric check up after suffering such a huge personal loss.
That's where AS must have played her game. The police approved psychiatrist must have been influenced by her to give a false certificate which could have resulted in his demotion.
And yes she could have arranged for the meds to be controlling his senses..
.