Also für Visual Basic habe ich schon mal routinen gesehen.
Ergo muss es mit C++ gehen.
Bei C++ sollte eigentlich eine Headerdatei für die winmm.dll dabeisein.
Andernfalls könnte man natürlich auch einen VB Quelltext als Vorlage nehmen und dann entsprechend in C++ umsetzen (primär geht es dabei nur um die Initialisierung/Geräteauswahl).

Es gibt sogar Fensternachrichten für Joysticks:

// Multimedia Window Messages
const int MM_JOY1MOVE = &H3A0;
const int MM_JOY2MOVE = &H3A1;
const int MM_JOY1ZMOVE = &H3A2;
const int MM_JOY2ZMOVE = &H3A3;
const int MM_JOY1BUTTONDOWN = &H3B5;
const int MM_JOY2BUTTONDOWN = &H3B6;
const int MM_JOY1BUTTONUP = &H3B7;
const int MM_JOY2BUTTONUP = &H3B8;



Die folgenden Deklarationen sind für VB:
Public Declare Function joyGetDevCaps Lib "winmm.dll" Alias "joyGetDevCapsA" (ByVal id As Long, lpCaps As JOYCAPS, ByVal uSize As Long) As Long
Public Declare Function joyGetNumDevs Lib "winmm.dll" Alias "joyGetNumDev" () As Long
Public Declare Function joyGetPos Lib "winmm.dll" Alias "joyGetPos" (ByVal uJoyID As Long, pji As JOYINFO) As Long
Public Declare Function joyGetPosEx Lib "winmm.dll" Alias "joyGetPosEx" (ByVal uJoyID As Long, pji As JOYINFOEX) As Long
Public Declare Function joyGetThreshold Lib "winmm.dll" Alias "joyGetThreshold" (ByVal id As Long, lpuThreshold As Long) As Long
Public Declare Function joyReleaseCapture Lib "winmm.dll" Alias "joyReleaseCapture" (ByVal id As Long) As Long
Public Declare Function joySetCapture Lib "winmm.dll" Alias "joySetCapture" (ByVal hwnd As Long, ByVal uID As Long, ByVal uPeriod As Long, ByVal bChanged As Long) As Long
Public Declare Function joySetThreshold Lib "winmm.dll" Alias "joySetThreshold" (ByVal id As Long, ByVal uThreshold As Long) As Long

Ich denke, dass man also zuerst mit joyGetNumDevs versuchen sollte, herauszufinden, ob überhaupt ein Joystick vorhanden ist.
Um dann mittels joyGetPos herauszufinden, wo der Stick gerade steht.