pydbxdriverack 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,52 @@
1
+ name: Upload Python Package
2
+
3
+ on:
4
+ release:
5
+ types: [published]
6
+
7
+ permissions:
8
+ contents: read
9
+
10
+ jobs:
11
+ release-build:
12
+ runs-on: ubuntu-latest
13
+
14
+ steps:
15
+ - uses: actions/checkout@v4
16
+
17
+ - name: Set up uv
18
+ uses: astral-sh/setup-uv@v5
19
+ with:
20
+ enable-cache: true
21
+ python-version: "3.14"
22
+
23
+ - name: Build release distributions
24
+ run: uv build
25
+
26
+ - name: Upload distributions
27
+ uses: actions/upload-artifact@v4
28
+ with:
29
+ name: release-dists
30
+ path: dist/
31
+
32
+ pypi-publish:
33
+ runs-on: ubuntu-latest
34
+ needs:
35
+ - release-build
36
+ permissions:
37
+ id-token: write
38
+
39
+ environment:
40
+ name: pypi
41
+
42
+ steps:
43
+ - name: Retrieve release distributions
44
+ uses: actions/download-artifact@v4
45
+ with:
46
+ name: release-dists
47
+ path: dist/
48
+
49
+ - name: Publish release distributions to PyPI
50
+ uses: pypa/gh-action-pypi-publish@release/v1
51
+ with:
52
+ packages-dir: dist/
@@ -0,0 +1,140 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ pip-wheel-metadata/
24
+ share/python-wheels/
25
+ *.egg-info/
26
+ .installed.cfg
27
+ *.egg
28
+ MANIFEST
29
+
30
+ # PyInstaller
31
+ *.manifest
32
+ *.spec
33
+
34
+ # Installer logs
35
+ pip-log.txt
36
+ pip-delete-this-directory.txt
37
+
38
+ # Unit test / coverage reports
39
+ htmlcov/
40
+ .tox/
41
+ .nox/
42
+ .coverage
43
+ .coverage.*
44
+ .cache
45
+ nosetests.xml
46
+ coverage.xml
47
+ *.cover
48
+ *.py,cover
49
+ .hypothesis/
50
+ .pytest_cache/
51
+
52
+ # Translations
53
+ *.mo
54
+ *.pot
55
+
56
+ # Django stuff:
57
+ *.log
58
+ local_settings.py
59
+ db.sqlite3
60
+ db.sqlite3-journal
61
+
62
+ # Flask stuff:
63
+ instance/
64
+ .webassets-cache
65
+
66
+ # Scrapy stuff:
67
+ .scrapy
68
+
69
+ # Sphinx documentation
70
+ docs/_build/
71
+
72
+ # PyBuilder
73
+ target/
74
+
75
+ # Jupyter Notebook
76
+ .ipynb_checkpoints
77
+
78
+ # IPython
79
+ profile_default/
80
+ ipython_config.py
81
+
82
+ # pyenv
83
+ .python-version
84
+
85
+ # pipenv
86
+ Pipfile.lock
87
+
88
+ # PEP 582
89
+ __pypackages__/
90
+
91
+ # Celery stuff
92
+ celerybeat-schedule
93
+ celerybeat.pid
94
+
95
+ # SageMath parsed files
96
+ *.sage.py
97
+
98
+ # Environments
99
+ .env
100
+ .venv
101
+ env/
102
+ venv/
103
+ ENV/
104
+ env.bak/
105
+ venv.bak/
106
+
107
+ # Spyder project settings
108
+ .spyderproject
109
+ .spyproject
110
+
111
+ # Rope project settings
112
+ .ropeproject
113
+
114
+ # mkdocs documentation
115
+ /site
116
+
117
+ # mypy
118
+ .mypy_cache/
119
+ .dmypy.json
120
+ dmypy.json
121
+
122
+ # Pyre type checker
123
+ .pyre/
124
+
125
+ # IDE
126
+ .vscode/
127
+ .idea/
128
+ *.swp
129
+ *.swo
130
+ *~
131
+ .DS_Store
132
+
133
+ # UV specific
134
+ .venv/
135
+ uv.lock
136
+
137
+ # Test/temporary files
138
+ .gemini
139
+ test.html
140
+ wireshark_tests
@@ -0,0 +1,59 @@
1
+ exclude: |
2
+ (?x)^(
3
+ \.git|
4
+ \.venv|
5
+ __pycache__|
6
+ build|
7
+ dist
8
+ )/
9
+
10
+ repos:
11
+ # Standard pre-commit hooks
12
+ - repo: https://github.com/pre-commit/pre-commit-hooks
13
+ rev: v4.5.0
14
+ hooks:
15
+ - id: trailing-whitespace
16
+ - id: end-of-file-fixer
17
+ - id: check-yaml
18
+ - id: check-added-large-files
19
+ - id: check-merge-conflict
20
+ - id: debug-statements
21
+
22
+ # Black - Code formatter
23
+ - repo: https://github.com/psf/black
24
+ rev: 24.1.1
25
+ hooks:
26
+ - id: black
27
+ args:
28
+ - --line-length=100
29
+ - --target-version=py39
30
+
31
+ # Ruff - Linter
32
+ - repo: https://github.com/astral-sh/ruff-pre-commit
33
+ rev: v0.1.14
34
+ hooks:
35
+ - id: ruff
36
+ args:
37
+ - --fix
38
+ - --select=E,F,W,I,N,UP,B,A
39
+ - --line-length=100
40
+ - --target-version=py39
41
+
42
+ # MyPy - Type checker
43
+ - repo: https://github.com/pre-commit/mirrors-mypy
44
+ rev: v1.8.0
45
+ hooks:
46
+ - id: mypy
47
+ additional_dependencies:
48
+ - types-requests>=2.31.0
49
+ - types-PyYAML>=6.0.0
50
+ args:
51
+ - --warn-return-any
52
+ - --warn-unused-configs
53
+ - --check-untyped-defs
54
+ - --no-implicit-optional
55
+ - --warn-redundant-casts
56
+ - --warn-unused-ignores
57
+ - --warn-no-return
58
+ - --strict-equality
59
+ - --ignore-missing-imports
@@ -0,0 +1,123 @@
1
+ Metadata-Version: 2.4
2
+ Name: pydbxdriverack
3
+ Version: 0.1.0
4
+ Summary: Python library for connecting and managing DBX DriveRack devices
5
+ Project-URL: Homepage, https://github.com/matteogheza/pydbxdriverack
6
+ Project-URL: Documentation, https://github.com/matteogheza/pydbxdriverack?tab=readme-ov-file#usage
7
+ Project-URL: Repository, https://github.com/matteogheza/pydbxdriverack.git
8
+ Project-URL: Issues, https://github.com/matteogheza/pydbxdriverack/issues
9
+ Author-email: Matteo Gheza <me@matteogheza.it>
10
+ License-Expression: GPL-3.0-only
11
+ Keywords: audio,connection,dbx,device,driverack,dsp
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Intended Audience :: Other Audience
15
+ Classifier: Intended Audience :: System Administrators
16
+ Classifier: Natural Language :: English
17
+ Classifier: Programming Language :: Python :: 3
18
+ Classifier: Programming Language :: Python :: 3.9
19
+ Classifier: Programming Language :: Python :: 3.10
20
+ Classifier: Programming Language :: Python :: 3.11
21
+ Classifier: Programming Language :: Python :: 3.12
22
+ Classifier: Programming Language :: Python :: 3.13
23
+ Classifier: Programming Language :: Python :: 3.14
24
+ Classifier: Programming Language :: Python :: 3.15
25
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
26
+ Classifier: Topic :: System :: Hardware :: Hardware Drivers
27
+ Requires-Python: >=3.9
28
+ Description-Content-Type: text/markdown
29
+
30
+ # pydbxdriverack
31
+
32
+ Python library for discovering, connecting to, and controlling dbx DriveRack PA2 devices.
33
+
34
+ ## Features
35
+
36
+ - Discover PA2 devices on the local network (UDP broadcast)
37
+ - Connect and authenticate over TCP
38
+ - Read device info (name, class, firmware)
39
+ - Recall presets and list preset names
40
+ - Control output mutes
41
+ - Read meter and limiter data
42
+ - Monitor AFS (Advanced Feedback Suppression) state
43
+
44
+ ## 🤖 AI Assistance Disclosure
45
+
46
+ Parts of this project were developed with the assistance of Artificial Intelligence. AI tools were utilized as an accelerator to:
47
+ * Co-author and refine segments of the core library code.
48
+ * Help parse and structure raw data payloads during the reverse-engineering of the original hardware protocol.
49
+ * Transform early functional prototypes into a structured, production-ready package architecture.
50
+ * Generate test suites (`pytest`) and draft structural documentation.
51
+
52
+ While AI assisted in speeding up the development workflow, all architectural decisions, hardware testing, protocol verification, and final code reviews were executed entirely by the author to ensure reliability and accuracy.
53
+
54
+ ---
55
+
56
+ ## Installation
57
+
58
+ Install from source:
59
+
60
+ ```bash
61
+ pip install .
62
+ ```
63
+
64
+ For development dependencies:
65
+
66
+ ```bash
67
+ pip install -e .
68
+ pip install pytest pytest-cov pytest-asyncio black ruff mypy pre-commit
69
+ ```
70
+
71
+ ## Quick Start
72
+
73
+ ```python
74
+ import asyncio
75
+
76
+ from pydbxdriverack.connection import PA2Connection
77
+ from pydbxdriverack.device import PA2Device
78
+ from pydbxdriverack.discovery import async_discover_devices
79
+
80
+
81
+ async def main() -> None:
82
+ devices = await async_discover_devices(timeout=3)
83
+ if not devices:
84
+ print("No DriveRack PA2 found")
85
+ return
86
+
87
+ host = devices[0]
88
+ conn = PA2Connection(host, password="administrator")
89
+ await conn.connect()
90
+
91
+ try:
92
+ pa2 = PA2Device(conn)
93
+ await pa2.async_update_info()
94
+
95
+ print("Connected to:", pa2.device_name)
96
+ print("Firmware:", pa2.software_version)
97
+
98
+ # Example: unmute all outputs
99
+ await pa2.async_unmute_all()
100
+ finally:
101
+ await conn.disconnect()
102
+
103
+
104
+ if __name__ == "__main__":
105
+ asyncio.run(main())
106
+ ```
107
+
108
+ ## Running Tests
109
+
110
+ ```bash
111
+ pytest
112
+ ```
113
+
114
+ ## Project Layout
115
+
116
+ - `src/pydbxdriverack/connection.py`: TCP connection and protocol request handling
117
+ - `src/pydbxdriverack/device.py`: High-level device API
118
+ - `src/pydbxdriverack/discovery.py`: UDP discovery
119
+ - `src/pydbxdriverack/const.py`: Protocol constants and paths
120
+
121
+ ## License
122
+
123
+ GPL-3.0-only
@@ -0,0 +1,94 @@
1
+ # pydbxdriverack
2
+
3
+ Python library for discovering, connecting to, and controlling dbx DriveRack PA2 devices.
4
+
5
+ ## Features
6
+
7
+ - Discover PA2 devices on the local network (UDP broadcast)
8
+ - Connect and authenticate over TCP
9
+ - Read device info (name, class, firmware)
10
+ - Recall presets and list preset names
11
+ - Control output mutes
12
+ - Read meter and limiter data
13
+ - Monitor AFS (Advanced Feedback Suppression) state
14
+
15
+ ## 🤖 AI Assistance Disclosure
16
+
17
+ Parts of this project were developed with the assistance of Artificial Intelligence. AI tools were utilized as an accelerator to:
18
+ * Co-author and refine segments of the core library code.
19
+ * Help parse and structure raw data payloads during the reverse-engineering of the original hardware protocol.
20
+ * Transform early functional prototypes into a structured, production-ready package architecture.
21
+ * Generate test suites (`pytest`) and draft structural documentation.
22
+
23
+ While AI assisted in speeding up the development workflow, all architectural decisions, hardware testing, protocol verification, and final code reviews were executed entirely by the author to ensure reliability and accuracy.
24
+
25
+ ---
26
+
27
+ ## Installation
28
+
29
+ Install from source:
30
+
31
+ ```bash
32
+ pip install .
33
+ ```
34
+
35
+ For development dependencies:
36
+
37
+ ```bash
38
+ pip install -e .
39
+ pip install pytest pytest-cov pytest-asyncio black ruff mypy pre-commit
40
+ ```
41
+
42
+ ## Quick Start
43
+
44
+ ```python
45
+ import asyncio
46
+
47
+ from pydbxdriverack.connection import PA2Connection
48
+ from pydbxdriverack.device import PA2Device
49
+ from pydbxdriverack.discovery import async_discover_devices
50
+
51
+
52
+ async def main() -> None:
53
+ devices = await async_discover_devices(timeout=3)
54
+ if not devices:
55
+ print("No DriveRack PA2 found")
56
+ return
57
+
58
+ host = devices[0]
59
+ conn = PA2Connection(host, password="administrator")
60
+ await conn.connect()
61
+
62
+ try:
63
+ pa2 = PA2Device(conn)
64
+ await pa2.async_update_info()
65
+
66
+ print("Connected to:", pa2.device_name)
67
+ print("Firmware:", pa2.software_version)
68
+
69
+ # Example: unmute all outputs
70
+ await pa2.async_unmute_all()
71
+ finally:
72
+ await conn.disconnect()
73
+
74
+
75
+ if __name__ == "__main__":
76
+ asyncio.run(main())
77
+ ```
78
+
79
+ ## Running Tests
80
+
81
+ ```bash
82
+ pytest
83
+ ```
84
+
85
+ ## Project Layout
86
+
87
+ - `src/pydbxdriverack/connection.py`: TCP connection and protocol request handling
88
+ - `src/pydbxdriverack/device.py`: High-level device API
89
+ - `src/pydbxdriverack/discovery.py`: UDP discovery
90
+ - `src/pydbxdriverack/const.py`: Protocol constants and paths
91
+
92
+ ## License
93
+
94
+ GPL-3.0-only
@@ -0,0 +1,114 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "pydbxdriverack"
7
+ version = "0.1.0"
8
+ description = "Python library for connecting and managing DBX DriveRack devices"
9
+ readme = "README.md"
10
+ requires-python = ">=3.9"
11
+ license = "GPL-3.0-only"
12
+ authors = [
13
+ {name = "Matteo Gheza", email = "me@matteogheza.it"}
14
+ ]
15
+ keywords = ["dbx", "driverack", "dsp", "audio", "device", "connection"]
16
+ classifiers = [
17
+ "Development Status :: 3 - Alpha",
18
+
19
+ "Intended Audience :: Developers",
20
+ "Intended Audience :: System Administrators",
21
+ "Intended Audience :: Other Audience",
22
+
23
+ "Topic :: System :: Hardware :: Hardware Drivers",
24
+ "Topic :: Software Development :: Libraries :: Python Modules",
25
+
26
+ "Natural Language :: English",
27
+
28
+ "Programming Language :: Python :: 3",
29
+ "Programming Language :: Python :: 3.9",
30
+ "Programming Language :: Python :: 3.10",
31
+ "Programming Language :: Python :: 3.11",
32
+ "Programming Language :: Python :: 3.12",
33
+ "Programming Language :: Python :: 3.13",
34
+ "Programming Language :: Python :: 3.14",
35
+ "Programming Language :: Python :: 3.15",
36
+ ]
37
+
38
+ dependencies = []
39
+
40
+ [dependency-groups]
41
+ dev = [
42
+ "pytest>=7.4.0",
43
+ "pytest-cov>=4.1.0",
44
+ "pytest-asyncio>=0.21.0",
45
+ "black>=23.7.0",
46
+ "ruff>=0.0.280",
47
+ "mypy>=1.4.1",
48
+ "pre-commit>=3.3.3"
49
+ ]
50
+ test = [
51
+ "pytest>=7.4.0",
52
+ "pytest-cov>=4.1.0",
53
+ ]
54
+
55
+ [project.urls]
56
+ Homepage = "https://github.com/matteogheza/pydbxdriverack"
57
+ Documentation = "https://github.com/matteogheza/pydbxdriverack?tab=readme-ov-file#usage"
58
+ Repository = "https://github.com/matteogheza/pydbxdriverack.git"
59
+ Issues = "https://github.com/matteogheza/pydbxdriverack/issues"
60
+
61
+ [tool.hatch.build.targets.wheel]
62
+ packages = ["src/pydbxdriverack"]
63
+
64
+ [tool.black]
65
+ line-length = 100
66
+ target-version = ["py39"]
67
+ include = '\.pyi?$'
68
+ extend-exclude = '''
69
+ /(
70
+ # directories
71
+ \.eggs
72
+ | \.git
73
+ | \.hg
74
+ | \.mypy_cache
75
+ | \.tox
76
+ | \.venv
77
+ | build
78
+ | dist
79
+ )/
80
+ '''
81
+
82
+ [tool.ruff]
83
+ lint.select = ["E", "F", "W", "I", "N", "UP", "B", "A"]
84
+ lint.ignore = []
85
+ line-length = 100
86
+ target-version = "py39"
87
+ exclude = [
88
+ ".git",
89
+ ".venv",
90
+ "__pycache__",
91
+ "build",
92
+ "dist",
93
+ ]
94
+
95
+ [tool.mypy]
96
+ python_version = "3.9"
97
+ warn_return_any = true
98
+ warn_unused_configs = true
99
+ disallow_untyped_defs = false
100
+ disallow_incomplete_defs = false
101
+ check_untyped_defs = true
102
+ no_implicit_optional = true
103
+ warn_redundant_casts = true
104
+ warn_unused_ignores = true
105
+ warn_no_return = true
106
+ strict_equality = true
107
+
108
+ [tool.pytest.ini_options]
109
+ testpaths = ["tests"]
110
+ python_files = ["test_*.py", "*_test.py"]
111
+ addopts = "--cov=src/pydbxdriverack --cov-report=html --cov-report=term-missing"
112
+
113
+ [tool.coverage.run]
114
+ omit = ["src/pydbxdriverack/simulator/*"]
@@ -0,0 +1,19 @@
1
+ import importlib.metadata
2
+
3
+ from .connection import PA2AuthError, PA2Connection, PA2ConnectionError
4
+ from .device import PA2Device
5
+ from .discovery import async_discover_devices
6
+
7
+ try:
8
+ __version__ = importlib.metadata.version("pydbxdriverack")
9
+ except importlib.metadata.PackageNotFoundError:
10
+ __version__ = "0.0.1"
11
+
12
+ __all__ = [
13
+ "PA2Connection",
14
+ "PA2ConnectionError",
15
+ "PA2AuthError",
16
+ "PA2Device",
17
+ "async_discover_devices",
18
+ "__version__",
19
+ ]