I am trying to control a power supply that is connected to my com port through Visual Basic 6.0. The manufacturer of the power supply provided me with a dll and some bad instruction on how to use it. I think I have figured out how to talk to the dll but I am not able to get a connection. Here is the code that I am using to try to connect:
Private Declare Function MBConnect Lib "C:\DllTest\MBMASTER.dll" (ByVal CommPort As Integer, ByVal Timeout As Integer, ByVal BaudRate As String, ByVal Parity As Byte, ByVal StopBits As Byte, ByVal Handshake1 As Boolean, ByVal Handshake2 As Boolean) As Long
and I call the code like this:
Handle = MBConnect(1, 1000, 19200, 0, 2, False, False)
(Handle is supposed to return a key that I use in other commands to reference the connection)
Any ideas??
Private Declare Function MBConnect Lib "C:\DllTest\MBMASTER.dll" (ByVal CommPort As Integer, ByVal Timeout As Integer, ByVal BaudRate As String, ByVal Parity As Byte, ByVal StopBits As Byte, ByVal Handshake1 As Boolean, ByVal Handshake2 As Boolean) As Long
and I call the code like this:
Handle = MBConnect(1, 1000, 19200, 0, 2, False, False)
(Handle is supposed to return a key that I use in other commands to reference the connection)
Any ideas??