Commit Graph

1656 Commits

Author SHA1 Message Date
anecdata
85301cb0e5 fix typo 2021-11-11 17:26:07 -06:00
anecdata
18f2019300 Set Station MAC address & validate connect SSID len 2021-11-11 17:04:35 -06:00
Hosted Weblate
90d5a90567
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-11-11 19:10:47 +01:00
Hosted Weblate
e471217a00
Merge remote-tracking branch 'origin/main' 2021-11-11 19:10:45 +01:00
Jonny Bergdahl
e8e7e0a66e
Translated using Weblate (Swedish)
Currently translated at 100.0% (1020 of 1020 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-11-11 19:10:44 +01:00
Scott Shawcroft
c1177662cd
Merge pull request #5537 from microDev1/monitor-mode
Add Monitor Mode
2021-11-11 10:10:39 -08:00
Wellington Terumi Uemura
fea781207b
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1020 of 1020 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-11-10 10:53:31 +01:00
Hosted Weblate
2ce13c8c7b
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-11-09 18:54:04 +01:00
Hosted Weblate
dc6bf3890b
Merge remote-tracking branch 'origin/main' 2021-11-09 18:54:02 +01:00
Jonny Bergdahl
77cb2a15d0
Translated using Weblate (Swedish)
Currently translated at 100.0% (1015 of 1015 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-11-09 18:54:02 +01:00
Wellington Terumi Uemura
cba6a684bc
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1015 of 1015 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-11-09 18:54:01 +01:00
Scott Shawcroft
05b9ba82aa
Merge pull request #5558 from jepler/dither3
Implement dithering
2021-11-09 09:53:52 -08:00
Jeff Epler
cbfa41f238 Merge remote-tracking branch 'origin/main' into dither3 2021-11-08 16:46:36 -06:00
Hosted Weblate
e119c88600
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-11-08 19:50:11 +01:00
Hosted Weblate
df7a39c7d2
Merge remote-tracking branch 'origin/main' 2021-11-08 19:50:09 +01:00
Reza Almanda
13d05aa229
Translated using Weblate (Indonesian)
Currently translated at 44.3% (448 of 1011 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/id/
2021-11-08 19:50:09 +01:00
Scott Shawcroft
bb71f8c9b3
Merge pull request #5544 from jepler/alphablend
bitmaptools: add alphablend
2021-11-08 10:50:03 -08:00
Jeff Epler
eaf8bc0abe bitmaptools: add dither
This can convert a BGR565_SWAPPED bitmap to B&W in about 82ms on
esp32-s2.
2021-11-08 10:35:44 -06:00
Wellington Terumi Uemura
f1ea57e032
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1011 of 1011 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-11-07 17:53:21 +01:00
Jonny Bergdahl
a555475e65
Translated using Weblate (Swedish)
Currently translated at 100.0% (1011 of 1011 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-11-05 19:37:42 +01:00
Jeff Epler
8e8c44afea Merge remote-tracking branch 'origin/main' into alphablend 2021-11-05 11:24:51 -05:00
Hosted Weblate
4ed1249927
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-11-05 16:24:32 +01:00
Scott Shawcroft
c27b3a0e4f
Merge pull request #5490 from jepler/gifio
Implement gifio.GifWriter
2021-11-05 08:24:24 -07:00
Jeff Epler
2ec2761ce0 bitmaptools: add alphablend
This blends two "565"-format bitmaps, including byteswapped ones. All
the bitmaps have to have the same memory format.

The routine takes about 63ms on a Kaluga when operating on 320x240 bitmaps.
Of course, displaying the bitmap also takes time.

There's untested code for the L8 (8-bit greyscale) case. This can be
enabled once gifio is merged.
2021-11-05 08:16:48 -05:00
hexthat
f7ba0d23de
Translated using Weblate (Chinese (Pinyin))
Currently translated at 100.0% (1010 of 1010 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/zh_Latn/
2021-11-05 05:07:54 +01:00
Jonny Bergdahl
9db5d57e50
Translated using Weblate (Swedish)
Currently translated at 100.0% (1010 of 1010 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-11-05 05:07:53 +01:00
Wellington Terumi Uemura
6d7e6dfabd
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1010 of 1010 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-11-05 05:07:53 +01:00
Jeff Epler
334a9c85ce Merge remote-tracking branch 'origin/main' into gifio 2021-11-04 20:22:00 -05:00
Hosted Weblate
7f9fa8c201
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-11-04 21:33:40 +01:00
Jeff Epler
a8614a61dc ParallelImageCapture: Add continuous capture on espressif
By having a pair of buffers, the capture hardware can fill one buffer while
Python code (including displayio, etc) operates on the other buffer.  This
increases the responsiveness of camera-using code.

On the Kaluga it makes the following improvements:
 * 320x240 viewfinder at 30fps instead of 15fps using directio
 * 240x240 animated gif capture at 10fps instead of 7.5fps

As discussed at length on Discord, the "usual end user" code will look like
this:

    camera = ...

    with camera.continuous_capture(buffer1, buffer2) as capture:
        for frame in capture:
            # Do something with frame

However, rather than presenting a context manager, the core code consists of
three new functions to start & stop continuous capture, and to get the next
frame.  The reason is twofold.  First, it's simply easier to implement the
context manager object in pure Python.  Second, for more advanced usage, the
context manager may be too limiting, and it's easier to iterate on the right
design in Python code.  In particular, I noticed that adapting the
JPEG-capturing programs to use continuous capture mode needed a change in
program structure.

The camera app was structured as
```python
while True:
    if shutter button was just pressed:
        capture a jpeg frame
    else:
        update the viewfinder
```

However, "capture a jpeg frame" needs to (A) switch the camera settings and (B)
capture into a different, larger buffer then (C) return to the earlier
settings. This can't be done during continuous capture mode. So just
restructuring it as follows isn't going to work:

```python
with camera.continuous_capture(buffer1, buffer2) as capture:
    for frame in capture:
        if shutter button was just pressed:
            capture a jpeg frame, without disturbing continuous capture mode
        else:
            update the viewfinder
```

The continuous mode is only implemented in the espressif port; others
will throw an exception if the associated methods are invoked.  It's not
impossible to implement there, just not a priority, since these micros don't
have enough RAM for two framebuffer copies at any resonable sizes.

The capture code, including single-shot capture, now take mp_obj_t in the
common-hal layer, instead of a buffer & length.  This was done for the
continuous capture mode because it has to identify & return to the user the
proper Python object representing the original buffer.  In the Espressif port,
it was convenient to implement single capture in terms of a multi-capture,
which is why I changed the singleshot routine's signature too.
2021-11-03 11:02:46 -05:00
microDev
27b137f931
Merge branch 'main' into monitor-mode 2021-11-02 13:56:56 +05:30
microDev
95172cf3ce
add monitor class
Co-authored-by: anecdata <16617689+anecdata@users.noreply.github.com>
2021-11-02 12:32:09 +05:30
Hosted Weblate
b26e6a04c5
Merge remote-tracking branch 'origin/main' 2021-10-31 12:37:11 +01:00
hexthat
ef95ff3fa5
Translated using Weblate (Chinese (Pinyin))
Currently translated at 100.0% (1007 of 1007 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/zh_Latn/
2021-10-31 12:37:11 +01:00
Senuros
409092b180 several more german translations added 2021-10-31 06:17:31 +01:00
Senuros
7734e85eeb Added some german translations 2021-10-29 17:55:23 +02:00
Jeff Epler
c34b6f757f Implement gifio.GifWriter
This involves:
 * Adding a new "L8" colorspace for colorconverters
 * factoring out displayio_colorconverter_convert_pixel
 * Making a minimal "colorspace only" version of displayio for the
   unix port (testing purposes)
 * fixing an error message

I only tested writing B&W animated images, with the following script:
```python
import displayio
import gifio

with gifio.GifWriter("foo.gif", 64, 64, displayio.Colorspace.L8) as g:
    for i in range(0, 256, 14):
        data = bytes([i, 255-i] * 32 + [255-i, i] * 32) * 32
        print("add_frame")
        g.add_frame(data)

# expected to raise an error, buffer is not big enough
with gifio.GifWriter("/dev/null", 64, 64, displayio.Colorspace.L8) as g:
    g.add_frame(bytes([3,3,3]))
```
2021-10-26 08:54:18 -05:00
Hosted Weblate
e0460e03e0
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-10-25 23:42:22 +02:00
Max Holliday
e45fe3d778
Merge branch 'adafruit:main' into samd-sleep 2021-10-24 15:46:07 -07:00
Jonny Bergdahl
39f62aaae5
Translated using Weblate (Swedish)
Currently translated at 100.0% (1007 of 1007 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-10-23 09:37:02 +02:00
Wellington Terumi Uemura
77bc2bae45
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1007 of 1007 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-10-23 09:37:02 +02:00
Max Holliday
f7ba711ec6
Merge branch 'adafruit:main' into samd-sleep 2021-10-22 14:56:44 -07:00
Hosted Weblate
f53cb19958
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-10-22 01:43:30 +02:00
Kattni Rembor
2c15f5439b Update help() to have circuitpython.org 2021-10-21 18:07:07 -04:00
Max Holliday
e74a8e38fe
Merge branch 'adafruit:main' into samd-sleep 2021-10-21 09:52:55 -07:00
Jonny Bergdahl
95e4902468
Translated using Weblate (Swedish)
Currently translated at 100.0% (1008 of 1008 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-10-20 09:36:08 +02:00
Wellington Terumi Uemura
2f22498263
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (1008 of 1008 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-10-20 09:36:08 +02:00
Hosted Weblate
0658e31645
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-10-19 00:56:41 +02:00
Hosted Weblate
fdb0522c3c
Merge remote-tracking branch 'origin/main' 2021-10-19 00:56:38 +02:00
Jonny Bergdahl
a3050d1f1e
Translated using Weblate (Swedish)
Currently translated at 100.0% (1007 of 1007 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-10-19 00:56:38 +02:00