You will need OnGenericMotionListener:
OnGenericMotion(...., MotionEvent me) {
if (me.getToolType(0) == MotionEvent.TOOL_TYPE_MOUSE) {
}
api is 14+necessary [confirmed] The tablet I found with a usb mouse and can confirm that this works for mouse movement. You will be filled with messages, so you should consider simple operations or sleep.
source
share