diff options
Diffstat (limited to 'minion/src/wifi_module.hpp')
-rw-r--r-- | minion/src/wifi_module.hpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/minion/src/wifi_module.hpp b/minion/src/wifi_module.hpp index 5a4148c..3621229 100644 --- a/minion/src/wifi_module.hpp +++ b/minion/src/wifi_module.hpp @@ -6,6 +6,8 @@ constexpr auto MAX_NETWORK_MODULE_RESPONSE_LENGTH = 128U; +constexpr auto ASCII_TO_CHAR = 48U; + enum WifiMode { Station = 1, @@ -66,6 +68,21 @@ public: */ const char *get_local_ip(char *local_ip_out) noexcept; + bool has_incoming_request() noexcept; + + /** + * Reads a incoming HTTP request. + * + * @param raw_request_out Raw request output buffer. + * + * @returns The connection ID. + */ + size_t read_incoming_request(char *raw_request_out) noexcept; + + bool close_connection(size_t connection_id) noexcept; + + bool send(size_t connection_id, const char *data); + private: SoftwareSerial _serial; |