Hello,
You can capture the button press event by configuring them as KeyEvent in xml file. For implementation details check out the following link:
Note that, you do not need to integrate S Pen Remote SDK for working with button press event. Only configuring a xml file is good enough.