G
GraemeR
Hi, when I execute the following call (on an iPAQ Pocket PC) nothing happens
to the RS232 cable I'm using.
<System.Runtime.InteropServices.DllImport("coredll.dll")> _
Private Shared Function CreateFile( _
ByVal lpFileName As String, _
ByVal dwDesiredAccess As Integer, _
ByVal dwShareMode As Integer, _
ByVal lpSecurityAttributes As Integer, _
ByVal dwCreationDisposition As Integer, _
ByVal dwFlagsAndAttributes As Integer, _
ByVal hTemplateFile As Integer) As Integer
End Function
Public Sub openPort()
mhRS = CreateFile("COM1:", GENERIC_READ Or GENERIC_WRITE, 0, 0,
OPEN_EXISTING, 0, 0)
End Sub
Mappling the DllImport to "kernal32.dll" and compiling+executing as a
Windows application causes RS232 cable to light up.
Is there some massaging I need to do to get the Pocket PC serial port to
behave as the desktop port does?
Note: I can verify that the port and cable work by using the CEWedge
application http://www.taltech.com/products/cewedge.html
Thanks for advice you can offer, Graeme.
to the RS232 cable I'm using.
<System.Runtime.InteropServices.DllImport("coredll.dll")> _
Private Shared Function CreateFile( _
ByVal lpFileName As String, _
ByVal dwDesiredAccess As Integer, _
ByVal dwShareMode As Integer, _
ByVal lpSecurityAttributes As Integer, _
ByVal dwCreationDisposition As Integer, _
ByVal dwFlagsAndAttributes As Integer, _
ByVal hTemplateFile As Integer) As Integer
End Function
Public Sub openPort()
mhRS = CreateFile("COM1:", GENERIC_READ Or GENERIC_WRITE, 0, 0,
OPEN_EXISTING, 0, 0)
End Sub
Mappling the DllImport to "kernal32.dll" and compiling+executing as a
Windows application causes RS232 cable to light up.
Is there some massaging I need to do to get the Pocket PC serial port to
behave as the desktop port does?
Note: I can verify that the port and cable work by using the CEWedge
application http://www.taltech.com/products/cewedge.html
Thanks for advice you can offer, Graeme.