sdwire 0.1.2__py3-none-any.whl → 0.2.1__py3-none-any.whl
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.
- {backend → sdwire/backend}/detect.py +4 -4
- {backend → sdwire/backend}/device/sdwire.py +1 -1
- {backend → sdwire/backend}/device/sdwirec.py +1 -1
- {backend → sdwire/backend}/utils.py +3 -3
- sdwire/main.py +3 -3
- {sdwire-0.1.2.dist-info → sdwire-0.2.1.dist-info}/METADATA +58 -1
- sdwire-0.2.1.dist-info/RECORD +14 -0
- sdwire-0.1.2.dist-info/RECORD +0 -14
- {backend → sdwire/backend}/__init__.py +0 -0
- {backend → sdwire/backend}/device/usb_device.py +0 -0
- /constants.py → /sdwire/constants.py +0 -0
- {sdwire-0.1.2.dist-info → sdwire-0.2.1.dist-info}/LICENSE +0 -0
- {sdwire-0.1.2.dist-info → sdwire-0.2.1.dist-info}/WHEEL +0 -0
- {sdwire-0.1.2.dist-info → sdwire-0.2.1.dist-info}/entry_points.txt +0 -0
@@ -3,10 +3,10 @@ from typing import List
|
|
3
3
|
from adafruit_board_toolkit import circuitpython_serial as cpserial
|
4
4
|
from serial.tools.list_ports_common import ListPortInfo
|
5
5
|
|
6
|
-
import constants
|
7
|
-
from
|
8
|
-
from
|
9
|
-
from
|
6
|
+
from sdwire import constants
|
7
|
+
from .device.sdwire import SDWire
|
8
|
+
from .device.sdwirec import SDWireC
|
9
|
+
from .device.usb_device import PortInfo
|
10
10
|
|
11
11
|
import usb.core
|
12
12
|
import usb.util
|
@@ -1,9 +1,9 @@
|
|
1
1
|
import sys
|
2
2
|
import logging
|
3
3
|
import click
|
4
|
-
from
|
5
|
-
from
|
6
|
-
from
|
4
|
+
from .device.sdwire import SDWire
|
5
|
+
from .device.sdwirec import SDWireC
|
6
|
+
from . import detect
|
7
7
|
|
8
8
|
log = logging.getLogger(__name__)
|
9
9
|
|
sdwire/main.py
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
#!/usr/bin/env python
|
2
2
|
import click
|
3
|
-
from backend import utils
|
4
|
-
from backend import detect
|
5
|
-
from backend.device.sdwire import SDWire
|
3
|
+
from .backend import utils
|
4
|
+
from .backend import detect
|
5
|
+
from .backend.device.sdwire import SDWire
|
6
6
|
|
7
7
|
|
8
8
|
@click.group()
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: sdwire
|
3
|
-
Version: 0.1
|
3
|
+
Version: 0.2.1
|
4
4
|
Summary: CLI application to interact with Badgerd SDWire Gen2 devices
|
5
5
|
License: GPL-3
|
6
6
|
Author: Talha Can Havadar
|
@@ -56,3 +56,60 @@ Commands:
|
|
56
56
|
ts ts/host => connects the sdcard interface to host machine
|
57
57
|
```
|
58
58
|
|
59
|
+
## Installing
|
60
|
+
|
61
|
+
Using pip
|
62
|
+
|
63
|
+
```
|
64
|
+
pip install sdwire
|
65
|
+
```
|
66
|
+
|
67
|
+
Using apt
|
68
|
+
|
69
|
+
```
|
70
|
+
sudo add-apt-repository ppa:tchavadar/badgerd
|
71
|
+
sudo apt install python3-sdwire
|
72
|
+
```
|
73
|
+
|
74
|
+
## Listing SDWire Devices
|
75
|
+
|
76
|
+
`sdwire list` command will search through usb devices connected to the system
|
77
|
+
and prints out the list of gen2 and legacy devices.
|
78
|
+
|
79
|
+
```
|
80
|
+
❯ sdwire list
|
81
|
+
Serial Product Info
|
82
|
+
sdwire_gen2_101 [SDWire-Gen2::Badgerd Technologies]
|
83
|
+
bdgrd_sdwirec_522 [sd-wire::SRPOL]
|
84
|
+
```
|
85
|
+
|
86
|
+
## Switching SD Card Connection
|
87
|
+
|
88
|
+
`sdwire switch` command switches the sd card connection to specified direction.
|
89
|
+
If there is more than one sdwire connected to then you need specify which sdwire
|
90
|
+
you want to alter with `--serial` or `-s` options.
|
91
|
+
|
92
|
+
If there is only one sdwire connected then you dont need to specify the serial,
|
93
|
+
it will pick the one connected automatically. See the examples below.
|
94
|
+
|
95
|
+
```
|
96
|
+
❯ sdwire list
|
97
|
+
Serial Product Info
|
98
|
+
sdwire_gen2_101 [SDWire-Gen2::Badgerd Technologies]
|
99
|
+
bdgrd_sdwirec_522 [sd-wire::SRPOL]
|
100
|
+
|
101
|
+
❯ sdwire switch -s bdgrd_sdwirec_522 target
|
102
|
+
|
103
|
+
❯ sdwire switch target
|
104
|
+
Usage: sdwire switch [OPTIONS] COMMAND [ARGS]...
|
105
|
+
Try 'sdwire switch --help' for help.
|
106
|
+
|
107
|
+
Error: There is more then 1 sdwire device connected, please use --serial|-s to specify!
|
108
|
+
|
109
|
+
❯ sdwire list
|
110
|
+
Serial Product Info
|
111
|
+
bdgrd_sdwirec_522 [sd-wire::SRPOL]
|
112
|
+
|
113
|
+
❯ sdwire switch host
|
114
|
+
```
|
115
|
+
|
@@ -0,0 +1,14 @@
|
|
1
|
+
sdwire/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
+
sdwire/backend/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
3
|
+
sdwire/backend/detect.py,sha256=3iSPiG0fLjxCp5sSJ6D4AO39P2wypHY4nApsJWYgCyI,2024
|
4
|
+
sdwire/backend/device/sdwire.py,sha256=Cl1WSWdH9Zr9D0bH5g7jz_rTqJiS5KVydJfV83GUEbg,675
|
5
|
+
sdwire/backend/device/sdwirec.py,sha256=BZXvCq3bmJzzA5seCVOYIdmr6FBeAreE95_n-2kiuMQ,1035
|
6
|
+
sdwire/backend/device/usb_device.py,sha256=6Mt24B22yTD4RdY24LgnRaVtbX60EPE2SAK-pN0ZESc,775
|
7
|
+
sdwire/backend/utils.py,sha256=ruOZJTPVtTKaQOLP-FylHAb67ygoCJ-o2ug8XjQUr44,1615
|
8
|
+
sdwire/constants.py,sha256=Ip2d7ow5Nj0nO0OyHeiXuGJJcK33BGmTspLtNEduFAo,127
|
9
|
+
sdwire/main.py,sha256=ndbRoCkSckItLDH0q3zacC0mqfa0ZL-TJGDkIGJKrBU,2138
|
10
|
+
sdwire-0.2.1.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
11
|
+
sdwire-0.2.1.dist-info/METADATA,sha256=qb8ljSlQhbMmZzmsuyXHKIHhN7FpmlD4JpkvbeoNEmM,3162
|
12
|
+
sdwire-0.2.1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
13
|
+
sdwire-0.2.1.dist-info/entry_points.txt,sha256=pxy0zJKVcNWXPk5PtNjTLExOBpqFNth37wtdYdYRXCE,43
|
14
|
+
sdwire-0.2.1.dist-info/RECORD,,
|
sdwire-0.1.2.dist-info/RECORD
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
sdwire/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
backend/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
3
|
-
backend/detect.py,sha256=U1O5fbwEepFuCsxBl-MKhp1JBhQlKtBOiALxxcme5cg,2033
|
4
|
-
backend/device/sdwire.py,sha256=jNIbAqMk4cU2tRmYCYyb9lHZXFZqVb806z7STX-e6W4,689
|
5
|
-
backend/device/sdwirec.py,sha256=Uq2Y3XagHgZW6EPXmqoKiR93fV167mRmDTHIh0J6JqA,1049
|
6
|
-
backend/device/usb_device.py,sha256=6Mt24B22yTD4RdY24LgnRaVtbX60EPE2SAK-pN0ZESc,775
|
7
|
-
backend/utils.py,sha256=UXxO3eYHpYAjhp7p2CmQXORAC0_96ikXODUXRFg0LB0,1635
|
8
|
-
constants.py,sha256=Ip2d7ow5Nj0nO0OyHeiXuGJJcK33BGmTspLtNEduFAo,127
|
9
|
-
sdwire/main.py,sha256=adVUleGCnEEQp2MakaD1t3muaevxH8W74rpJGxuX98o,2135
|
10
|
-
sdwire-0.1.2.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
11
|
-
sdwire-0.1.2.dist-info/METADATA,sha256=2DBOL0aPLvHgVM8ovpbaq0l-ZIA2KiQ63bSYRKIQ_ek,1839
|
12
|
-
sdwire-0.1.2.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
13
|
-
sdwire-0.1.2.dist-info/entry_points.txt,sha256=pxy0zJKVcNWXPk5PtNjTLExOBpqFNth37wtdYdYRXCE,43
|
14
|
-
sdwire-0.1.2.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|