Committer:
yangcq88517
Date:
Wed Mar 30 19:58:48 2016 +0000
Revision:
8:4da2ac03e35e
put every thing together and documentation bug fix

Who changed what in which revision?

UserRevisionLine numberNew contents of line
yangcq88517 8:4da2ac03e35e 1 #include "RemoteCommandOptions.h"
yangcq88517 8:4da2ac03e35e 2
yangcq88517 8:4da2ac03e35e 3
yangcq88517 8:4da2ac03e35e 4 RemoteCommandOptions::RemoteCommandOptions()
yangcq88517 8:4da2ac03e35e 5 : TransmitOptions()
yangcq88517 8:4da2ac03e35e 6 { }
yangcq88517 8:4da2ac03e35e 7
yangcq88517 8:4da2ac03e35e 8 RemoteCommandOptions::RemoteCommandOptions(unsigned char option)
yangcq88517 8:4da2ac03e35e 9 : TransmitOptions(option)
yangcq88517 8:4da2ac03e35e 10 { }
yangcq88517 8:4da2ac03e35e 11
yangcq88517 8:4da2ac03e35e 12 RemoteCommandOptions::RemoteCommandOptions(bool disable_retries_and_route_repair, bool apply_changes, bool enable_APS_encryption, bool use_extended_transmission_timeout)
yangcq88517 8:4da2ac03e35e 13 : TransmitOptions(disable_retries_and_route_repair, enable_APS_encryption, use_extended_transmission_timeout)
yangcq88517 8:4da2ac03e35e 14 {
yangcq88517 8:4da2ac03e35e 15 if (apply_changes)
yangcq88517 8:4da2ac03e35e 16 value |= 0x02;
yangcq88517 8:4da2ac03e35e 17 }
yangcq88517 8:4da2ac03e35e 18
yangcq88517 8:4da2ac03e35e 19 RemoteCommandOptions * RemoteCommandOptions::ApplyChanges = new RemoteCommandOptions (0x02);
yangcq88517 8:4da2ac03e35e 20
yangcq88517 8:4da2ac03e35e 21 void RemoteCommandOptions::setApplyChanges(bool status)
yangcq88517 8:4da2ac03e35e 22 {
yangcq88517 8:4da2ac03e35e 23 if (status)
yangcq88517 8:4da2ac03e35e 24 value |= 0x02;
yangcq88517 8:4da2ac03e35e 25 else
yangcq88517 8:4da2ac03e35e 26 value &= 0xFD;
yangcq88517 8:4da2ac03e35e 27 }
yangcq88517 8:4da2ac03e35e 28
yangcq88517 8:4da2ac03e35e 29 bool RemoteCommandOptions::getApplyChanges()
yangcq88517 8:4da2ac03e35e 30 {
yangcq88517 8:4da2ac03e35e 31 if (value & 0x02 == 0x02)
yangcq88517 8:4da2ac03e35e 32 return true;
yangcq88517 8:4da2ac03e35e 33 else return false;
yangcq88517 8:4da2ac03e35e 34 }