//Fall information output
void FallDetectionRadar::Fall_inf(byte inf[]){
switch(inf[3]){
case REPORT_FALL:
switch(inf[4]){
case ALARM:
ShowData(inf);
switch(inf[5]){
case ALARM_FALL:
switch (inf[6]){
case SUSPECTED_FALL:
Serial.println("A suspected fall was detected.");
break;
case REAL_FALL:
Serial.println("A real fall was detected.");
break;
case NO_FALL:
Serial.println("A no fall was detected.");
break;
}
break;
case ALARM_RESIDUAL:
switch (inf[6]){
case NONE:
Serial.println("No warning message at this time.");
break;
case FIRST:
Serial.println("First warning prompt.");
break;
case SENCOND:
Serial.println("Second warning prompt.");
break;
case THIRD:
Serial.println("Third warning prompt.");
break;
case FORTH:
Serial.println("Fourth warning prompt.");
break;
}
break;
}
Serial.println("----------------------------");
break;
}
break;
}
}
Sir why this code is not working
when i run this code we get only this
55 8 0 6 1 1 2 CE 54
15:28:48.878 -> A no fall was detected.
15:28:48.878 -> ----------------------------
15:29:34.118 -> 55 A 0 4 3 5 1 1 1 9D 4
15:29:34.247 -> 55 16 0 4 1 2 47 32 34 56 44 31 53 59 1 D 0 0 0 8 8D 3 0
15:29:34.340 -> 55 16 0 4 1 2 47 32 34 56 44 31 53 1 0 0 31 30 31 30 35 82 D5
15:29:34.565 -> 55 8 0 3 4 C 7 1A A
15:29:34.754 -> 55 A 0 4 3 5 0 FF FF D 24
15:29:34.979 -> 55 B 0 4 3 6 0 0 0 0 DD 95
15:29:35.214 -> 55 8 0 6 1 1 2 CE 54
15:29:35.214 -> 55 8 0 6 1 1 2 CE 54
15:29:35.214 -> A no fall was detected.
15:29:35.214 -> ----------------------------
15:29:35.402 -> 55 8 0 3 5 C 2 8B C9
15:29:35.658 -> 55 8 0 5 1 1 0 4F D1
15:29:35.739 -> 55 8 0 5 3 8 3 A8 40
15:29:35.973 -> 55 B 0 5 4 2 0 0 0 0 3D 22
15:29:36.302 -> 55 8 0 3 5 D 1 CA 58
15:29:36.518 -> 55 8 0 4 5 A F 48 D8
15:29:37.418 -> 55 A 0 4 5 1 0 FF FF 84 14
15:29:39.431 -> 55 B 0 4 3 6 0 0 0 0 DD 95
15:29:49.545 -> 55 B 0 4 3 6 0 0 80 3F FC 45
15:29:51.679 -> 55 B 0 4 3 6 0 0 80 3F FC 45
15:29:53.585 -> 55 B 0 4 3 6 0 0 80 3F FC 45
15:29:56.621 -> 55 B 0 4 3 6 0 0 80 3F FC 45
15:29:58.668 -> 55 A 0 4 3 5 1 1 1 9D 4
15:29:59.659 -> 55 A 0 4 3 7 1 1 3 1D 7D
15:30:00.831 -> 55 B 0 4 3 6 0 0 0 40 DC 65
15:30:02.614 -> 55 B 0 4 3 6 0 0 D0 41 40 65
15:30:03.722 -> 55 B 0 4 3 6 0 0 5C 42 64 A4
15:30:05.714 -> 55 B 0 4 3 6 0 0 8C 42 39 64
15:30:06.823 -> 55 B 0 4 3 6 0 0 A8 41 62 65
15:30:08.755 -> 55 B 0 4 3 6 0 0 A0 42 25 A4
15:30:10.761 -> 55 B 0 4 3 6 0 0 96 42 32 4
15:30:12.804 -> 55 B 0 4 3 6 0 0 30 42 49 A4
//Fall information output void FallDetectionRadar::Fall_inf(byte inf[]){ switch(inf[3]){ case REPORT_FALL: switch(inf[4]){ case ALARM: ShowData(inf); switch(inf[5]){ case ALARM_FALL: switch (inf[6]){ case SUSPECTED_FALL: Serial.println("A suspected fall was detected."); break; case REAL_FALL: Serial.println("A real fall was detected."); break; case NO_FALL: Serial.println("A no fall was detected."); break; } break; case ALARM_RESIDUAL: switch (inf[6]){ case NONE: Serial.println("No warning message at this time."); break; case FIRST: Serial.println("First warning prompt."); break; case SENCOND: Serial.println("Second warning prompt."); break; case THIRD: Serial.println("Third warning prompt."); break; case FORTH: Serial.println("Fourth warning prompt."); break; } break; } Serial.println("----------------------------"); break; } break; } }
Sir why this code is not working
when i run this code we get only this
55 8 0 6 1 1 2 CE 54 15:28:48.878 -> A no fall was detected. 15:28:48.878 -> ---------------------------- 15:29:34.118 -> 55 A 0 4 3 5 1 1 1 9D 4 15:29:34.247 -> 55 16 0 4 1 2 47 32 34 56 44 31 53 59 1 D 0 0 0 8 8D 3 0 15:29:34.340 -> 55 16 0 4 1 2 47 32 34 56 44 31 53 1 0 0 31 30 31 30 35 82 D5 15:29:34.565 -> 55 8 0 3 4 C 7 1A A 15:29:34.754 -> 55 A 0 4 3 5 0 FF FF D 24 15:29:34.979 -> 55 B 0 4 3 6 0 0 0 0 DD 95 15:29:35.214 -> 55 8 0 6 1 1 2 CE 54 15:29:35.214 -> 55 8 0 6 1 1 2 CE 54 15:29:35.214 -> A no fall was detected. 15:29:35.214 -> ---------------------------- 15:29:35.402 -> 55 8 0 3 5 C 2 8B C9 15:29:35.658 -> 55 8 0 5 1 1 0 4F D1 15:29:35.739 -> 55 8 0 5 3 8 3 A8 40 15:29:35.973 -> 55 B 0 5 4 2 0 0 0 0 3D 22 15:29:36.302 -> 55 8 0 3 5 D 1 CA 58 15:29:36.518 -> 55 8 0 4 5 A F 48 D8 15:29:37.418 -> 55 A 0 4 5 1 0 FF FF 84 14 15:29:39.431 -> 55 B 0 4 3 6 0 0 0 0 DD 95 15:29:49.545 -> 55 B 0 4 3 6 0 0 80 3F FC 45 15:29:51.679 -> 55 B 0 4 3 6 0 0 80 3F FC 45 15:29:53.585 -> 55 B 0 4 3 6 0 0 80 3F FC 45 15:29:56.621 -> 55 B 0 4 3 6 0 0 80 3F FC 45 15:29:58.668 -> 55 A 0 4 3 5 1 1 1 9D 4 15:29:59.659 -> 55 A 0 4 3 7 1 1 3 1D 7D 15:30:00.831 -> 55 B 0 4 3 6 0 0 0 40 DC 65 15:30:02.614 -> 55 B 0 4 3 6 0 0 D0 41 40 65 15:30:03.722 -> 55 B 0 4 3 6 0 0 5C 42 64 A4 15:30:05.714 -> 55 B 0 4 3 6 0 0 8C 42 39 64 15:30:06.823 -> 55 B 0 4 3 6 0 0 A8 41 62 65 15:30:08.755 -> 55 B 0 4 3 6 0 0 A0 42 25 A4 15:30:10.761 -> 55 B 0 4 3 6 0 0 96 42 32 4 15:30:12.804 -> 55 B 0 4 3 6 0 0 30 42 49 A4