puzzlebox
Loading...
Searching...
No Matches
PBSocket Class Reference

Asynchronous puzzle box socket connection. More...

#include <sock.h>

Public Member Functions

 PBSocket (const char *addr, uint16_t port)
 Constructor that immediately calls set_server()
 
void set_server (const char *addr, uint16_t port)
 Configure target server.
 
void sock_connect ()
 Attempt to connect to server and start sock_task() in a thread.
 
void send (const char *buf, size_t buf_sz)
 Send data over the TCP connection.
 

Detailed Description

Note
Once connected, this class will call i2c_recv() when a complete I²C message has been received

Member Function Documentation

◆ send()

void PBSocket::send ( const char * buf,
size_t buf_sz )
Parameters
bufData to send
buf_szSize of buf in bytes

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