Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?

Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?

Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?
Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?
2024-11-25 05:37:23
Model: Tapo P115  
Hardware Version: V1
Firmware Version: 1.1.3 Build 240523 Rel. 175054

The energy and power usage data I downloaded only include 7-days worth of hourly logs. Daily data is available for the last 3 months (it may be more but I have only had these smart plugs for just over a month now). I also bought temperature/humidity sensors which allows me to specify the begin and the end date for the data period as well as the data interval (1 minute, 15 minute, hour) to include in the download file. The temp/humidity data covers the entire duration I've had the sensors in detailed minutes. I would like to get hourly records for the energy and power usage for at least a month. Is there a way to do this?

 

  0      
  0      
#1
Options
3 Reply
Re:Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?
2024-11-26 21:30:56

  @hh820,

I will have to forward the request to the team, as I am not sure - but I do not think so.

 

I believe that this may be a result of the energy monitoring data being stored on the plug itself, rather than using our servers to host the data.

 

Given that the interfaces only go back a week for daily data and the exports change to have summarized data, I would think it may be the result of storage running out. By summarizing the data after a week, it would save significant storage on the plug - especially when these devices typically only have a few MB of storage to work with. The sensors also get the added advantage of storing their data to their hub, which may justify their added settings.

  0  
  0  
#2
Options
Re:Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?
2024-12-13 04:07:24

  @Riley_S Thank you for seeking the possibility of this functionality in the future, if the dev team accepts the request.

Thank you also for enlightening me that the data is stored at each device. I have seen on GitHub that the device would respond to REST API. I will explore automatically downloading the data in a regular interval before the memory space runs out. Your response opened a door of hope that I can deal with this limitation. Manually initiating the data download from the phone app is prone to exceeding the 7-day limit.

 

  0  
  0  
#3
Options
Re:Is there a way to download hourly energy usage of Tapo smart plugs for more than 7 recent days?
2 weeks ago - last edited 2 weeks ago

A 32-bit data structure could be employed to store usage data for each 1-hour period. If we allocate 16 bits to the usage data, we can represent every value from 0.0 Wh to 3,276.8 Wh. With the remaining 16 bits we can represent every unique 1-hour period for the past 7 years and ~6 months. Thus, each usage record only need take 4 bytes of storage. Using only 262 kb we can store over 7 years worth of hourly usage data.

 

To make a concrete example, a usage of 1,987.2 Watt-hours during the noon hour of September 7, 2021, could be encoded as hexadecimal 79244DA0. The first 2 bytes store the number of hours back from the current hour [$hex(7924) = $dec(31,012) hours], and the second 2-bytes encode the Watt-hours x 10 [$hex(4DA0) = $dec(19872) = 1987.2 Watt-hours].

  0  
  0  
#4
Options
icon

Accessibility Adjustments

icon RESET

Choose the right accessibility profile for you

OFF

Seizure Safe

Eliminates flashes and reduces color

OFF

Cognitive Disability

Assists with reading and focusing

OFF

Vision Impaired

Enhances the website's visuals

OFF

ADHD Friendly

More focus and fewer distractions

Content Adjustments

Adjust Scale

icon
100%
icon

Highlight Title

icon

Highlight Link

icon

Text Magnifier

icon

Readable Font

icon

Adjust Fontsize

icon
100%
icon

Align Center

icon

Adjust LineHeight

icon
100%
icon

Align Left

icon

Adjust LetterSpacing

icon
100%
icon

Align Right

icon

Color Adjustment

Low Saturate

icon

High Saturate

icon

Dark Contrast

icon

Light Contrast

icon

Set Text Colors

Monochrome

icon

Set Title Colors

High Contrast

icon

Set BackgroundColor

Orientation Adjustments

Muted

icon

Hide Images

icon

Read Mode

icon

Stop Animation

icon

Reading Mask

icon

Highlight Hover

icon

Big Black Cursor

mutedicon

Big White Cursor

icon

Hide Video/Audio

icon

Stop Video

icon

Stop Audio

icon

Hide Animation

icon

Reading Guide

icon

Useful Links