
Zsonet (Modern bell system)
Zsonet — Smart School Bell System
Zsonet is a full-stack IoT system that automates school bell and announcement schedules. It replaces manually-programmed Arduino setups with a cloud-connected platform that lets school staff manage audio files, bell schedules, and device settings entirely from a web dashboard or mobile app — no physical access to the hardware required.
The Problem It Solves
Traditional school bell systems are hardcoded. Changing a schedule or a voice file means physically reprogramming the device. Zsonet eliminates that by syncing everything over the internet: the device downloads its schedule and audio files automatically and executes them locally, so it continues working even when offline.
How It Works
A school admin logs into the web dashboard or mobile app. They upload MP3 audio files (morning assembly, break time, dismissal, etc.) to a cloud audio library. They then create a schedule — assigning each audio file to a specific time and set of days (e.g., Monday–Friday at 07:30). They can also designate a global intro melody and outro melody that play before and after every bell.
The ESP32 hardware device connects to WiFi on boot, syncs its clock with NTP via a DS3231 RTC module, and pulls its schedule from the backend API. It compares a version hash and only downloads new or changed audio files to its microSD card. At scheduled times, it plays the correct file through an I2S amplifier. If the internet goes down, the device continues operating from the last synced schedule and files on the SD card — the RTC keeps time accurately.
Devices are configured via Bluetooth (BLE). When pressed, the device enters BLE mode and broadcasts a GATT server. The mobile app connects, sends WiFi credentials and an auth code, and the device saves them to NVRAM and reboots into normal operation.
A credit system controls usage. Each bell play consumes one credit, and each audio file download costs ten. Credits are managed through recharge codes (ZNET-XXXX-XXXX-XXXX format) generated by the superadmin. Schools pay via PayPlus Africa and receive a code to top up their device wallet.
Hardware
- ESP32 microcontroller (two variants: 2×16 LCD and 4×16 LCD display)
- DS3231 real-time clock module (I2C)
- MicroSD card module (SPI)
- MAX98357A I2S amplifier with speaker
- Push button for mode switching (BELL → BLE → CREDIT → BELL)
Tech Stack
┌───────────────┬────────────────────────────────────────────────────────────────────┐ │ Layer │ Technology │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Backend │ Node.js + Express, Prisma ORM, PostgreSQL (Neon), hosted on Render │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Frontend │ React (Vite) │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Mobile │ Flutter (Android + iOS) │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Firmware │ ESP32 Arduino framework, ESP8266Audio, ArduinoJson, BLE GATT │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Audio storage │ Cloudinary │ ├───────────────┼────────────────────────────────────────────────────────────────────┤ │ Auth │ JWT, bcrypt; roles: superadmin / admin / staff │ └───────────────┴────────────────────────────────────────────────────────────────────┘
Key Features
- Automated scheduling — time + day-of-week triggers, fires once per minute per entry
- Intro/outro melodies — global system melodies that wrap every bell play
- Cloud audio library — upload, preview, rename, delete MP3s; superadmin audio visible to all schools
- OTA schedule sync — checksum-based diffing; only changed files are re-downloaded
- Offline resilience — RTC + SD card keeps the device running without internet
- BLE provisioning — configure WiFi credentials wirelessly from the mobile app
- Credit system — NVRAM-authoritative credit balance; ZNET recharge codes; PayPlus Africa payment integration
- Heartbeat + play logs — device reports online status and playback history to the backend every 2 minutes
- Role-based access — superadmin manages all schools; school admins manage their own schedules and staff
Target Users
Schools in West Africa (primary market: Togo). The dashboard UI is designed for non-technical school secretaries. French-language support is included in the mobile app.
Deployment
Backend: Render (Node/Express + Neon PostgreSQL) Frontend: static React build Mobile: Flutter APK / iOS build Firmware: flashed to ESP32 via USB; reconfigured wirelessly via BLE thereafter
