mirror of
https://github.com/lumapu/ahoy.git
synced 2025-04-30 10:46:24 +02:00
No delay
This commit is contained in:
parent
dd085e4a69
commit
8030acd283
2 changed files with 4 additions and 2 deletions
|
@ -109,6 +109,7 @@ int main(int argc, char** argv)
|
||||||
dstaddrs.push_back(string("1Node"));
|
dstaddrs.push_back(string("1Node"));
|
||||||
dstaddrs.push_back(string("2Node"));
|
dstaddrs.push_back(string("2Node"));
|
||||||
dstaddrs.push_back(serno2shockburstaddrbytes(114174608145));
|
dstaddrs.push_back(serno2shockburstaddrbytes(114174608145));
|
||||||
|
dstaddrs.push_back("\x45\x81\x60\x74\x01");
|
||||||
dstaddrs.push_back(serno2shockburstaddrbytes(114174608177));
|
dstaddrs.push_back(serno2shockburstaddrbytes(114174608177));
|
||||||
|
|
||||||
// channels that we will scan
|
// channels that we will scan
|
||||||
|
@ -127,7 +128,7 @@ int main(int argc, char** argv)
|
||||||
cout << " - ";
|
cout << " - ";
|
||||||
}
|
}
|
||||||
cout << " " << flush;
|
cout << " " << flush;
|
||||||
delay(10);
|
//delay(10);
|
||||||
}
|
}
|
||||||
cout << endl;
|
cout << endl;
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include <time.h> // CLOCK_MONOTONIC_RAW, timespec, clock_gettime()
|
#include <time.h> // CLOCK_MONOTONIC_RAW, timespec, clock_gettime()
|
||||||
#include <RF24/RF24.h> // RF24, RF24_PA_LOW, delay()
|
#include <RF24/RF24.h> // RF24, RF24_PA_LOW, delay()
|
||||||
|
#include <unistd.h> // usleep()
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
|
@ -45,7 +46,7 @@ void receiveForever(int ch, string myaddr)
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
uint8_t pipe;
|
uint8_t pipe;
|
||||||
delay(500);
|
usleep(500000);
|
||||||
if (radio.failureDetected) {
|
if (radio.failureDetected) {
|
||||||
cout << "!f! " << flush;
|
cout << "!f! " << flush;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue