Add simple HTTP server

This commit is contained in:
Kamil Trzcinski
2022-04-04 18:27:28 +02:00
parent c8fb6b0780
commit 317fb65508
5 changed files with 101 additions and 1 deletions

6
main.c
View File

@@ -3,6 +3,7 @@
#include "device.h"
#include "links.h"
#include "v4l2.h"
#include "http.h"
int camera_width = 1920;
int camera_height = 1080;
@@ -103,6 +104,11 @@ int main(int argc, char *argv[])
// return -1;
// }
int httpfd = http_listen(9090, 5);
if (httpfd >= 0) {
http_worker_threads(httpfd, 8);
}
bool running = false;
links_loop(links, &running);