The 3270 emulator should insert a message in a buffer and then call the DL-BASE to send it. The message contains source and destination LPIs, which are set up when the connection is opened; see LPI Connections for more information.
The application can either obtain a new buffer to contain the message to be sent (using sepdbubl), or reuse one in which it previously received a message. The application is responsible for any buffer it has obtained or in which it has received a message; it must either use (or reuse) the buffer to send a message or release it (using sepdburl). If the buffer to be reused does not contain the correct number of elements for the message to be sent, the application can obtain additional elements (using sbpibegt) or release existing ones (using sbpiberl); in this case, it must also ensure that the numelts field in the buffer header indicates the correct number of elements.
The function used to send the message is sbpusend.