123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104 |
- #ifndef HTTP_SERVER_H_INCLUDED
- #define HTTP_SERVER_H_INCLUDED
- #include <stdio.h>
- #include <string.h>
- #include <stdlib.h>
- #include <stdbool.h>
- #include "wifi_manager.h"
- #include "freertos/FreeRTOS.h"
- #include "freertos/task.h"
- #include "freertos/event_groups.h"
- #include "esp_wifi.h"
- #include "esp_event_loop.h"
- #include "nvs_flash.h"
- #include "esp_log.h"
- #include "driver/gpio.h"
- #include "mdns.h"
- #include "lwip/api.h"
- #include "lwip/err.h"
- #include "lwip/netdb.h"
- #include "lwip/opt.h"
- #include "lwip/memp.h"
- #include "lwip/ip.h"
- #include "lwip/raw.h"
- #include "lwip/udp.h"
- #include "lwip/priv/api_msg.h"
- #include "lwip/priv/tcp_priv.h"
- #include "lwip/priv/tcpip_priv.h"
- #ifdef __cplusplus
- extern "C" {
- #endif
- void CODE_RAM_LOCATION http_server(void *pvParameters);
- void CODE_RAM_LOCATION http_server_netconn_serve(struct netconn *conn);
- void CODE_RAM_LOCATION http_server_start();
- char* CODE_RAM_LOCATION http_server_get_header(char *request, char *header_name, int *len);
- void CODE_RAM_LOCATION strreplace(char *src, char *str, char *rep);
- bool http_server_lock_json_object(TickType_t xTicksToWait);
- void http_server_unlock_json_object();
- #define PROTECTED_JSON_CALL(a) if(http_server_lock_json_object( portMAX_DELAY )){ \ a; http_server_unlocklock_json_object(); } else{ ESP_LOGE(TAG, "could not get access to json mutex in wifi_scan"); }
- #ifdef __cplusplus
- }
- #endif
- #endif
|