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 measurement #170

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

leivos-unikie
Copy link
Collaborator

@leivos-unikie leivos-unikie commented Nov 8, 2024

Create keywords and tools for starting recording power measurement and extracting measurement data from the measurement agent. This PR does not yet apply the power measurement keywords. Application examples can be found in:
https://github.com/leivos-unikie/ci-test-automation/tree/power_measurement_test
https://github.com/leivos-unikie/ci-test-automation/tree/power_measurement_test2

  • IP address to measurement agent can be given from command line or from test_config

  • Login credentials to measurement agent have been added to ghaf-infra (https://github.com/tiiuae/ghaf-infra/pull/327/files). Running locally would require that you provide the credentials as variables via command line and comment out the respective line in variables.robot.

  • Use keyword Start recording power anywhere to start recording power measurement results on the measurement agent. (This will start power_mesurement.py script on RPi power logger https://github.com/tiiuae/ghaf-power-measurement)

  • Use keyword Stop recording power to stop recording power measurement results on the measurement agent.

  • Use keyword Get power record with filename argument to copy the power record file to test agent.

  • Power measurement keywords are filled with Run Keyword And Ignore Error to prevent any potential errors causing any tests, setups or teardowns to fail. This enables usage of power measurement in ci-test-automation so that the test setups missing power measurement HW are not affected.

  • The power measurement tooling monitors also measurement frequency:
    A warning of unusually low measurement frequency will be shown in the power plot in case of drop in the measurement frequency. This can help in detecting any problems in the measurement hardware.

@leivos-unikie leivos-unikie marked this pull request as draft November 8, 2024 11:46
@leivos-unikie leivos-unikie force-pushed the power_measurement branch 2 times, most recently from e3ee99a to 05d3d2c Compare November 26, 2024 11:56
@leivos-unikie leivos-unikie force-pushed the power_measurement branch 2 times, most recently from 6bbfd46 to c56c375 Compare December 4, 2024 17:57
@leivos-unikie leivos-unikie marked this pull request as ready for review December 4, 2024 17:58
@leivos-unikie leivos-unikie force-pushed the power_measurement branch 3 times, most recently from c485859 to 611b65f Compare December 5, 2024 20:42
Prevent power measurement errors failing any tests.

Monitor also drops in measurement frequency:
A warning of unusually low measurement frequency
will be shown in the power plot in case of drop in
the measurement frequency. This can help in detecting
any problems in the measurement hardware.

Signed-off-by: Samuli Leivo <[email protected]>
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.

1 participant