I have a 24 GHz mmWave Human Static Presence Sensor. According to the manufacturer, it has a human detection range of up to 12 meters. My question is it possible to reduce this range to e.g. 3 meters?
If so, how to do it?
I see, but there is another thing. I found a second libary: Seeed-Studio-MR24FDB1-Sensor, where there is sample code in it called Physical_Parameters_Example. After running this code on the Serial Port Monitor I get the following data:
My question is how should I write the code so that I can control the LED depending on the received data, e.g. if the value is greater than 5, light the LED. From what I can see, the function that determines the value of the variable and the message to be printed is in the file named falldetectionradar.cpp I don't have much experience in programming, so I'm asking for help.
If I understand it correctly, that's it data frames sent by the radar. In the previously mentioned cpp file there is a fragment that defines this function:
#include <falldetectionradar.h>
#define LED 10
FallDetectionRadar radar;
void setup()
{
radar.SerialInit();
Serial.begin(9600);
pinMode(LED, OUTPUT);
delay(1500);
Serial.println("Readly");
}
void loop()
{
radar.recvRadarBytes(); //Receive radar data and start processing
if (radar.newData == true)
{ //The data is received and transferred to the new list dataMsg[]
byte dataMsg[radar.dataLen+1] = {0x00};
dataMsg[0] = 0x55; //Add the header frame as the first element of the array
for (byte n = 0; n < radar.dataLen; n++)dataMsg[n+1] = radar.Msg[n]; //Frame-by-frame transfer
radar.newData = false; //A complete set of data frames is saved
//radar.ShowData(dataMsg); //Serial port prints a set of received data frames
radar.Bodysign_judgment(dataMsg, 5, 10); //Output of human movement using sign parameters + możliwość ustawienia wartości, które dają dany efekt
if(fb >= 5)
{
digitalWrite (LED, HIGH) // Turn on LED
}
}
}
This exatcly the same code as in on of the examples which I mentioned earlier
Actually, I write that function to cpp. and it works. But it turned out that this program can only detect motion, not presence, which means I have to use something else Nevertheless, thank you very much for your help
The problem is in your selection of the radar sensor. It uses Doppler effect to detect motion, as ALL radar sensors do. You will have to find a radar the does not use Doppler effect.