Any Help With Zooming Glitch With XP-Pen Artist 22E Pro

Hi all. I’ve been following the development and the art being done in blender and I finally started to jump in and participate (Thanks blender guru). I’m familiarizing myself with all the short cuts and trying to develop a workflow that centers around my drawing tablet (XP-Pen Artist22E Pro). I’m using blender 2.91 with 64gb ram and a 2080ti. So far it’s worked pretty well but when I zoom in/out, pan, or orbit (I’m using one of the pen buttons as the middle mouse button) the camera will abruptly flip upside down or zoom so far in that I can’t see anything. Sometimes it happens when I let go of the middle mouse button and sometimes it happens when I let go of the keyboard modifier but it’s very frustrating. I’ve tried using a mouse and had no issues and the tablet is working fine in photoshop etc. Do any of you have any idea what could be causing me this issue?