From 429a7e85c29e2776f3a4293517513a5d523f6388 Mon Sep 17 00:00:00 2001 From: Sadeep Madurange Date: Wed, 14 Jan 2026 22:31:29 +0800 Subject: RF lock and site search posts. --- _log/fpm-door-lock-rf.md | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) (limited to '_log/fpm-door-lock-rf.md') diff --git a/_log/fpm-door-lock-rf.md b/_log/fpm-door-lock-rf.md index 7c2b9ef..e29f733 100644 --- a/_log/fpm-door-lock-rf.md +++ b/_log/fpm-door-lock-rf.md @@ -6,7 +6,7 @@ project: true thumbnail: thumb_sm.jpeg --- -Wanted to unlock door with fingerprint, wirelessly to avoid drilling. +Wanted to unlock the door with fingerprint, wirelessly to avoid drilling. 2024-11: Started with basic 433MHz RF modules and two Arduinos. Connected data lines of the transceivers to UART RXD/TXDs of the MCUs. Unreliable--constant @@ -20,22 +20,10 @@ ATmega328P runs at 5V; RFM69 3.3V. Suspect logic-level converter (LLC) issues. High resistance; Not enough swing. 2025-04: Ditched RFM69s. Switched to NRF24L01+ modules--data pins 5V tolerant, -no LLC required. Spent six weekends writing a clean-room driver from scratch. -Works like a charm. +no LLC required. Spent six weekends writing a clean-room driver. Works like a +charm. -Basic security via xor cipher--good enough for a door behind a guard post and -a gate: - -``` -void xor(const char *k, const char *s, char *d, uint8_t n) -{ - int i; - for (i = 0; i < n; i++) - d[i] = s[i] ^ k[i]; -} -``` - -Resists replay attacks by cycling the key: +XOR cipher encrypts RF channel. Key cycled to resist replay attacks: ``` static inline void keygen(char *buf, uint8_t n) -- cgit v1.2.3