Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Power] Add extra display page showing power consumption #1012

Merged
merged 3 commits into from
Jun 14, 2024

Conversation

TD-er
Copy link
Contributor

@TD-er TD-er commented Jun 13, 2024

Since I have been busy with the AXP192 on this T-beam 1.0 board, I thought why not adding a separate display showing the actual power state.

PAXcounter_power_page_discharge
Power page showing discharge current

PAXcounter_power_page_charge
Power page showing charge current

PAXcounter_power_page_nocharge
Power page showing no charge, but with USB connected

As the display is updated quite often, I had to apply some basic filtering on the USB power stats or else it was hardly readable since the values fluctuate quite a lot.

@cyberman54
Copy link
Owner

Thanks for this PR (and the other one). I will look at this soon, test & merge.

@TD-er
Copy link
Contributor Author

TD-er commented Jun 13, 2024

@cyberman54 I just tested with this in the beginning of the setup() function:

  // Reduce power consumption
  setCpuFrequencyMhz(80);

This reduces the power consumption with about 50 mWatt.
Typically it uses 660 mWatt when the CPU freq. is set to 80 MHz.
When left running at 240 mHz, the power consumption is about 710 - 730 mWatt.

I'm also making the screen layout for this power display page a bit more readable, including the power consumption (or power used for charging)

@TD-er
Copy link
Contributor Author

TD-er commented Jun 13, 2024

Running from battery:
PXL_20240613_225943078

Charging from USB:
PXL_20240613_225955519

Will append the commit for it in a minute

Copy link
Owner

@cyberman54 cyberman54 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make power consumption optional, because main purpose of paxcounter is wifi/ble sniffing, affording high cpu speed

@cyberman54 cyberman54 merged commit cc957f6 into cyberman54:master Jun 14, 2024
41 of 42 checks passed
@TD-er TD-er deleted the feature/display_page_power branch June 14, 2024 10:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants