Configuration Options

Set the system configuration options in the file src/config/config_ip_app_httpc.h. This section lists the options and their default values.


The HTTP connection task stack size. The default value is 2048. All request (open, write, and close) and response (open, read, and close) functions are called from this task, so set the stack size accordingly.


The default server port. The default value is 80.


The maximum number of connections. The default value is 4.


The maximum transfer size a connection can send at a time. The default value is 2048. Depending on the size of the assigned buffers, this can be slightly increased.


The idle timeout. This is the time in seconds after which the connection is closed if there is no communication on it. The default value is 10.

Note:  For this timeout the precision is 500ms, so timeout may occur 500ms earlier.


The maximum file request buffer size. The default value is 128. The request buffer holds the request URI, the optional URL-encoded INPUT string.


The maximum request host buffer size. The default value is 64. The request buffer holds the host header value.

Note:  The following two options define the default parameters written to the request header.


The default header HTML version. The default value is "HTTP/1.1".  


The default user agent name. The default value is "HCC demo".


Keep the default of 0 to use the native HCC implementation. Set it to 1 to use the BSD socket implementation.

Note:  The following two options configure HTTP Secure connections.


Keep the default of 1 to enable HTTP Secure connections, otherwise set it to 0. This option must be enabled for dynamic variables. 


The HTTP secure connection transfer unit for socket connection. The default value is 1200.

This must be less than the maximum data that can be transferred by TLS in a single secure PDU.