XBee and XBee-PRO ZigBee RF modules provide cost-effective wireless connectivity to electronic devices. They are interoperable with other ZigBee PRO feature set devices, including devices from other vendors.
Request/ATCommandRequest.cpp
- Committer:
- yangcq88517
- Date:
- 2015-10-22
- Revision:
- 0:837e6c48e90d
- Child:
- 6:5f31ddc17239
File content as of revision 0:837e6c48e90d:
#include "ATCommandRequest.h" ATCommandRequest::ATCommandRequest(char frameID, const char * command, const char * parameter, int offset, int length) : TxBase(2 + (parameter == NULL ? 0 : length), APIFrame::AT_Command, frameID) { set(command[0]); set(command[1]); if (parameter != NULL) sets(parameter, offset, length); } void ATCommandRequest::setAppleChanges(bool appleChanges) { if (appleChanges) setFrameType(APIFrame::AT_Command); else setFrameType(APIFrame::AT_Command_Queue_Parameter_Value); } void ATCommandRequest::setCommand(const char * command) { set(2, command[0]); set(3, command[1]); } void ATCommandRequest::setParameter(const char * parameter, int offset, int length) { setPosition(4); sets(parameter, offset, length); }