main/task_http.h

Wed, 03 Jul 2024 20:01:31 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Wed, 03 Jul 2024 20:01:31 +0200
branch
idf 5.1
changeset 142
1f7069278fe7
parent 0
b74b0e4902c3
permissions
-rw-r--r--

Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.

0
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
1 /**
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
2 * @file task_http.h
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
3 * @brief HTTP and Websocket server functions.
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
4 */
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
5
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
6 #ifndef _TASK_HTTP_H
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
7 #define _TASK_HTTP_H
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
8
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
9
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
10 /**
142
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
11 * @brief Send text to client with the set number.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
12 * @param num The client connection number.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
13 * @param msg The message to send.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
14 * @param len The length of the message to send.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
15 * @return 1 if message send.
0
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
16 */
142
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
17 int ws_server_send_text_client(int num, char* msg);
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
18
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
19
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
20 /**
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
21 * @brief Sends text to all clients with the set url.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
22 * @param msg The message to send.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
23 * @return The number of clients the message was send to.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
24 */
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
25 int ws_server_send_text_clients(char* msg);
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
26
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
27
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
28 /**
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
29 * @brief Install the HTTP/Websocket server.
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
30 */
1f7069278fe7 Version 0.4.2. Removed the components/websocket server and switched to the official http and websockets server. This server will also recover if the wifi connection disconnects and reconnects.
Michiel Broek <mbroek@mbse.eu>
parents: 0
diff changeset
31 void install_http_server(void);
0
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
32
b74b0e4902c3 Initial checkin brewboard
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
33 #endif

mercurial