Badass Automation: Auto Check-in via WiFi with Raspberry Pi (Part 3)
We already talked about the entities and how the backend of rh_mexico is structured in Drupal. But it's one thing for the software to be robust, and another for users to actually use it. The harsh reality: people are too lazy to clock in.

The human factor
No matter how beautiful the Check-in button is on their phone, people arrive at the office thinking about what they are going to eat for breakfast or the client that's bothering them, not about opening a web app. So instead of fighting them, I decided to make the hardware work for me.
Enter Raspberry Pi and WifiAutoCheckinManager
I grabbed a Raspberry Pi, connected it to the office network, and set up a script that scans the devices connected to our router using ARP and SNMP queries. Every time an employee's phone (whose MAC Address is pre-registered in the WifiDeviceRegistry) connects to our network, the Raspberry sends a secure Webhook to Drupal.
That's where the WifiAutoCheckinManager service shines:
1. It receives the payload from the device.
2. Cross-references the MAC Address with the Drupal user.
3. Checks if they already have an entry check-in for the day. If not, it triggers the attendance automatically.

The employee literally just has to walk through the office door. Their phone connects to the WiFi, the router tells the Raspberry, the Raspberry tells Drupal, and boom, attendance registered. Pure magic. Zero friction.
In Chapter 4, we'll dive into a darker topic: Punishments, rewards, and how the system ruthlessly calculates tardiness without any Human Resources intervention.