It seems that it doesn't actually read the HOME button being pressed, but instead is a flag for when the HOME exit screen popup is being shown.
To prove this I created a test program with no exit callback setup. No home button presses were detected.
I then did exactly the same but with an exit callback, the flag for PSP_CTRL_HOME was set on every read of the pad data when the popup was active, not just on the initial press.
It seems that when the HOME exit callback is active, the PSP_CTRL_HOME bitmask is set on every peek/read.
I believe Sony did this so you could effectively disable reading buttons while the popup is active, using this style of polling:
Code: Select all
sceCtrlPeekBufferPositive(&pad, 1);
if((pad.Buttons & PSP_CTRL_HOME) == 0)
{
// Popup not active
if(pad.Buttons & PSP_CTRL_CROSS)
{
// Handle true button presses etc.
}
}
All of this relates to usermode.