Braille Glove
 
Loading...
Searching...
No Matches
WifiSlave Class Reference

< Include for TCP server More...

#include <WifiSlave.h>

Public Member Functions

 WifiSlave (GloveModel gloveModel)
 Constructs a WifiSlave object with a given glove model.
 
void setup ()
 Standard setup function for the Wi-Fi slave.
 
void loop ()
 Standard loop function for the Wi-Fi slave.
 
void processMessage (const uint8_t *mac, const uint8_t *buf, size_t count)
 Processes the received message.
 

Static Public Member Functions

static void onReceiveCallback (const uint8_t *mac, const uint8_t *buf, size_t count, void *arg)
 Callback function for handling received data.
 

Detailed Description

< Include for TCP server

This class defines the behavior of a WiFi slave device, including receiving data via Wi-Fi and processing it to control actuators.

Constructor & Destructor Documentation

◆ WifiSlave()

WifiSlave::WifiSlave ( GloveModel gloveModel)

Constructs a WifiSlave object with a given glove model.

Parameters
gloveModelThe glove model to be used for actuator control and pattern execution.

Member Function Documentation

◆ loop()

void WifiSlave::loop ( )

Standard loop function for the Wi-Fi slave.

Continuously handles incoming data and controls the actuators accordingly.

◆ onReceiveCallback()

void WifiSlave::onReceiveCallback ( const uint8_t * mac,
const uint8_t * buf,
size_t count,
void * arg )
static

Callback function for handling received data.

This function is called when data is received via Wi-Fi. It identifies the type of data and processes it accordingly.

Parameters
macThe MAC address of the sender.
bufThe received data buffer.
countThe number of bytes received.
argAdditional argument passed to the callback (not used here).

◆ processMessage()

void WifiSlave::processMessage ( const uint8_t * mac,
const uint8_t * buf,
size_t count )

Processes the received message.

This function processes the message and takes the appropriate actions based on the content of the message.

Parameters
macThe MAC address of the sender.
bufThe received data buffer.
countThe number of bytes received.

◆ setup()

void WifiSlave::setup ( )

Standard setup function for the Wi-Fi slave.

Initializes necessary components for Wi-Fi communication and the glove model.


The documentation for this class was generated from the following files: