Functions#

This section provides a reference to the Firmware Upgrade API functions.

Functions#

sl_status_t
sl_si91x_http_otaf(uint8_t type, uint8_t flags, uint8_t *ip_address, uint16_t port, uint8_t *resource, uint8_t *host_name, uint8_t *extended_header, uint8_t *user_name, uint8_t *password, uint8_t *post_data, uint32_t post_data_length)

Post the HTTP data for the requested URL to HTTP server.This is a non-blocking API.

Function Documentation#

sl_si91x_http_otaf#

sl_status_t sl_si91x_http_otaf (uint8_t type, uint8_t flags, uint8_t * ip_address, uint16_t port, uint8_t * resource, uint8_t * host_name, uint8_t * extended_header, uint8_t * user_name, uint8_t * password, uint8_t * post_data, uint32_t post_data_length)

Post the HTTP data for the requested URL to HTTP server.This is a non-blocking API.

Parameters
[in]type

Valid values are: 0 - HTTPGET, 1 - HTTPPOST

[in]flags

Select version and security:

Flags

Macro

Description

BIT(0)

IPV6

Set this bit to enable IPv6, by default it is configured to IPv4.

BIT(1)

SSL_ENABLE

Set this bit to enable SSL feature.

BIT(2)

SI91X_TLS_V_1_0

Set this bit to support SSL TLS Version 1.0 if HTTPS is enabled.

BIT(3)

SI91X_TLS_V_1_2

Set this bit to support SSL_TLS Version 1.2 if HTTPS is enabled.

BIT(4)

SI91X_TLS_V_1_1

Set this bit to support SSL_TLS Version 1.1 if HTTPS is enabled.

BIT(6)

HTTP_V_1_1

Set this bit to use HTTP version 1.1

[in]ip_address

Server IP address.

[in]port

Port number. Default : 80 - HTTP, 443 - HTTPS

[in]resource

Requested resource URL in string format.

[in]host_name

Host name.

[in]extended_header

Extender header if present, after each header member append \r\n

[in]user_name

Username for server authentication.

[in]password

Password for server authentication.

[in]post_data

HTTP data to be posted to server.

[in]post_data_length

HTTP data length to be posted to server.

Returns


Definition at line 75 of file components/si91x/sl_net/protocols/firmware_upgrade/firmware_upgradation.h