hyrichter you mentioned an interest in robotics. Here is a link to a cheap I/O board that works perfectly fine with dark basic http://www.awce.com/gp3.htm.
I used DBP_SerialPortMulti_exp.dll By CattleRustler and the styx plugin for the activeX.
Here is a small example of a program to controll the board.
REM Project: GP3_Controller
REM Created: 10/3/2007 8:33:40 AM
REM
REM ***** Main Source File *****
REM
sync on:sync rate 30
SET DISPLAY MODE 640,480,32
SET WINDOW ON
SET WINDOW SIZE 640,480
disable escapekey
global gTickStart
gTickStart = 0
global gTickNow
global gPWM5
global gADC4
if RegisterActiveXDLL("awcgp3dll.dll")
print "Dll Registered"
else
print "Dll Un-Registered"
endif
sync
if ClassAvailable("awcgp3dll.GP3DLL",1)
print "is correct class name"
else
print "is not correct class name"
endif
sync
if ClassExist(1)
print "class exist = true"
else
print "class exist = false"
endif
sync
OpenPort(1,1)
LedOn(1,1)
counter = 0
`****************************************Main Loop***************************
while escapekey()=0
cls
if rightkey()=1
ThrustFwd()
endif
counter = counter+1
text 0,100,str$(counter)
sync
if escapekey()=1 then CleanUp()
endwhile
`******************************************Clean Up
function CleanUp()
LedOn(1,0)
ClosePort(1,0)
if COM CLASS EXIST(1)
DELETE COM 1
endif
result = unregister dll("gp3.ocx")
if result = 1
print "Dll gp3.ocx UN-Registered"
else
print "Dll gp3.ocx Not-Found"
endif
sync
wait 2000
end
endfunction
function RegisterActiveXDLL(dll$)
result = register dll(dll$)
endfunction result
function ClassAvailable(class$,comnum)
result = COM class AVAILABLE(class$)
if result
LOAD COM CLASS class$,comnum
endif
endfunction result
function ClassExist(comnum)
result=COM CLASS EXIST(comnum)
endfunction result
function OpenPort(comnum,portnum)
SET COM integer comnum,"portopen",portnum
`CALL COM FUNC(1,"portopen","I"
endfunction
function ClosePort(comnum,portnum)
SET COM integer comnum,"portopen",portnum
endfunction
function LedOn(comnum,state)
SET COM integer comnum,"led",state
endfunction
function SetBlinkTime()
CALL COM FUNC 1,"setcounter","II",8,0
endfunction
function SetPinHigh(comnum,pin)
CALL COM FUNC comnum,"high","I",pin
endfunction
function SetPinLo(comnum,pin)
CALL COM FUNC comnum,"low","I",pin
endfunction
function SetPwm(comnum,channel,duty,freq)
CALL COM FUNC comnum,"pwm","III",channel,duty,freq
endfunction
function SetHWPwm(comnum,channel,freq)
CALL COM FUNC comnum,"pwm","II",channel,freq
endfunction
function RepeatCommand(comnum,count)
CALL COM FUNC comnum,"repeat","I",count
endfunction
function ResetGP3(comnum)
CALL COM FUNC comnum,"resetall"
endfunction
function ADC(comnum,channel)
result=CALL COM FUNC(comnum,"a2d","I",channel)
endfunction result
function Ready(comnum)
result=CALL COM FUNC(comnum,"ready")
endfunction result
function _OK(comnum)
result=CALL COM FUNC(comnum,"ok")
endfunction result
function ThrustFwd()
`if rightkey()=1
SetPwm(1,0,128,5000)
SetPwm(1,1,128,5000)
SetPwm(1,2,128,5000)
SetPwm(1,5,128,5000)
`SetPwm(1,3,128,5000)
`endif
endfunction