Code Confidencebuild 3.0.0.201402161939

cyg_ppp_wait_up()

Name

cyg_ppp_wait_up -- Wait for PPP connection to come up

Synopsis

#include <cyg/ppp/ppp.h>
        

cyg_int32 cyg_ppp_wait_up(cyg_ppp_handle_t handle);

Description

This function waits until the PPP connection is running and then returns. This is needed because the actual bring up of the connection happens mostly after the call to cyg_ppp_up() returns, and may take some time to complete, especially if dialling a remote server.

The result of this call will be zero when the connection is running, or -1 if the connection failed to start for some reason. If the connection is already running when this call is made it will return immediately with a zero result. If the connection is not in the process of coming up, or has failed, or has terminated, then a result of -1 will be returned immediately. Thus this function may also be used to test that the connection is still running at any point.