Commit 1b3bebea authored by Vasilis Tsiligiannis's avatar Vasilis Tsiligiannis

Do not start 'rigtld' (fixes #300)

Assume that 'rigctld' is running on the system through a process
manager.
Signed-off-by: Vasilis Tsiligiannis's avatarVasilis Tsiligiannis <acinonyx@openwrt.gr>
parent 5d0f82a9
Pipeline #83246165 passed with stages
in 7 minutes and 3 seconds
......@@ -12,7 +12,7 @@ from validators.url import url
import satnogsclient.config
from satnogsclient.locator import locator
from satnogsclient.scheduler.tasks import exec_rigctld, status_listener
from satnogsclient.scheduler.tasks import status_listener
from satnogsclient.settings import GPSD_ENABLED, LOG_FORMAT, LOG_LEVEL, \
SATNOGS_API_TOKEN, SATNOGS_NETWORK_API_URL, SATNOGS_STATION_ELEV, \
SATNOGS_STATION_ID, SATNOGS_STATION_LAT, SATNOGS_STATION_LON
......@@ -55,7 +55,6 @@ def main():
ser = threading.Thread(target=status_listener, args=())
ser.daemon = True
ser.start()
exec_rigctld()
LOGGER.info('Press Ctrl+C to exit SatNOGS poller')
while True:
time.sleep(10)
......@@ -4,7 +4,6 @@ import logging
import os
import signal
import subprocess
from multiprocessing import Process
import requests
from dateutil import parser
......@@ -212,26 +211,3 @@ def get_observation_list():
def get_observation(job_id):
obs = SCHEDULER.get_job(job_id)
return obs
def exec_rigctld():
rig = Process(target=rigctld_subprocess, args=())
rig.start()
def rigctld_subprocess():
# Start rigctl daemon
rig_args = ["rigctld"]
if settings.RIG_MODEL != "":
rig_args += ["-m", settings.RIG_MODEL]
if settings.RIG_FILE != "":
rig_args += ["-r", settings.RIG_FILE]
if settings.RIG_PTT_FILE != "":
rig_args += ["-p", settings.RIG_PTT_FILE]
if settings.RIG_PTT_TYPE != "":
rig_args += ["-P", settings.RIG_PTT_TYPE]
if settings.RIG_SERIAL_SPEED != "":
rig_args += ["-s", settings.RIG_SERIAL_SPEED]
rig_args += ["-t", str(settings.SATNOGS_RIG_PORT)]
LOGGER.info('Starting rigctl daemon')
subprocess.call(rig_args)
......@@ -72,13 +72,6 @@ SATNOGS_ROT_THRESHOLD = int(environ.get('SATNOGS_ROT_THRESHOLD', 4))
SATNOGS_ROT_FLIP = bool(strtobool(environ.get('SATNOGS_ROT_FLIP', 'False')))
SATNOGS_ROT_FLIP_ANGLE = int(environ.get('SATNOGS_ROT_FLIP_ANGLE', 75))
# Rigctld settings
RIG_MODEL = ""
RIG_FILE = ""
RIG_PTT_FILE = ""
RIG_PTT_TYPE = ""
RIG_SERIAL_SPEED = ""
# Common script parameters
SATNOGS_DOPPLER_CORR_PER_SEC = environ.get('SATNOGS_DOPPLER_CORR_PER_SEC', None)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment