Home » Circuit, Networking » PRTG Alarm Light with Arduino

PRTG Alarm Light with Arduino

A friend asked if there was a way to trigger an alarm light in his data center when PRTG detected an alert on monitored devices.  I couldn’t find an off-the-shelf solution so I decided to make one using the following approach.  It works.  I don’t know if it’s the best or if it’s even good.

In the production environment, I plan to set up a lightweight PC to run the processing.org sketch, then connect the alert light box to the USB port for power and instructions.

 PRTG Alarm Light
PRTG Alarm Light with Processing.org and Arduino



Things you need:

PRTG v 14: Great application from Paessler to monitor and alert on hardware, network, or application performance.  I really like this product.  Their API is straightforward, easy to consume, and easy to make actionable. Download PRTG and  Read up on their HTTP API.  In PRTG, Create an APIUSER account – name/pw of your choosing – whatever you pick, update it in ‘settings.conf’.

processing.org: Java based programming language to query the PRTG API, then command the Adruino to do something.  In this case, trigger an RGB LED in specific patterns and colors.  Download processing.org.

Arduino: Programmable circuit board. Download the Arduino programming IDE.  Download the Firmata Sketch for the Arduino. Load the Firmata sketch to the Arduino.  All other programming is done in processing.org.  I put the board into this box made for Arduino.  I also dismantled an Energizer LED Touch Light for the housing / diffuser.  Is that called a diffuser?

RGB LED (I used common cathode): This is the thing that lights up in a variety of colors and blinks.

Simple pinout for arduino and rgb LED

Simple pinout for arduino and rgb LED




















Here are some pics.(Key for scale.)

PRTG Alarm Light

PRTG Alarm Light

PRTG Alarm Light
PRTG Alarm Light

Steps of the program:

1) Load settings.conf configuration file via loadJSON method.

Sample ‘settings.conf’

 "friendlyDelayInterval": 1,
 "HttpApiUserName": "prtgadmin",
 "HttpApiPassword": "prtgadmin",
 "HttpProtocol": "HTTP://",
 "HttpSiteToCheck": "IP_ADDRESS_OR_HOSTNAME", 
 "HttpSiteToCheckPortNumber": "", 
 "HttpApiSensorDownString": "/api/table.json?content=sensors&columns=objid,downtimesince,device,sensor,lastvalue,status,message,priority&filter_status=5&filter_status=4&filter_status=10&filter_status=13&filter_status=14&sortby=priority",
 "Sound_CriticalAlert": "acheeve.mp3",
 "Sound_AllClear": "ding.mp3",

2) Confirm that the PRTG server/API is reachable.

3) Consume the PRTG API in JSON format.

4) Interpret the results of the PRTG API.

5) Trigger the appropriate light pattern based on JSON results.

6) Loop.



PRTG_Alert_Light processing.org sketch.


What do you need to do?

  1. Download my processing.org sketch.
  2. Push the Firmata sketch to your Arduino.
  3. Update the ‘settings.conf’ with your particulars.
  4. Find some fun wav/mp3 files for audio alerts and put them in the same sketch folder.
  5. Connect the RGB LED to your Arduino.
  6. Find a cool housing to put it in.
  7. Extend the code to do other things.  The PRTG HTTP API is very flexible.  Let me know what you end up doing with it.