dc735501a63fe80b48033fb5f3c6404e7adfeb8c
Board-dat/NBL/NBL1107-dat/NBL1107-dat.md
| ... | ... | @@ -19,12 +19,7 @@ |
| 19 | 19 | |
| 20 | 20 | |
| 21 | 21 | |
| 22 | -## Board Map |
|
| 23 | - |
|
| 24 | - |
|
| 25 | - |
|
| 26 | - |
|
| 27 | -board version V2 |
|
| 22 | +## Board Map board version V2 |
|
| 28 | 23 | |
| 29 | 24 | green box == [[relay-signal-dat]] // orange box == BT module [[NBL1101-dat]] // the rest == [[MCU-dat]] - [[HC32F003-dat]] |
| 30 | 25 | |
| ... | ... | @@ -50,25 +45,25 @@ green box == [[relay-signal-dat]] // orange box == BT module [[NBL1101-dat]] // |
| 50 | 45 | |
| 51 | 46 | |
| 52 | 47 | |
| 53 | -| pin | MCU pins | BT Modules | Sensors | Other | |
|
| 54 | -| --- | ---------- | ---------- | ---------- | -------------------- | |
|
| 55 | -| 1 | Reset | | | Button Reset or PROG | |
|
| 56 | -| 2 | U0_TXD | BT_RXD | | | |
|
| 57 | -| 3 | U0_RXD | BT_TXD | | | |
|
| 58 | -| 7 | P03 | - | - | NC | |
|
| 59 | -| 8 | P15 | BT_IN2 | | | |
|
| 60 | -| 9 | P14 | BT_IN1 | | | |
|
| 61 | -| 10 | P23 | BT_stat | | | |
|
| 62 | -| 11 | P24 | | | Button Alternative | |
|
| 63 | -| 12 | P25 | | Sensor SDA | | |
|
| 64 | -| 13 | P26 | | Sensor SCL | | |
|
| 65 | -| 14 | P27 | | | lead out free | |
|
| 66 | -| 15 | P31 | | | lead out free | |
|
| 67 | -| 16 | P32 | BT_PWRC | | | |
|
| 68 | -| 17 | P33 | | | Bat_ADC | |
|
| 69 | -| 18 | P34 | | | Relay | |
|
| 70 | -| 19 | P35_U1_TXD | | | free or PROG | |
|
| 71 | -| 20 | P36_U1_RXD | | | free or PROG | |
|
| 48 | +| pin | MCU pins | Peripherals | Note | |
|
| 49 | +| --- | ---------- | ----------- | -------------------- | |
|
| 50 | +| 1 | Reset | alt._reset | Button Reset or PROG | |
|
| 51 | +| 2 | U0_TXD | BT_RXD | via jumper | |
|
| 52 | +| 3 | U0_RXD | BT_TXD | via jumper | |
|
| 53 | +| 7 | P03 | - | NC | |
|
| 54 | +| 8 | P15 | BT_IN2 | | |
|
| 55 | +| 9 | P14 | BT_IN1 | | |
|
| 56 | +| 10 | P23 | BT_stat | | |
|
| 57 | +| 11 | P24 | alt._button | Button Alternative | |
|
| 58 | +| 12 | P25 | Sensor SDA | | |
|
| 59 | +| 13 | P26 | Sensor SCL | | |
|
| 60 | +| 14 | P27 | | NC | |
|
| 61 | +| 15 | P31 | | NC | |
|
| 62 | +| 16 | P32 | BT_PWRC | | |
|
| 63 | +| 17 | P33 | Bat_ADC | | |
|
| 64 | +| 18 | P34 | Relay | | |
|
| 65 | +| 19 | P35_U1_TXD | | NC, free or PROG | |
|
| 66 | +| 20 | P36_U1_RXD | | NC, free or PROG | |
|
| 72 | 67 | |
| 73 | 68 | |
| 74 | 69 | |
| ... | ... | @@ -85,6 +80,7 @@ green box == [[relay-signal-dat]] // orange box == BT module [[NBL1101-dat]] // |
| 85 | 80 | |
| 86 | 81 |  |
| 87 | 82 | |
| 83 | +demo code - [[HDSC-SDK-dat]] - [[HC32F003-dat]] - https://github.com/Edragon/MCU-HDSC-APP |
|
| 88 | 84 | |
| 89 | 85 | ## ref |
| 90 | 86 |
Chip-cn-dat/EY-dat/EY-25M-dat/EY-25M-dat.md
| ... | ... | @@ -10,13 +10,17 @@ |
| 10 | 10 | - 电源(1.8-3.6V) |
| 11 | 11 | - baudrate default 9600bps |
| 12 | 12 | |
| 13 | +- [[mesh-node-dat]] - [[EY-25M-mesh-dat.md]] - [[EY-25M-dat]] |
|
| 14 | + |
|
| 15 | +- [[ibeacon-dat]] - [[keyfab-dat]] - [[DTU-dat]] - [[IO-panel-dat]] - [[IOs-dat]] - [[GPIO-dat]] |
|
| 16 | + |
|
| 13 | 17 | |
| 14 | 18 | ## boards |
| 15 | 19 | |
| 16 | 20 | |
| 17 | 21 |  |
| 18 | 22 | |
| 19 | -- [[NBL1101-dat]] - [[NBL1107-dat]] |
|
| 23 | +- [[NBL1101-dat]] - [[NBL1107-dat]] - [[EY-25M-dat]] |
|
| 20 | 24 | |
| 21 | 25 | |
| 22 | 26 | |
| ... | ... | @@ -129,6 +133,19 @@ |
| 129 | 133 | | | | AT+CUIO | +CUIO=0,0,0,0,0, | |
| 130 | 134 | |
| 131 | 135 | |
| 136 | +### mesh data send |
|
| 137 | + |
|
| 138 | +Example: `41 54 2b 4d 45 53 48` 00 ff ff 11 22 33 `0d 0a` |
|
| 139 | + |
|
| 140 | + 41 54 2b 4d 45 53 48 00 ff ff 11 22 33 0d 0a |
|
| 141 | + |
|
| 142 | +Instruction: The red part (`41 54 2b 4d 45 53 48`) is hexadecimal data of AT+MESH. The example function is to |
|
| 143 | +send broadcast data to all devices in the target network. The broadcast data content is: `11 22 33` |
|
| 144 | + |
|
| 145 | +As there are too many functions of MESH network, it will not be described in detail in this document. Please refer |
|
| 146 | +to the document of Instructions for use of mesh. PDF. |
|
| 147 | + |
|
| 148 | + |
|
| 132 | 149 | ## UUID |
| 133 | 150 | |
| 134 | 151 | UUID List |
| ... | ... | @@ -211,6 +228,10 @@ Control the OUT1 pin of target 0008 to be low level, and there is an ACK respons |
| 211 | 228 | |
| 212 | 229 | 41 54 2b 4d 45 53 48 11 00 08 AA B2 E7 01 00 |
| 213 | 230 | |
| 231 | + |
|
| 232 | + |
|
| 233 | + |
|
| 234 | + |
|
| 214 | 235 | ## ref |
| 215 | 236 | |
| 216 | 237 | - [[BLE-dat]] |
Chip-cn-dat/EY-dat/EY-25M-dat/EY-25M-mesh-dat.md
| ... | ... | @@ -0,0 +1,71 @@ |
| 1 | + |
|
| 2 | + |
|
| 3 | +# EY-25M-mesh-dat.md |
|
| 4 | + |
|
| 5 | +- [[mesh-node-dat]] - [[EY-25M-mesh-dat.md]] - [[EY-25M-dat]] |
|
| 6 | + |
|
| 7 | + |
|
| 8 | +## MESH Networking Module Configuration Guide |
|
| 9 | + |
|
| 10 | +The module defaults to **MESH networking mode**, so manual setup is typically unnecessary for standard use. To manually configure the MESH mode, send the command `AT+ROLE5`, followed by `AT+RESET` to restart the device and apply changes. |
|
| 11 | + |
|
| 12 | +--- |
|
| 13 | + |
|
| 14 | +## 1. Configuration Examples |
|
| 15 | + |
|
| 16 | +### Example 1: Routing Node Configuration |
|
| 17 | +This setup configures the device as a standard routing node capable of controlling other devices in the network via hardware buttons. |
|
| 18 | + |
|
| 19 | +1. **Set Network ID (NETID) to 1122:** `AT+NETID1122` |
|
| 20 | +2. **Set Local Short Address to 0005:** `AT+MADDR0005` |
|
| 21 | +3. **Set Node Class to Routing Node:** `AT+MCLSS0` |
|
| 22 | +4. **Configure KEY1 Broadcast:** `AT+KEY1,0008,3,1` |
|
| 23 | + *Configures KEY1 to broadcast a signal that controls the **OUT3** output on all devices.* |
|
| 24 | +5. **Apply Changes:** `AT+RESET` |
|
| 25 | + *Result: KEY1 can now control the OUT3 IO levels of all devices in the network.* |
|
| 26 | + |
|
| 27 | +### Example 2: Low-Power Terminal Node |
|
| 28 | +Ideal for battery-operated devices. In this mode, the device consumes only **3µA**. |
|
| 29 | + |
|
| 30 | +1. **Set Network ID (NETID) to 1122:** `AT+NETID1122` |
|
| 31 | +2. **Set Local Short Address to 0005:** `AT+MADDR0005` |
|
| 32 | +3. **Set Node Class to Low-Power Terminal:** `AT+MCLSS1` |
|
| 33 | +4. **Configure KEY1 Broadcast:** `AT+KEY1,0008,3,1` |
|
| 34 | +5. **Apply Changes:** `AT+RESET` |
|
| 35 | + *Behavior: Data is sent when the key is pressed; the device enters **Deep Sleep** immediately upon key release.* |
|
| 36 | + |
|
| 37 | +### Example 3: Routing Node with Manual Hex Commands |
|
| 38 | +Configure the device as a router and send raw data to the network. |
|
| 39 | + |
|
| 40 | +1. **Set Network ID (NETID) to 1122:** `AT+NETID1122` |
|
| 41 | +2. **Set Local Short Address to 0005:** `AT+MADDR0005` |
|
| 42 | +3. **Set Node Class to Routing Node:** `AT+MCLSS0` |
|
| 43 | +4. **Apply Changes:** `AT+RESET` |
|
| 44 | + |
|
| 45 | +--- |
|
| 46 | + |
|
| 47 | +## 2. Data Transmission (Hex Format) |
|
| 48 | + |
|
| 49 | +The following commands use the prefix `41 54 2b 4d 45 53 48` (which translates to `AT+MESH`). |
|
| 50 | + |
|
| 51 | +| Action | Hex Command | |
|
| 52 | +| :--- | :--- | |
|
| 53 | +| **Broadcast Data** (1122334455) to all devices | `41 54 2b 4d 45 53 48 00 FF FF 11 22 33 44 55 0D 0A` | |
|
| 54 | +| **Point-to-Point** (1122334455) to Device 0008 | `41 54 2b 4d 45 53 48 00 00 08 11 22 33 44 55 0D 0A` | |
|
| 55 | +| **Remote Control** (Set 0008 OUT1 Low + ACK) | `41 54 2b 4d 45 53 48 11 00 08 AA B2 E7 01 00` | |
|
| 56 | + |
|
| 57 | +--- |
|
| 58 | + |
|
| 59 | +## 3. Command Reference Table |
|
| 60 | + |
|
| 61 | +| Command | Function | Description | |
|
| 62 | +| :--- | :--- | :--- | |
|
| 63 | +| `AT+ROLE5` | Set Mode | Configures the module for MESH networking. | |
|
| 64 | +| `AT+NETIDxxxx` | Network ID | Sets the group ID (e.g., 1122). | |
|
| 65 | +| `AT+MADDRxxxx` | Short Address | Sets the unique device address (e.g., 0005). | |
|
| 66 | +| `AT+MCLSS0` | Router Mode | Always-on node that routes packets. | |
|
| 67 | +| `AT+MCLSS1` | Terminal Mode | Low-power node (3µA) for end-devices. | |
|
| 68 | +| `AT+KEYx,addr,io,val` | Key Mapping | Binds a physical key to a remote IO action. | |
|
| 69 | +| `AT+RESET` | Restart | Required to save and execute new settings. | |
|
| 70 | +## ref |
|
| 71 | + |
Network-dat/Bluetooth-dat/iBeacon-dat/iBeacon-dat.md
| ... | ... | @@ -1,13 +1,6 @@ |
| 1 | 1 | |
| 2 | 2 | # iBeacon-dat |
| 3 | 3 | |
| 4 | -## e.g. [[JDY-25M-dat]] |
|
| 5 | - |
|
| 6 | -需要配置 iBeacon 模式,请发送 AT+ROLE3,再发 AT+RESET 重启 |
|
| 7 | -- 第一步配置 iBeacon 的 UUID:AT+IBUUID 例子:AT+IBUUIDFDA50693A4E24FB1AFCFC6EB07647825 |
|
| 8 | -- 第二步配置 iBeacon 的 MAJOR:AT+MAJOR0007 |
|
| 9 | -- 第一步配置 iBeacon 的 MINOR:AT+MINOR000A |
|
| 10 | - |
|
| 11 | 4 | |
| 12 | 5 | |
| 13 | 6 | ## ESP32 |
| ... | ... | @@ -22,4 +15,19 @@ |
| 22 | 15 | #define SERVICE_UUID "7A0247E7-8E88-409B-A959-AB5092DDB03E" |
| 23 | 16 | #define BEACON_UUID "2D7A9F0C-E0E8-4CC9-A71B-A21DB2D034A1" |
| 24 | 17 | #define BEACON_UUID_REV "A134D0B2-1DA2-1BA7-C94C-E8E00C9F7A2D" |
| 25 | - #define CHARACTERISTIC_UUID "82258BAA-DF72-47E8-99BC-B73D7ECD08A5" |
|
| ... | ... | \ No newline at end of file |
| 0 | + #define CHARACTERISTIC_UUID "82258BAA-DF72-47E8-99BC-B73D7ECD08A5" |
|
| 1 | + |
|
| 2 | + |
|
| 3 | + |
|
| 4 | +## tech |
|
| 5 | + |
|
| 6 | +- [[NBL1101-dat]] - [[NBL1107-dat]] - [[EY-25M-dat]] |
|
| 7 | + |
|
| 8 | +### e.g. [[EY-25M-dat]] |
|
| 9 | + |
|
| 10 | +需要配置 iBeacon 模式,请发送 AT+ROLE3,再发 AT+RESET 重启 |
|
| 11 | + |
|
| 12 | +- 第一步配置 iBeacon 的 UUID:AT+IBUUID 例子:AT+IBUUIDFDA50693A4E24FB1AFCFC6EB07647825 |
|
| 13 | +- 第二步配置 iBeacon 的 MAJOR:AT+MAJOR0007 |
|
| 14 | +- 第一步配置 iBeacon 的 MINOR:AT+MINOR000A |
|
| 15 | + |
Network-dat/Bluetooth-dat/mesh-node-dat/mesh-node-dat.md
| ... | ... | @@ -1,6 +1,10 @@ |
| 1 | 1 | |
| 2 | 2 | # mesh-node-dat |
| 3 | 3 | |
| 4 | + |
|
| 5 | +- [[mesh-node-dat]] - [[EY-25M-mesh-dat.md]] - [[EY-25M-dat]] |
|
| 6 | + |
|
| 7 | + |
|
| 4 | 8 |  |
| 5 | 9 | |
| 6 | 10 |  |
| ... | ... | @@ -8,4 +12,9 @@ |
| 8 | 12 | - Relay nodes: These need to always be awake and therefore consume more power. Relay nodes function to receive and forward message packets across the network. In our lighting example, relay nodes will be mains powered, so it is unlikely they would have energy supply concerns. |
| 9 | 13 | - Low-power nodes: These nodes are usually battery powered and are typically in a power-saving sleep mode for the majority of the time. |
| 10 | 14 | - Friend nodes: Low-power nodes are always associated with a friend node, which stores and forwards messages according to an agreed schedule. An ambient light sensor used to control outside lights at dusk and dawn is an example of a low-power node. |
| 11 | -- Proxy nodes: These nodes enable non-BLE-compliant devices to connect into the mesh through the use of the Bluetooth Generic Attribute (GATT) profile interface. |
|
| ... | ... | \ No newline at end of file |
| 0 | +- Proxy nodes: These nodes enable non-BLE-compliant devices to connect into the mesh through the use of the Bluetooth Generic Attribute (GATT) profile interface. |
|
| 1 | + |
|
| 2 | + |
|
| 3 | + |
|
| 4 | +## ref |
|
| 5 | + |
Network-dat/DTU-dat/DTU-dat.md
| ... | ... | @@ -1 +1,13 @@ |
| 1 | -# DTU-dat |
|
| ... | ... | \ No newline at end of file |
| 0 | +# DTU-dat |
|
| 1 | + |
|
| 2 | + |
|
| 3 | +- [[serial-dat]] - [[DTU-dat]] |
|
| 4 | + |
|
| 5 | + |
|
| 6 | +## tech |
|
| 7 | + |
|
| 8 | +- [[NBL1101-dat]] - [[NBL1107-dat]] |
|
| 9 | + |
|
| 10 | + |
|
| 11 | +## ref |
|
| 12 | + |
Network-dat/RF-dat/LORA-DAT/Lora-dat.md
| ... | ... | @@ -17,7 +17,7 @@ legacy wiki page |
| 17 | 17 | |
| 18 | 18 | - [[semtech-dat]] |
| 19 | 19 | |
| 20 | - |
|
| 20 | +- [[RSSI-dat]] |
|
| 21 | 21 | |
| 22 | 22 | |
| 23 | 23 | ## chip |
| ... | ... | @@ -137,6 +137,9 @@ HPD Series - [[NWL1074-dat]] - [[NWL1075-dat]] - [[NWL1077-dat]] |
| 137 | 137 | |
| 138 | 138 | LoRa devices and networks (such as LoRaWAN) enable smart IoT applications to help address major global challenges like energy management, depletion of natural resources, pollution control, infrastructure efficiency, and disaster prevention. Semtech’s LoRa devices have achieved hundreds of successful application cases in smart cities, homes and buildings, communities, metering, supply chain and logistics, agriculture, and more. LoRa networks now cover hundreds of millions of devices in over 100 countries/regions, aiming to create a smarter planet. |
| 139 | 139 | |
| 140 | +- [[lora-app-dat]] |
|
| 141 | + |
|
| 142 | + |
|
| 140 | 143 | ## lora frequency |
| 141 | 144 | |
| 142 | 145 | | Version | Frequency Range | Applicable Regions | |
Network-dat/RF-dat/LORA-DAT/lora-app-dat/lora-app-dat.md
| ... | ... | @@ -0,0 +1,13 @@ |
| 1 | + |
|
| 2 | + |
|
| 3 | +# lora-app-dat |
|
| 4 | + |
|
| 5 | +- [[lorawan-dat]] |
|
| 6 | + |
|
| 7 | + |
|
| 8 | + |
|
| 9 | + |
|
| 10 | + |
|
| 11 | +## ref |
|
| 12 | + |
|
| 13 | +- [[lora-app]] - [[lora]] |
|
| ... | ... | \ No newline at end of file |
Network-dat/network-dat.md
| ... | ... | @@ -70,6 +70,9 @@ |
| 70 | 70 | - [[WIFI-DAT]] - [[HTTP-dat]] - [[UDP-dat]] - [[MQTT-dat]] - [[TCPIP-dat]] |
| 71 | 71 | |
| 72 | 72 | |
| 73 | + |
|
| 74 | + |
|
| 75 | + |
|
| 73 | 76 | ## RC apps protocols |
| 74 | 77 | |
| 75 | 78 | |
| ... | ... | @@ -206,6 +209,12 @@ A microcontroller talking to a cellular modem (SIMCom, Quectel) over UART often |
| 206 | 209 | |
| 207 | 210 | |
| 208 | 211 | |
| 212 | +## apps |
|
| 213 | + |
|
| 214 | +- [[geofence-dat]] - [[BLE-dat]] - [[UWB-dat]] - [[network-dat]] - [[lorawan-dat]] - [[RSSI-dat]] - [[app-dat]] - [[wifi-dat]] |
|
| 215 | + |
|
| 216 | + |
|
| 217 | + |
|
| 209 | 218 | ## ref |
| 210 | 219 | |
| 211 | 220 | - [[antenna-dat]] |
| ... | ... | \ No newline at end of file |
Tech-dat/GPIO-dat/GPIO-dat.md
| ... | ... | @@ -2,6 +2,16 @@ |
| 2 | 2 | # GPIO-dat |
| 3 | 3 | |
| 4 | 4 | |
| 5 | +## apps |
|
| 6 | + |
|
| 7 | +- [[IO-panel-dat]] - [[IOs-dat]] - [[GPIO-dat]] |
|
| 8 | + |
|
| 9 | +## info |
|
| 10 | + |
|
| 11 | + |
|
| 12 | + |
|
| 13 | + |
|
| 14 | + |
|
| 5 | 15 | GPIOS (Giant Pixel Interleaved Octal Shifts) is a method used in data storage and transfer used in several of Texas Instruments DSP chips. In these chips, the Gpio mode is used for general purpose applications. Here are some of the common GPIO (General Purpose Input/Output) modes: |
| 6 | 16 | |
| 7 | 17 | 1. PP (Push-Pull): In this mode, the output pins are in a high impedance state and provide a high drive current when being driven. |
| ... | ... | @@ -23,6 +33,12 @@ GPIOS (Giant Pixel Interleaved Octal Shifts) is a method used in data storage an |
| 23 | 33 | - [[MSP1072-dat]] - [[CH423-dat]] |
| 24 | 34 | |
| 25 | 35 | |
| 36 | + |
|
| 37 | + |
|
| 38 | +## tech |
|
| 39 | + |
|
| 40 | +- [[NBL1101-dat]] - [[NBL1107-dat]] |
|
| 41 | + |
|
| 26 | 42 | ## ref |
| 27 | 43 | |
| 28 | 44 | - [[logic-shifter]] |
| ... | ... | \ No newline at end of file |
Tech-dat/Interface-dat/Serial-dat/Serial-dat.md
| ... | ... | @@ -146,6 +146,9 @@ Booting Mode select |
| 146 | 146 | |
| 147 | 147 | |
| 148 | 148 | |
| 149 | +## APP |
|
| 150 | + |
|
| 151 | +- [[serial-dat]] - [[DTU-dat]] |
|
| 149 | 152 | |
| 150 | 153 | |
| 151 | 154 |
app-dat/geofence-dat/geofence-dat.md
| ... | ... | @@ -0,0 +1,101 @@ |
| 1 | + |
|
| 2 | +# geofence-dat |
|
| 3 | + |
|
| 4 | + |
|
| 5 | + |
|
| 6 | +- [[BLE-dat]] - [[UWB-dat]] - [[network-dat]] - [[lorawan-dat]] - [[RSSI-dat]] - [[geofence-dat]] - [[app-dat]] - [[wifi-dat]] |
|
| 7 | + |
|
| 8 | + |
|
| 9 | + |
|
| 10 | +## Option 1: Comparison of Geofencing Technologies |
|
| 11 | + |
|
| 12 | +This summary compares LoRaWAN RSSI with higher-precision alternatives for a child-safety "electric fence." |
|
| 13 | + |
|
| 14 | +| Technology | Typical Precision | Reliability | Best Use Case | |
|
| 15 | +| :----------------------- | :---------------- | :----------------- | :-------------------------------------------------------------------------- | |
|
| 16 | +| **LoRaWAN RSSI** | 10m – 30m | **Low** | Long-range "neighborhood" tracking where exact boundaries don't matter. | |
|
| 17 | +| **GPS + LoRaWAN** | 5m – 10m | **High (Outdoor)** | Large properties or hiking. GPS handles location; LoRa transmits the alert. | |
|
| 18 | +| **Ultra-Wideband (UWB)** | 0.1m – 0.5m | **Excellent** | Precise "invisible fences" for yards. High accuracy, very low latency. | |
|
| 19 | +| **Bluetooth (BLE 5.1+)** | 1m – 5m | **Medium** | Short-range (indoor/small garden) using "Direction Finding" (AoA). | |
|
| 20 | + |
|
| 21 | +--- |
|
| 22 | + |
|
| 23 | +## Option 2: Technical Implementation & Hybrid Suggestions |
|
| 24 | + |
|
| 25 | +If you are building a custom tracker (e.g., using an ESP32-S3 or similar), consider these three implementation paths for copy-paste planning: |
|
| 26 | + |
|
| 27 | +### 1. The "Filtered RSSI" Path (LoRaWAN Only) |
|
| 28 | +* **Method:** Use a **Kalman Filter** to smooth the signal. |
|
| 29 | +* **Logic:** `If (Average_RSSI < Threshold) AND (Duration > 5 seconds) -> Trigger Alarm`. |
|
| 30 | +* **Pros:** Lowest power consumption; no extra hardware. |
|
| 31 | + |
|
| 32 | +### 2. The "Reliable Outdoor" Path (GPS + LoRa) |
|
| 33 | +* **Hardware:** LoRa Module + Small GPS Module (e.g., u-blox NEO-6M). |
|
| 34 | +* **Logic:** The wearable calculates its own coordinates. If the GPS coordinate is outside a pre-defined polygon, it sends an **"ALARM"** packet via LoRa. |
|
| 35 | +* **Pros:** Not affected by signal bouncing or body blocking. |
|
| 36 | + |
|
| 37 | +### 3. The "High Precision" Path (UWB) |
|
| 38 | +* **Hardware:** DW1000 or ESP32-UWB modules. |
|
| 39 | +* **Logic:** Uses "Time of Flight" instead of signal strength. It measures how long the radio wave takes to travel, providing centimeter-level accuracy. |
|
| 40 | +* **Pros:** True "Electric Fence" performance. If the kid crosses a specific line, you know instantly. |
|
| 41 | + |
|
| 42 | + |
|
| 43 | +## Technical Blueprint: 10KM LoRaWAN Geofence |
|
| 44 | + |
|
| 45 | +### 1. The Scaling Problem (Distance vs. Signal) |
|
| 46 | +In a 10 km radius, the signal follows the **Inverse Square Law**. |
|
| 47 | +* **0m to 500m:** RSSI drops significantly (e.g., -40dBm to -90dBm). High precision. |
|
| 48 | +* **1km to 10km:** RSSI drops very slowly (e.g., -110dBm to -120dBm). Low precision. |
|
| 49 | +* **The "Dead Zone":** Beyond 5km, environmental noise (weather, buildings) is often stronger than the distance signal. |
|
| 50 | + |
|
| 51 | +--- |
|
| 52 | + |
|
| 53 | +### 2. Recommended System Architecture |
|
| 54 | + |
|
| 55 | +| Feature | Specification | Reason | |
|
| 56 | +| :------------------- | :--------------------- | :------------------------------------------------------------- | |
|
| 57 | +| **Hardware** | ESP32-S3 + SX1262 LoRa | High processing power + best-in-class LoRa sensitivity. | |
|
| 58 | +| **Logic** | GPS-Triggered LoRa | Use GPS for the "Fence" logic; use LoRa to send the "Warning." | |
|
| 59 | +| **Spreading Factor** | SF10 or SF12 | Required to maintain a stable link at 10km range. | |
|
| 60 | +| **Antenna** | 5.8dBi Fiberglass | Increases gain to ensure the 10km boundary is reachable. | |
|
| 61 | + |
|
| 62 | +--- |
|
| 63 | + |
|
| 64 | +### 3. Implementation Logic (The "Smart" Fence) |
|
| 65 | + |
|
| 66 | +To make a 10km fence reliable, do not use RSSI as the *only* trigger. Use this hybrid logic: |
|
| 67 | + |
|
| 68 | +#### A. The "Keep-Alive" Pulse (RSSI) |
|
| 69 | +The tracker sends a small packet every 60 seconds. |
|
| 70 | +* **Logic:** If the Gateway misses 3 consecutive packets, trigger an **"Out of Range / Connection Lost"** warning. This is your fail-safe if the device is destroyed or enters a dead zone. |
|
| 71 | + |
|
| 72 | +#### B. The GPS Geofence (Precision) |
|
| 73 | +The wearable (child's device) monitors its own GPS coordinates. |
|
| 74 | +* **Logic:** |
|
| 75 | + 1. Define a `Home_Center` (Lat/Lon). |
|
| 76 | + 2. Calculate `Distance_to_Home` on the device. |
|
| 77 | + 3. `If (Distance_to_Home > 10,000 meters)` -> Send a High-Priority LoRa packet: **"FENCE_BREACHED"**. |
|
| 78 | + |
|
| 79 | +--- |
|
| 80 | + |
|
| 81 | +### 4. Advanced Filtering for RSSI |
|
| 82 | +If you insist on using RSSI for the 10km boundary, you **must** use a **Kalman Filter** or **Exponential Moving Average (EMA)** to prevent false alarms. |
|
| 83 | + |
|
| 84 | +**Formula for EMA:** |
|
| 85 | +$$RSSI_{filtered} = (\alpha \times RSSI_{new}) + ((1 - \alpha) \times RSSI_{old})$$ |
|
| 86 | +*(Use $\alpha = 0.1$ for heavy smoothing at long distances).* |
|
| 87 | + |
|
| 88 | +--- |
|
| 89 | + |
|
| 90 | +### 5. Why RSSI alone fails at 10KM: |
|
| 91 | +* **The "Jitter":** At 10km, a child standing still will have an RSSI that jumps between -115 and -122. |
|
| 92 | +* **The "False Trigger":** An RSSI of -120 could mean "I am 10km away" OR it could mean "I am 2km away behind a large concrete building." |
|
| 93 | +* **Conclusion:** For a 10km goal, **GPS over LoRa** is the professional standard. RSSI is perfect for a 50-meter backyard fence, but dangerous for a 10,000-meter safety zone. |
|
| 94 | + |
|
| 95 | + |
|
| 96 | + |
|
| 97 | +## ref |
|
| 98 | + |
|
| 99 | + |
|
| 100 | + |
|
| 101 | + |
|
| ... | ... | \ No newline at end of file |
app-dat/keyfab-dat/keyfab-dat.md
| ... | ... | @@ -0,0 +1,20 @@ |
| 1 | + |
|
| 2 | + |
|
| 3 | +# keyfab-dat |
|
| 4 | + |
|
| 5 | + |
|
| 6 | + |
|
| 7 | + |
|
| 8 | + |
|
| 9 | + |
|
| 10 | + |
|
| 11 | +## tech |
|
| 12 | + |
|
| 13 | +- [[NBL1101-dat]] - [[NBL1107-dat]] - [[BLE-dat]] |
|
| 14 | + |
|
| 15 | + |
|
| 16 | + |
|
| 17 | + |
|
| 18 | +## ref |
|
| 19 | + |
|
| 20 | + |