XBee API operation library for mbed for miniprojects
Dependencies: SmartLabXBeeCore
Fork of SmartLabXBeeAPI2 by
Diff: XBeeAPI.h
- Revision:
- 5:da252d355673
- Parent:
- 2:723cccd7659a
diff -r 451ab26ae555 -r da252d355673 XBeeAPI.h --- a/XBeeAPI.h Mon Oct 26 18:04:30 2015 +0000 +++ b/XBeeAPI.h Fri Oct 30 00:39:31 2015 +0000 @@ -6,18 +6,18 @@ #include "CoreAPI.h" /** XBee API library entry poiont. -*Example: +* Example: * @code -*#include "mbed.h" -*#include "XBeeAPI.h" +* #include "mbed.h" +* #include "XBeeAPI.h" * -*XBeeAPI xbee(p9, p10, true); -*Address add(0x00,0x00,0x1022); -*XBeeTx16Request tx16(0x00, &add, &OptionsBase::DEFAULT, "Hello From XBEE API", 0, 19); -*XBeeRx16Indicator rx16(NULL); +* XBeeAPI xbee(p9, p10, true); +* Address add(0x0013A200,0x406CABD,0x0456); +* XBeeTx16Request tx16(0x00, &add, OptionsBase::DEFAULT, "Hello From XBEE API", 0, 19); +* XBeeRx16Indicator rx16(NULL); * -*int main() -*{ +* int main() +* { * xbee.setVerifyChecksum(false); * xbee.start(); * @@ -99,14 +99,14 @@ * frame = xbee.getResponse(); * } * } -*} -*@endcode +* } +* @endcode */ class XBeeAPI: public CoreAPI { public: - /** Create a XBeeAPI instance. + /** Create a XBeeAPI instance, with baud rate 9600 and no escape. * * @param tx data transmission line * @param rx data receiving line @@ -114,7 +114,7 @@ */ XBeeAPI(PinName tx, PinName rx); - /** Create a XBeeAPI instance. + /** Create a XBeeAPI instance, with baud rate 9600. * * @param tx data transmission line * @param rx data receiving line @@ -136,6 +136,7 @@ /** Create a SerialData instance with other serial interface. * * @param serial class that implementes ISerial interface. + * @param baudRate baud rate * @param isEscape API escaped operating mode (AP = 2) works similarly to API mode. The only difference is that when working in API escaped mode, some bytes of the API frame specific data must be escaped. * */