This application note and User Script provides a method for monitoring Display Spot connections over time, letting you know about unexpected network and connection issues. The script will send an email and/or log a message to Blocks' log file when a Display Spot disconnects unexpectedly.
The script has a separate function to just send a email, letting you test this part of the functionality, making sure that your email server settings are correct.
You can either try this out on its own, as an application note. Or you can take just the script and add it to an already existing Blocks installation.
You need a computer with a running blocks server and a web browser to use this application note.
Here's a PIXILAB-blocks-root folder containing everything you need for this application Download this ZIP file and unpack it then follow the instructions in the general setup section.
Edit your Blocks server's configuration file to add required email serttings, as described here. If you are not familiar with the configuration file, please read that complete article from the top.
IMPORTANT: The email settings provided in those instructions are dummy settings. You must configure all dsettings as relevant for your own outgoing email server.
Once you've done the general setup, copied the files and pointed your Blocks server to this root folder, follow the configuration steps below under "Configuration Task".
First download the current set of blocks script files and install them according to the instructions found here. The scripts required here are SpotReporter.ts and SpotReporter.js. Copy them from the script/user-archive directory to the script/user directory and restart the server to enable them in Blocks.
Edit your Blocks server's configuration file to add required email serttings, as described here. If you are not familiar with the configuration file, please read that complete article from the top.
IMPORTANT: The email settings provided in those instructions are dummy settings. You must configure all dsettings as relevant for your own outgoing email server.
You also need to add a Task for this mechanism to work. This task does the following.
The following example task has a trigger starting it as soon as Blocks is started.
By default, all Display Spots in the system are monitored. Alternatively, you can specify a particular Spot Group, or list of groups, to monitor using an addSpotGroup statement, specifying the name of the group. if the group is nested, specify the full path to the target group from the top, separating each segment with a period. To monitor multiple groups, specify each group using its own addSpotGroup statement. Put those statements above (outside) the while loop. To reset the list of Spot Group back to the default of monitoring all Display Spots, use an addSpotGroup statement with an empty string (a pair of quote signs).
Finally, test the email sending functionality by adding and manually running a temporary task like this,but using your own email address in the sendTo field.