Microchip® Advanced Software Framework

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Provisioning

Data Structures

struct  _scanitem
 Store the scan list and then later populate when creating the database. More...
 
struct  at_ble_wifiprov_complete_ind
 
struct  at_ble_wifiprov_scan_mode_change_ind_t
 
struct  wifiprov_scanlist_ind
 

Typedefs

typedef struct _scanitem scanitem
 Store the scan list and then later populate when creating the database. More...
 
typedef struct _scanitem scanitem
 Store the scan list and then later populate when creating the database. More...
 

Enumerations

enum  {
  WIFIPROV_CONFIGURE_REQ = 0xDC00,
  WIFIPROV_CONFIGURE_CFM,
  WIFIPROV_CREATE_DB_REQ,
  WIFIPROV_CREATE_DB_CFM,
  WIFIPROV_START_CMD,
  WIFIPROV_DISABLE_CMD,
  WIFIPROV_COMPLETE_IND,
  WIFIPROV_SCANLIST_IND,
  WIFIPROV_CONNECTION_STATE_CHANGE_IND,
  WIFIPROV_SCAN_MODE_CHANGE_IND
}
 Messages from APP to WiFi Provisioning Profile. More...
 
enum  {
  WIFIPROV_SCANMODE_INIT = 0,
  WIFIPROV_SCANMODE_SCANNING = 1,
  WIFIPROV_SCANMODE_DONE
}
 WIFIPROV_SCANMODE. More...
 
enum  {
  WIFIPROV_CON_STATE_DISCONNECTED,
  WIFIPROV_CON_STATE_CONNECTING,
  WIFIPROV_CON_STATE_CONNECTED
}
 
enum  {
  WIFIPROV_CONFIGURE_REQ = 0xDC00,
  WIFIPROV_CONFIGURE_CFM,
  WIFIPROV_CREATE_DB_REQ,
  WIFIPROV_CREATE_DB_CFM,
  WIFIPROV_START_CMD,
  WIFIPROV_DISABLE_CMD,
  WIFIPROV_COMPLETE_IND,
  WIFIPROV_SCANLIST_IND,
  WIFIPROV_CONNECTION_STATE_CHANGE_IND,
  WIFIPROV_SCAN_MODE_CHANGE_IND
}
 Messages from APP to WiFi Provisioning Profile. More...
 
enum  {
  WIFIPROV_SCANMODE_INIT = 0,
  WIFIPROV_SCANMODE_SCANNING = 1,
  WIFIPROV_SCANMODE_DONE
}
 WIFIPROV_SCANMODE. More...
 
enum  {
  WIFIPROV_CON_STATE_DISCONNECTED,
  WIFIPROV_CON_STATE_CONNECTING,
  WIFIPROV_CON_STATE_CONNECTED
}
 

Functions

void wifiprov_complete_ind_handler (uint8_t *data, at_ble_wifiprov_complete_ind *param)
 Provisioning complete handler. More...
 
at_ble_status_t wifiprov_configure_provisioning (uint8_t *localname, at_ble_auth_t lauthtype)
 Configure provisioning. More...
 
at_ble_status_t wifiprov_create_db (void)
 Create provisioning database. More...
 
at_ble_status_t wifiprov_disable (void)
 Disable provisioning. More...
 
at_ble_status_t wifiprov_scan_list_ind_send (struct wifiprov_scanlist_ind *param)
 wifiprov_scan_list_ind_send More...
 
void wifiprov_scan_mode_change_ind_handler (uint8_t *data, at_ble_wifiprov_scan_mode_change_ind_t *param)
 [Internal API] wifiprov_scan_mode_change_ind_handler More...
 
at_ble_status_t wifiprov_scan_mode_change_ind_send (uint8_t scanmode)
 wifiprov_scan_mode_change_ind_send More...
 
at_ble_status_t wifiprov_start (uint8_t *pin, uint8_t len)
 Start provisioning. More...
 
at_ble_status_t wifiprov_wifi_con_update (uint8_t con_state)
 wifiprov_wifi_con_update More...
 

typedef struct _scanitem scanitem

Store the scan list and then later populate when creating the database.

typedef struct _scanitem scanitem

Store the scan list and then later populate when creating the database.

anonymous enum

Messages from APP to WiFi Provisioning Profile.

Enumerator
WIFIPROV_CONFIGURE_REQ 
WIFIPROV_CONFIGURE_CFM 
WIFIPROV_CREATE_DB_REQ 

Add WIFIPROV into the database.

WIFIPROV_CREATE_DB_CFM 

Inform APP about DB creation status.

WIFIPROV_START_CMD 

Start provisioning.

WIFIPROV_DISABLE_CMD 

Disable provisioning (eg timeout, bonding fail or bad provisioning details)

WIFIPROV_COMPLETE_IND 

Provisioning complete (success or fail)

WIFIPROV_SCANLIST_IND 

Receiving scanlist from Wifi side.

WIFIPROV_CONNECTION_STATE_CHANGE_IND 

Inform APP about_connection_state changes.

WIFIPROV_SCAN_MODE_CHANGE_IND 

Inform App about Scan Mode changes.

anonymous enum

WIFIPROV_SCANMODE.

When scan mode is used to send indication from App to the WiFi Prov profile, WIFIPROV_SCANMODE_SCANNING indicates Scanning is in progress WIFIPROV_SCANMODE_DONE indicates scanning is completed - note that this indication should only be used when no scan results were obtained during the scan These result in the database being updated When scan mode is used to send indication from WiFi Prov profile to the App, WIFIPROV_SCANMODE_SCANNING request to start WiFi scanning and supply scan results

Enumerator
WIFIPROV_SCANMODE_INIT 
WIFIPROV_SCANMODE_SCANNING 

Scanning is indicated as in progress.

WIFIPROV_SCANMODE_DONE 

Scanning is indicated as complete.

anonymous enum
Enumerator
WIFIPROV_CON_STATE_DISCONNECTED 
WIFIPROV_CON_STATE_CONNECTING 
WIFIPROV_CON_STATE_CONNECTED 
anonymous enum

Messages from APP to WiFi Provisioning Profile.

Enumerator
WIFIPROV_CONFIGURE_REQ 
WIFIPROV_CONFIGURE_CFM 
WIFIPROV_CREATE_DB_REQ 

Add WIFIPROV into the database.

WIFIPROV_CREATE_DB_CFM 

Inform APP about DB creation status.

WIFIPROV_START_CMD 

Start provisioning.

WIFIPROV_DISABLE_CMD 

Disable provisioning (eg timeout, bonding fail or bad provisioning details)

WIFIPROV_COMPLETE_IND 

Provisioning complete (success or fail)

WIFIPROV_SCANLIST_IND 

Receiving scanlist from Wifi side.

WIFIPROV_CONNECTION_STATE_CHANGE_IND 

Inform APP about_connection_state changes.

WIFIPROV_SCAN_MODE_CHANGE_IND 

Inform App about Scan Mode changes.

anonymous enum

WIFIPROV_SCANMODE.

When scan mode is used to send indication from App to the WiFi Prov profile, WIFIPROV_SCANMODE_SCANNING indicates Scanning is in progress WIFIPROV_SCANMODE_DONE indicates scanning is completed - note that this indication should only be used when no scan results were obtained during the scan These result in the database being updated When scan mode is used to send indication from WiFi Prov profile to the App, WIFIPROV_SCANMODE_SCANNING request to start WiFi scanning and supply scan results

Enumerator
WIFIPROV_SCANMODE_INIT 
WIFIPROV_SCANMODE_SCANNING 

Scanning is indicated as in progress.

WIFIPROV_SCANMODE_DONE 

Scanning is indicated as complete.

anonymous enum
Enumerator
WIFIPROV_CON_STATE_DISCONNECTED 
WIFIPROV_CON_STATE_CONNECTING 
WIFIPROV_CON_STATE_CONNECTED 

at_ble_status_t wifiprov_configure_provisioning ( uint8_t *  localname,
at_ble_auth_t  lauthtype 
)

Configure provisioning.

Parameters
[in]localnamemust be a null terminated string
[in]lauthtypeauth type to be used for provisioning
Returns
AT_BLE_SUCCESS
AT_BLE_FAILURE
Parameters
[in]localnamemust be a null terminated string
Returns
AT_BLE_SUCCESS
AT_BLE_FAILURE

References AT_BLE_FAILURE, INTERFACE_MSG_DONE, INTERFACE_MSG_INIT, INTERFACE_PACK_ARG_BLOCK, INTERFACE_PACK_ARG_UINT8, INTERFACE_SEND_WAIT, INTERFACE_UNPACK_UINT8, MAX_LOCALNAME_LENGTH, TASK_WIFIPROV, WIFIPROV_CONFIGURE_CFM, and WIFIPROV_CONFIGURE_REQ.

Referenced by ble_prov_init().

at_ble_status_t wifiprov_disable ( void  )

Disable provisioning.

If connected, disconnect, if advertising stop advertising.

Returns
AT_BLE_SUCCESS
AT_BLE_FAILURE

References INTERFACE_MSG_DONE, INTERFACE_MSG_INIT, INTERFACE_SEND_NO_WAIT, status, TASK_WIFIPROV, and WIFIPROV_DISABLE_CMD.

Referenced by ble_prov_stop().

at_ble_status_t wifiprov_scan_list_ind_send ( struct wifiprov_scanlist_ind param)
void wifiprov_scan_mode_change_ind_handler ( uint8_t *  data,
at_ble_wifiprov_scan_mode_change_ind_t param 
)

[Internal API] wifiprov_scan_mode_change_ind_handler

Scan mode has changed notification

Parameters
[in]data
[in]paramWIFIPROV_SCANMODE_SCANNING WIFIPROV_SCANMODE_DONE
Returns
none.

References INTERFACE_UNPACK_DONE, INTERFACE_UNPACK_INIT, INTERFACE_UNPACK_UINT8, and at_ble_wifiprov_scan_mode_change_ind_t::scanmode.

Referenced by handle_ble_event().

at_ble_status_t wifiprov_scan_mode_change_ind_send ( uint8_t  scanmode)
at_ble_status_t wifiprov_start ( uint8_t *  pin,
uint8_t  len 
)

Start provisioning.

If idle then start

Parameters
[in]pin6 digit decimal PIN
[in]len
Returns
AT_BLE_SUCCESS
AT_BLE_FAILURE

References INTERFACE_MSG_DONE, INTERFACE_MSG_INIT, INTERFACE_PACK_ARG_BLOCK, INTERFACE_SEND_NO_WAIT, status, TASK_WIFIPROV, and WIFIPROV_START_CMD.

Referenced by ble_prov_start().

at_ble_status_t wifiprov_wifi_con_update ( uint8_t  con_state)