Tiny protocol  0.9.0
Tiny communication protocol for microcontrollers
Public Member Functions | List of all members
Tiny::Packet< S > Class Template Reference

#include <TinyPacket.h>

Inheritance diagram for Tiny::Packet< S >:
Inheritance graph
[legend]
Collaboration diagram for Tiny::Packet< S >:
Collaboration graph
[legend]

Public Member Functions

 Packet ()
 
- Public Member Functions inherited from Tiny::IPacket
 IPacket (char *buf, size_t size)
 
virtual ~IPacket ()=default
 
void clear ()
 
void put (uint8_t byte)
 
void put (char chr)
 
void put (uint16_t data)
 
void put (uint32_t data)
 
void put (int16_t data)
 
void put (const char *str)
 
void put (const IPacket &pkt)
 
uint8_t getByte ()
 
char getChar ()
 
uint16_t getUint16 ()
 
int16_t getInt16 ()
 
uint32_t getUint32 ()
 
char * getString ()
 
size_t size () const
 
size_t maxSize () const
 
char * data ()
 
uint8_t & operator[] (size_t idx)
 
IPacketoperator= (char chr)
 

Detailed Description

template<size_t S>
class Tiny::Packet< S >

Template class to create packet with static allocation of buffer Use this class for microcontrollers with few resources.

Constructor & Destructor Documentation

◆ Packet()

template<size_t S>
Tiny::Packet< S >::Packet ( )
inline

Creates IPacket instance with statically allocated buffer


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