1 hour, open-source design LoRa infrared sensor terminal

Tip 1: Rui meter LoRa all products strictly follow the GB standard LoRaWAN agreement .
Tip 2: You are free to copy, modify and commercial of the project, please indicate sharp meters originality .
Tip 3: If you have other LoRa needs or suggestions, please contact Rui meters [email protected]

LoRa infrared sensor terminal

LoRa infrared sensor terminal

LoRa infrared sensor terminal may automatically detect the activities of the human body, based on LoRa transmitted to the server, can send alarm signals to the monitoring platform, and electrical equipment can be automatically controlled.
LoRa LoRaWAN infrared sensors Arduino open-source design

Components and materials

LoRa expansion boardLoRa expansion board x 1 purchase link
Arduino UNO Arduino UNO x 1 purchase link

Infrared sensor moduleX 1 infrared sensor module purchase link
buzzerbuzzer x 1 purchasing link
LEDthe LED x 1 purchase link
resistance220 x 1 ohm resistor purchase link
antennaantenna x 1 purchasing link
DuPont lineDupont line x 8 purchase link

Software and network

LoRa Gateway LoRa gateway purchase link
LoRaServerLoRaServer download link
LoRaAppLoRaApp download link
Arduino IDEArduino IDE download link

Project Introduction

Emergency protection of life and property, has been the basic needs of society.

LoRa 红外感应终端可自动探测人体的活动,既可向监控平台发送报警信号,又可以自动控制照明、空调等电器设备,以降低能耗和提升用户体验感。

LoRa 红外感应终端广泛应用于:住所、商铺、仓库、银行、办公室等场景。


红外防盗报警系统

Infrared anti-theft alarm system


空间检测
Space detection


丰富的应用场景
Rich application scenarios

相比传统的产品,LoRa 红外感应终端具备的优点为:

  • 安装简单便捷,不需要布线
  • 长距离通信,防止数据丢失
  • 超低功耗,2节5号电池工作数年

本项目开源设计 LoRa 红外感应终端的核心—软件和硬件,用户选择一个漂亮的外壳和电池,即可组成一个产品。
同时,简介了 LoRa 网络组件,轻松构建一个商用的安防物联网。

技术细节

元器件介绍

LoRa expansion board
这是专为 Arduino 而设计的 LoRa 扩展板,既可以安装在 Arduino UNO 上,也能使用杜邦线连接到 Arduino Pro Mini。

它能达到空旷 10km 的通信距离,休眠电流仅 1.3uA。精心设计的软件库,使其开发极为容易:

  • 发送数据
LoRa.write("123", 3);
  • 接收数据
if (LoRa.availabe()) { 
    len = LoRa.read(buf, MAX_LEN); 
}

Arduino UNO

Arduino UNO 是最常用的开发板,它便宜简单,接线方便。
Infrared sensor module
红外感应模块,采用数字智能热释电红外传感器,主要用于检测人体活动信息,感应角度 100 度,最大距离 12 米。
buzzer
有源压电式蜂鸣器,音量高达 90dB,宽范围供电 3~24v,性价比高。
antenna
470MHz 高频胶棒天线,增益 3.5dB,特别适合中国 LoRa 频段范围(470~510MHz)。

硬件接线

如下图所示,使用公对母的杜邦线连接 Arduino、红外感应模块、蜂鸣器、LED和电阻。
Wiring Diagram

通信逻辑

如下图所示,LoRa 红外感应终端上报人体活动事件给 App。

为此,需要配置如下的网络组件:

运行效果

如下图所示,侦测到安全区域内有人体活动,LoRa 终端进行声光报警,通过 LoRa 发送消息,App 显示本次感应事件。

ArduinoLoRa+红外感应演示视频

App operating results

行业第一的超低功耗—休眠仅 1.4uA

如下图所示(实物拍摄),ArduinoLoRa+ 的低功耗可达 1.4uA,这不仅是行业第一的超低功耗,而且达到了器件极限
Low power consumption up to 1.4uA
如下图所示,2 节 5 号碱性电池容量约 2890mAH,因为 LoRa 红外感应终端是”平时休眠,触发供电“,设平均 10 分钟工作一次,电池可工作近 9 年。终端电池寿命计算器
Battery life of nearly 9 years

Arduino 代码

编译本工程需要添加 LoRa 驱动库

使用 Arduino IDE 打开工程,点击"Sketch -> Include Library -> Add .ZIP Library…"

Arduino 的 zip 库安装路径一般为:C:\Users\Administrator\Documents\Arduino\libraries

Arduino 的代码简洁,容易理解,下载链接

/*
   PIR sketch
   a Passive Infrared motion sensor connected to pin 2
   lights the LED on pin 13
*/
#include <lora.h>

lora LoRa;

const int ledPin = 13;            // choose the pin for the LED
const int inputPin = 2;           // choose the input pin (for the PIR sensor)

void setup() 
{
  pinMode(ledPin, OUTPUT);         // declare LED as output
  pinMode(inputPin, INPUT);        // declare pushbutton as input
  Serial.begin(115200);            // for LoRa Node
}

void loop()
{
  boolean array[1];
    
  int val = digitalRead(inputPin);  // read input value
  if (HIGH == val)                  // check if the input is HIGH
  {
    array[0] = true;
    LoRa.write(array, sizeof(array[0]));  // report to LoRa Server that a motion detected

    digitalWrite(ledPin, HIGH);     // turn LED on if motion detected
    delay(3000);
    digitalWrite(ledPin, LOW);      // turn LED off
  }
}

低成本批量生产

LoRa 红外感应终端的硬件成本约 ¥60,这依赖于批量数目和供货渠道。

批量生产的一些技术挑战:尺寸,成本,功耗,烧录,升级
我们为您准备好解决方案:低成本快速开发LoRa终端:从1到10000

Published 134 original articles · won praise 330 · views 920 000 +

Guess you like

Origin blog.csdn.net/jiangjunjie_2005/article/details/103952676