We have about 40 ADC24s at customer sites, all running on windows XP. We are using a VB6 Application to switch one of the Digital Ouputs on and off.
When we run the application on XP, all works great, our application takes samples from 1 analog channel every 1- 30 seconds and the digital output can be switched on or off instantaneoulsy.
However, when we run the application in windows 7, 32 bit Pro edition, each time the digital ouput is told to switch on or off, the program hangs for about 8 seconds. At the end of the 8 seconds the ouput switches.
The problem seems to be where we are calling HRDLSetDigitalIOChannel, it takes about 8 seconds to return a value.
Here is the code we have that is calling it:
Private Sub TestLight()
Dim ret As Integer
If g_hADC = 0 Then Exit Sub
If g_TChannelReadings(0).ReadingDisplay >= g_oApp.LightONPressure And (Not g_oApp.fLightLit) Then
ret = HRDLSetDigitalIOChannel(g_hADC, 1, 1, 0)
g_oApp.fLightLit = True
If g_TChannelReadings(0).ReadingDisplay <= g_oApp.LightOFFPressure And (g_oApp.fLightLit) Then
ret = HRDLSetDigitalIOChannel(g_hADC, 1, 0, 0)
g_oApp.fLightLit = False
The function is declared thus:
Public Declare Function HRDLSetDigitalIOChannel Lib "PicoHRDL.dll" (ByVal handle As Integer, ByVal directionOut As Integer, ByVal digitalOutPinState As Integer, ByVal enabledDigitalIn As Integer) As Integer
We are currently using PICOHRDL.dll version 220.127.116.11 at the customer site on XP and it works fine.
On windows 7, we have tried this version upto the latest version (18.104.22.168) but none cause the DO to switch as it should.
We have also tried running in compatibility mode with no change.
Is this a known problem with windows 7?
Our client is currently in the process of moving up to windows 7 , so we could do with a hand to fix our problem before then.