mirror of
https://github.com/markqvist/LXST.git
synced 2026-04-27 14:20:39 +00:00
Sync upstream
This commit is contained in:
parent
8b23d792a6
commit
54d73da83c
9 changed files with 19 additions and 11 deletions
|
|
@ -8,8 +8,6 @@ from collections import deque
|
||||||
from .Codecs import Codec, CodecError
|
from .Codecs import Codec, CodecError
|
||||||
from .Sources import LocalSource
|
from .Sources import LocalSource
|
||||||
|
|
||||||
RNS.loglevel = RNS.LOG_DEBUG
|
|
||||||
|
|
||||||
class ToneSource(LocalSource):
|
class ToneSource(LocalSource):
|
||||||
DEFAULT_FRAME_MS = 80
|
DEFAULT_FRAME_MS = 80
|
||||||
DEFAULT_SAMPLERATE = 48000
|
DEFAULT_SAMPLERATE = 48000
|
||||||
|
|
|
||||||
|
|
@ -9,8 +9,6 @@ from .Sinks import LocalSink
|
||||||
from .Codecs import Codec, CodecError
|
from .Codecs import Codec, CodecError
|
||||||
from .Codecs.libs.pyogg import OpusFile
|
from .Codecs.libs.pyogg import OpusFile
|
||||||
|
|
||||||
RNS.loglevel = RNS.LOG_DEBUG
|
|
||||||
|
|
||||||
class LinuxBackend():
|
class LinuxBackend():
|
||||||
SAMPLERATE = 48000
|
SAMPLERATE = 48000
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -659,7 +659,7 @@ def main():
|
||||||
parser.add_argument("--rnsconfig", action="store", default=None, help="path to alternative Reticulum config directory", type=str)
|
parser.add_argument("--rnsconfig", action="store", default=None, help="path to alternative Reticulum config directory", type=str)
|
||||||
parser.add_argument("-s", "--service", action="store_true", help="run as a service", default=False)
|
parser.add_argument("-s", "--service", action="store_true", help="run as a service", default=False)
|
||||||
parser.add_argument("--systemd", action="store_true", help="display example systemd unit", default=False)
|
parser.add_argument("--systemd", action="store_true", help="display example systemd unit", default=False)
|
||||||
parser.add_argument("--version", action="version", version="rnprobe {version}".format(version=__version__))
|
parser.add_argument("--version", action="version", version="rnphone {version}".format(version=__version__))
|
||||||
parser.add_argument('-v', '--verbose', action='count', default=0)
|
parser.add_argument('-v', '--verbose', action='count', default=0)
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
__version__ = "0.2.7"
|
__version__ = "0.3.0"
|
||||||
|
|
|
||||||
14
README.md
14
README.md
|
|
@ -47,3 +47,17 @@ If you want to try out LXST, you can install it with pip:
|
||||||
```bash
|
```bash
|
||||||
pip install lxst
|
pip install lxst
|
||||||
```
|
```
|
||||||
|
|
||||||
|
On Raspberry Pi, install various dependencies with:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Audio codecs
|
||||||
|
sudo apt install python3-pip python3-pyaudio python3-dev python3-cryptography build-essential libopusfile0 libsdl2-dev libavcodec-dev libavdevice-dev libavfilter-dev portaudio19-dev codec2 libcodec2-1.0 xclip xsel
|
||||||
|
wget https://raw.githubusercontent.com/markqvist/Sideband/main/docs/utilities/pycodec2-3.0.1-cp311-cp311-linux_aarch64.whl
|
||||||
|
pip install ./pycodec2-3.0.1-cp311-cp311-linux_aarch64.whl --break-system-packages
|
||||||
|
|
||||||
|
# For hardware control over I2C:
|
||||||
|
pip install smbus2 --break-system-packages # Install smbus module if not already installed
|
||||||
|
sudo raspi-config # Enable the I2C bus under "Interface Options"
|
||||||
|
sudo apt install python3-rpi.gpio # Install gpio module system-wide
|
||||||
|
```
|
||||||
|
|
@ -2,7 +2,6 @@ import RNS
|
||||||
import LXST
|
import LXST
|
||||||
import sys
|
import sys
|
||||||
import time
|
import time
|
||||||
RNS.loglevel = RNS.LOG_DEBUG
|
|
||||||
|
|
||||||
target_frame_ms = 20
|
target_frame_ms = 20
|
||||||
pipelined_output = True
|
pipelined_output = True
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,6 @@ import RNS
|
||||||
import LXST
|
import LXST
|
||||||
import sys
|
import sys
|
||||||
import time
|
import time
|
||||||
RNS.loglevel = RNS.LOG_DEBUG
|
|
||||||
|
|
||||||
if len(sys.argv) < 2:
|
if len(sys.argv) < 2:
|
||||||
print("No codec specified")
|
print("No codec specified")
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,6 @@ import RNS
|
||||||
import LXST
|
import LXST
|
||||||
import sys
|
import sys
|
||||||
import time
|
import time
|
||||||
RNS.loglevel = RNS.LOG_DEBUG
|
|
||||||
|
|
||||||
target_frame_ms = 40
|
target_frame_ms = 40
|
||||||
tone = LXST.Generators.ToneSource(frequency=388, ease_time_ms=3.14159, target_frame_ms=target_frame_ms)
|
tone = LXST.Generators.ToneSource(frequency=388, ease_time_ms=3.14159, target_frame_ms=target_frame_ms)
|
||||||
|
|
|
||||||
5
setup.py
5
setup.py
|
|
@ -40,10 +40,11 @@ setuptools.setup(
|
||||||
'rnphone=LXST.Utilities.rnphone:main',
|
'rnphone=LXST.Utilities.rnphone:main',
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
install_requires=["rns>=0.9.3",
|
install_requires=["rns>=0.9.5",
|
||||||
|
"lxmf>=0.7.0",
|
||||||
"soundcard",
|
"soundcard",
|
||||||
"numpy",
|
"numpy",
|
||||||
"pycodec2",
|
"pycodec2",
|
||||||
"audioop-lts>=0.2.1;python_version>='3.13'"],
|
"audioop-lts>=0.2.1;python_version>='3.13'"],
|
||||||
python_requires=">=3.7",
|
python_requires=">=3.7",
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue