Commit Graph

1103 Commits

Author SHA1 Message Date
Scott Shawcroft d274074f01
Merge remote-tracking branch 'adafruit/master' into vectorio 2020-05-12 12:29:05 -07:00
Scott Shawcroft f7303e6bd0
Merge pull request #2754 from maholli/non-standard-nvm
Add non-standard nvm to QSPI for external flash support
2020-05-12 11:56:33 -07:00
Scott Shawcroft 55f78bfb70
Merge pull request #2878 from WarriorOfWire/ujson-stream-protocol
ujson: work with mp stream protocol for fast & easy read
2020-05-11 15:40:27 -07:00
DavePutz 407938bf3a
Added a check for platforms supporting RTC before calling rtc_reset()
Added an #if CIRCUITPY_RTC check  for platforms supporting RTC
2020-05-11 12:03:44 -05:00
DavePutz 2ddfab315c
Added call to rtc_reset() in rtc_init()
Fix for issue #2872. The rtc_time_source had not been initialized; causing a time.time() call to fail.
2020-05-11 11:31:18 -05:00
warriorofwire eb3d5fa453 ujson: do not eat trailing whitespace
Ujson should only worry about whitespace before JSON.  This becomes apparent when you are using MP stream protocol to read directly from input buffers.

When you attempt to read(1) on a UART (and possibly other protocols) you have to wait for either the byte or the timeout.

Fixes:
- Waiting for a timeout after you have completed reading a correct and complete JSON off the input.
- Raising an OSError after reading a correct and complete JSON off the input.
- Eating more data than semantically owned off the input buffer.
- Blocking to start parsing JSON until the entire JSON body has been loaded into a potentially large, contiguous Python object.

Code you would write before:
```
line = board_busio_uart_port.read_line()
json_dict = json.loads(line)
```
or reaching for fixed buffers and swapping them around in Python.

Code that did not work before that does now:
```
json_dict = json.load(board_busio_uart_port)
```

- This removes the need for intermediate copies of data when reading JSON from micropython stream protocol inputs.
- It also increases total application speed by parsing JSON concurrently with receiving on boards that read from UART via DMA.
- It simplifies code that users write while improving their apps.
2020-05-10 20:45:42 -07:00
warriorofwire 206d0e598a Add vectorio: for drawing shapes
vectorio builds on m4 express feather

Concrete shapes are composed into a VectorShape which is put into a displayio Group for display.

VectorShape provides transpose and x/y positioning for shape implementations.

Included Shapes:

* Circle
  - A radius; Circle is positioned at its axis in the VectorShape.
  - You can freely modify the radius to grow and shrink the circle in-place.

* Polygon
  - An ordered list of points.
  - Beteween each successive point an edge is inferred.  A final edge closing the shape is inferred between the last
    point and the first point.
  - You can modify the points in a Polygon.  The points' coordinate system is relative to (0, 0) so if you'd like a
      top-center justified 10x20 rectangle you can do points [(-5, 0), (5, 0), (5, 20), (0, 20)] and your VectorShape
      x and y properties will position the rectangle relative to its top center point

* Rectangle
  A width and a height.
2020-05-09 15:38:22 -07:00
Dan Halbert 8d00d99ca0
Shrink hallowing_m0_express to fit ko build 2020-05-08 22:51:21 -04:00
Dan Halbert 602eabe668
Squeeze hallowing_m0_express build slightly
ko build is a little too big.
2020-05-04 17:18:53 -04:00
Dan Halbert c377d4bea7
Merge branch 'master' into non-standard-nvm 2020-05-04 16:08:45 -04:00
Scott Shawcroft 3799c34564
Disable bitbangio on CPX Crickit so we have room for lower_power.
Enable pixelbuf in its place because we'll need it soon.
2020-04-29 13:57:09 -07:00
Max Holliday b2de5a9df9 fixing my goofy gcc-arm local stuff 2020-04-28 12:24:10 -07:00
Max Holliday 6c4decd4e2 decoupling chip specific functions from EXTERNAL_FLASH_QSPI_SINGLE 2020-04-28 11:51:07 -07:00
Scott Shawcroft 755d404edf
Merge remote-tracking branch 'adafruit/master' into lower_power 2020-04-27 16:45:10 -07:00
Max Holliday 86943ca8a1 Merge remote-tracking branch 'adafruit/master' 2020-04-27 13:51:51 -07:00
Scott Shawcroft 9e4b94f466
Merge pull request #2805 from tannewt/update_tinyusb
Update tinyusb
2020-04-26 20:55:36 -07:00
Lucian Copeland bd0df9e3bc Minor redundancy fix 2020-04-23 17:43:35 -04:00
Lucian Copeland c6c77726e7 Merge remote-tracking branch 'upstream/master' into stm32-docfix 2020-04-23 13:39:48 -04:00
Lucian Copeland 8791ca6af3 implement requested changes 2020-04-23 13:33:41 -04:00
Scott Shawcroft dcb0e50f04
Fix USB midi and hid disable. 2020-04-21 14:15:44 -07:00
Scott Shawcroft bebf27e733
Merge remote-tracking branch 'adafruit/master' into lower_power
This isn't perfect and needs a bit more testing.
2020-04-20 18:25:13 -07:00
Scott Shawcroft a4d86b96fd
Merge pull request #2777 from pewpew-game/master
Fix RGB/BGR colors in Stage
2020-04-20 15:25:29 -07:00
Jeff Epler 5fcc6d6286 RGBMatrix: finish renaming from Protomatter
This gets all the purely internal references.  Some uses of
protomatter/Protomatter/PROTOMATTER remain, as they are references
to symbols in the Protomatter C library itself.
2020-04-17 18:44:07 -05:00
Jeff Epler 3d6258f63d Rename Protomatter -> RGBMatrix
This is a quick rename, it changes the user-facing names but not the
internal names of things.
2020-04-17 18:43:57 -05:00
Jeff Epler a32337718d Rename _protomatter -> protomatter
I originally believed that there would be a wrapper library around it,
like with _pixelbuf; but this proves not to be the case, as there's
too little for the library to do.
2020-04-17 18:43:57 -05:00
Scott Shawcroft 7e3d4c61b5
Update TinyUSB and add interrupt hooks. 2020-04-17 14:16:49 -07:00
Radomir Dopieralski 43022d8294 Add copyrights to pewpew m4 and ugame board.c 2020-04-17 09:50:11 +02:00
Scott Shawcroft b3552efc76
Remove accidental file 2020-04-16 11:28:01 -07:00
Radomir Dopieralski f39ca6052e Fix RGB/BGR colors in Stage
This makes the colors used by the stage library compatible with those
used by the displayio library.
2020-04-15 23:41:38 +02:00
Scott Shawcroft b580b34cbf
Merge remote-tracking branch 'adafruit/master' into lower_power 2020-04-14 17:14:44 -07:00
Jeff Epler 23bced26da samd: actually disable protomatter timer
Just setting the timer handler to NO_INTERRUPT doesn't stop the
interrupt from occurring.
2020-04-14 18:24:58 -05:00
Jeff Epler 759fdffda5 Update ports/atmel-samd/boards/pyportal_titano/board.c
Co-Authored-By: Scott Shawcroft <scott@tannewt.org>
2020-04-14 18:24:58 -05:00
Jeff Epler 09dc46a984 Add Protomatter and FramebufferDisplay 2020-04-14 18:24:54 -05:00
Jeff Epler a51d4f7a45 pycubed: add trailing newline to file
POSIX specifies that text files end in a trailing newline
2020-04-14 18:24:54 -05:00
Sabas cac4fb0318
Merge branch 'master' into nfc_copy 2020-04-09 17:05:11 -05:00
sabas1080 49771b4d7f Update to v1.3 2020-04-09 14:27:51 -05:00
Scott Shawcroft d0a25ca9ac
Tweaks based on dhalberts feedback 2020-04-08 10:49:46 -07:00
Max Holliday 181ecf4a9b fixing my goofy CROSS_COMPILE fix 2020-04-07 21:54:46 -07:00
Max Holliday a53a26be70 missed a debug flag 2020-04-07 18:24:53 -07:00
Max Holliday 826837186c adds standard (non-queued) SPI support to QSPI for external flash 2020-04-07 18:17:25 -07:00
Scott Shawcroft c0ba2a839f
Updates based on feedback from jepler 2020-04-06 16:03:31 -07:00
Scott Shawcroft e99cf6e441
Rework sleep timing
It didn't account for background task time and could end up
sleeping for way longer than it should because the RTC compare time
had already passed.
2020-04-03 18:07:56 -07:00
Scott Shawcroft 46af4bdd0e
Fix SAMD21 PulseIn 2020-04-02 17:35:52 -07:00
Scott Shawcroft 77562a2acd
Update the supported ports 2020-03-31 18:27:55 -07:00
Scott Shawcroft 8fe512c7e9
Merge remote-tracking branch 'adafruit/master' into lower_power 2020-03-31 15:13:58 -07:00
Brian Dean 7cfa8e1a68 board_vina_m0:pins.c: PGM_LED is on PA28 not PA15. 2020-03-29 18:59:00 -04:00
Jeff Epler 54e8c63b4f
Merge pull request #2730 from tannewt/fix_fourwire_phase_polarity
Add polarity and phase to FourWire.
2020-03-28 07:28:37 -05:00
Scott Shawcroft 798118b74f
Update board.c's to remove remaining tick.h 2020-03-27 14:52:35 -07:00
Scott Shawcroft e4c4a4a3de
Swap to committed dependencies 2020-03-27 14:39:59 -07:00
Scott Shawcroft b043384949
Update built in display init 2020-03-27 14:35:29 -07:00