Commit Graph

12048 Commits

Author SHA1 Message Date
sommersoft
6205ed9a0c updated cdc_enabled; now more dynamic status return 2018-03-24 03:42:58 +00:00
sommersoft
ef16109c5d updated with requested changes 2018-03-24 00:55:48 +00:00
Scott Shawcroft
fa88446679
Merge pull request #697 from jepler/issue501
extmod/vfs_fat_file: Implement SEEK_CUR for non-zero offset.
2018-03-23 14:48:41 -07:00
Scott Shawcroft
8d376a3efb
Merge pull request #693 from jepler/issue236
Implement * and *= for array.array
2018-03-23 14:46:03 -07:00
sommersoft
f237657e5e extended buffer check to usb_cdc_background 2018-03-23 18:41:27 +00:00
Dan Halbert
ce8f7e69bf
Merge pull request #700 from adafruit/tannewt-patch-6
Update USB PID
2018-03-23 13:25:39 -04:00
Scott Shawcroft
63d826a52a
Update USB PID 2018-03-23 09:34:02 -07:00
sommersoft
ccbe557e30 removed leftover debugging bits 2018-03-23 15:45:30 +00:00
sommersoft
d434635822 add buffer check before triggering new usb read 2018-03-23 15:07:02 +00:00
Ayke van Laethem
fa55b15ac6 extmod/vfs_fat_file: Implement SEEK_CUR for non-zero offset.
CPython doesn't allow SEEK_CUR with non-zero offset for files in text mode,
and uPy inherited this behaviour for both text and binary files.  It makes
sense to provide full support for SEEK_CUR of binary-mode files in uPy, and
to do this in a minimal way means also allowing to use SEEK_CUR with
non-zero offsets on text-mode files.  That seems to be a fair compromise.
2018-03-23 09:19:56 -05:00
Dan Halbert
261586518a
Merge pull request #694 from tannewt/feather_m4
Add Feather M4 Express support.
2018-03-23 09:16:10 -04:00
Jeff Epler
cdb83b18ec Implement * and *= for array.array 2018-03-23 07:37:07 -05:00
Scott Shawcroft
fd7dcff4e9 Add Feather M4 Express support.
* Also fixed detection of SPI flash chip to correct look in the 2+
spots.
* Added support for using QSPI in dual read mode.
2018-03-23 00:00:13 -07:00
Dan Halbert
00eacbf45e
Merge pull request #692 from tannewt/latest_m4
Add support for the Metro M4 Rev F and make the SPI flash code more robust
2018-03-22 22:01:33 -04:00
Scott Shawcroft
06b4c83f59 Add reminder to remove Saleae when going fast. 2018-03-22 17:44:44 -07:00
Scott Shawcroft
3bf4d69f67 Update Metro M4 to rev F and make flash reset on start. 2018-03-22 16:42:47 -07:00
Scott Shawcroft
0c4bbefdf0
Merge pull request #691 from jepler/issue689
Autocreate files that prevent MacOS indexing of the CIRCUITPYTHON dive
2018-03-22 10:28:41 -07:00
Scott Shawcroft
f8bee74e8e
Merge pull request #690 from jepler/no-gitter
README: delete reference to gitter
2018-03-22 10:06:02 -07:00
Jeff Epler
a7e3c74fed Autocreate files that prevent MacOS indexing of the CIRCUITPYTHON dive
.. the price of this appears to be about 112 bytes of flash and 12
bytes of RAM, according to the stats printed during the build.

It also uses up 4 directory entries (out of 128), but does not reduce
the number of blocks usable for storing file contents.

These are the same items noted in the Adafruit README for Trinket M0
as preventing MacOS indexing.

Closes: #689
2018-03-22 08:07:32 -05:00
Jeff Epler
9ddf60f8b4 CONTRIBUTING: delete reference to gitter 2018-03-21 21:35:07 -05:00
Jeff Epler
edfc76be4d README: delete reference to gitter
"We don't use gitter anymore" -- the last message on
https://gitter.im/adafruit/circuitpython on February 18
2018-03-21 21:11:24 -05:00
Scott Shawcroft
9ab39eb2d2
Merge pull request #688 from jepler/atsamd-build-reqs
Better document build requirements and steps
2018-03-20 10:03:01 -07:00
Scott Shawcroft
286e342a9a
Merge pull request #686 from jepler/lto-type-diagnostic
Fix array vs pointer error in declaration of circuitpython_help_text
2018-03-20 10:01:28 -07:00
Scott Shawcroft
0f90f35606
Merge pull request #685 from jepler/uart-diagnostic
UART: Fix maybe-uninitialized diagnostic
2018-03-20 09:59:31 -07:00
Jeff Epler
3f82fe8da9 README.rst: document mpy-cross gotcha
This was biting me, leading to an odd error later on.
2018-03-20 07:53:30 -05:00
Jeff Epler
fa491b4c32 README.rst: spell out gcc version requirements
.. the text was adapted from ports/stm32 and a conversation with
Dan Halbert.
2018-03-20 07:53:30 -05:00
iabdalkader
7b0a020a02 stm32/boards/NUCLEO_H743ZI: Disable uSD transceiver.
There's no uSD Transceiver on this NUCLEO board.
2018-03-20 23:26:03 +11:00
iabdalkader
1e0a67f290 stm32/boards/NUCLEO_H743ZI: Enable hardware I2C support. 2018-03-20 23:25:43 +11:00
iabdalkader
24a9facd89 stm32/i2c: Add H7 I2C timing configurations.
Found the timing for full (400 KHz) and FM+ (1MHz) in the HAL examples, and
used CubeMX to calculate the standard value (100KHz).
2018-03-20 23:25:01 +11:00
iabdalkader
2ebc538d63 stm32/dma: Enable H7 DMA descriptors. 2018-03-20 23:24:45 +11:00
Jeff Epler
002797a3b4 Fix array vs pointer error in declaration of circuitpython_help_text
Building with gcc 5.4.1 (Debian Stretch) with the unsupported
-Wno-error=lto-type-mismatch flag removed, the following diagnostic
occurs:

