fiatlux/firmware/web.cpp

35 lines
579 B
C++
Raw Normal View History

2021-07-02 16:45:29 +00:00
//
// Created by jedi on 25.06.21.
2021-07-18 23:25:27 +00:00
//
#include "web.h"
#include "system.h"
#include "lux.h"
#include "wifi.h"
#include <cstring>
#include <FreeRTOS.h>
#include <task.h>
extern "C" {
#include <sysparam.h>
#include <lwipopts.h>
}
#include <espressif/esp_common.h>
#include <lwip/tcp.h>
extern "C" {
#include <httpd/httpd.h>
}
extern "C" [[noreturn]] void httpd_task(void *pvParameters) {
while(!uxSemaphoreGetCount( wifi_available_semaphore ))
vTaskDelay(500 / portTICK_PERIOD_MS);
httpd_init();
for (;;)
vTaskDelay(500 / portTICK_PERIOD_MS);
}