node-red-contrib-tdn-wifi 1.0.3 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -59
- package/package.json +10 -16
- package/LICENSE +0 -661
- package/examples/Basic.json +0 -28
- package/tdn-wifi.html +0 -89
- package/tdn-wifi.js +0 -505
package/README.md
CHANGED
|
@@ -1,61 +1,3 @@
|
|
|
1
1
|
# node-red-contrib-tdn-wifi
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
**systemd-networkd + wpa_supplicant** (not NetworkManager, not dhcpcd). No dependencies beyond Node's
|
|
5
|
-
own built-ins — nothing else to `npm install`.
|
|
6
|
-
|
|
7
|
-
## Quick start
|
|
8
|
-
|
|
9
|
-
1. Drag a **WiFi Config** node onto any flow (it needs no wiring — 0 inputs) and deploy.
|
|
10
|
-
2. Open `/wifi-config` (same host/port as Node-RED, or click **Open WiFi Config page** on the node).
|
|
11
|
-
3. Click **Scan Networks**, pick one, enter its password, **Connect**.
|
|
12
|
-
4. On success the page shows the assigned IP, gateway, DNS servers, and a live reachability check
|
|
13
|
-
against the node's **Check URL** (blank = `https://1.1.1.1`).
|
|
14
|
-
|
|
15
|
-
**⚠️ Security note: `/wifi-config` is unauthenticated by default (matching this Pi's other TDN pages)
|
|
16
|
-
and can change the Pi's WiFi network and store a new password on the device. Only run this on a
|
|
17
|
-
trusted LAN. If this Pi is ever reachable from an untrusted network, put it behind a reverse proxy or
|
|
18
|
-
VPN, or add your own auth in front of it.**
|
|
19
|
-
|
|
20
|
-
## Requirements on the Pi
|
|
21
|
-
|
|
22
|
-
- `wpa_cli` (part of `wpasupplicant`) reachable for the WiFi interface's control socket — Node-RED runs
|
|
23
|
-
as root on the Pi, so this works without extra permission setup.
|
|
24
|
-
- `ip` (iproute2) — used to read the interface's IP address and default route.
|
|
25
|
-
- `resolvectl` (systemd-resolved) for DNS servers, with a fallback to reading `/etc/resolv.conf` if it's
|
|
26
|
-
not present.
|
|
27
|
-
|
|
28
|
-
Only home-style WPA2/WPA3-Personal networks are supported (SSID + password, 8-63 characters) — no
|
|
29
|
-
WPA-Enterprise/802.1x.
|
|
30
|
-
|
|
31
|
-
## Install / update
|
|
32
|
-
|
|
33
|
-
```bash
|
|
34
|
-
# Install (from the Pi, same pattern as the TDN MWA packages)
|
|
35
|
-
cd /root/.node-red
|
|
36
|
-
npm install /path/to/node-red-contrib-tdn-wifi
|
|
37
|
-
|
|
38
|
-
# Update after a new version is published
|
|
39
|
-
npm install node-red-contrib-tdn-wifi@latest
|
|
40
|
-
|
|
41
|
-
sudo systemctl restart nodered
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
## Output
|
|
45
|
-
|
|
46
|
-
The node emits `{ payload: { event: 'connected' | 'disconnected', ssid? } }` whenever the WiFi state
|
|
47
|
-
changes, polled every 30 seconds independent of the page — wire it to a
|
|
48
|
-
MWA send node (`node-red-contrib-tdn-mwa` or `node-red-contrib-tdn-mwa-web`) to get an alert when
|
|
49
|
-
this Pi's WiFi drops or reconnects.
|
|
50
|
-
|
|
51
|
-
## Example
|
|
52
|
-
|
|
53
|
-
**Import → Examples → node-red-contrib-tdn-wifi → Basic**: the WiFi Config node with a debug node on its
|
|
54
|
-
output.
|
|
55
|
-
|
|
56
|
-
## Why no NetworkManager (`nmcli`)?
|
|
57
|
-
|
|
58
|
-
This Pi's networking is configured with systemd-networkd + wpa_supplicant directly, so the node drives
|
|
59
|
-
`wpa_cli` for scanning/associating and `ip`/`resolvectl` for reading the resulting IP configuration,
|
|
60
|
-
rather than `nmcli`. If you're deploying this on a Pi OS image that uses NetworkManager instead, this
|
|
61
|
-
package will not work as-is.
|
|
3
|
+
This package is no longer available.
|
package/package.json
CHANGED
|
@@ -1,19 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "node-red-contrib-tdn-wifi",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "
|
|
5
|
-
"license": "
|
|
6
|
-
"
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
"
|
|
12
|
-
|
|
13
|
-
],
|
|
14
|
-
"node-red": {
|
|
15
|
-
"nodes": {
|
|
16
|
-
"tdn-wifi": "tdn-wifi.js"
|
|
17
|
-
}
|
|
18
|
-
}
|
|
3
|
+
"version": "1.0.4",
|
|
4
|
+
"description": "No longer available.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"bugs": {
|
|
7
|
+
"email": "npm.switchpoint@gmail.com"
|
|
8
|
+
},
|
|
9
|
+
"keywords": [],
|
|
10
|
+
"files": [
|
|
11
|
+
"README.md"
|
|
12
|
+
]
|
|
19
13
|
}
|