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

small changes to second perf script #9

Merged
merged 1 commit into from
Oct 16, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions second_perf_script
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@ echo none | $SUDO $TEE /sys/class/leds/led0/trigger >/dev/null
while true #creates an infinite loop until the script exits itself
do

# turns on led.
turn_on_act_led

cpu_total=100
one_second=1

Expand All @@ -56,7 +53,8 @@ do
# fraction of the second that the LED will stay off
led_off_time=$(echo "$one_second - $led_on_time" | $BC -l)

# sleeps for the calculated fraction of a second
# turns on led, and sleeps for the calculated fraction of a second
turn_on_act_led
$SLEEP "$led_on_time"

# turns off led, and sleeps for the rest of the second
Expand Down