Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SVXLink fails to successfully stay running #57

Closed
mytechguyri opened this issue Jan 22, 2019 · 7 comments
Closed

SVXLink fails to successfully stay running #57

mytechguyri opened this issue Jan 22, 2019 · 7 comments

Comments

@mytechguyri
Copy link

Open first boot, the following error message is recorded in the repeater log
Tue Jan 22 22:04:20 2019: *** ERROR: No logics available. Bailing out...
Tue Jan 22 22:04:21 2019: SvxLink v1.6.99.10 Copyright (C) 2003-2017 Tobias Blomberg / SM0SVX
Tue Jan 22 22:04:21 2019:
Tue Jan 22 22:04:21 2019: SvxLink comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
Tue Jan 22 22:04:21 2019: welcome to redistribute it in accordance with the terms and conditions in the
Tue Jan 22 22:04:21 2019: GNU GPL (General Public License) version 2 or later.
Tue Jan 22 22:04:21 2019:
Tue Jan 22 22:04:21 2019: Using configuration file: /etc/svxlink/svxlink.conf
Tue Jan 22 22:04:21 2019: --- Using sample rate 48000Hz
Tue Jan 22 22:04:21 2019:
Tue Jan 22 22:04:21 2019: Starting logic: ORP_RepeaterLogic_Port1
Tue Jan 22 22:04:21 2019: Loading RX: RX_Port1
Tue Jan 22 22:04:21 2019: Loading TX: TX_Port1
Tue Jan 22 22:04:21 2019: *** ERROR: Could not open GPIO /sys/class/gpio/gpio506/value for writing in transmitter TX_Port1.
Tue Jan 22 22:04:21 2019: *** ERROR: Could not initialize TX "TX_Port1"
Tue Jan 22 22:04:21 2019: *** ERROR: Could not initialize Logic object "ORP_RepeaterLogic_Port1". Skipping...
Tue Jan 22 22:04:21 2019: *** ERROR: No logics available. Bailing out...

Restarting SVXLink gives the same result, it will not stay running.
If I go to Interfaces, reload the presets for my PiRepeater 1X, and update the ports (even though they appear correct when I went to the screen, input port 26, output port 506) THEN restart SVXLink, NOW it stays running until I reboot the PI... then the problem starts over again, and I must reconfigure the ports for the interface again.

@mytechguyri
Copy link
Author

After reconfiguring ports, and restarting, the log shows successful restart
Tue Jan 22 22:25:59 2019: *** ERROR: Squelch detector initialization failed for RX "RX_Port1"
Tue Jan 22 22:25:59 2019: *** ERROR: Could not initialize RX "RX_Port1"
Tue Jan 22 22:25:59 2019: *** ERROR: Could not initialize Logic object "ORP_RepeaterLogic_Port1". Skipping...
Tue Jan 22 22:25:59 2019: *** ERROR: No logics available. Bailing out...
Tue Jan 22 22:26:02 2019: SvxLink v1.6.99.10 Copyright (C) 2003-2017 Tobias Blomberg / SM0SVX
Tue Jan 22 22:26:02 2019:
Tue Jan 22 22:26:02 2019: SvxLink comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
Tue Jan 22 22:26:02 2019: welcome to redistribute it in accordance with the terms and conditions in the
Tue Jan 22 22:26:02 2019: GNU GPL (General Public License) version 2 or later.
Tue Jan 22 22:26:02 2019:
Tue Jan 22 22:26:02 2019: Using configuration file: /etc/svxlink/svxlink.conf
Tue Jan 22 22:26:02 2019: --- Using sample rate 48000Hz
Tue Jan 22 22:26:02 2019:
Tue Jan 22 22:26:02 2019: Starting logic: ORP_RepeaterLogic_Port1
Tue Jan 22 22:26:02 2019: Loading RX: RX_Port1
Tue Jan 22 22:26:02 2019: Loading TX: TX_Port1
Tue Jan 22 22:26:02 2019: ORP_RepeaterLogic_Port1: Event handler script successfully loaded.

@mytechguyri
Copy link
Author

Problem is that the gpio ports are initialized too early in the boot process. Change to systemd config so that they don't load until after network ready.

@Dloranger
Copy link
Contributor

After=network.target

@Dloranger
Copy link
Contributor

needs confirmed, but I think this is the correct edits

image

@mytechguyri
Copy link
Author

mytechguyri commented Apr 19, 2019 via email

@Dloranger
Copy link
Contributor

This seems to work reliably on my pi zero with a wifi dongle

[Unit]
Description=SvxLink repeater control software GPIO setup
Documentation=man:svxlink(1)
# fix to address the gpio not exporting at boot
Requires=systemd-modules-load.service
After=systemd-modules.load.service
After=network.target
Before=sysvinit.target
ConditionPathExists=/sys/class/i2c-adapter

[Service]
Type=oneshot
ExecStart=/usr/sbin/svxlink_gpio_up
ExecStop=/usr/sbin/svxlink_gpio_down
#Restart=on-failure
TimeoutStartSec=60
WorkingDirectory=/etc/svxlink
RemainAfterExit=True

@abcrawford
Copy link
Contributor

This was address in the 2.1.x build script.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants