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:
- pannaannap
- Date:
- 2017-01-05
- Revision:
- 11:4c3876be77b1
- Parent:
- 7:e51d0fbb1a25
- Child:
- 27:27cffdb2e9d3
File content as of revision 11:4c3876be77b1:
#include "master.h"
#include "sensor_main.h"
#include "common.h"
#define MASTER 0
#define SLAVE1 1
// ATTENTION: choose mode in flag!
int main() {
switch(MODE) {
case MASTER:
master_loop();
break;
case SLAVE1:
// TODO vector of description for multiple sensors
// TODO sensor class
SensorDescription description(PIR1, PIR1_ADDRESS, MASTER_ADDRESS);
sensor_loop(description);
break;
}
return 0;
}