Microchip® Advanced Software Framework

task_http.c File Reference

HTTP component task for the HTTP Netconn Example.

Copyright (c) 2013-2018 Microchip Technology Inc. and its subsidiaries.

#include "task_defs.h"
#include "stdio_serial.h"
#include "ethernet.h"
#include "sysclk.h"
#include "lwip/opt.h"
#include "lwip/tcpip.h"
#include "httpd.h"
#include "tc.h"
#include "lwip/stats.h"

Functions

static void configure_timer_for_bandwidth_stats (void)
 Enable TC1 channel 0 to trigger each second to compute GMAC stats. More...
 
void create_http_task (uint16_t stack_depth_words, unsigned portBASE_TYPE task_priority)
 Create the HTTP task. More...
 
static void http_task (void *pvParameters)
 HTTP task core function. More...
 
void TC3_Handler (void)
 

Variables

uint32_t lwip_rx_count
 
uint32_t lwip_rx_rate
 
uint32_t lwip_tx_count
 Used to compute LwIP bandwidth. More...
 
uint32_t lwip_tx_rate
 

static void configure_timer_for_bandwidth_stats ( void  )
static

Enable TC1 channel 0 to trigger each second to compute GMAC stats.

References pmc_enable_periph_clk(), tc_enable_interrupt(), tc_init(), tc_start(), and tc_write_rc().

Referenced by http_task().

void create_http_task ( uint16_t  stack_depth_words,
unsigned portBASE_TYPE  task_priority 
)

Create the HTTP task.

Parameters
stack_depth_wordsTask stack size in 32 bits word.
task_priorityTask priority.

References http_task(), NULL, and xTaskCreate.

Referenced by main().

uint32_t lwip_rx_count
uint32_t lwip_rx_rate

Referenced by cgi_status(), and TC3_Handler().

uint32_t lwip_tx_count

Used to compute LwIP bandwidth.

Used to compute LwIP bandwidth.

Referenced by ksz8851snl_low_level_output(), and TC3_Handler().

uint32_t lwip_tx_rate

Referenced by cgi_status(), and TC3_Handler().