nx_tuya_smartconfig.nx
buildroot/runtime/nx_tuya_smartconfig.nx
about
nx_tuya_smartconfig.nx -- SOVEREIGN Tuya smartconfig BROADCAST encoder.
Faithful port of tuya-convert's broadcast.py + crc.py (kueblc 2019, broadcast ported from
tuyapi/link), sovereignly fetched to knowledge/fetched/tuya_{broadcast,crc}.raw. Produces the UDP
packet-LENGTH body a Tuya device in EZ mode sniffs. The FULL broadcast = broadcast_head [1,3,6,10]
(sent in the header phase) + this body, sent as UDP to 255.255.255.255:30011 (payload = `\0`*len),
5ms gap. Tuya CRC-8 is its OWN polynomial (per-bit: if (r^b)&1: r^=0x18;r>>=1;r|=0x80 else r>>=1) --
NOT the Dallas/Maxim of ESP-Touch. The device DECODES the lengths -> SSID+password+token -> joins.
NEVER-BRICK #26: emits reversible Wi-Fi creds only. license_tier: ORIGINAL
dependencies 1 imports · 2 importers
imports: nx_syscalls_x86_64.nx
imported by: nx_tuya_emit_a64.nxnx_tuya_smartconfig_gate.nx
structs
| none |
consts
| 11 | const K_MAGIC_1024: i64 = 1024 |
functions
| 14 | func nx_tuya_crc8_byte(bIn: i64) -> i64 |
| 26 | func nx_tuya_crc8(arr: *i64, n: i64) -> i64 |
| 35 | func nx_tuya_bcast(pw: *u8, pw_n: i64, ssid: *u8, ssid_n: i64, tok: *u8, tok_n: i64, |