Skip to content

Commit f0369ee

Browse files
committed
Add support for Analog Discovery 3
1 parent 754930c commit f0369ee

11 files changed

+359
-41
lines changed

.github/workflows/build.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ jobs:
1717
runs-on: ubuntu-latest
1818
steps:
1919
- name: Checkout code
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121
- name: Set up Python
22-
uses: actions/setup-python@v4
22+
uses: actions/setup-python@v5
2323
with:
24-
python-version: '3.8'
24+
python-version: '3.12'
2525
- name: Install Dependencies
2626
run: pip install -r requirements.txt
2727
- name: Check pylint, mypy, black
@@ -30,7 +30,7 @@ jobs:
3030
run: make build
3131
- name: Archive build artifacts
3232
if: always()
33-
uses: actions/upload-artifact@v2
33+
uses: actions/upload-artifact@v4
3434
with:
3535
name: distribution
3636
path: dist/

.github/workflows/publish.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
runs-on: ubuntu-latest
1818
steps:
1919
- name: Checkout code
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121
- name: Create Release
2222
id: create_release
2323
uses: actions/create-release@v1
@@ -40,11 +40,11 @@ jobs:
4040
runs-on: ubuntu-latest
4141
steps:
4242
- name: Checkout code
43-
uses: actions/checkout@v3
43+
uses: actions/checkout@v4
4444
- name: Set up Python
45-
uses: actions/setup-python@v4
45+
uses: actions/setup-python@v5
4646
with:
47-
python-version: '3.8'
47+
python-version: '3.12'
4848
- name: Install Dependencies
4949
run: pip install build twine
5050
- name: Build Package

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
__pycache__/
33
*.egg-info/
44
dist/
5+
.mypy_cache/
56

67
# Visual Studio
78
.vs/

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ with dwf.AnalogDiscovery2() as device:
2222
- Low-level API with complete access to the Digilent Waveforms API.
2323
- Powerful high-level API that supports one-line configuration statements.
2424
- Supports all sub-modules, such as oscilloscope, arbitrary waveform generator, logic analyzer, pattern generator, digital I/O, and power supplies.
25-
- Works with all WaveForms devices, such as the **Analog Discovery 2** or the **Digital Discovery**.
25+
- Works with all WaveForms devices, such as the **Analog Discovery 2**, the **Analog Discovery 3**, or the **Digital Discovery**.
2626

2727
## Installing DwfPy
2828

@@ -32,7 +32,7 @@ You can install the [DwfPy package](https://pypi.org/project/dwfpy/) from PyPI u
3232
pip install dwfpy
3333
```
3434

35-
In order to use the **DwfPy** package, you need **Python 3.6** or higher.
35+
In order to use the **DwfPy** package, you need **Python 3.8** or higher.
3636

3737
As **DwfPy** builds on top of the WaveForms API, you need to install the [WaveForms software][WaveForms-Software], which includes the required runtime components to access the WaveForms devices.
3838

pyproject.toml

+9-8
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,19 @@ build-backend = "setuptools.build_meta"
88
[tool.pylint.messages_control]
99
max-line-length = 120
1010
disable = [
11+
"cyclic-import",
12+
"duplicate-code",
13+
"no-else-return",
14+
"redefined-builtin",
15+
"too-few-public-methods",
1116
"too-many-arguments",
12-
"too-many-locals",
17+
"too-many-branches",
1318
"too-many-instance-attributes",
14-
"too-many-public-methods",
1519
"too-many-lines",
16-
"too-many-branches",
20+
"too-many-locals",
21+
"too-many-positional-arguments",
22+
"too-many-public-methods",
1723
"too-many-return-statements",
18-
"too-few-public-methods",
19-
"no-else-return",
20-
"duplicate-code",
21-
"cyclic-import",
22-
"redefined-builtin",
2324
]
2425

2526
[[tool.mypy.overrides]]

setup.cfg

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[metadata]
22
name = dwfpy
3-
version = 1.1.2
3+
version = 1.1.3
44
description = Python Bindings for Digilent WaveForms API
55
long_description = file: README.md
66
long_description_content_type = text/markdown
77
url = https://github.com/mariusgreuel/dwfpy
88
author = Marius Greuel
99
author_email = greuelm@mgtek.com
1010
license = MIT
11-
keywords = digilent,waveforms,analog discovery,digital discovery,ad2
11+
keywords = digilent,waveforms,analog discovery,digital discovery,ad2,ad3
1212
classifiers =
1313
Programming Language :: Python :: 3
1414
License :: OSI Approved :: MIT License
@@ -20,7 +20,7 @@ project_urls =
2020
package_dir =
2121
= src
2222
packages = find:
23-
python_requires = >=3.6
23+
python_requires = >=3.8
2424
install_requires =
2525
numpy
2626

src/dwfpy/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
ElectronicsExplorer,
4343
AnalogDiscovery,
4444
AnalogDiscovery2,
45+
AnalogDiscovery3,
4546
DigitalDiscovery,
4647
)
4748
from dwfpy.application import Application

src/dwfpy/bindings.py

+129-7
Large diffs are not rendered by default.

src/dwfpy/constants.py

+3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ class DeviceId(enum.IntEnum):
2020
ANALOG_DISCOVERY2 = 3
2121
DIGITAL_DISCOVERY = 4
2222
ADP3X50 = 6
23+
ECLYPSE = 7
2324
ADP5250 = 8
25+
DPS3340 = 9
26+
ANALOG_DISCOVERY3 = 10
2427

2528

2629
class DeviceType(enum.IntEnum):

0 commit comments

Comments
 (0)