pypicoboot 1.1.3__py3-none-any.whl → 1.1.5__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.
- picoboot/_version.py +1 -1
- picoboot/core/enums.py +5 -0
- picoboot/picoboot.py +6 -1
- {pypicoboot-1.1.3.dist-info → pypicoboot-1.1.5.dist-info}/METADATA +1 -1
- pypicoboot-1.1.5.dist-info/RECORD +12 -0
- pypicoboot-1.1.3.dist-info/RECORD +0 -12
- {pypicoboot-1.1.3.dist-info → pypicoboot-1.1.5.dist-info}/WHEEL +0 -0
- {pypicoboot-1.1.3.dist-info → pypicoboot-1.1.5.dist-info}/top_level.txt +0 -0
picoboot/_version.py
CHANGED
picoboot/core/enums.py
CHANGED
|
@@ -24,6 +24,11 @@ class NamedIntEnum(enum.IntEnum):
|
|
|
24
24
|
def __str__(self):
|
|
25
25
|
return self.name
|
|
26
26
|
|
|
27
|
+
def __format__(self, fmt):
|
|
28
|
+
if any(c in fmt for c in "xXod"):
|
|
29
|
+
return format(self.value, fmt)
|
|
30
|
+
return self.name
|
|
31
|
+
|
|
27
32
|
@classmethod
|
|
28
33
|
def from_string(cls, value: Union[str, int]) -> "NamedIntEnum":
|
|
29
34
|
if not value:
|
picoboot/picoboot.py
CHANGED
|
@@ -361,7 +361,12 @@ class PicoBoot:
|
|
|
361
361
|
if transfer_length is None:
|
|
362
362
|
transfer_length = 0 if data_out is None else len(data_out)
|
|
363
363
|
|
|
364
|
-
|
|
364
|
+
logger.debug(f"Preparing to send command {cmd_id} (0x{cmd_id:02X}) with args length {len(args)} and transfer_length {transfer_length}")
|
|
365
|
+
try:
|
|
366
|
+
token, header = self._build_command(cmd_id, args=args, transfer_length=transfer_length)
|
|
367
|
+
except ValueError as e:
|
|
368
|
+
logger.error(f"Error building command: {e}")
|
|
369
|
+
raise
|
|
365
370
|
logger.debug(f"Sending command {cmd_id} (0x{cmd_id:02X}) with token {token} (0x{token:08X}) and transfer_length {transfer_length}")
|
|
366
371
|
|
|
367
372
|
self.ep_out.write(header, timeout=timeout)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
picoboot/__init__.py,sha256=cQPxH_qPx7ph9SQ-Z4Jc2YCU3SKYnDta6wzU-Q65suc,72
|
|
2
|
+
picoboot/_version.py,sha256=IBIa1MUqdpUxt22DZwmZqY06i-ZLW-fhyOCvwK-Q50w,778
|
|
3
|
+
picoboot/picoboot.py,sha256=1jmeh8XWI1P3rGqDAsGRUdNcI7DkEVeXov1Siz6Wn74,25206
|
|
4
|
+
picoboot/picobootmonitor.py,sha256=3msEP2S8ZS7P8QVgKpq9Z9Rcud78XygmG1_0L_OZOvs,2443
|
|
5
|
+
picoboot/utils.py,sha256=SjpAoPZrgyD9Ws7NIFVBHt0zPOb8Lpu2_lsmfeT2rXE,1083
|
|
6
|
+
picoboot/core/__init__.py,sha256=fmoYRI4KbzhLjXblEs_H9zgdCs7oDuSKeNEG_-kMgYo,32
|
|
7
|
+
picoboot/core/enums.py,sha256=ugXS-dbdnusLib_ge0vT1OugHVG9ZjJfpUR073MhwdQ,1353
|
|
8
|
+
picoboot/tools/picotool.py,sha256=e2xjIxP5UZn9yfjxUWkJXq6KQHyw4YsGbuQbTauo0-Q,94
|
|
9
|
+
pypicoboot-1.1.5.dist-info/METADATA,sha256=ToZNvxM2jo4zmYG_UqbYkdrTTUyCbPgTZxVdQMWFsvw,41111
|
|
10
|
+
pypicoboot-1.1.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
11
|
+
pypicoboot-1.1.5.dist-info/top_level.txt,sha256=sjegZQO5-kQdFOXXJHm0P7Hg1Nw4Ri0WKHnRYDTsa4I,9
|
|
12
|
+
pypicoboot-1.1.5.dist-info/RECORD,,
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
picoboot/__init__.py,sha256=cQPxH_qPx7ph9SQ-Z4Jc2YCU3SKYnDta6wzU-Q65suc,72
|
|
2
|
-
picoboot/_version.py,sha256=FjzHapAlay2lqwhKnlSSCkLPonTSJdSVFJvqRgarBRs,778
|
|
3
|
-
picoboot/picoboot.py,sha256=GwL6DFVQSzdq7NvZE7zv_PT9mPG357j2GlHuPJoezus,24938
|
|
4
|
-
picoboot/picobootmonitor.py,sha256=3msEP2S8ZS7P8QVgKpq9Z9Rcud78XygmG1_0L_OZOvs,2443
|
|
5
|
-
picoboot/utils.py,sha256=SjpAoPZrgyD9Ws7NIFVBHt0zPOb8Lpu2_lsmfeT2rXE,1083
|
|
6
|
-
picoboot/core/__init__.py,sha256=fmoYRI4KbzhLjXblEs_H9zgdCs7oDuSKeNEG_-kMgYo,32
|
|
7
|
-
picoboot/core/enums.py,sha256=YQnCtiX3XwG5RtAIhTmD37DMZMEGmcPIaTiwsW3ckxw,1211
|
|
8
|
-
picoboot/tools/picotool.py,sha256=e2xjIxP5UZn9yfjxUWkJXq6KQHyw4YsGbuQbTauo0-Q,94
|
|
9
|
-
pypicoboot-1.1.3.dist-info/METADATA,sha256=bZg7x1-8o35H9oivMY5YPpa5_qKH9ntA2ZGhuguBTjs,41111
|
|
10
|
-
pypicoboot-1.1.3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
11
|
-
pypicoboot-1.1.3.dist-info/top_level.txt,sha256=sjegZQO5-kQdFOXXJHm0P7Hg1Nw4Ri0WKHnRYDTsa4I,9
|
|
12
|
-
pypicoboot-1.1.3.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|