VERSION 1.0 CLASS
BEGIN
  MultiUse = -1  'True
END
Attribute VB_Name = "Port"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = True
Option Explicit
'*****************************************************************************
' Module:
'        Port.cls
'-----------------------------------------------------------------------------
' Description:
'        This file contains the properties and functions of this class.
'
'-----------------------------------------------------------------------------
' History:
'                 
'        Rev. Author         Date        Description
'        ---------------------------------------------------------------------
'        1.0  ste            29.09.99    final version
'        1.1  ste            17.02.00    three new properties added
'
'
'*****************************************************************************

Private vPort  As Variant
Private iFirstPin  As Integer
Private iLastPin  As Integer
Private sDescription  As String
' ste 17.02.00
Private iInputThresholdType  As Integer
Private iOutputEdgeType  As Integer
Private iOutputDriverType  As Integer


'*****************************************************************************
'Description:
'        This property returns the description of the port.
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        The description of the port.
'*****************************************************************************
Public Property Get Description() As String
    On Error Resume Next
    
    Description = sDescription
End Property

Public Property Let Description(sNew As String)
    On Error Resume Next

    sDescription = sNew
End Property


'*****************************************************************************
'Description:
'        This property returns the port number.
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        The port number.
'*****************************************************************************
Public Property Get PortNumber() As Variant
    On Error Resume Next
    
    PortNumber = vPort
End Property

Public Property Let PortNumber(vNew As Variant)
    On Error Resume Next

    vPort = vNew
End Property


'*****************************************************************************
'Description:
'        This property returns the first pin number from a port.
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        The first pin number.
'*****************************************************************************
Public Property Get FirstPin() As Integer
    On Error Resume Next
    
    FirstPin = iFirstPin
End Property

Public Property Let FirstPin(iNew As Integer)
    On Error Resume Next

    iFirstPin = iNew
End Property


'*****************************************************************************
'Description:
'        This property returns the last pin number from a port.
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        The last pin number.
'*****************************************************************************
Public Property Get LastPin() As Integer
    On Error Resume Next
    
    LastPin = iLastPin
End Property

Public Property Let LastPin(iNew As Integer)
    On Error Resume Next

    iLastPin = iNew
End Property


'*****************************************************************************
'Description:
'        This property sets/returns the input threshold type.
'        The type can be configured pin- (1), nible- (2), byte- (3) or port-wise (4)
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        Input threshold type 
'*****************************************************************************
Public Property Get InputThresholdType() As Integer
    On Error Resume Next
    
    InputThresholdType = iInputThresholdType
End Property

Public Property Let InputThresholdType(iNew As Integer)
    On Error Resume Next

    iInputThresholdType = iNew
End Property


'*****************************************************************************
'Description:
'        This property sets/returns the output edge characteristic type.
'        The type can be configured pin- (1), nible- (2), byte- (3) or port-wise (4)
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        Output edge characteristic type 
'*****************************************************************************
Public Property Get OutputEdgeType() As Integer
    On Error Resume Next
    
    OutputEdgeType = iOutputEdgeType
End Property

Public Property Let OutputEdgeType(iNew As Integer)
    On Error Resume Next

    iOutputEdgeType = iNew
End Property


'*****************************************************************************
'Description:
'        This property sets/returns the output driver characteristic type.
'        The type can be configured pin- (1), nible- (2), byte- (3) or port-wise (4)
'-----------------------------------------------------------------------------
'Parameters:
'-----------------------------------------------------------------------------
'Returns:
'        Output driver characteristic type 
'*****************************************************************************
Public Property Get OutputDriverType() As Integer
    On Error Resume Next
    
    OutputDriverType = iOutputDriverType
End Property

Public Property Let OutputDriverType(iNew As Integer)
    On Error Resume Next

    iOutputDriverType = iNew
End Property


Private Sub Class_Initialize()
End Sub

Private Sub Class_Terminate()
End Sub





