com.partnersoft.interfaces.qualcomm
Class AutotracLib

java.lang.Object
  extended by com.partnersoft.interfaces.qualcomm.AutotracLib

public class AutotracLib
extends java.lang.Object

The raw interface to the DLL.

Author:
Russell Cagle Copyright 2007 Partner Software, Inc.

Field Summary
static byte CTRL_A
           
static byte CTRL_B
           
static byte CTRL_D
           
static byte CTRL_J
           
static byte CTRL_S
           
static java.lang.String dllName
          Should look for PartnerWin32.dll.
static int MACRO_TYPE_RETURN
           
static int MACRO_TYPE_SEND
           
static int MC_ASCII
           
static int MC_BINARY
           
static int MC_MACRO
           
 
Method Summary
static int AMPI_CloseLink(long serialDescriptor)
           
static int AMPI_GetLastError(long serialDescriptor)
           
static int AMPI_OpenLink(java.lang.String serialPort, long[] serialDescriptor)
          Returns the void* we get back in the array.
static int AMPI_ReceiveMessage(long serialDescriptor, int messageNumber, int receiptRequested, int dontMarkRead, MessageReceive message)
           
static int AMPI_RequestMacroDefinition(long serialDescriptor, int macroNumber, int macroType, MacroDefinition result)
          Returns the int we get back in the array.
static int AMPI_RequestMctPosition(long serialDescriptor, PositionMct result)
           
static int AMPI_RequestStatusMct(long serialDescriptor, StatusMct result)
           
static int AMPI_RequestStatusMessage(long serialDescriptor, int messageNumber, StatusMessage result)
           
static int AMPI_RequestStatusObcChannel(long serialDescriptor, StatusObc result)
           
static int AMPI_ResetCommunication(long serialDescriptor)
           
static int AMPI_SendMessage(long serialDescriptor, MessageSend message)
          When this function returns, the messageNumber field is filled in.
static int AMPI_SetLastError(long serialDescriptor, int lastError)
           
static int AMPI_SetTimeZone(long serialDescriptor, int timeZone)
           
static boolean checkNativeLibrary()
          Lazily loads the native library and returns success or failure.
static void main(java.lang.String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dllName

public static final java.lang.String dllName
Should look for PartnerWin32.dll.

See Also:
Constant Field Values

CTRL_A

public static final byte CTRL_A
See Also:
Constant Field Values

CTRL_B

public static final byte CTRL_B
See Also:
Constant Field Values

CTRL_D

public static final byte CTRL_D
See Also:
Constant Field Values

CTRL_J

public static final byte CTRL_J
See Also:
Constant Field Values

CTRL_S

public static final byte CTRL_S
See Also:
Constant Field Values

MACRO_TYPE_RETURN

public static int MACRO_TYPE_RETURN

MACRO_TYPE_SEND

public static int MACRO_TYPE_SEND

MC_ASCII

public static int MC_ASCII

MC_BINARY

public static int MC_BINARY

MC_MACRO

public static int MC_MACRO
Method Detail

checkNativeLibrary

public static boolean checkNativeLibrary()
Lazily loads the native library and returns success or failure. Only tries to load the library once; subsequent calls return the success or failure of the first call.


AMPI_CloseLink

public static int AMPI_CloseLink(long serialDescriptor)

AMPI_GetLastError

public static int AMPI_GetLastError(long serialDescriptor)

AMPI_OpenLink

public static int AMPI_OpenLink(java.lang.String serialPort,
                                long[] serialDescriptor)
Returns the void* we get back in the array. The array must be 1 element long. Throws an exception if we get an error code.

Parameters:
serialDescriptor -
Returns:

AMPI_ReceiveMessage

public static int AMPI_ReceiveMessage(long serialDescriptor,
                                      int messageNumber,
                                      int receiptRequested,
                                      int dontMarkRead,
                                      MessageReceive message)
Parameters:
serialDescriptor -
Returns:

AMPI_RequestMacroDefinition

public static int AMPI_RequestMacroDefinition(long serialDescriptor,
                                              int macroNumber,
                                              int macroType,
                                              MacroDefinition result)
Returns the int we get back in the array. The array must be 1 element long.

Parameters:
serialDescriptor -
Returns:

AMPI_RequestMctPosition

public static int AMPI_RequestMctPosition(long serialDescriptor,
                                          PositionMct result)

AMPI_RequestStatusMct

public static int AMPI_RequestStatusMct(long serialDescriptor,
                                        StatusMct result)

AMPI_RequestStatusMessage

public static int AMPI_RequestStatusMessage(long serialDescriptor,
                                            int messageNumber,
                                            StatusMessage result)

AMPI_RequestStatusObcChannel

public static int AMPI_RequestStatusObcChannel(long serialDescriptor,
                                               StatusObc result)

AMPI_ResetCommunication

public static int AMPI_ResetCommunication(long serialDescriptor)

AMPI_SendMessage

public static int AMPI_SendMessage(long serialDescriptor,
                                   MessageSend message)
When this function returns, the messageNumber field is filled in.

Parameters:
serialDescriptor -
message -
Returns:

AMPI_SetTimeZone

public static int AMPI_SetTimeZone(long serialDescriptor,
                                   int timeZone)

AMPI_SetLastError

public static int AMPI_SetLastError(long serialDescriptor,
                                    int lastError)

main

public static void main(java.lang.String[] args)