Compare commits

...

4 Commits

Author SHA1 Message Date
954e387544 updated README.md 2026-01-24 10:26:20 +01:00
f22b2a8e82 added .gitignore 2026-01-24 09:15:44 +01:00
e9da74e3c8 added usage() 2026-01-24 09:14:36 +01:00
fb803c13f0 added usage to measure_temp.sh
run-cpu-stress.sh uses the  job file in fio.
2026-01-24 06:20:50 +01:00
6 changed files with 53 additions and 4 deletions

2
.gitignore vendored Normal file
View File

@@ -0,0 +1,2 @@
*.log

View File

@@ -1,3 +1,5 @@
# pistress # pistress
Measure the CPU core temperature on a Raspberry Pi on full load A bunch of scripts for measuring the core temperature of the Raspberry Pi 5 CPU under full load
and plotting graphs .
Requirements: fio, gnuplot

View File

@@ -1,6 +1,21 @@
#!/bin/bash #!/bin/bash
START=$(date +%s) START=$(date +%s)
usage() {
local name=${0##*/}
cat <<-EOF
Usage: ${name} [-h || --help]
measures the pu core temperature an echoes with a squenence number to stdout.
EOF
}
if [[ "$1" == "-h" || "$1" == "--help" ]]; then
usage
exit 0
fi
while true; do while true; do
NOW=$(date +%s) NOW=$(date +%s)
TS=$((NOW - START)) TS=$((NOW - START))

View File

@@ -1,12 +1,27 @@
#!/bin/bash #!/bin/bash
usage() {
local name=${0##*/}
cat <<-EOF
Usage: ${name} [-h || --help] <logfile> <outfile> <title>
Generates graph of the <logfile> and writes it to <outfile>
EOF
}
if [[ "$1" == "-h" || "$1" == "--help" ]]; then
usage
exit 0
fi
# Eingabeparameter # Eingabeparameter
LOGFILE="${1}" LOGFILE="${1}"
OUTFILE="${2}" OUTFILE="${2}"
TITLE="${3}" TITLE="${3}"
if [ -z "$LOGFILE" ] || [ -z "$OUTFILE" ] || [ -z "$TITLE" ]; then if [ -z "$LOGFILE" ] || [ -z "$OUTFILE" ] || [ -z "$TITLE" ]; then
echo "Usage: ${0} <temp.log> <output.png> <title>" usage
exit 1 exit 1
fi fi

View File

@@ -5,8 +5,23 @@ ICE_LOG="${2}"
OUTFILE="${3}" OUTFILE="${3}"
TITLE="${4} TITLE="${4}
usage() {
local name=${0##*/}
cat <<-EOF
Usage: ${name} [-h || --help] <logfile>i <logfile2> <outfile> <title>
Generates graph of the <logfile> and <logfile2> and writes it to <outfile>
EOF
}
if [[ "$1" == "-h" || "$1" == "--help" ]]; then
usage
exit 0
fi
if [ -z "${ACTIVE_LOG}" ] || [ -z "${ICE_LOG}" ] || [ -z "${OUTFILE}" ]; then if [ -z "${ACTIVE_LOG}" ] || [ -z "${ICE_LOG}" ] || [ -z "${OUTFILE}" ]; then
echo "Usage: $0 <temp_active.log> <temp_ice.log> <output.png>" usage
exit 1 exit 1
fi fi

View File

@@ -1,5 +1,5 @@
temp_data.sh > temp.log & temp_data.sh > temp.log &
TPID=$! TPID=$!
fio ~/git/fio/jobs/fio_cpu fio fio/fio_cpu
kill $TPID kill $TPID