Perpetual and low-cost power meter for monitoring residential and industrial appliances