ESPectre SDK 2.8.0-280-gac7af68
Wi-Fi CSI motion sensing for ESP32 firmware
Loading...
Searching...
No Matches
direct_websocket_protocol.h File Reference
#include <cstddef>
#include <string>

Go to the source code of this file.

Classes

struct  espectre::DirectWebSocketRequest

Namespaces

namespace  espectre

Functions

bool espectre::parse_direct_websocket_request (const std::string &payload, DirectWebSocketRequest *request, std::string *error=nullptr)
bool espectre::direct_websocket_request_to_command (const DirectWebSocketRequest &request, EspectreCommand *command, std::string *error=nullptr)
std::string espectre::direct_websocket_success_response (const std::string &id, const std::string &result_json="{}")
std::string espectre::direct_websocket_error_response (const std::string &id, const char *code, const char *message)
std::string espectre::direct_websocket_event (const char *event, const std::string &data_json)

Variables

constexpr const char * espectre::ESPECTRE_DIRECT_WEBSOCKET_ENDPOINT = "/espectre/v1/ws"
constexpr const char * espectre::ESPECTRE_DIRECT_WEBSOCKET_SUBPROTOCOL = "espectre.v1"
constexpr unsigned espectre::ESPECTRE_DIRECT_ENVELOPE_VERSION = 1U
constexpr size_t espectre::ESPECTRE_DIRECT_MAX_FRAME_SIZE = 4096U
constexpr size_t espectre::ESPECTRE_DIRECT_MAX_REQUEST_ID_SIZE = 64U
constexpr size_t espectre::ESPECTRE_DIRECT_MAX_METHOD_SIZE = 64U