* Add delay feature to Threshold sensor
The threshold must be met constantly for on_delay or off_delay amount of time in order to switch to the respective state. Among other things, this allows turning an energy meter in to a "device is running" state, because it can ignore the small periods of time where the energy meter drops to zero.
* Some minor punctuation and rewording a confusing line