TMEndSession Overview Group

The TMEndSession API call ends the session on the 1-Wire network that was designated by the session handle 'session_handle'. It returns a 1 if the session specified by 'session_handle' was successfully closed, and 0 if there was no valid session established with the specified session handle.


short far pascal TMEndSession(

long session_handle// 1-Wire network session handle
);

For a description of the above types, see the TMEX Type Descriptions.

Parameters

session_handle

Specifies session handle on an 1-Wire network. The session handle must be set as a result of a call to TMExtendedStartSession.

Return Value

0 => session_handle already invalid

1 => session ended, session_handle no longer valid

<0 => TMEX Session Error Return Codes

Code Example

See Also

TMExtendedStartSession, TMValidSession