Skip to content

Commit

Permalink
Add argument to only show version number
Browse files Browse the repository at this point in the history
  • Loading branch information
adelnoureddine committed Oct 20, 2023
1 parent e423a9f commit 5281ae9
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 4 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ PowerJoular supports RAPL package domain (core, including integrated graphics, a

On Raspberry Pi and Asus Tinker Board, PowerJoular uses its own research-based empirical regression models to estimate the power consumption of the ARM processor.

We currently support the following Raspberry Pi models and Asus Tinker Board:
The supported list of Raspberry Pi and Asus Tinker Board models are listed below.
We support all revisions of each model lineup. However, the model is generated and trained on a specific revision (listed between brackets), and the accuracy is best on this particular revision.

We currently support the following Raspberry Pi and Asus Tinker Board models:
- Model Zero W (rev 1.1), for 32 bits OS
- Model 1 B (rev 2), for 32 bits OS
- Model 1 B+ (rev 1.2), for 32 bits OS
Expand Down Expand Up @@ -160,4 +163,4 @@ PowerJoular is licensed under the GNU GPL 3 license only (GPL-3.0-only).
Copyright (c) 2020-2023, Adel Noureddine, Université de Pau et des Pays de l'Adour.
All rights reserved. This program and the accompanying materials are made available under the terms of the GNU General Public License v3.0 only (GPL-3.0-only) which accompanies this distribution, and is available at: https://www.gnu.org/licenses/gpl-3.0.en.html

Author : Adel Noureddine
Author : Adel Noureddine
8 changes: 7 additions & 1 deletion src/help_info.adb
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ with Ada.Characters.Latin_1; use Ada.Characters.Latin_1;
package body Help_Info is

procedure Show_Help is
Version_Number : constant String := "0.6.2";
Version_Number : constant String := "0.7.0";
begin
Put_Line (ESC & "[93m" & "~~ PowerJoular ~~" & ESC & "[0m");
Put_Line ("Version " & Version_Number);
Expand Down Expand Up @@ -51,4 +51,10 @@ package body Help_Info is
Put_Line ("Copyright (c) 2020-2023, Adel Noureddine. PowerJoular is licensed under the GNU GPL 3 license only (GPL-3.0-only)");
end;

procedure Show_Version is
Version_Number : constant String := "0.7.0";
begin
Put_Line (Version_Number);
end;

end Help_Info;
3 changes: 3 additions & 0 deletions src/help_info.ads
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,7 @@ package Help_Info is
-- Print help information on the terminal
procedure Show_Help;

-- Print version number
procedure Show_Version;

end Help_Info;
5 changes: 4 additions & 1 deletion src/powerjoular.adb
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,13 @@ begin

-- Loop over command line options
loop
case Getopt ("h t f: p: a: o: u l") is
case Getopt ("h v t f: p: a: o: u l") is
when 'h' => -- Show help
Show_Help;
return;
when 'v' => -- Show help
Show_Version;
return;
when 't' => -- Show power data on terminal
Show_Terminal := True;
when 'p' => -- Monitor a particular PID
Expand Down

0 comments on commit 5281ae9

Please sign in to comment.