Thank you very much @maxmp, it is working flawlessly. Just one query, Hi-res is not supported on Pie? I am using it on Pie, and from the last build I noticed Hi-res is not working on Pie, but in Oreo it was working fine.
Headset buttons are not detected by the player when the screen is off. But it detects when the screen is off and for that session it works off screen also. So as it goes, I have to press headset atleast once to make sure it is detectable off screen. Very irritating bug.
What about the headphone buttons? I am having the same issue as @MeGustaPowerAmp. I am on Redmi Note 4 with android version 8.1. Other audio players respond on the headphone buttons where Poweramp only detects when the screen is on. But fails to respond on the headphone buttons when the screen is off. I am facing this bug from 709 build.