../../py/builtin.h:121:19: error: type of 'circuitpython_help_text' does not match original declaration [-Werror]
 extern const char MICROPY_PY_BUILTINS_HELP_TEXT[];
                   ^
../../shared-bindings/help.c:38:13: note: previously declared here
 const char *circuitpython_help_text =
             ^
lto1: all warnings being treated as errors
lto-wrapper: fatal error: /usr/bin/arm-none-eabi-gcc returned 1 exit status
2018-03-19 22:11:40 -05:00
Dan Halbert
4e3748d0ae
Merge pull request #683 from kattni/digital-pin-assignments
Added digital pin assignments to CPX
2018-03-19 22:17:21 -04:00
Jeff Epler
dddfad6594 UART: Fix maybe-uninitialized diagnostic
The following error occurs when building with gcc 5.4.1 (debian stretch):

common-hal/busio/UART.c:104:83: error: 'sercom_index' may be used uninitialized in this function [-Werror=maybe-uninitialized]
                   sercom_insts[rx->sercom[j].index]->USART.CTRLA.bit.ENABLE == 0) ||

It may be related to the addition of rx-only UARTs; gcc is unable
to infer the intended relationship between have_tx and sercom_index
being set (I am still not entirely confident of it myself)
2018-03-19 20:40:04 -05:00
Damien George
22c693aa6f tests/pyb/can: Update to test pyb.CAN restart, state, info, inplace recv 2018-03-19 15:15:39 +11:00
Damien George
0abbafd424 stm32/can: Add "list" param to CAN.recv() to receive data inplace.
This API matches (as close as possible) how other pyb classes allow inplace
operations, such as pyb.SPI.recv(buf).
2018-03-19 15:12:24 +11:00
Damien George
5e1279d41a travis: Pass -j4 to make to speed up compilation.
This seems to reduce the Travis build time by roughly 1 minute / 10%.
2018-03-19 11:57:38 +11:00
Damien George
e37b8ba5a5 stm32: Use STM32xx macros instead of MCU_SERIES_xx to select MCU type.
The CMSIS files for the STM32 range provide macros to distinguish between
the different MCU series: STM32F4, STM32F7, STM32H7, STM32L4, etc.  Prefer
to use these instead of custom ones.
2018-03-17 10:42:50 +11:00
Damien George
5edce4539b py/objexcept: Make MP_DEFINE_EXCEPTION public so ports can define excs. 2018-03-17 00:31:40 +11:00
Damien George
f6a1f18603 py/makeqstrdefs.py: Optimise by using compiled re's so it runs faster.
By using pre-compiled regexs, using startswith(), and explicitly checking
for empty lines (of which around 30% of the input lines are), automatic
qstr extraction is speed up by about 10%.
2018-03-16 23:54:06 +11:00
Damien George
06aa13c350 stm32/can: Use explicit byte extraction instead of casting to word ptr.
Casting the Data array to a uint32_t* leads to strict aliasing errors on
older gcc compilers.
2018-03-16 23:52:13 +11:00
Damien George
9600a1f207 tests/pyb: Update CAN test to expect that auto_restart is printed. 2018-03-16 18:37:55 +11:00
Damien George
b7d576d69a docs/library/pyb.CAN: Clean up documentation of data constants. 2018-03-16 18:29:43 +11:00
Damien George
a25e6c6b65 stm32/can: Add CAN.info() method to retrieve error and tx/rx buf info. 2018-03-16 18:28:35 +11:00
Damien George
d7e67fb1b4 stm32/can: Add CAN.state() method to get the state of the controller.
This is useful for monitoring errors on the bus and knowing when a restart
is needed.
2018-03-16 17:10:41 +11:00
Kattni
05e2a7d1ac Added digital pin assignments 2018-03-15 20:28:09 -04:00
Scott Shawcroft
bf42611738
Merge pull request #681 from jerryneedell/patch-1
fix dotstar for Gemma_M0 in CP3.0
2018-03-15 10:05:26 -07:00
Damien George
1272c3c65d stm32/can: Add CAN.restart() method so controller can leave bus-off. 2018-03-15 17:29:30 +11:00
Damien George
823ca03008 stm32/can: Add "auto_restart" option to constructor and init() method. 2018-03-15 17:17:33 +11:00
Damien George
1608c4f5be stm32/can: Use enums to index keyword arguments, for clarity. 2018-03-15 17:15:41 +11:00
Damien George
2036196d71 stm32/can: Improve can.recv() so it checks for events, eg ctrl-C.
This patch provides a custom (and simple) function to receive data on the
CAN bus, instead of the HAL function.  This custom version calls
mp_handle_pending() while waiting for messages, which, among other things,
allows to interrupt the recv() method via KeyboardInterrupt.
2018-03-15 16:34:07 +11:00