QtXBee::Wpan::RxResponseIoSampleBase Class Reference

#include <rxresponseiosamplebase.h>

Inheritance diagram for QtXBee::Wpan::RxResponseIoSampleBase:
QtXBee::Wpan::RxBaseResponse QtXBee::XBeeResponse QtXBee::XBeePacket QtXBee::Wpan::RxResponseIoSample16 QtXBee::Wpan::RxResponseIoSample64

Public Types

enum  Pin {
  ADC5 = 16384, ADC4 = 8192, ADC3 = 4096, ADC2 = 2048,
  ADC1 = 1024, ADC0 = 512, DIO8 = 256, DIO7 = 128,
  DIO6 = 64, DIO5 = 32, DIO4 = 16, DIO3 = 8,
  DIO2 = 4, DIO1 = 2, DIO0 = 1
}
 

Public Member Functions

 RxResponseIoSampleBase (QObject *parent=0)
 
virtual void clear ()
 Clears the packet by reseting all attributes to their default value. More...
 
virtual QString toString ()
 Returns a debug string containing all packet's informations. More...
 
void setChannelMask (ChannelMask mask)
 
ChannelMask channelMask () const
 
void setSampleCount (const quint8 count)
 
quint8 sampleCount () const
 
- Public Member Functions inherited from QtXBee::Wpan::RxBaseResponse
 RxBaseResponse (QObject *parent=0)
 
void setRSSI (const qint8 rssi)
 Sets the RSSI (Received Signal Strength Indication) More...
 
void setOptions (const quint8 options)
 
qint8 rssi () const
 Returns the RSSI (Received Signal Strength Indication) More...
 
quint8 options () const
 
- Public Member Functions inherited from QtXBee::XBeeResponse
 XBeeResponse (QObject *parent=0)
 XBeeResponse's constructor. More...
 
 ~XBeeResponse ()
 XBeeResponse's destructor.
 
void setData (const QByteArray &data)
 Sets the response's data. More...
 
QByteArray data () const
 Returns the response's data. More...
 
- Public Member Functions inherited from QtXBee::XBeePacket
 XBeePacket (QObject *parent=0)
 XBeePacket's constructor. More...
 
void setStartDelimiter (unsigned sd)
 Sets the frame's start delimiter. By default the start delemiter is set to 0x7E. More...
 
void setLength (unsigned length)
 Sets the frame's length. More...
 
void setFrameType (ApiId type)
 Sets the frame's type. More...
 
void setFrameId (quint8 id)
 Sets the frame's id. More...
 
void setChecksum (unsigned cs)
 Sets the checksum. More...
 
bool setPacket (const QByteArray &packet)
 Sets the packet's raw data. More...
 
QByteArray packet () const
 Returns the frame's packet (raw data) More...
 
unsigned startDelimiter () const
 Returns the frame's start delimiter. More...
 
quint16 length () const
 Returns the frame-specific data length (Number of bytes between the length and the checksum) More...
 
ApiId frameType () const
 Returns the frame's type. More...
 
quint8 frameId () const
 Returns the frame's id. More...
 
unsigned checksum () const
 Returns the packet's checksum. More...
 
virtual void assemblePacket ()
 Assembles the packet to be able to send it. More...
 
void escapePacket ()
 
bool unescapePacket ()
 

Protected Member Functions

virtual bool parseApiSpecificData (const QByteArray &data)
 Parses the packet API specific data. More...
 

Protected Attributes

quint8 m_samplesCount
 
ChannelMask m_channelMask
 
- Protected Attributes inherited from QtXBee::Wpan::RxBaseResponse
qint8 m_rssi
 
quint8 m_options
 
- Protected Attributes inherited from QtXBee::XBeeResponse
QByteArray m_data
 
- Protected Attributes inherited from QtXBee::XBeePacket
QByteArray m_packet
 

Additional Inherited Members

- Static Public Member Functions inherited from QtXBee::XBeePacket
static QString frameTypeToString (const ApiId type)
 Returns the given frame type ApiId into a human readable string. More...
 

Detailed Description

Todo:
Implement RxResponseIoSampleBase class
Note
Not implemented

Member Function Documentation

void QtXBee::Wpan::RxResponseIoSampleBase::clear ( )
virtual

Clears the packet by reseting all attributes to their default value.

Note
All subclass should reimplement this method.

Reimplemented from QtXBee::Wpan::RxBaseResponse.

bool QtXBee::Wpan::RxResponseIoSampleBase::parseApiSpecificData ( const QByteArray &  data)
protectedvirtual

Parses the packet API specific data.

Are conciderated as packet specific data, the data between API frame Id and checksum.

For example, the AT command response frame:

at_command_response_frame.jpg

The specific part is bytes [6 - (length() -1)] (AT command, Status, Value)

Parameters
data
Returns
true if succeeded; false otherwise.
Note
All subclasses must reimplement this method, which is called by XBeePacket::setPacket()

Reimplemented from QtXBee::XBeePacket.

QString QtXBee::Wpan::RxResponseIoSampleBase::toString ( )
virtual

Returns a debug string containing all packet's informations.

Returns
a debug string containing all packet's informations.

Reimplemented from QtXBee::Wpan::RxBaseResponse.


The documentation for this class was generated from the following files:
  • /home/thomas/Projects/QtXBee/src/qtxb/wpan/rxresponseiosamplebase.h
  • /home/thomas/Projects/QtXBee/src/qtxb/wpan/rxresponseiosamplebase.cpp