Trying to configure and write to two ports as outputs on daqpad 6507 using vb6.
First use DIG_SCAN_Setup (iDevice%,iGroup%,iGroupSize%,
iPortList%(0),iDir%)to configure ports.
idevice=1 'from MAX
igroup=1 'arbitrary def
igroupsize=2 'num of ports
iportlist(0)=0, iportlist(1)=1 'for ports 0 and 1. This is APA and APB respectively.
idir=1 'for output port.
This executes without error and if it is called again indicates config already has taken place. Call with group size 0 to "unconfig"
So far so good. Now use _Block_Out(iDevice%, iGroup%, piBuffer%(0),ulCount&)
piBuffer(0)=15 '(0xF)
piBuffer(1)=255 '(0xFF)
for data output of 0xFFF. this executes without error also. Then call
DIG_Block_Check(iDevice%, iGroup%, ulRemaining&)
ulRemaining& initially=1
in a loop but the problem is that ulRemaining stays=1 forever. Also trying to read inputs on ports 3 and 4 wired to these port 0 and 1 outputs using DIG_Block_In. Always returns zero and has same ulRemaining issue as DIG_Block_Out.
Appreciate any help. Thank you, Rick Beauchaine