more updates on proppy

pull/27/head
accius 4 months ago
parent ffb23011c0
commit 4b4cc07477

@ -23,44 +23,38 @@ RUN curl -L -o ITURHFProp "https://github.com/ITU-R-Study-Group-3/ITU-R-HF/relea
&& curl -L -o libp372.so "https://github.com/ITU-R-Study-Group-3/ITU-R-HF/releases/download/v14.3/libp372.so" \ && curl -L -o libp372.so "https://github.com/ITU-R-Study-Group-3/ITU-R-HF/releases/download/v14.3/libp372.so" \
&& chmod +x ITURHFProp && chmod +x ITURHFProp
# Download source to get Data files - try ITU first, then GitHub source # Download GitHub source (more reliable than ITU)
RUN curl -L -o itu-hf.zip "https://www.itu.int/en/ITU-R/study-groups/rsg3/rwp3m/Software%20Products/ITU-R-HF_14.3.zip" 2>/dev/null || true \ RUN curl -L -o source.tar.gz "https://github.com/ITU-R-Study-Group-3/ITU-R-HF/archive/refs/tags/v14.3.tar.gz" \
&& if [ -f itu-hf.zip ] && [ $(stat -c%s itu-hf.zip) -gt 1000000 ]; then \ && tar -xzf source.tar.gz \
echo "=== Using ITU download ===" && unzip -o itu-hf.zip; \ && echo "=== Source structure ===" \
else \ && ls -la ITU-R-HF-14.3/ \
echo "=== ITU download failed, using GitHub source ===" && \ && echo "=== P533 structure ===" \
curl -L -o source.tar.gz "https://github.com/ITU-R-Study-Group-3/ITU-R-HF/archive/refs/tags/v14.3.tar.gz" && \ && ls -la ITU-R-HF-14.3/P533/ 2>/dev/null || echo "No P533 dir" \
tar -xzf source.tar.gz; \ && echo "=== Finding ALL required files ===" \
fi \ && find ITU-R-HF-14.3 -name "ionos*.bin" -type f \
&& echo "=== Top level contents ===" \ && find ITU-R-HF-14.3 -name "*.ant" -type f \
&& ls -la \ && find ITU-R-HF-14.3 -name "COEFF01W.BIN" -type f
&& echo "=== All directories ===" \
&& find . -type d | head -30 \
&& echo "=== All .bin files ===" \
&& find . -name "*.bin" \
&& echo "=== All .ant files ===" \
&& find . -name "*.ant" \
&& echo "=== All COEFF files ===" \
&& find . -name "COEFF*.BIN" | head -5
# Copy Data directory from wherever it is, or build it from individual files # Create Data directory and copy ALL required files explicitly
RUN mkdir -p /opt/iturhfprop/Data && \ RUN mkdir -p /opt/iturhfprop/Data \
DATA_DIR=$(find . -type d -name "Data" | grep -v "\.git" | head -1) && \ && echo "=== Copying COEFF files ===" \
if [ -n "$DATA_DIR" ] && [ -d "$DATA_DIR" ]; then \ && find ITU-R-HF-14.3 -name "COEFF*.BIN" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; \
echo "Found Data at: $DATA_DIR" && \ && find ITU-R-HF-14.3 -name "COEFF*.txt" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; \
cp -r "$DATA_DIR"/* /opt/iturhfprop/Data/ 2>/dev/null || true; \ && echo "=== Copying ionospheric data ===" \
fi && \ && find ITU-R-HF-14.3 -name "ionos*.bin" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; \
echo "=== Copying all data files to Data/ ===" && \ && echo "=== Copying antenna files ===" \
find . -name "COEFF*.BIN" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && find ITU-R-HF-14.3 -name "*.ant" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; \
find . -name "COEFF*.txt" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && echo "=== Copying other data files ===" \
find . -name "ionos*.bin" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && find ITU-R-HF-14.3 -name "P1239*.txt" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; 2>/dev/null || true \
find . -name "*.ant" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && find ITU-R-HF-14.3 -name "P372*.txt" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; 2>/dev/null || true \
find . -name "P1239*.txt" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && find ITU-R-HF-14.3 -name "anthr.dat" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; 2>/dev/null || true \
find . -name "P372*.txt" -exec cp {} /opt/iturhfprop/Data/ \; 2>/dev/null || true && \ && find ITU-R-HF-14.3 -name "*.csv" -type f -exec cp -v {} /opt/iturhfprop/Data/ \; 2>/dev/null || true \
echo "=== Final Data contents ===" && ls -la /opt/iturhfprop/Data/ | head -30 && echo "=== Final Data directory ===" \
&& ls -la /opt/iturhfprop/Data/ \
&& echo "=== File count: $(ls -1 /opt/iturhfprop/Data/ | wc -l) ==="
# Cleanup downloaded archives # Cleanup
RUN rm -rf ITU-R-HF* itu-hf.zip source.tar.gz P533 *.exe *.dll 2>/dev/null || true RUN rm -rf ITU-R-HF-14.3 source.tar.gz
# Set library path so ITURHFProp can find shared libs # Set library path so ITURHFProp can find shared libs
ENV LD_LIBRARY_PATH=/opt/iturhfprop:$LD_LIBRARY_PATH ENV LD_LIBRARY_PATH=/opt/iturhfprop:$LD_LIBRARY_PATH

@ -36,9 +36,9 @@ if (!fs.existsSync(TEMP_DIR)) {
fs.mkdirSync(TEMP_DIR, { recursive: true }); fs.mkdirSync(TEMP_DIR, { recursive: true });
} }
// HF band frequencies (MHz) // HF band frequencies (MHz) - P.533 valid range is 2-30 MHz
const HF_BANDS = { const HF_BANDS = {
'160m': 1.9, '160m': 2.0, // Adjusted from 1.9 to meet P.533 minimum of 2 MHz
'80m': 3.5, '80m': 3.5,
'60m': 5.3, '60m': 5.3,
'40m': 7.1, '40m': 7.1,
@ -47,8 +47,8 @@ const HF_BANDS = {
'17m': 18.1, '17m': 18.1,
'15m': 21.1, '15m': 21.1,
'12m': 24.9, '12m': 24.9,
'10m': 28.1, '10m': 28.1
'6m': 50.1 // Note: 6m (50 MHz) excluded - outside P.533 HF range (2-30 MHz)
}; };
/** /**

Loading…
Cancel
Save

Powered by TurnKey Linux.