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.

Dependencies:   BufferedArray

Dependents:   MBEDminiproject

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers OptionsBase.cpp Source File

OptionsBase.cpp

00001 #include "OptionsBase.h"
00002 
00003 OptionsBase::OptionsBase()
00004 {
00005     value = 0x00;
00006 }
00007 
00008 OptionsBase::OptionsBase(unsigned char option)
00009 {
00010     value = option;
00011 }
00012 
00013 OptionsBase * OptionsBase::DEFAULT = new OptionsBase();
00014 
00015 OptionsBase * OptionsBase::DisableRetriesRouteRepair = new OptionsBase(0x01);
00016 
00017 bool OptionsBase::getDisableRetriesRouteRepair()
00018 {
00019     if ((value & 0x01) == 0x01)
00020         return true;
00021     else return false;
00022 }
00023 
00024 void OptionsBase::setDisableRetriesRouteRepair(bool status)
00025 {
00026     if (status)
00027         value |= 0x01;
00028     else
00029         value &= 0xFE;
00030 }
00031 
00032 unsigned char OptionsBase::getValue()
00033 {
00034     return value;
00035 }