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.
Diff: Device/Pin.cpp
- Revision:
- 6:5f31ddc17239
- Parent:
- 4:a0f1fba6c2fb
--- a/Device/Pin.cpp Thu Nov 05 23:03:42 2015 +0000 +++ b/Device/Pin.cpp Sat Nov 14 16:42:36 2015 +0000 @@ -1,13 +1,13 @@ #include "Pin.h" -char Pin::bitfield[2] = {0,0}; +unsigned char Pin::bitfield[2] = {0,0}; -Pin::Pin(char number) +Pin::Pin(unsigned char number) { num = number; } -Pin::Pin(char number, char msbCom, char lsbCom, char msbIODet, char lsbIODet) +Pin::Pin(unsigned char number, unsigned char msbCom, unsigned char lsbCom, unsigned char msbIODet, unsigned char lsbIODet) { num = number; com[0] = msbCom; @@ -16,7 +16,7 @@ IODet[1] = lsbIODet; } -char Pin::getNumber() +unsigned char Pin::getNumber() { return num; } @@ -26,7 +26,7 @@ return com; } -char * Pin::IOChangeDetectionConfiguration(Pin ** pins, char size) +unsigned char * Pin::IOChangeDetectionConfiguration(Pin ** pins, unsigned char size) { Pin::bitfield[0] = 0; Pin::bitfield[1] = 0; @@ -37,12 +37,12 @@ return Pin::bitfield; } -char * Pin::getIODetection() +unsigned char * Pin::getIODetection() { return IODet; } -bool operator <(const Pin &a,const Pin &b) +bool operator ==(const Pin &a,const Pin &b) { - return a.num < b.num; + return a.num == b.num; } \ No newline at end of file