Musical programmable school bell "Schoolboy-4"


    On a habr more than once did the description of work with a TL-MR3020 router in terms of expanding its capabilities based on openwrt firmware. I want to show another option for finalizing the router, in which it can become a full-fledged participant in the school educational process. The article describes the device and the procedure for working with a music programmable school bell "Schoolboy-4."

    Module "Schoolboy-4"

    For those who are eager to try it in work, I suggest immediately flashing your router with alternative CyberWrt firmware and selecting this module in the Modules / test menu, then clicking Install and after a while you will be able to experiment yourself. For full-fledged work, you need a usb-audio card, which is inserted directly into the router case in the photo.


    In Russia and the world there are several dozen different implementations of automated call systems. The first such systems appeared back in the USSR, and in some places they still worked. Many of them simply automate the delivery of traditional loud bells. Some of them allow using a wire broadcasting system instead of regular calls, which is usually a part of the school notification system.

    The option described below is the 4th school bell under the uncomplicated name “Schoolboy”. The first two versions were made by my friend, Eugene Penner, who sold them on AVR. I took over the baton and executed the third option on the basis of a mobile phone as an application in Java2ME. For many years they worked faithfully in some schools in the Urals and Siberia.

    If we look atsource codes , then we will see that the next call is a set of shell and javascript scripts. Calls are controlled by shell scripts using the crond service. The web interface is written in javascript using the jQuery library. The router connects to the amplifier of the wired broadcast system through an audio card. Access to management can be organized both over a local wired network and over WiFi.

    At the moment, prototypes of the Shkolnik-4 call were installed in two schools and underwent trial operation for several months.


    A general view and description of the interface are presented below.


    There are not many settings:

    Automatic is a mode in which at 1 minute of the first every day there is an automatic change of schedule according to the annual plan. If the automatic mode is off, the schedule will be constant (see below).

    Schedule - select a schedule for the manual switching mode.

    Preliminary - time in minutes for which preliminary calls are made, if enabled (see the Schedules tab).

    Melody - a melody for a preliminary call. Due to space limitations in the router, all tunes are still limited to a set of five. Sync

    Buttonsets the time from the browser on the router. The fact is that the TL-MR3020 is synchronized through the network, if it is not there, then the unix era is being established. There is no RTC chip on board. This is one of the minuses of this router for such an application.

    The Stop button stops the crond service, and Restart restarts it.

    The Test button tests the sound path by playing a short sound file.


    This is just a children's coloring. “Dip” with a brush into the schedule and write what you need for the current year. Do not forget to save your creativity by clicking on the Save button . This plan is needed for the automatic schedule change mode.


    You cannot add or remove schedules in the current version, but you can edit them. We select the schedule from the list, a set of calls for it appears below. Add / remove lines, change the melody, enable or disable the call from the job for the crond service, enable or disable the additional preliminary call. Everything is intuitive. You can also play the current melody, but it will be played in the browser, and not through the audio card.
    The Apply button is needed if several schedules change at once. First you need to Apply the current changes to go to the next schedule, and then click Save . After that, all changes will be saved.

    Tabs System Log and Debuggingcontain specific information for setting up the call. CyberWrt module "Schoolboy-4" is immediately ready to work after installation. If the crond service is not running, instead of the WORK text, the word STOP will be displayed. No calls will be made.

    Operating procedure

    1. Install the module or assemble it yourself for your system.
    2. Edit schedules, save.
    3. Draw up an annual plan, save.
    4. Turn on automatic mode, save.
    5. Restart button.

    Note . If the router is not connected to the local network or, for another reason, cannot be synchronized through the network to set the time, then this operation must be performed manually (the Sync button ). Unfortunately, the time zone also needs to be changed manually in the configuration file, which requires special knowledge.


    - replacement of a person, always accurate delivery of calls;
    - a more pleasant psychological atmosphere in the school;
    - the ability to configure control via a local network or WiFi ( qualification required );
    - call setup is carried out through the browser of a smartphone, tablet, laptop or PC;
    - work in manual mode (selected schedule) or automatic - according to the annual plan.


    - a wired broadcasting system is required (the call is connected to the free input of the amplifier);
    - 5 melodies are preinstalled (usually no longer required), there is no possibility to upload your own via the interface yet;
    - the router on which the call is based does not have the ability to save time when the power is turned off, but can be synchronized through the network if it is configured to work on a network with Internet access. Therefore, when you turn on you need to perform the synchronization operation through the interface.
    - 4 arbitrary schedules are available for change (in the future it will be possible to add an arbitrary amount, although this is usually not required);


    action.cgi - the processor of post-requests from the page;
    index.cgi - required as part of the CyberWrt module;
    json.cgi - JSON parser on shell script;
    scheduler.cgi - generate tasks for crond;

    main.html - the main page;
    style.css - styles for tabs;

    jquery-1.11.0.min.js - jQuery library;
    main.js - contains classes for working with objects on the page: schedules, settings, plan, etc.
    webtoolkit.base64.js - Base64 codec;

    * .json - configuration files;
    * .mp3 - melodies;

    log.txt - message log, cyclically rewritten.


    Sources are distributed freely, free of charge and at your own peril, as they say. As a sound card, a simple Chinese one for 150 p. (it is shown in the photo above, screwed with a paper clip). If you want to set up such a call in your school, then go to an appointment directly with the school principal, in private. I do not need any goodies for the implementation, I would be pleased to just know if such a device will work somewhere. The only thing I would accept as a gift for the collection is the old Soviet calls of the "Electronics" type.


    1. Sources on github .
    2. Schoolboy-3. User Manual (pdf).
    3. CyberWrt module "Schoolboy-4" (thread on the forum).
    4. Musical programmable school bell "Schoolboy-3" .

    Also popular now: