# DioConfig.GetDInMask() method

Determines the bits on a specified port that are configured for input.

Member of the cDIOConfig class. Accessible from the MccBoard.DioConfig property.

## Function prototype

VB .NET:

Public Function GetDInMask(ByVal devNum As Integer, ByRef configVal As Integer) As MccDaq.ErrorInfo

C# .NET:

public MccDaq.ErrorInfo GetDInMask(int devNum, out int configVal)

## Parameters

devNum

Number of the port whose input bit configuration you want to determine.

configVal

Returns the bit configuration of the specified port. Any of the lower eight bits that return a value of 1 are configured for input.

## Returns

- An ErrorInfo object that indicates the status of the operation.

## Notes

Use GetDInMask() with the GetDOutMask() method to determine if an AuxPort is configurable. If you apply both methods to the same port, and both configVal parameters returned have input and output bits that overlap, the port is not configurable. You can determine overlapping bits by ANDing both parameters.

For example, the PCI-DAS08 has seven bits of digital I/O (four outputs and three inputs). For this board, the configVal parameter returned by GetDInMask()is always 7 (0000 0111), while the configVal parameter returned by GetDOutMask() is always 15 (0000 1111). When you And both configVal parameters together, you get a non-zero number (7). Any non-zero number indicates that input and output bits overlap for the specified port, and that port is a non-configurable AuxPort.