Yeah it seems like the program is going to fast for it since your program keeps calling the PERFORM CHECKLIST FOR CONTROL DEVICES command every loop resulting in the crash. For some reason I can't return a 1 with checklist value a() when I test my gamepad.
BUT, code below works for me. Instead of checking constantly, I call the Input_DefaultController() function with the spacebar.
I do agree that DBPro should not crash like that though. It should be able to handle a constant check like that. I'll take a look at the DBPro Google source code that I have and see if I can spot something quick. If I can find something I'll post the c++ code change that I did in your Bug Report thread.
Also, I noticed that we need to somehow clear the "JoyStick Information" when the user unplugs the game device. Mine keeps the same info when I unplug my gamepad and then call the Input_DefaultController() function again.
sync on
sync rate 60
autocam off
make camera 1
color backdrop 1,0
GLOBAL quantity as INTEGER
quantity=0
Do
if spacekey()=1 and space_key=0
Input_DefaultController()
space_key=1
endif
if spacekey()=0 and space_key=1
space_key=0
endif
text 10, 10, "Press spacebar to check for control devices..."
text 10, 20, "quantity:"+str$(quantity)
text 10, 30, CONTROL DEVICE NAME$()
For i = 0 to 30
text 10, 40+(i*10), Str$(JoyStick Information(i))
Next i
sync
loop
Function Input_DefaultController()
empty checklist
PERFORM CHECKLIST FOR CONTROL DEVICES
quantity=checklist quantity()
if quantity>0
SET CONTROL DEVICE checklist string$(quantity)
endif
EndFunction