creation of a fake station for testing

jd-update
flavienhaas 7 years ago
parent bfb7ffe288
commit 57e2e000d7

@ -32,14 +32,14 @@ void setup(){
Serial.println(Ethernet.localIP());
}
void SerialPrintElapsedTime( boolean espaceFinal=true ){ // to display the elapsed time
unsigned long h,m,s = millis()/1000;
m=s/60;
h=m/60;
s=s-(m*60);
m=m-(h*60);
Serial << ((h<10)?"0":"") << h << ":" << ((m<10)?"0":"") << m << ":" << ((s<10)?"0":"") << s << (espaceFinal?" ":"");
}
//void SerialPrintElapsedTime( boolean espaceFinal=true ){ // to display the elapsed time
// unsigned long h,m,s = millis()/1000;
// m=s/60;
// h=m/60;
// s=s-(m*60);
// m=m-(h*60);
// Serial << ((h<10)?"0":"") << h << ":" << ((m<10)?"0":"") << m << ":" << ((s<10)?"0":"") << s << (espaceFinal?" ":"");
//}
void loop() {
// LoRa receiver
@ -55,7 +55,7 @@ void loop() {
for( int i=0; i<longueurTrame; i++ ){
tampon[i]=(byte)LoRa.read();
}
SerialPrintElapsedTime(); // diplay the time the frame arrived
// SerialPrintElapsedTime(); // diplay the time the frame arrived
Serial.print("0x");
for( int i=0; i<longueurTrame; i++ ){ // display the frame in hexadecimal
if( tampon[i] < 0x0F ) Serial.print("0");

@ -0,0 +1,9 @@
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Loading…
Cancel
Save