circuitpython-stubs 8.2.8__tar.gz → 8.2.10__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.
- {circuitpython-stubs-8.2.8/circuitpython_stubs.egg-info → circuitpython-stubs-8.2.10}/PKG-INFO +1 -1
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/_bleio/__init__.pyi +21 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/_eve/__init__.pyi +54 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/_pixelmap/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/_stage/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/adafruit_bus_device/i2c_device/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/adafruit_bus_device/spi_device/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/adafruit_pixelbuf/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/aesio/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/alarm/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/analogbufio/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/analogio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audiobusio/__init__.pyi +9 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audiocore/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audioio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audiomixer/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audiomp3/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/audiopwmio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/bitbangio/__init__.pyi +12 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/busio/__init__.pyi +19 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/camera/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/canio/__init__.pyi +9 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10/circuitpython_stubs.egg-info}/PKG-INFO +1 -1
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/countio/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/digitalio/__init__.pyi +5 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/displayio/__init__.pyi +30 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/espcamera/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/espnow/__init__.pyi +8 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/espulp/__init__.pyi +5 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/fontio/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/framebufferio/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/frequencyio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/gifio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/gnss/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/hashlib/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/i2ctarget/__init__.pyi +8 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/imagecapture/__init__.pyi +7 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ipaddress/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/is31fl3741/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/keypad/__init__.pyi +18 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/mdns/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/memorymap/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/memorymonitor/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/microcontroller/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/nvm/__init__.pyi +4 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/onewireio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/paralleldisplay/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/picodvi/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ps2io/__init__.pyi +7 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/pulseio/__init__.pyi +12 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/pwmio/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/qrio/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/rgbmatrix/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/rotaryio/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/rp2pio/__init__.pyi +12 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/sdcardio/__init__.pyi +5 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/sdioio/__init__.pyi +6 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/sharpdisplay/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/socketpool/__init__.pyi +25 -4
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ssl/__init__.pyi +13 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/storage/__init__.pyi +8 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/synthio/__init__.pyi +15 -2
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/terminalio/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/touchio/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb/core/__init__.pyi +5 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb_cdc/__init__.pyi +7 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb_hid/__init__.pyi +1 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb_host/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb_midi/__init__.pyi +3 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/watchdog/__init__.pyi +2 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/wifi/__init__.pyi +15 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/MANIFEST.in +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/README.rst +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/_pew/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/adafruit_bus_device/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/alarm/pin/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/alarm/time/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/alarm/touch/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/atexit/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/bitmaptools/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/bitops/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/board/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/circuitpython_stubs.egg-info/SOURCES.txt +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/circuitpython_stubs.egg-info/dependency_links.txt +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/circuitpython_stubs.egg-info/not-zip-safe +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/circuitpython_stubs.egg-info/top_level.txt +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/cyw43/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/dualbank/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/espidf/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/floppyio/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/getpass/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/math/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/msgpack/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/neopixel_write/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/os/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/rainbowio/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/random/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/rtc/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/samd/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/setup.cfg +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/setup.py +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/struct/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/supervisor/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/time/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/traceback/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/uheap/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/numpy/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/numpy/carray/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/numpy/fft/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/numpy/linalg/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/scipy/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/scipy/linalg/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/scipy/optimize/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/user/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ulab/utils/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/usb/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/ustack/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/vectorio/__init__.pyi +0 -0
- {circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/zlib/__init__.pyi +0 -0
|
@@ -120,9 +120,11 @@ class Adapter:
|
|
|
120
120
|
:param tx_power int: transmitter power while advertising in dBm
|
|
121
121
|
:param directed_to Address: peer to advertise directly to"""
|
|
122
122
|
...
|
|
123
|
+
|
|
123
124
|
def stop_advertising(self) -> None:
|
|
124
125
|
"""Stop sending advertising packets."""
|
|
125
126
|
...
|
|
127
|
+
|
|
126
128
|
def start_scan(
|
|
127
129
|
self,
|
|
128
130
|
prefixes: ReadableBuffer = b"",
|
|
@@ -153,6 +155,7 @@ class Adapter:
|
|
|
153
155
|
:returns: an iterable of `_bleio.ScanEntry` objects
|
|
154
156
|
:rtype: iterable"""
|
|
155
157
|
...
|
|
158
|
+
|
|
156
159
|
def stop_scan(self) -> None:
|
|
157
160
|
"""Stop the current scan."""
|
|
158
161
|
...
|
|
@@ -170,6 +173,7 @@ class Adapter:
|
|
|
170
173
|
:param Address address: The address of the peripheral to connect to
|
|
171
174
|
:param float/int timeout: Try to connect for timeout seconds."""
|
|
172
175
|
...
|
|
176
|
+
|
|
173
177
|
def erase_bonding(self) -> None:
|
|
174
178
|
"""Erase all bonding information stored in flash memory."""
|
|
175
179
|
...
|
|
@@ -209,6 +213,7 @@ class Address:
|
|
|
209
213
|
def __eq__(self, other: object) -> bool:
|
|
210
214
|
"""Two Address objects are equal if their addresses and address types are equal."""
|
|
211
215
|
...
|
|
216
|
+
|
|
212
217
|
def __hash__(self) -> int:
|
|
213
218
|
"""Returns a hash for the Address data."""
|
|
214
219
|
...
|
|
@@ -266,6 +271,7 @@ class Characteristic:
|
|
|
266
271
|
Remote Characteristic objects are created by `Connection.discover_remote_services()`
|
|
267
272
|
as part of remote Services."""
|
|
268
273
|
...
|
|
274
|
+
|
|
269
275
|
def add_to_service(
|
|
270
276
|
self,
|
|
271
277
|
service: Service,
|
|
@@ -359,6 +365,7 @@ class CharacteristicBuffer:
|
|
|
359
365
|
:param int buffer_size: Size of ring buffer that stores incoming data coming from client.
|
|
360
366
|
Must be >= 1."""
|
|
361
367
|
...
|
|
368
|
+
|
|
362
369
|
def read(self, nbytes: Optional[int] = None) -> Optional[bytes]:
|
|
363
370
|
"""Read characters. If ``nbytes`` is specified then read at most that many
|
|
364
371
|
bytes. Otherwise, read everything that arrives until the connection
|
|
@@ -368,12 +375,14 @@ class CharacteristicBuffer:
|
|
|
368
375
|
:return: Data read
|
|
369
376
|
:rtype: bytes or None"""
|
|
370
377
|
...
|
|
378
|
+
|
|
371
379
|
def readinto(self, buf: WriteableBuffer) -> Optional[int]:
|
|
372
380
|
"""Read bytes into the ``buf``. Read at most ``len(buf)`` bytes.
|
|
373
381
|
|
|
374
382
|
:return: number of bytes read and stored into ``buf``
|
|
375
383
|
:rtype: int or None (on a non-blocking error)"""
|
|
376
384
|
...
|
|
385
|
+
|
|
377
386
|
def readline(self) -> bytes:
|
|
378
387
|
"""Read a line, ending in a newline character.
|
|
379
388
|
|
|
@@ -385,6 +394,7 @@ class CharacteristicBuffer:
|
|
|
385
394
|
def reset_input_buffer(self) -> None:
|
|
386
395
|
"""Discard any unread characters in the input buffer."""
|
|
387
396
|
...
|
|
397
|
+
|
|
388
398
|
def deinit(self) -> None:
|
|
389
399
|
"""Disable permanently."""
|
|
390
400
|
...
|
|
@@ -413,12 +423,15 @@ class Connection:
|
|
|
413
423
|
Connections may also be made when another device initiates a connection. To use a Connection
|
|
414
424
|
created by a peer, read the `Adapter.connections` property."""
|
|
415
425
|
...
|
|
426
|
+
|
|
416
427
|
def disconnect(self) -> None:
|
|
417
428
|
"""Disconnects from the remote peripheral. Does nothing if already disconnected."""
|
|
418
429
|
...
|
|
430
|
+
|
|
419
431
|
def pair(self, *, bond: bool = True) -> None:
|
|
420
432
|
"""Pair to the peer to improve security."""
|
|
421
433
|
...
|
|
434
|
+
|
|
422
435
|
def discover_remote_services(
|
|
423
436
|
self, service_uuids_whitelist: Optional[Iterable[UUID]] = None
|
|
424
437
|
) -> Tuple[Service, ...]:
|
|
@@ -478,6 +491,7 @@ class Descriptor:
|
|
|
478
491
|
and attached to a Characteristic by calling `add_to_characteristic()`.
|
|
479
492
|
Remote Descriptor objects are created by `Connection.discover_remote_services()`
|
|
480
493
|
as part of remote Characteristics in the remote Services that are discovered."""
|
|
494
|
+
|
|
481
495
|
@classmethod
|
|
482
496
|
def add_to_characteristic(
|
|
483
497
|
cls,
|
|
@@ -545,6 +559,7 @@ class PacketBuffer:
|
|
|
545
559
|
:param int max_packet_size: Maximum size of packets. Overrides value from the characteristic.
|
|
546
560
|
(Remote characteristics may not have the correct length.)"""
|
|
547
561
|
...
|
|
562
|
+
|
|
548
563
|
def readinto(self, buf: WriteableBuffer) -> int:
|
|
549
564
|
"""Reads a single BLE packet into the ``buf``. Raises an exception if the next packet is longer
|
|
550
565
|
than the given buffer. Use `incoming_packet_length` to read the maximum length of a single packet.
|
|
@@ -552,6 +567,7 @@ class PacketBuffer:
|
|
|
552
567
|
:return: number of bytes read and stored into ``buf``
|
|
553
568
|
:rtype: int"""
|
|
554
569
|
...
|
|
570
|
+
|
|
555
571
|
def write(self, data: ReadableBuffer, *, header: Optional[bytes] = None) -> int:
|
|
556
572
|
"""Writes all bytes from data into the same outgoing packet. The bytes from header are included
|
|
557
573
|
before data when the pending packet is currently empty.
|
|
@@ -561,6 +577,7 @@ class PacketBuffer:
|
|
|
561
577
|
:return: number of bytes written. May include header bytes when packet is empty.
|
|
562
578
|
:rtype: int"""
|
|
563
579
|
...
|
|
580
|
+
|
|
564
581
|
def deinit(self) -> None:
|
|
565
582
|
"""Disable permanently."""
|
|
566
583
|
...
|
|
@@ -577,6 +594,7 @@ class ScanEntry:
|
|
|
577
594
|
def __init__(self) -> None:
|
|
578
595
|
"""Cannot be instantiated directly. Use `_bleio.Adapter.start_scan`."""
|
|
579
596
|
...
|
|
597
|
+
|
|
580
598
|
def matches(self, prefixes: ScanEntry, *, match_all: bool = True) -> bool:
|
|
581
599
|
"""Returns True if the ScanEntry matches all prefixes when ``match_all`` is True. This is stricter
|
|
582
600
|
than the scan filtering which accepts any advertisements that match any of the prefixes
|
|
@@ -600,9 +618,11 @@ class ScanResults:
|
|
|
600
618
|
def __init__(self) -> None:
|
|
601
619
|
"""Cannot be instantiated directly. Use `_bleio.Adapter.start_scan`."""
|
|
602
620
|
...
|
|
621
|
+
|
|
603
622
|
def __iter__(self) -> Iterator[ScanEntry]:
|
|
604
623
|
"""Returns itself since it is the iterator."""
|
|
605
624
|
...
|
|
625
|
+
|
|
606
626
|
def __next__(self) -> ScanEntry:
|
|
607
627
|
"""Returns the next `_bleio.ScanEntry`. Blocks if none have been received and scanning is still
|
|
608
628
|
active. Raises `StopIteration` if scanning is finished and no other results are available.
|
|
@@ -670,6 +690,7 @@ class UUID:
|
|
|
670
690
|
def pack_into(self, buffer: WriteableBuffer, offset: int = 0) -> None:
|
|
671
691
|
"""Packs the UUID into the given buffer at the given offset."""
|
|
672
692
|
...
|
|
693
|
+
|
|
673
694
|
def __eq__(self, other: object) -> bool:
|
|
674
695
|
"""Two UUID objects are equal if their values match and they are both 128-bit or both 16-bit."""
|
|
675
696
|
...
|
|
@@ -13,17 +13,20 @@ from circuitpython_typing import ReadableBuffer
|
|
|
13
13
|
class _EVE:
|
|
14
14
|
def __init__(self) -> None:
|
|
15
15
|
"""Create an _EVE object"""
|
|
16
|
+
|
|
16
17
|
def register(self, o: object) -> None: ...
|
|
17
18
|
def flush(self) -> None:
|
|
18
19
|
"""Send any queued drawing commands directly to the hardware.
|
|
19
20
|
|
|
20
21
|
:param int width: The width of the grid in tiles, or 1 for sprites."""
|
|
21
22
|
...
|
|
23
|
+
|
|
22
24
|
def cc(self, b: ReadableBuffer) -> None:
|
|
23
25
|
"""Append bytes to the command FIFO.
|
|
24
26
|
|
|
25
27
|
:param ~circuitpython_typing.ReadableBuffer b: The bytes to add"""
|
|
26
28
|
...
|
|
29
|
+
|
|
27
30
|
def AlphaFunc(self, func: int, ref: int) -> None:
|
|
28
31
|
"""Set the alpha test function
|
|
29
32
|
|
|
@@ -33,6 +36,7 @@ class _EVE:
|
|
|
33
36
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
34
37
|
"""
|
|
35
38
|
...
|
|
39
|
+
|
|
36
40
|
def Begin(self, prim: int) -> None:
|
|
37
41
|
"""Begin drawing a graphics primitive
|
|
38
42
|
|
|
@@ -41,11 +45,13 @@ class _EVE:
|
|
|
41
45
|
Valid primitives are ``BITMAPS``, ``POINTS``, ``LINES``, ``LINE_STRIP``, ``EDGE_STRIP_R``, ``EDGE_STRIP_L``, ``EDGE_STRIP_A``, ``EDGE_STRIP_B`` and ``RECTS``.
|
|
42
46
|
"""
|
|
43
47
|
...
|
|
48
|
+
|
|
44
49
|
def BitmapExtFormat(self, format: int) -> None:
|
|
45
50
|
"""Set the bitmap format
|
|
46
51
|
|
|
47
52
|
:param int format: bitmap pixel format."""
|
|
48
53
|
...
|
|
54
|
+
|
|
49
55
|
def BitmapHandle(self, handle: int) -> None:
|
|
50
56
|
"""Set the bitmap handle
|
|
51
57
|
|
|
@@ -54,12 +60,14 @@ class _EVE:
|
|
|
54
60
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
55
61
|
"""
|
|
56
62
|
...
|
|
63
|
+
|
|
57
64
|
def BitmapLayoutH(self, linestride: int, height: int) -> None:
|
|
58
65
|
"""Set the source bitmap memory format and layout for the current handle. high bits for large bitmaps
|
|
59
66
|
|
|
60
67
|
:param int linestride: high part of bitmap line stride, in bytes. Range 0-7
|
|
61
68
|
:param int height: high part of bitmap height, in lines. Range 0-3"""
|
|
62
69
|
...
|
|
70
|
+
|
|
63
71
|
def BitmapLayout(self, format: int, linestride: int, height: int) -> None:
|
|
64
72
|
"""Set the source bitmap memory format and layout for the current handle
|
|
65
73
|
|
|
@@ -67,12 +75,14 @@ class _EVE:
|
|
|
67
75
|
:param int linestride: bitmap line stride, in bytes. Range 0-1023
|
|
68
76
|
:param int height: bitmap height, in lines. Range 0-511"""
|
|
69
77
|
...
|
|
78
|
+
|
|
70
79
|
def BitmapSizeH(self, width: int, height: int) -> None:
|
|
71
80
|
"""Set the screen drawing of bitmaps for the current handle. high bits for large bitmaps
|
|
72
81
|
|
|
73
82
|
:param int width: high part of drawn bitmap width, in pixels. Range 0-3
|
|
74
83
|
:param int height: high part of drawn bitmap height, in pixels. Range 0-3"""
|
|
75
84
|
...
|
|
85
|
+
|
|
76
86
|
def BitmapSize(
|
|
77
87
|
self, filter: int, wrapx: int, wrapy: int, width: int, height: int
|
|
78
88
|
) -> None:
|
|
@@ -84,12 +94,14 @@ class _EVE:
|
|
|
84
94
|
:param int width: drawn bitmap width, in pixels. Range 0-511
|
|
85
95
|
:param int height: drawn bitmap height, in pixels. Range 0-511"""
|
|
86
96
|
...
|
|
97
|
+
|
|
87
98
|
def BitmapSource(self, addr: int) -> None:
|
|
88
99
|
"""Set the source address for bitmap graphics
|
|
89
100
|
|
|
90
101
|
:param int addr: Bitmap start address, pixel-aligned. May be in SRAM or flash. Range 0-16777215
|
|
91
102
|
"""
|
|
92
103
|
...
|
|
104
|
+
|
|
93
105
|
def BitmapSwizzle(self, r: int, g: int, b: int, a: int) -> None:
|
|
94
106
|
"""Set the source for the r,g,b and a channels of a bitmap
|
|
95
107
|
|
|
@@ -98,6 +110,7 @@ class _EVE:
|
|
|
98
110
|
:param int b: blue component source channel. Range 0-7
|
|
99
111
|
:param int a: alpha component source channel. Range 0-7"""
|
|
100
112
|
...
|
|
113
|
+
|
|
101
114
|
def BitmapTransformA(self, p: int, v: int) -> None:
|
|
102
115
|
"""Set the :math:`a` component of the bitmap transform matrix
|
|
103
116
|
|
|
@@ -109,6 +122,7 @@ class _EVE:
|
|
|
109
122
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
110
123
|
"""
|
|
111
124
|
...
|
|
125
|
+
|
|
112
126
|
def BitmapTransformB(self, p: int, v: int) -> None:
|
|
113
127
|
"""Set the :math:`b` component of the bitmap transform matrix
|
|
114
128
|
|
|
@@ -120,6 +134,7 @@ class _EVE:
|
|
|
120
134
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
121
135
|
"""
|
|
122
136
|
...
|
|
137
|
+
|
|
123
138
|
def BitmapTransformC(self, v: int) -> None:
|
|
124
139
|
"""Set the :math:`c` component of the bitmap transform matrix
|
|
125
140
|
|
|
@@ -128,6 +143,7 @@ class _EVE:
|
|
|
128
143
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
129
144
|
"""
|
|
130
145
|
...
|
|
146
|
+
|
|
131
147
|
def BitmapTransformD(self, p: int, v: int) -> None:
|
|
132
148
|
"""Set the :math:`d` component of the bitmap transform matrix
|
|
133
149
|
|
|
@@ -139,6 +155,7 @@ class _EVE:
|
|
|
139
155
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
140
156
|
"""
|
|
141
157
|
...
|
|
158
|
+
|
|
142
159
|
def BitmapTransformE(self, p: int, v: int) -> None:
|
|
143
160
|
"""Set the :math:`e` component of the bitmap transform matrix
|
|
144
161
|
|
|
@@ -150,6 +167,7 @@ class _EVE:
|
|
|
150
167
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
151
168
|
"""
|
|
152
169
|
...
|
|
170
|
+
|
|
153
171
|
def BitmapTransformF(self, v: int) -> None:
|
|
154
172
|
"""Set the :math:`f` component of the bitmap transform matrix
|
|
155
173
|
|
|
@@ -158,6 +176,7 @@ class _EVE:
|
|
|
158
176
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
159
177
|
"""
|
|
160
178
|
...
|
|
179
|
+
|
|
161
180
|
def BlendFunc(self, src: int, dst: int) -> None:
|
|
162
181
|
"""Set pixel arithmetic
|
|
163
182
|
|
|
@@ -167,11 +186,13 @@ class _EVE:
|
|
|
167
186
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
168
187
|
"""
|
|
169
188
|
...
|
|
189
|
+
|
|
170
190
|
def Call(self, dest: int) -> None:
|
|
171
191
|
"""Execute a sequence of commands at another location in the display list
|
|
172
192
|
|
|
173
193
|
:param int dest: display list address. Range 0-65535"""
|
|
174
194
|
...
|
|
195
|
+
|
|
175
196
|
def Cell(self, cell: int) -> None:
|
|
176
197
|
"""Set the bitmap cell number for the vertex2f command
|
|
177
198
|
|
|
@@ -180,6 +201,7 @@ class _EVE:
|
|
|
180
201
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
181
202
|
"""
|
|
182
203
|
...
|
|
204
|
+
|
|
183
205
|
def ClearColorA(self, alpha: int) -> None:
|
|
184
206
|
"""Set clear value for the alpha channel
|
|
185
207
|
|
|
@@ -188,6 +210,7 @@ class _EVE:
|
|
|
188
210
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
189
211
|
"""
|
|
190
212
|
...
|
|
213
|
+
|
|
191
214
|
def ClearColorRGB(self, red: int, green: int, blue: int) -> None:
|
|
192
215
|
"""Set clear values for red, green and blue channels
|
|
193
216
|
|
|
@@ -198,6 +221,7 @@ class _EVE:
|
|
|
198
221
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
199
222
|
"""
|
|
200
223
|
...
|
|
224
|
+
|
|
201
225
|
def Clear(self, c: int, s: int, t: int) -> None:
|
|
202
226
|
"""Clear buffers to preset values
|
|
203
227
|
|
|
@@ -205,6 +229,7 @@ class _EVE:
|
|
|
205
229
|
:param int s: clear stencil buffer. Range 0-1
|
|
206
230
|
:param int t: clear tag buffer. Range 0-1"""
|
|
207
231
|
...
|
|
232
|
+
|
|
208
233
|
def ClearStencil(self, s: int) -> None:
|
|
209
234
|
"""Set clear value for the stencil buffer
|
|
210
235
|
|
|
@@ -213,6 +238,7 @@ class _EVE:
|
|
|
213
238
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
214
239
|
"""
|
|
215
240
|
...
|
|
241
|
+
|
|
216
242
|
def ClearTag(self, s: int) -> None:
|
|
217
243
|
"""Set clear value for the tag buffer
|
|
218
244
|
|
|
@@ -220,6 +246,7 @@ class _EVE:
|
|
|
220
246
|
|
|
221
247
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
222
248
|
"""
|
|
249
|
+
|
|
223
250
|
def ColorA(self, alpha: int) -> None:
|
|
224
251
|
"""Set the current color alpha
|
|
225
252
|
|
|
@@ -228,6 +255,7 @@ class _EVE:
|
|
|
228
255
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
229
256
|
"""
|
|
230
257
|
...
|
|
258
|
+
|
|
231
259
|
def ColorMask(self, r: int, g: int, b: int, a: int) -> None:
|
|
232
260
|
"""Enable and disable writing of frame buffer color components
|
|
233
261
|
|
|
@@ -239,6 +267,7 @@ class _EVE:
|
|
|
239
267
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
240
268
|
"""
|
|
241
269
|
...
|
|
270
|
+
|
|
242
271
|
def ColorRGB(self, red: int, green: int, blue: int) -> None:
|
|
243
272
|
"""Set the drawing color
|
|
244
273
|
|
|
@@ -249,28 +278,34 @@ class _EVE:
|
|
|
249
278
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
250
279
|
"""
|
|
251
280
|
...
|
|
281
|
+
|
|
252
282
|
def Display(self) -> None:
|
|
253
283
|
"""End the display list"""
|
|
254
284
|
...
|
|
285
|
+
|
|
255
286
|
def End(self) -> None:
|
|
256
287
|
"""End drawing a graphics primitive
|
|
257
288
|
|
|
258
289
|
:meth:`Vertex2ii` and :meth:`Vertex2f` calls are ignored until the next :meth:`Begin`.
|
|
259
290
|
"""
|
|
260
291
|
...
|
|
292
|
+
|
|
261
293
|
def Jump(self, dest: int) -> None:
|
|
262
294
|
"""Execute commands at another location in the display list
|
|
263
295
|
|
|
264
296
|
:param int dest: display list address. Range 0-65535"""
|
|
265
297
|
...
|
|
298
|
+
|
|
266
299
|
def Macro(self, m: int) -> None:
|
|
267
300
|
"""Execute a single command from a macro register
|
|
268
301
|
|
|
269
302
|
:param int m: macro register to read. Range 0-1"""
|
|
270
303
|
...
|
|
304
|
+
|
|
271
305
|
def Nop(self) -> None:
|
|
272
306
|
"""No operation"""
|
|
273
307
|
...
|
|
308
|
+
|
|
274
309
|
def PaletteSource(self, addr: int) -> None:
|
|
275
310
|
"""Set the base address of the palette
|
|
276
311
|
|
|
@@ -279,15 +314,19 @@ class _EVE:
|
|
|
279
314
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
280
315
|
"""
|
|
281
316
|
...
|
|
317
|
+
|
|
282
318
|
def RestoreContext(self) -> None:
|
|
283
319
|
"""Restore the current graphics context from the context stack"""
|
|
284
320
|
...
|
|
321
|
+
|
|
285
322
|
def Return(self) -> None:
|
|
286
323
|
"""Return from a previous call command"""
|
|
287
324
|
...
|
|
325
|
+
|
|
288
326
|
def SaveContext(self) -> None:
|
|
289
327
|
"""Push the current graphics context on the context stack"""
|
|
290
328
|
...
|
|
329
|
+
|
|
291
330
|
def ScissorSize(self, width: int, height: int) -> None:
|
|
292
331
|
"""Set the size of the scissor clip rectangle
|
|
293
332
|
|
|
@@ -297,6 +336,7 @@ class _EVE:
|
|
|
297
336
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
298
337
|
"""
|
|
299
338
|
...
|
|
339
|
+
|
|
300
340
|
def ScissorXY(self, x: int, y: int) -> None:
|
|
301
341
|
"""Set the top left corner of the scissor clip rectangle
|
|
302
342
|
|
|
@@ -306,6 +346,7 @@ class _EVE:
|
|
|
306
346
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
307
347
|
"""
|
|
308
348
|
...
|
|
349
|
+
|
|
309
350
|
def StencilFunc(self, func: int, ref: int, mask: int) -> None:
|
|
310
351
|
"""Set function and reference value for stencil testing
|
|
311
352
|
|
|
@@ -316,6 +357,7 @@ class _EVE:
|
|
|
316
357
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
317
358
|
"""
|
|
318
359
|
...
|
|
360
|
+
|
|
319
361
|
def StencilMask(self, mask: int) -> None:
|
|
320
362
|
"""Control the writing of individual bits in the stencil planes
|
|
321
363
|
|
|
@@ -324,6 +366,7 @@ class _EVE:
|
|
|
324
366
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
325
367
|
"""
|
|
326
368
|
...
|
|
369
|
+
|
|
327
370
|
def StencilOp(self, sfail: int, spass: int) -> None:
|
|
328
371
|
"""Set stencil test actions
|
|
329
372
|
|
|
@@ -333,6 +376,7 @@ class _EVE:
|
|
|
333
376
|
These values are part of the graphics context and are saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
334
377
|
"""
|
|
335
378
|
...
|
|
379
|
+
|
|
336
380
|
def TagMask(self, mask: int) -> None:
|
|
337
381
|
"""Control the writing of the tag buffer
|
|
338
382
|
|
|
@@ -341,6 +385,7 @@ class _EVE:
|
|
|
341
385
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
342
386
|
"""
|
|
343
387
|
...
|
|
388
|
+
|
|
344
389
|
def Tag(self, s: int) -> None:
|
|
345
390
|
"""Set the current tag value
|
|
346
391
|
|
|
@@ -349,6 +394,7 @@ class _EVE:
|
|
|
349
394
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
350
395
|
"""
|
|
351
396
|
...
|
|
397
|
+
|
|
352
398
|
def Vertex2ii(self, x: int, y: int, handle: int, cell: int) -> None:
|
|
353
399
|
""":param int x: x-coordinate in pixels. Range 0-511
|
|
354
400
|
:param int y: y-coordinate in pixels. Range 0-511
|
|
@@ -357,12 +403,14 @@ class _EVE:
|
|
|
357
403
|
|
|
358
404
|
This method is an alternative to :meth:`Vertex2f`."""
|
|
359
405
|
...
|
|
406
|
+
|
|
360
407
|
def Vertex2f(self, b: float) -> None:
|
|
361
408
|
"""Draw a point.
|
|
362
409
|
|
|
363
410
|
:param float x: pixel x-coordinate
|
|
364
411
|
:param float y: pixel y-coordinate"""
|
|
365
412
|
...
|
|
413
|
+
|
|
366
414
|
def LineWidth(self, width: float) -> None:
|
|
367
415
|
"""Set the width of rasterized lines
|
|
368
416
|
|
|
@@ -371,6 +419,7 @@ class _EVE:
|
|
|
371
419
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
372
420
|
"""
|
|
373
421
|
...
|
|
422
|
+
|
|
374
423
|
def PointSize(self, size: float) -> None:
|
|
375
424
|
"""Set the diameter of rasterized points
|
|
376
425
|
|
|
@@ -379,6 +428,7 @@ class _EVE:
|
|
|
379
428
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
380
429
|
"""
|
|
381
430
|
...
|
|
431
|
+
|
|
382
432
|
def VertexTranslateX(self, x: float) -> None:
|
|
383
433
|
"""Set the vertex transformation's x translation component
|
|
384
434
|
|
|
@@ -387,6 +437,7 @@ class _EVE:
|
|
|
387
437
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
388
438
|
"""
|
|
389
439
|
...
|
|
440
|
+
|
|
390
441
|
def VertexTranslateY(self, y: float) -> None:
|
|
391
442
|
"""Set the vertex transformation's y translation component
|
|
392
443
|
|
|
@@ -395,6 +446,7 @@ class _EVE:
|
|
|
395
446
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
396
447
|
"""
|
|
397
448
|
...
|
|
449
|
+
|
|
398
450
|
def VertexFormat(self, frac: int) -> None:
|
|
399
451
|
"""Set the precision of vertex2f coordinates
|
|
400
452
|
|
|
@@ -403,6 +455,7 @@ class _EVE:
|
|
|
403
455
|
This value is part of the graphics context and is saved and restored by :meth:`SaveContext` and :meth:`RestoreContext`.
|
|
404
456
|
"""
|
|
405
457
|
...
|
|
458
|
+
|
|
406
459
|
def cmd0(self, n: int) -> None:
|
|
407
460
|
"""Append the command word n to the FIFO
|
|
408
461
|
|
|
@@ -411,6 +464,7 @@ class _EVE:
|
|
|
411
464
|
This method is used by the ``eve`` module to efficiently add
|
|
412
465
|
commands to the FIFO."""
|
|
413
466
|
...
|
|
467
|
+
|
|
414
468
|
def cmd(self, n: int, fmt: str, args: Tuple[str, ...]) -> None:
|
|
415
469
|
"""Append a command packet to the FIFO.
|
|
416
470
|
|
|
@@ -32,16 +32,20 @@ class PixelMap:
|
|
|
32
32
|
|
|
33
33
|
def fill(self, color: PixelType) -> None:
|
|
34
34
|
"""Fill all the pixels in the map with the given color"""
|
|
35
|
+
|
|
35
36
|
def indices(self, index: int) -> Tuple[int]:
|
|
36
37
|
"""Return the PixelBuf indices for a PixelMap index"""
|
|
38
|
+
|
|
37
39
|
@overload
|
|
38
40
|
def __getitem__(self, index: slice) -> PixelReturnSequence:
|
|
39
41
|
"""Retrieve the value of the underlying pixels."""
|
|
40
42
|
...
|
|
43
|
+
|
|
41
44
|
@overload
|
|
42
45
|
def __getitem__(self, index: int) -> PixelReturnType:
|
|
43
46
|
"""Retrieve the value of one of the underlying pixels at 'index'."""
|
|
44
47
|
...
|
|
48
|
+
|
|
45
49
|
@overload
|
|
46
50
|
def __setitem__(self, index: slice, value: PixelSequence) -> None: ...
|
|
47
51
|
@overload
|
|
@@ -52,8 +56,10 @@ class PixelMap:
|
|
|
52
56
|
For RGBW byteorders, if given only RGB values either as an int or as a tuple, the white value
|
|
53
57
|
is used instead when the red, green, and blue values are the same."""
|
|
54
58
|
...
|
|
59
|
+
|
|
55
60
|
def __len__(self) -> int:
|
|
56
61
|
"""Length of the map"""
|
|
62
|
+
|
|
57
63
|
def show(self) -> None:
|
|
58
64
|
"""Transmits the color data to the pixels so that they are shown. This is done automatically
|
|
59
65
|
when `auto_write` is True."""
|
|
@@ -65,9 +65,11 @@ class Layer:
|
|
|
65
65
|
This class is intended for internal use in the ``stage`` library and
|
|
66
66
|
it shouldn't be used on its own."""
|
|
67
67
|
...
|
|
68
|
+
|
|
68
69
|
def move(self, x: int, y: int) -> None:
|
|
69
70
|
"""Set the offset of the layer to the specified values."""
|
|
70
71
|
...
|
|
72
|
+
|
|
71
73
|
def frame(self, frame: int, rotation: int) -> None:
|
|
72
74
|
"""Set the animation frame of the sprite, and optionally rotation its
|
|
73
75
|
graphic."""
|
|
@@ -97,6 +99,7 @@ class Text:
|
|
|
97
99
|
This class is intended for internal use in the ``stage`` library and
|
|
98
100
|
it shouldn't be used on its own."""
|
|
99
101
|
...
|
|
102
|
+
|
|
100
103
|
def move(self, x: int, y: int) -> None:
|
|
101
104
|
"""Set the offset of the text to the specified values."""
|
|
102
105
|
...
|
{circuitpython-stubs-8.2.8 → circuitpython-stubs-8.2.10}/adafruit_bus_device/spi_device/__init__.pyi
RENAMED
|
@@ -48,6 +48,7 @@ class SPIDevice:
|
|
|
48
48
|
def __enter__(self) -> busio.SPI:
|
|
49
49
|
"""Starts a SPI transaction by configuring the SPI and asserting chip select."""
|
|
50
50
|
...
|
|
51
|
+
|
|
51
52
|
def __exit__(self) -> None:
|
|
52
53
|
"""Ends a SPI transaction by deasserting chip select. See
|
|
53
54
|
:ref:`lifetime-and-contextmanagers` for more info."""
|
|
@@ -66,21 +66,25 @@ class PixelBuf:
|
|
|
66
66
|
"""Transmits the color data to the pixels so that they are shown. This is done automatically
|
|
67
67
|
when `auto_write` is True."""
|
|
68
68
|
...
|
|
69
|
+
|
|
69
70
|
def fill(self, color: PixelType) -> None:
|
|
70
71
|
"""Fills the given pixelbuf with the given color."""
|
|
71
72
|
...
|
|
73
|
+
|
|
72
74
|
@overload
|
|
73
75
|
def __getitem__(self, index: slice) -> PixelReturnSequence:
|
|
74
76
|
"""Returns the pixel value at the given index as a tuple of (Red, Green, Blue[, White]) values
|
|
75
77
|
between 0 and 255. When in PWM (DotStar) mode, the 4th tuple value is a float of the pixel
|
|
76
78
|
intensity from 0-1.0."""
|
|
77
79
|
...
|
|
80
|
+
|
|
78
81
|
@overload
|
|
79
82
|
def __getitem__(self, index: int) -> PixelReturnType:
|
|
80
83
|
"""Returns the pixel value at the given index as a tuple of (Red, Green, Blue[, White]) values
|
|
81
84
|
between 0 and 255. When in PWM (DotStar) mode, the 4th tuple value is a float of the pixel
|
|
82
85
|
intensity from 0-1.0."""
|
|
83
86
|
...
|
|
87
|
+
|
|
84
88
|
@overload
|
|
85
89
|
def __setitem__(self, index: slice, value: PixelSequence) -> None: ...
|
|
86
90
|
@overload
|
|
@@ -48,6 +48,7 @@ class AES:
|
|
|
48
48
|
cipher.encrypt_into(inp, outp)
|
|
49
49
|
hexlify(outp)"""
|
|
50
50
|
...
|
|
51
|
+
|
|
51
52
|
def rekey(
|
|
52
53
|
self,
|
|
53
54
|
key: ReadableBuffer,
|
|
@@ -59,6 +60,7 @@ class AES:
|
|
|
59
60
|
:param ~circuitpython_typing.ReadableBuffer IV: Initialization vector to use
|
|
60
61
|
for CBC or CTR mode"""
|
|
61
62
|
...
|
|
63
|
+
|
|
62
64
|
def encrypt_into(self, src: ReadableBuffer, dest: WriteableBuffer) -> None:
|
|
63
65
|
"""Encrypt the buffer from ``src`` into ``dest``.
|
|
64
66
|
|
|
@@ -66,6 +68,7 @@ class AES:
|
|
|
66
68
|
buffers must be a multiple of 16 bytes, and must be equal length. For
|
|
67
69
|
CTR mode, there are no restrictions."""
|
|
68
70
|
...
|
|
71
|
+
|
|
69
72
|
def decrypt_into(self, src: ReadableBuffer, dest: WriteableBuffer) -> None:
|
|
70
73
|
"""Decrypt the buffer from ``src`` into ``dest``.
|
|
71
74
|
For ECB mode, the buffers must be 16 bytes long. For CBC mode, the
|
|
@@ -146,20 +146,24 @@ class SleepMemory:
|
|
|
146
146
|
def __init__(self) -> None:
|
|
147
147
|
"""Not used. Access the sole instance through `alarm.sleep_memory`."""
|
|
148
148
|
...
|
|
149
|
+
|
|
149
150
|
def __bool__(self) -> bool:
|
|
150
151
|
"""``sleep_memory`` is ``True`` if its length is greater than zero.
|
|
151
152
|
This is an easy way to check for its existence.
|
|
152
153
|
"""
|
|
153
154
|
...
|
|
155
|
+
|
|
154
156
|
def __len__(self) -> int:
|
|
155
157
|
"""Return the length. This is used by (`len`)"""
|
|
156
158
|
...
|
|
159
|
+
|
|
157
160
|
@overload
|
|
158
161
|
def __getitem__(self, index: slice) -> bytearray: ...
|
|
159
162
|
@overload
|
|
160
163
|
def __getitem__(self, index: int) -> int:
|
|
161
164
|
"""Returns the value at the given index."""
|
|
162
165
|
...
|
|
166
|
+
|
|
163
167
|
@overload
|
|
164
168
|
def __setitem__(self, index: slice, value: ReadableBuffer) -> None: ...
|
|
165
169
|
@overload
|