Hello
I should interface Seeed sensor Module MR24HPB1 ,Human Stationary Presence Radar Sensor with ESP32 C3 board
#include <radar.h>
#ifdef AVR
** #include <SoftwareSerial.h>**
** SoftwareSerial SSerial(2, 3); // RX, TX**
** #define Serial1 SSerial**
#endif
#define MESSAGE_HEAD 0x55
int data[14] = {0};
int i = 0;
int Msg;
int Situation_action;
radar RADAR;
void setup()
{
** Serial1.begin(115200);**
** Serial.begin(115200);**
** Serial.println(“Readly”);**
}
void Bodysign_judgment(int ad1, int ad2, int ad3, int ad4, int ad5){
** float s;**
** s = RADAR.Bodysign_val(ad1, ad2, ad3, ad4, ad5);**
** if(s > 1.5 && s < 35){**
** Serial.println(“SOMEBODY STOP”);**
** }**
** else if(s < 1.5){**
** Serial.println(“NOBODY”);**
** }**
** else if(s > 35){**
** Serial.println(“SOMEBODY MOVE”);**
** }**
}
void loop()
{
** Serial.println(“Readly 40”);**
** Msg = Serial1.read();**
** delay(1000);**
** delay(1000);**
** if(Msg == MESSAGE_HEAD){**
** Serial.println(“Readly 47”);**
** for(i = 0; i<14; i++){**
** data[i] = Msg; **
** Msg = Serial1.read();**
** Serial.println(“Readly 46”);**
** if (Msg == MESSAGE_HEAD){**
** RADAR.Situation_judgment(data[5], data[6], data[7], data[8], data[9]); //雷达数据解码**
** if (Situation_action = 1){**
** Serial.println(“radar said nobody”);**
** }**
** if (Situation_action = 2){**
** Serial.println(“radar said somebody move”);**
** }**
** if (Situation_action = 3){**
** Serial.println(“radar said somebody stop”);**
** }**
** if (Situation_action = 4){**
** Serial.println(“radar said no move”);**
** }**
** if (Situation_action = 5){**
** Serial.println(“radar said somebody close”);**
** }**
** if (Situation_action = 6){**
** Serial.println(“radar said somebody away”);**
** } **
** continue;**
** }**
** delay(25);**
** }**
** }**
This library i will be using GitHub - Seeed-Studio/Seeed_Arduino_24GHz_Radar_Sensor
I found issues
ESP-ROM:esp32c3-api1-20210207