Functions | |
PCHAR | TcPortGetName (TC_PORT port) |
It returns the name of a given port. | |
TC_STATUS | TcPortQueryBoard (TC_PORT port, PTC_BOARD pBoard) |
It returns the board handle containing the given port. | |
PCHAR | TcPortGetDescription (TC_PORT port) |
It returns the description of a given port. | |
TC_STATUS | TcPortSetDescription (TC_PORT port, PCHAR pPortName) |
It sets the description of a given physical port. | |
TC_PORT_TYPE | TcPortGetType (TC_PORT port) |
It returns the type of a given port. | |
TC_STATUS | TcPortQueryMacAddress (TC_PORT port, BYTE pMac[6]) |
It queries a port for the MAC address. | |
TC_STATUS | TcPortQueryAggregatedPortList (TC_PORT aggregatingPort, PTC_PORT *ppPorts, PULONG pLength) |
It queries an aggregating port for the list of physical ports that it aggregates. | |
BOOLEAN | TcPortIsEqual (TC_PORT portA, TC_PORT portB) |
It compares two port handles to check if they correspond to the same port. | |
TC_STATUS | TcPortQueryLinkStatus (TC_PORT port, PTC_LINK_INFO pLinkInfo) |
Queries a port for the link status. | |
TC_STATUS | TcPortQueryStatistics (TC_PORT port, PTC_STATISTICS pStatistics) |
It queries the statistics of a physical port. | |
TC_STATUS | TcPortSetFeature (TC_PORT port, ULONG feature, ULONG value) |
It sets a specific feature on the port. | |
TC_STATUS | TcPortQueryFeature (TC_PORT port, ULONG feature, PULONG pValue) |
It queries a specific feature on the port. | |
TC_STATUS | TcPortSetAutonegotiationParameters (TC_PORT port, TC_AUTONEG_PARAMETERS autonegParameters) |
It sets the autonegotiation parameters of a physical port i.e. it enables/disables autonegotiation and controls which link speeds should be advertised during autonegotiation. | |
TC_STATUS | TcPortQueryAutonegotiationParameters (TC_PORT port, PTC_AUTONEG_PARAMETERS pAutonegParameters) |
It queries the autonegotiation parameters of a port i.e. if autonegotiation is enabled, which link speed be advertised during autonegotiation and which link speeds are supported by the port. |
PCHAR TcPortGetName | ( | TC_PORT | port | ) |
It returns the name of a given port.
port | The handle of a port to query for the name |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It returns the board handle containing the given port.
port | The handle of a port to query for the board | |
pBoard | Pointer to a board handle. On success it will contain the handle to the board. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
PCHAR TcPortGetDescription | ( | TC_PORT | port | ) |
It returns the description of a given port.
port | The handle of a port to get the description from. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It sets the description of a given physical port.
port | The handle of a port to set the description of. | |
pPortName | Pointer to a string containing the port description. |
Thread safety: this function is thread safe if called on different ports. Calling this function on the same port from multiple threads concurrently can lead to unexpected results.
TC_PORT_TYPE TcPortGetType | ( | TC_PORT | port | ) |
It returns the type of a given port.
port | The handle of a port to query for the type. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It queries a port for the MAC address.
port | The handle of a port to query for the MAC address | |
pMac | A caller allocated array of at least 6 bytes to hold the MAC address of the port. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
TC_STATUS TcPortQueryAggregatedPortList | ( | TC_PORT | aggregatingPort, | |
PTC_PORT * | ppPorts, | |||
PULONG | pLength | |||
) |
It queries an aggregating port for the list of physical ports that it aggregates.
aggregatingPort | The handle of a port to query. | |
ppPorts | Address of a caller allocated pointer to a TC_PORT. On success, the pointer will point to an array of port handles aggregated by the port. The returned list must not be freed. | |
pLength | Address of a caller allocated unsigned long. On success, it contains the number of entries in the array of port handles ppPorts. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It compares two port handles to check if they correspond to the same port.
portA | Handle to the first port | |
portB | Handle to the second port |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
TC_STATUS TcPortQueryLinkStatus | ( | TC_PORT | port, | |
PTC_LINK_INFO | pLinkInfo | |||
) |
Queries a port for the link status.
port | Handle to the port to query. | |
pLinkInfo | Pointer to a caller allocated TC_LINK_INFO structure. On success it contains the status of the link of the port. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
TC_STATUS TcPortQueryStatistics | ( | TC_PORT | port, | |
PTC_STATISTICS | pStatistics | |||
) |
It queries the statistics of a physical port.
port | Port handle | |
pStatistics | Pointer to a caller allocated statistics handle. On success it will return a valid statistics handle. In case of success, the returned statistics handle should be released with TcStatisticsDestroy. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It sets a specific feature on the port.
port | Port handle | |
feature | Identifier of the feature. A list of the available features can be found in section Features. | |
value | Value of the feature to be set. Please refer to the documentation of the specific feature you are trying to set in section Features. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
It queries a specific feature on the port.
port | Port handle | |
feature | Identifier of the feature. A list of the available features can be found in section Features. | |
pValue | Pointer to a 32bit integer. On success it will return the value of the feature. Please refer to the documentation in section Features to know what values can be returned by querying a specific feature. |
Thread safety: this function is thread safe i.e. it can be called from multiple threads concurrently.
TC_STATUS TcPortSetAutonegotiationParameters | ( | TC_PORT | port, | |
TC_AUTONEG_PARAMETERS | autonegParameters | |||
) |
It sets the autonegotiation parameters of a physical port i.e. it enables/disables autonegotiation and controls which link speeds should be advertised during autonegotiation.
port | Handle to a physical port. | |
autonegParameters | Parameters to enable/disable autonegotiation, set the advertised link speeds or force a link speed. Please refer to the documentation of TC_AUTONEG_PARAMETERS for details on autonegotiation. |
Thread safety: this function is thread safe if called on different port handles (TC_PORT). Calling this function on the same port from concurrent threads yields undefined results.
TC_STATUS TcPortQueryAutonegotiationParameters | ( | TC_PORT | port, | |
PTC_AUTONEG_PARAMETERS | pAutonegParameters | |||
) |
It queries the autonegotiation parameters of a port i.e. if autonegotiation is enabled, which link speed be advertised during autonegotiation and which link speeds are supported by the port.
port | Handle to a physical port. | |
pAutonegParameters | Address of a caller allocated TC_AUTONEG_PARAMETERS structure. On success it contain the current autonegotiation parameters. Please refer to the documentation of TC_AUTONEG_PARAMETERS for details on autonegotiation. |
Thread safety: this function is thread safe if called on different port handles (TC_PORT). Calling this function on the same port from concurrent threads yields undefined results.
TurboCap API documentation. Copyright (c) 2007-2008 CACE Technologies. All rights reserved.