Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

README.md 4.3 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. ![Aptdec logo](textlogo.png)
  2. Copyright (c) 2004-2009 Thierry Leconte (F4DWV), Xerbo (xerbo@protonmail.com) 2019-2020
  3. ## Description
  4. Aptdec is an FOSS program that decodes images transmitted by NOAA weather satellites. These satellites transmit continuously (among other things), medium resolution (1px/4km) images of the earth on 137 MHz.
  5. These transmissions could be easily received with an simple antenna and cheap SDR. Then the transmission can easily be decoded in narrow band FM mode.
  6. Aptdec can convert these audio files into `png` images.
  7. For each audio file up to 6 images can be generated:
  8. 1. Raw image: contains the 2 transmitted channel images + telemetry and synchronization pulses.
  9. 2. Calibrated channel A image
  10. 3. Calibrated channel B image
  11. 4. Temperature compensated IR image
  12. 5. Palleted image
  13. 6. MCIR (Map Color InfraRed) image
  14. The input audio file must be mono with a sample rate in the range of 4160-62400 Hz, lower samples rates will process faster.
  15. Aptdec uses `libsndfile` to read the input audio, so any format supported by `libsndfile` may be used (however it has only tested with `.wav` files).
  16. ## Compilation
  17. Aptdec is portable since it is written in standard C.
  18. It has successfully compiled and ran on Debian with both `gcc`, `clang` and `tcc` and will most likely work on any Unix platform.
  19. Just edit the Makefile and run `make` (no configure script as of right now).
  20. Aptdec uses `libsndfile`, `libpng` and `libm`.
  21. The `snd.h` and `png.h` headers must be present on your system.
  22. If they are not on standard path, edit the include path in the Makefile.
  23. ## Usage
  24. To compile
  25. `make`
  26. To run without installing
  27. `./aptdec [options] audio files...`
  28. To install
  29. `sudo make install`
  30. To run once installed
  31. `aptdec [options] audio files...`
  32. To uninstall
  33. `sudo make uninstall`
  34. ## Options
  35. ```
  36. -i [r|a|b|t|m|p]
  37. Output image type
  38. Raw (r), Channel A (a), Channel B (b), Palleted (p), Temperature (t) or MCIR (m)
  39. Default: "ab"
  40. -d <dir>
  41. Images destination directory (optional)
  42. Default: Current directory
  43. -s [15|16|17|18|19]
  44. Satellite number
  45. For temperature calibration
  46. Default: "19"
  47. -e [r|a|b|c|t|m]
  48. Effects
  49. Histogram equalise (h), Crop Telemetry (t), Denoise (d), Precipitation (p) or Linear equalise (l)
  50. Defaults: off
  51. -m <file>
  52. Map file generated by wxmap
  53. -o <filename>
  54. Output image filename
  55. -r
  56. Realtime decode. When decoding in realtime it is highly recommended to choose a plain raw image.
  57. ```
  58. ## Output
  59. Generated images are outputted in PNG and are 24 bit RGB for all image types apart from pure greyscale images.
  60. Image names are `audiofile-x.png`, where `x` is:
  61. - `r` for raw images
  62. - `a` channel A images
  63. - `b` channel B images
  64. - `p` for a paletted image
  65. - `t` for temperature calibrated images
  66. - `m` for MCIR images
  67. Currently there are 6 available effects:
  68. - `t` for crop telemetry, off by default, only has effects on raw images
  69. - `h` for histogram equalise
  70. - `d` for a median denoise filter
  71. - `p` for a precipitation overlay
  72. - `f` to flip the image (for southbound passes)
  73. - `l` to linearly equalise the image, stretch the colors in the image to black and white
  74. ## Examples
  75. `aptdec -d images -i ab *.wav`
  76. This will process all `.wav` files in the current directory, generate calibrated channel A and B images and put them in the `images` directory.
  77. `aptdec -e dh -i b audio.wav`
  78. Decode `audio.wav` with denoise and histogram equalization and save it into the current directory.
  79. `aptdec -e d -p palettes/N19-June-High-Vegetation.png -i p audio.wav`
  80. Create a false color image from the `N19-June-High-Vegetation.pn` palette.
  81. ## Realtime decoding
  82. As of recently a realtime output was added allowing realtime decoding of images.
  83. ```
  84. mkfifo /tmp/aptaudio
  85. aptdec /tmp/aptaudio
  86. sox -t pulseaudio alsa_output.pci-0000_00_1b.0.analog-stereo.monitor -c 1 -t wav /tmp/aptaudio
  87. ```
  88. Perform a realtime decode with the audio being played out of `alsa_output.pci-0000_00_1b.0.analog`. To stop the decode kill the `sox` process
  89. ## Further reading
  90. [https://noaasis.noaa.gov/NOAASIS/pubs/Users_Guide-Building_Receive_Stations_March_2009.pdf](https://noaasis.noaa.gov/NOAASIS/pubs/Users_Guide-Building_Receive_Stations_March_2009.pdf)
  91. [https://web.archive.org/web/20141220021557/https://www.ncdc.noaa.gov/oa/pod-guide/ncdc/docs/klm/tables.htm](https://web.archive.org/web/20141220021557/https://www.ncdc.noaa.gov/oa/pod-guide/ncdc/docs/klm/tables.htm)
  92. ## License
  93. See LICENSE.