had some time today --for shading add this to panelconf β
LAT=xxxxx #your latitude and longitude
LON=xxxxx
altitude=$(python3 -W ignore altitude.py -lon $LON -lat $LAT -t $2)
#altitude=$( printf "%.0f" $altitude)
#echo $altitude
####SHADING####################
SHADING1=1 #
SHADING2=1 #
SHADING3=1 #
###group1#####
UPPER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) ### 1/2 hr blocks 3,2,1 depicts noon location
LOWER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
PERCENT=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
#####PROCESS######
upper=$(echo ${UPPER[$1]} )
lower=$(echo ${LOWER[$1]} )
if (( $upper != 0 )); then
percent=$(echo ${PERCENT[$1]} )
percent=$(echo "($percent) / 100"| bc -l)
x=$(echo " $upper - $lower "| bc -l)
y=$(echo "$upper - $altitude"| bc -l)
FACTOR=$(echo "(($y/$x))"| bc -l)
SHADING1=$(echo "(1-($FACTOR*$percent))"| bc -l)
FACTOR=$(echo "scale=0; $FACTOR*100 /1" |bc) # scaling to remove decimal and float
if (( $FACTOR > 100 )); then SHADING1=$percent; fi
if (( $FACTOR <= 0 )); then SHADING1=1; fi
fi
#echo shading1 $SHADING1
###group2#####
UPPER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) ### 1/2 hr blocks 3,2,1 depicts noon location
LOWER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
PERCENT=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
#####PROCESS######
upper=$(echo ${UPPER[$1]} )
lower=$(echo ${LOWER[$1]} )
percent=$(echo ${PERCENT[$1]} )
if (( $upper != 0 )); then
percent=$(echo "$percent / 100"| bc -l)
x=$(echo " $upper - $lower "| bc -l)
y=$(echo "$upper - $altitude"| bc -l)
FACTOR=$(echo "(($y/$x))"| bc -l)
SHADING2=$(echo "(1-($FACTOR*$percent))"| bc -l)
FACTOR=$(echo "scale=0; $FACTOR*100 /1" |bc) # scaling to remove decimal and float
if (( $FACTOR > 100 )); then SHADING2=$percent; fi
if (( $FACTOR <= 0 )); then SHADING2=1; fi
fi
#echo shading2 $SHADING2
###group3#####
UPPER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) ### 1/2 hr blocks 3,2,1 depicts noon location
LOWER=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
PERCENT=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)
#####PROCESS######
upper=$(echo ${UPPER[$1]} )
lower=$(echo ${LOWER[$1]} )
percent=$(echo ${PERCENT[$1]} )
if (( $upper != 0 )); then
percent=$(echo "$percent / 100"| bc -l)
x=$(echo " $upper - $lower "| bc -l)
y=$(echo "$upper - $altitude"| bc -l)
FACTOR=$(echo "(($y/$x))"| bc -l)
SHADING3=$(echo "(1-($FACTOR*$percent))"| bc -l)
FACTOR=$(echo "scale=0; $FACTOR*100 /1" |bc) # scaling to remove decimal and float
if (( $FACTOR > 100 )); then SHADING3=$percent; fi
if (( $FACTOR <= 0 )); then SHADING3=1; fi
fi
#echo shading3 $SHADING3
and then modify the second last line in panelconf to this
TOTAL=$( echo "((($Group3*$SHADING3)+($G3w * $albedo/100)) + (($Group2*$SHADING2)+($G2w * $albedo/100)) + (($Group1*$SHADING1)+($G1w * $albedo/100))) * $inverter" | bc -l)
and you have to modify the solar API on the potential variable there are three to each solar-api
potential=$(./panelconf1 $numberA $Time)
and copy radiation.py and rename to altitude.py
commentt out the last line in it and uncomment
#print(altitude_deg) as mentioned above