mr moab wrote: ... I particularly want to know if the pump is stuck in "on" state for any extended length of time ...
Not a pump monitor as such, but ...
There are two failure states:
1. High water level
2. Low water level
float valve fails 'off'
float valve mechanically stuck below 'on' position
local pipe failure – water recycling into sump
float valve fails 'on'
float valve mechanically stuck above 'off' position
1 Add a high level float switch
If high level float switch turns 'on' create alarm condition
2. Add a low level float switch
a. create an alarm condition if the low level float switch turns 'off'
b create an alarm condition if the low level float switch is off for more than x seconds
The setup depends on available space in the sump to position a low level float switch and
its on/off levels compared to 'normal' pump operation
Hope this gives you an idea for a solution. I might try it myself having had a sump pump running continuously due to a stuck float switch. Fortunately I was in the house and heard the pump running – by which time the motor was hot and no doubt the 'water lubricated' lower bearing was running dry.
If you have a sump that dries out in summer for instance, you might have to create software that only enables the 'low level' alarm within a certain time from a normal level condition – haven't really thought that through !
Another thought – install a pump that has an independent float switch. These float switches control a mains outlet / mains socket that the pump is plugged in to. If you add an adapter /cube tap then the float switch can control two (or more circuits). One is of course the pump and the other is home made, feeding a mains (120v or 240v) relay with properly isolated low voltage contacts, which can indicate the main float switch state and hence whether the pump is energized or not.
PS sump = cistern