Web Setup

Functions for enabling/disabling web setup. More...

Modules

Types
Data types for web setup.
 

Functions

gos_result_t gos_setup_start (void)
 Start web setup. More...
 
gos_result_t gos_setup_stop (void)
 Stop web setup. More...
 
gos_result_t gos_setup_register_client_event_handler (gos_setup_client_event_t handler)
 Register setup client event handler. More...
 
gos_result_t gos_setup_register_finished_event_handler (gos_handler_t handler)
 Register web setup finished event handler. More...
 
const char * gos_setup_get_client_os_str (const gos_softap_client_t *client)
 Return the Setup Client's Operating System string. More...
 

Detailed Description

Functions for enabling/disabling web setup.

Function Documentation

◆ gos_setup_get_client_os_str()

const char* gos_setup_get_client_os_str ( const gos_softap_client_t client)

Return the Setup Client's Operating System string.

When the setup client connects to the HTTP server it supplies its operating system type, gos_setup_os_type_t . This API will convert gos_setup_os_type_t to a printable string.

Parameters
clientSetup client return by gos_setup_register_client_event_handler()
Returns
String representation of client's OS

◆ gos_setup_register_client_event_handler()

gos_result_t gos_setup_register_client_event_handler ( gos_setup_client_event_t  handler)

Register setup client event handler.

Register an event handler to execute when a client connects/disconnects AND when a client connects to the HTTP server. See gos_setup_client_event_t for more info.

Note
The event handler executes in the app thread context
Parameters
handlerEvent handler to execute on client connect/disconnect
Returns
gos_result_t, result of API call

◆ gos_setup_register_finished_event_handler()

gos_result_t gos_setup_register_finished_event_handler ( gos_handler_t  handler)

Register web setup finished event handler.

Register an event handler to execute when web setup finishes. Web setup can finish by the following ways:

Note
The event handler executes in the app thread context
Returns
gos_result_t, result of API call

◆ gos_setup_start()

gos_result_t gos_setup_start ( void  )

Start web setup.

See Gecko OS Command API documentation: setup web

See also Gecko OS Web App

Note
If no clients connect then setup will timeout after a configurable timeout. See the variable setup.web.idle_timeout
Returns
gos_result_t, result of API call

◆ gos_setup_stop()

gos_result_t gos_setup_stop ( void  )

Stop web setup.

See Gecko OS Command API documentation: setup stop

Returns
gos_result_t, result of API call