XBee API operation library for mbed
Embed:
(wiki syntax)
Show/hide line numbers
RemoteCommandOptions.cpp
00001 #include "RemoteCommandOptions.h" 00002 00003 00004 RemoteCommandOptions::RemoteCommandOptions() 00005 : TransmitOptions() 00006 { } 00007 00008 RemoteCommandOptions::RemoteCommandOptions(unsigned char option) 00009 : TransmitOptions(option) 00010 { } 00011 00012 RemoteCommandOptions::RemoteCommandOptions(bool disable_retries_and_route_repair, bool apply_changes, bool enable_APS_encryption, bool use_extended_transmission_timeout) 00013 : TransmitOptions(disable_retries_and_route_repair, enable_APS_encryption, use_extended_transmission_timeout) 00014 { 00015 if (apply_changes) 00016 value |= 0x02; 00017 } 00018 00019 RemoteCommandOptions * RemoteCommandOptions::ApplyChanges = new RemoteCommandOptions (0x02); 00020 00021 void RemoteCommandOptions::setApplyChanges(bool status) 00022 { 00023 if (status) 00024 value |= 0x02; 00025 else 00026 value &= 0xFD; 00027 } 00028 00029 bool RemoteCommandOptions::getApplyChanges() 00030 { 00031 if (value & 0x02 == 0x02) 00032 return true; 00033 else return false; 00034 }
Generated on Tue Jul 12 2022 11:17:04 by 1.7.2