satya@web:
/docs/iiitkota/nfc-mess/deployment
$
/

๐Ÿ› ๏ธ System Deployment Guide

This guide explains how to set up the NFC Gatekeeper system on a fresh Debian 12 (Bookworm) computer. This process is usually performed once by a technician.

๐Ÿ“‹ Prerequisites

Before you begin, ensure you have:

  • A computer running Debian 12.
  • At least one ACS ACR122U NFC Reader.
  • Internet connection for downloading necessary software.

For detailed documentation, read the gude at the repo: https://github.com/S4tyendra/nfc-gatekeeper/ For mess, You would use feat/mess-system branch.

Command:

git checkout feat/mess-system

๐Ÿ—๏ธ Step 1: Preparing the Operating System

We need to prepare the computer so it doesnโ€™t interfere with the NFC readers.

  1. Blacklist conflicting drivers: The computer has built-in drivers that try to talk to the NFC reader. We need to disable them so our specialized software can take control.
  2. Install dependencies: We need to install several tools like pcscd (which talks to the reader), python3 (which runs our app), and chromium (which shows the screen).
# Example commands (for technicians)
sudo apt update
sudo apt install -y pcscd chromium lightdm

๐Ÿ“‚ Step 2: Setting up Data Folders

The system needs a specific place to store its data. We use /var/lib/iiitk-nfc/ for this.

  • Databases: Located at /var/lib/iiitk-nfc/databases/.
  • Images: Located at /var/lib/iiitk-nfc/images/.

You must ensure that the user running the app has permission to read and write to these folders.

๐Ÿš€ Step 3: Starting the Backend

The backend is a Python application that stays running in the background. It is managed by a โ€œsystemd service,โ€ which means it starts automatically when the computer turns on.

If you need to restart it manually:

sudo systemctl restart nfc-gatekeeper

๐Ÿ–ฅ๏ธ Step 4: Setting up the Kiosk (The Screen)

The system is designed to run as a โ€œKiosk.โ€ This means that when the computer starts, it automatically logs in and opens a full-screen browser showing the entry/exit portal.

  • Auto-login: Configured in lightdm.
  • Auto-start browser: A special file in ~/.config/autostart/ tells the computer to open Chromium in --kiosk mode.

โœ… Step 5: Final Check

Once everything is set up, you should:

  1. Plug in the NFC readers.
  2. Test a card tap to ensure it shows up on the screen.