#!/bin/bash
if ! curl http://192.168.43.11/RELAY=ON | grep 'Relay is now: ON' >/dev/null 2>&1
then
echo "M111 failed"
exec display M111-failed.png
exit -1
fi
echo "M111 ok"
exit 0
