Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp
- Committer:
- HBP
- Date:
- 2011-03-01
- Revision:
- 0:265bb7b57633
File content as of revision 0:265bb7b57633:
#include "mbed.h"
Serial xbee1(p9, p10);
Serial pc(USBTX, USBRX);
uint32_t i=0;
void readxBee()
{
char c;
i++;
//if(xbee1.readable())
//{
xbee1.scanf("%c", &c);
pc.printf("%c", c);
//}
if(c == '?')
{
xbee1.printf("i=%u\n\r", i);
}
}
int main() {
xbee1.attach(&readxBee, Serial::RxIrq);
}