Single Phase PPL implementation

Are you asking how to implement a PLL or for an example? There are a couple demo models included with PLECS that include one if you search in the documentation (PLECS does have a library block for this too).