I just need some help. the Ipaq4 has 56 inputs.
Joystick x4 =16
1-4 player buttons 7 each = 28
Coin and Start 4 player = 8
Pause = 1
Exit/Back =1
Which Equals 54 . 2 left
Don't take my reply as gospel because I'm too much of a noob to be right.
But the P1 start = shift key and so the Shift+P2Start= ESC so that would be 1 button up your sleeve as you dint need a dedicated esc key. (you can actually shift + any other key = pause or esc ) So there would be 2 spare keys.
Now You could also make the shift key a dedicated button , which would use up one of your spares BUT then if you made shift + P1start = coin 1 , Shift + P2 start = coin 2, and same for P3 and P4 start/coin then you will have freed up 3 or 4 buttons.
Or you could edit mame to make p1 coin = p1 AND p2 coin and P3 coin = P3 AND P4 coin
Now -- rather than buy a ipac2 why not put that same money towards a spinner (i like the GGG one

"it's nice"). Because that comes with an optiwiz that gives you three more buttons (i think mouse 1,2 and 3)
Then you would have more buttons than you need.
There are many ways to get more from your IPAC4...... I have one and Ive got more than enough inputs for my setup (my setup is however a WIP so I cant be sure)