Skip to content

Commit

Permalink
add biastee (#9)
Browse files Browse the repository at this point in the history
* Add BiasTee option

* Add Biastee to read

* Update aiscatcher - linter
  • Loading branch information
kx1t authored Apr 26, 2024
1 parent 1fade0f commit 4d54a27
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ You can use `rtl_test` to see which devices and device serials are connected to
| `RTLSDR_DEVICE_GAIN` | SDR device gain. Can also be set to `auto` | `33` |
| `RTLSDR_DEVICE_PPM`| PPM deviation of your RTLSDR device | Empty |
| `RTLSDR_DEVICE_BANDWIDTH` | Channel bandwitdh of the receiver | `192K` |
| `RTLSDR_DEVICE_BIASTEE` | If set to `on`, `1`, `enabled`, or `yes`, the bias-tee function of the RTLSDR device will be switched on | Empty |
| `AISCATCHER_CHANNELS` | Channels flag for `ais-catcher`. Set to `AB` (receive on channel AB, default value if omitted), `CD` (receive on channel CD), or `CD AB` (receive on channel CD but forward this data to aggregators saying it's channel AB; this can be used to send channels CD data to aggregators that can't handle CD data) | Empty (`AB`) |
| `AISCATCHER_DECODER_MODEL` | Decoder model number for `ais-catcher` | `2` |
| `AISCATCHER_DECODER_AFC_WIDE` | `-go AFC_WIDE` flag for `ais-catcher`. Recommended to set to `on` | `on` |
Expand Down
7 changes: 4 additions & 3 deletions rootfs/etc/s6-overlay/scripts/aiscatcher
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
#!/command/with-contenv bash
# shellcheck shell=bash disable=SC1091,SC2016,SC2068,SC2076,SC2086,SC2015
# shellcheck shell=bash disable=SC1091,SC2016,SC2068,SC2076,SC2086,SC2015,SC2154

source /scripts/common
APPNAME="aiscatcher"
s6wrap=(s6wrap --quiet --timestamps --prepend="${APPNAME}")

#---------------------------------------------------------------------------------------------
# Copyright (C) 2022-2024, Ramon F. Kolb (kx1t)
Expand Down Expand Up @@ -204,6 +202,9 @@ if [[ -n "${RTLSDR_DEVICE_SERIAL}" ]]; then
#AISCATCHER_EXTRA_OPTIONS="$(sed -E 's/-c\s+[a-dA-D ]+//g' <<< "$AISCATCHER_EXTRA_OPTIONS")" # remove any -c items from param to avoid duplication
aiscatcher_command+=("-d ${RTLSDR_DEVICE_SERIAL}")
aiscatcher_command+=("-gr tuner ${RTLSDR_DEVICE_GAIN} rtlagc ON")
if chk_enabled "${RTLSDR_DEVICE_BIASTEE}"; then
aiscatcher_command+=("BIASTEE on")
fi
if [[ -n "${RTLSDR_DEVICE_PPM}" ]]; then
aiscatcher_command+=("-p ${RTLSDR_DEVICE_PPM}")
#AISCATCHER_EXTRA_OPTIONS="$(sed -E 's/-p\s+[0-9]+\s*//g'<<< "$AISCATCHER_EXTRA_OPTIONS")" # remove any -p items from param to avoid duplication
Expand Down

0 comments on commit 4d54a27

Please sign in to comment.