Dan Halbert
a5dc0fef5f
Revert #5341 . Does not work on power-cycle.
2021-09-16 11:59:43 -04:00
Max Holliday
1ccaeeb619
adding back heritage pycubed board defs
2021-09-15 14:36:27 -06:00
Max Holliday
4f10a91f85
moving boot counter to main() and re-adding old pin names for SD_CS
2021-09-15 14:33:54 -06:00
Max Holliday
5b69aa0a58
Merge branch 'adafruit:main' into pycubed_v05c
2021-09-15 14:23:56 -06:00
microDev
e91fb247a3
build docs dynamically
2021-09-16 00:05:42 +05:30
Scott Shawcroft
3cc4f25a1c
Merge pull request #5337 from hathach/tinyusb-compliance-stm-imxrt-esp32
...
update tinyusb to have esp32sx, stm32 and imxrt passed compliance test suite
2021-09-14 22:40:13 -07:00
Dan Halbert
9e8c6b2bab
Shrink pca10100 some more
2021-09-14 21:37:30 -04:00
Dan Halbert
02dc0481c5
shrink stm32f411ve_discovery
2021-09-14 19:50:46 -04:00
Dan Halbert
59b1bedcda
Merge pull request #5333 from microDev1/patch
...
Make `next_code_allocation` and `prev_traceback_allocation` movable
2021-09-14 19:27:40 -04:00
Scott Shawcroft
dfba2ee26e
Merge pull request #5342 from tannewt/rename_esp32s2_to_espressif
...
Rename esp32s2 port to espressif
2021-09-14 16:23:14 -07:00
Dan Halbert
0ab4df6f2f
shrink some SAMD21 builds, and nrf simmel
2021-09-14 17:10:49 -04:00
Dan Halbert
81e28308c2
Revert "turn off inline-unit-growth and max-inline-insns-auto uses"
...
This reverts commit 94d76e0f48
.
2021-09-14 16:56:04 -04:00
microDev
8520c430a7
Merge pull request #5341 from urish/patch-1
...
Enable WFI for raspberrypi port
2021-09-14 22:10:02 +05:30
Dan Halbert
94d76e0f48
turn off inline-unit-growth and max-inline-insns-auto uses
2021-09-14 12:15:21 -04:00
Scott Shawcroft
973a90f2aa
Rename esp32s2 port to espressif
...
This is in preparation for ESP32-S3 support and potentially others.
Related to #4363
2021-09-13 16:44:55 -07:00
Dan Halbert
650ce17c0d
Fix formatting
2021-09-13 19:12:21 -04:00
Uri Shaked
e5290a2886
Enable WFI for raspberrypi port
...
See #5331 for details
2021-09-14 01:09:15 +03:00
Scott Shawcroft
64ff8d9e19
v3 BLE file service: Add file modification times
2021-09-13 14:46:14 -07:00
Scott Shawcroft
5d90991745
Trade RAM for flash on pca10100
2021-09-13 12:04:27 -07:00
microDev
cddbfffb38
Merge pull request #5335 from skieast/espressif_hmi_v1.1_pins_update
...
Update pins.c to match hmi devkit board
2021-09-13 16:23:02 +05:30
Kamil Tomaszewski
a0d960f2a1
spresense: update SDK to 2.3.0
2021-09-13 11:04:15 +02:00
Bruce Segal
c4bea28446
Update pins.c to match hmi devkit board
2021-09-12 17:54:44 -07:00
Max Holliday
dbd557dc89
splitting pycubed board def into pycubed_v04 and pycubed_v05
2021-09-11 20:29:40 -06:00
Max Holliday
d9ae2c00b4
Merge branch 'adafruit:main' into pycubed_v05c
2021-09-11 20:09:59 -06:00
Dan Halbert
f5bb53e112
Merge pull request #5329 from dhalbert/prox-trinkey-squeeze
...
proxlight: Freeze adafruit_apds9960 instead of adafruit_hid; enable usb_midi
2021-09-10 18:17:42 -04:00
Max Holliday
bc26194bd0
Merge branch 'adafruit:main' into pycubed_v05c
2021-09-10 13:33:11 -06:00
Dan Halbert
aa1d089cdb
proxlight: Freeze adafruit_adps9960 instead of adafruit_hid; enable usb_midi
2021-09-10 14:50:09 -04:00
Dan Halbert
189efdf074
Use NO_PIN, not 0, for PDMIn unset pins.
...
Also:
- Use NO_PIN, not 0xff for I2SOut (cosmetic fix only; no actual functional change)
- Add VOLTAGE_MONITOR/BATTERY, ACCELEROMETER_INTERRUPT pins for LED Glasses Driver
2021-09-10 13:18:29 -04:00
Scott Shawcroft
0ee0ed7035
Merge pull request #5320 from rjp5th/main
...
Implement reset_reason for raspberrypi port
2021-09-09 10:54:14 -07:00
Pontus Oldberg
647eca6a81
Added support for Challenger RP2040 WiFi
2021-09-09 17:36:56 +02:00
microDev
09859a60e7
Merge pull request #5319 from tannewt/fix_nrf_gcc11
...
Fix the nRF builds with GCC 11.2
2021-09-09 09:09:34 +05:30
Max Holliday
fa83c1c2f9
adding boot counter to main.c
...
The boot counter is a uint8_t single-byte counter stored in the first NVM byte position (`micrcontroller.nvm[0]`). The counter increments by 1 each time the board boots, regardless if it's a hard or soft reset.
Enable the boot counter by adding `#define CIRCUITPY_BOOT_COUNTER 1` to your board's mpconfigboard.h file. Note that an error will be thrown during the build if `CIRCUITPY_INTERNAL_NVM_SIZE` is not also set within mpconfigboard.h.
2021-09-08 19:56:23 -06:00
Max Holliday
5d29caf499
Merge branch 'adafruit:main' into pycubed_v05c
2021-09-08 19:37:06 -06:00
Scott Shawcroft
2b4fdcdfa2
Fix scanning after a peripheral bond has been made
...
The BLE workflow will be advertising and the scan's load of
identities conflicts with it. This change ensures scanning and
advertising happens exclusively.
This showed as an unknown error 3204.
Fixes https://github.com/adafruit/Adafruit_CircuitPython_BLE/issues/134
2021-09-08 16:58:53 -07:00
Robert Pafford
65f8804816
Implement reset_reason for raspberrypi port
2021-09-08 18:34:34 -04:00
Scott Shawcroft
f2de010059
Fix the nRF builds with GCC 11.2
...
See adafruit/Adafruit_nRF52_Bootloader#221
for background on the flag.
2021-09-08 12:53:39 -07:00
Kattni
2ea330581d
Merge pull request #5310 from dhalbert/rsp2040-i2s-fix
...
Fix RP2040 I2S: always copy to output buffer
2021-09-07 18:18:30 -04:00
Scott Shawcroft
a5ac5e1efb
Merge pull request #5297 from durapensa/s2mini
...
Lolin S2 Mini - remove NeoPixel, pin assignments to match Wemos
2021-09-07 14:11:21 -07:00
Dan Halbert
d2d0bd289f
Fix RP2040 I2S: always copy to output buffer
2021-09-07 16:35:42 -04:00
Max Holliday
674a3027fc
updating pycubed firmware for mainboardv05 :)
2021-09-04 18:39:24 -06:00
Durapensa
7e10785ec7
Lolin S2 Mini - fix EOF issue caught by pre-commit
2021-09-03 16:46:50 -04:00
durapensa
2fc372b9e1
Lolin S2 Mini - Apply suggestions from code review
...
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-09-03 15:10:22 -04:00
Neradoc
8625e53817
change board dicts to include a common macro with __name__
2021-09-03 21:03:55 +02:00
Durapensa
15fc44cab7
Lolin S2 Mini fix typo in pin assignment
2021-09-03 12:20:07 -04:00
Durapensa
32b9450e7f
Lolin S2 Mini removed some redundant comments
2021-09-03 12:14:59 -04:00
Durapensa
c0f039da29
Lolin S2 Mini added pin definitions from Wemos/Lolin D1 Mini
2021-09-03 12:08:38 -04:00
Durapensa
ef6d7fe731
Lolin S2 Mini change 'Espressif' references to 'Wemos'
2021-09-03 10:17:44 -04:00
Durapensa
765eee424e
Lolin S2 Mini added I2C & SPI defs from Espressif MicroPython
2021-09-03 10:08:38 -04:00
Durapensa
ec20b2a02e
Merge branch 'main' of github.com:adafruit/circuitpython into s2mini
2021-09-03 09:26:47 -04:00
Durapensa
762c15535f
Lolin S2 Mini pin assignment changes
2021-09-03 09:12:14 -04:00
Scott Shawcroft
3508b01ed9
Merge pull request #5294 from tannewt/patch-1
...
Add FeatherS2 Neo from Unexpected Maker
2021-09-02 12:44:27 -07:00
Scott Shawcroft
bf5e8bf20b
Use Espressif PID
2021-09-02 10:17:38 -07:00
Scott Shawcroft
a78cc7a22c
Merge pull request #5293 from microDev1/patch
...
Make `aesio` module full build dependent
2021-09-02 09:34:53 -07:00
microDev
d526925d49
make aesio module full build dependent
2021-09-02 19:02:01 +05:30
Seon Rozenblum
9bfa2a416d
Added STAGE support for my TinyS2 board
2021-09-02 18:09:08 +10:00
Seon Rozenblum
24859ed596
Added support for my new FeatherS2 Neo esp32s2 board
2021-09-02 15:01:52 +10:00
Scott Shawcroft
57e4b78340
Merge pull request #5284 from tannewt/linking_fixes
...
Two fixes, one for ble workflow, one for linking
2021-09-01 15:21:33 -07:00
Scott Shawcroft
cf0899487f
Merge pull request #5237 from jepler/hmi
...
Add Espressif's HMI DevKit
2021-09-01 13:49:58 -07:00
Scott Shawcroft
0d280fa83c
Two fixes, one for ble workflow, one for linking
...
BLE workflow had an incorrect list size for characteristics
Linking didn't advance . link it should have without extra ().
2021-09-01 12:43:43 -07:00
Scott Shawcroft
9557ca89f2
Update USB PID
2021-09-01 10:50:48 -07:00
Scott Shawcroft
b80ffee105
Merge pull request #5268 from hathach/nrf-usb-compliance-test
...
Update tinyusb for USB Compliance Verification test
2021-09-01 10:48:35 -07:00
Scott Shawcroft
9c4c3e1780
Only sort .text for nrf
2021-09-01 08:57:18 -07:00
Damien George
25f30eb8a6
stm32/boards/LEGO_HUB_NO6: Add comment re constraints on SPI flash cfg.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-09-02 00:03:41 +10:00
Bruce Segal
bec7a6265a
Change name VBAT_SENSE -> BATTERY
2021-08-31 19:52:40 -07:00
Scott Shawcroft
0cffa6be81
Sort .text section to reduce fill on nRF
2021-08-31 19:33:44 -07:00
Scott Shawcroft
cd5acae4f4
Sort .text section to reduce fill
2021-08-31 18:04:01 -07:00
Bruce Segal
736b592d2d
Add IO9 / VBAT_SENSE to lilygo-t8-s2-st7789
2021-08-31 16:50:50 -07:00
Scott Shawcroft
771b4c7464
Add two space saving knobs
...
* Reduce the number of supported HID reports of IDs per descriptor.
This saves ~200 bytes in the default HID objects.
* (Not enabled) Compute QSTR attrs on init. This trades 1k RAM for
flash. Flash is the default (1).
2021-08-31 13:02:34 -07:00
Scott Shawcroft
cc0a6c8a5f
Merge remote-tracking branch 'adafruit/main' into fix_nrf_wdt_crashes
2021-08-31 11:03:44 -07:00
Damien George
35ead0ff0f
javascript/Makefile: Change variable to EXPORTED_RUNTIME_METHODS.
...
EXTRA_EXPORTED_RUNTIME_METHODS is deprecated.
Signed-off-by: Damien George <damien@micropython.org>
2021-09-01 00:42:40 +10:00
microDev
513ca098f9
Merge pull request #5273 from tannewt/fix_nrf_light_sleep_cdc
...
Fix nrf light_sleep when on usb
2021-08-31 13:29:04 +05:30
microDev
1dbeed87af
Merge pull request #5253 from tannewt/fix_nrf_gpiote_crash
...
Fix GPIOTE crashes by checking everything is ok
2021-08-31 09:11:36 +05:30
David Lechner
86371781e9
tools/uncrustify: Force 1 newline at end of file.
...
To keep things neat and tidy, we ensure that each file has 1 and only 1
newline at the end of each file.
Signed-off-by: David Lechner <david@pybricks.com>
2021-08-31 13:14:45 +10:00
Scott Shawcroft
6ef5241f59
Merge pull request #5267 from pewpew-game/meowbit-stage
...
stm32: Add support for Stage games to Meowbit
2021-08-30 18:35:41 -07:00
Scott Shawcroft
5fb4fa6f12
Merge pull request #5260 from jepler/paralleldisplay
...
Split out paralleldisplay to its own module
2021-08-30 18:35:15 -07:00
Scott Shawcroft
fa9c2189d4
Fix nrf light_sleep when on usb
...
Don't let pending serial input wake us up
Fixes #5257
2021-08-30 18:26:12 -07:00
Scott Shawcroft
a4246bcfa3
Fix two watchdog crashes
...
Fixes a crash from trying to raise an exception when trying to
deinit a RESET wdt by not raising an exception.
Fixes a crash when raise a wdt exception in the REPL when waiting
for input. We now catch and print any exceptions raised.
Fixes #5261
2021-08-30 18:10:43 -07:00
Scott Shawcroft
3ea90dbc1e
Merge pull request #5263 from jepler/printf-0xp
...
Include leading 0x on addresses printed with %p
2021-08-30 18:00:43 -07:00
Scott Shawcroft
838d30b3a4
Fix incorrect macros
2021-08-30 14:40:14 -07:00
Scott Shawcroft
8fbb3e6d25
Merge pull request #5239 from durapensa/s2mini
...
Add board Lolin S2 Mini
2021-08-30 14:12:56 -07:00
Scott Shawcroft
eabceb9fce
Fix builds without alarm
2021-08-30 14:09:36 -07:00
Radomir Dopieralski
89fc1890af
stm32: Add support for Stage games to Meowbit
...
This enables the _stage library and adds stage and ugame modules to the
frozen modules, so that all Stage games should work.
I had to do several hacks:
* Since displayio.release_displays doesn't release the pins, I couldn't
re-initialize the display inside the ugame module. Instead I changed
the default display initialization for the board to match what Stage
expects.
* I wanted to make the MENU key works as K_Z, but when I try to use it
with the keypad module, I get "pin in use" error. So for now only the
A and B buttons are used.
2021-08-30 20:27:50 +02:00
Damien George
6f19b9c08d
stm32/boards/LEGO_HUB_NO6: Add make commands to backup/restore firmware.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-08-31 00:16:39 +10:00
Damien George
bac791c5fd
stm32/boards/LEGO_HUB_NO6: Skip first 1MiB of SPI flash for storage.
...
The first 1MiB is used by the built-in bootloader and is best left as-is.
Signed-off-by: Damien George <damien@micropython.org>
2021-08-31 00:16:39 +10:00
Damien George
e3eed26d0b
stm32/boards/LEGO_HUB_NO6: Change SPI flash storage to use hardware SPI.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-08-31 00:16:39 +10:00
Damien George
6936f410ab
stm32/storage: Make extended-block-device more configurable.
...
A board can now define the following to fully customise the extended block
device interface provided by the storage sub-system:
- MICROPY_HW_BDEV_BLOCKSIZE_EXT
- MICROPY_HW_BDEV_READBLOCKS_EXT
- MICROPY_HW_BDEV_WRITEBLOCKS_EXT
- MICROPY_HW_BDEV_ERASEBLOCKS_EXT
Signed-off-by: Damien George <damien@micropython.org>
2021-08-31 00:16:39 +10:00
Patrick Van Oosterwijck
a66bd7a489
esp32/boards: Add GENERIC_C3_USB board with USB serial/JTAG support.
...
Add a new board type for ESP32-C3 revision 3 and up that implement the USB
serial/JTAG port on pin 18 and 19. This variant uses the USB serial for
programming and console, leaving the UART free.
- Pins 18 and 19 are correctly reserved for this variant. Also pins 14-17
are reserved for flash for any ESP32-C3 so they can't be reconfigured
anymore to crash the system.
- Added usb_serial_jtag.c and .h to implement this interface.
- Interface was tested to work correctly together with webrepl.
- Interface was tested to work correctly when sending and receiving
large files with ampy.
- Disconnecting terminal or USB will not hang the system when it's
trying to print.
2021-08-31 00:12:41 +10:00
Durapensa
80cadc6ec1
Added Espressif-assigned PID for "Lolin S2 Mini - CircuitPython"
2021-08-30 06:31:20 -04:00
lady ada
d50dc064ee
fix i2c
2021-08-29 17:53:57 -04:00
Jeff Epler
68af5fd040
unix: Filter out -std=gnu11
...
On Debian Bullseye, it is an error to include this flag when building
a C++ file, which caused the unix coverage build to fail.
2021-08-29 11:36:17 -05:00
Jeff Epler
d7193dcf7c
remove debug print
2021-08-29 11:36:17 -05:00
Jeff Epler
8f024316ad
explicitly disable paralleldisplay on a few boards
2021-08-29 07:33:54 -05:00
Jeff Epler
468558896c
remove paralleldisplay from ports where it was unimplemented
2021-08-29 07:33:54 -05:00
Jeff Epler
7520feed1c
Move ParallelBus to its own module
2021-08-29 07:33:54 -05:00
iabdalkader
a3ce8f08ec
rp2/mpconfigport.h: Allow boards to add root pointers.
2021-08-29 12:22:50 +10:00
iabdalkader
79baef843b
rp2/CMakeLists.txt: Add option to enable double tap reset to bootrom.
...
* For boards a with reset switch, pressing twice resets into bootloader.
* Enabled by linking with the pico_bootsel_via_double_reset library.
2021-08-29 12:20:01 +10:00
iabdalkader
c82244a7c0
rp2/rp2_flash: Disable IRQs while calling flash_erase/program.
...
Flash erase/program functions disable the XIP bit. If any code runs from
flash at the same time (eg an IRQ or code it calls) it will fail and cause
a lockup.
2021-08-29 12:15:01 +10:00
Dan Halbert
5a4029059e
Merge pull request #5246 from jpconstantineau/board-CNCEncoderPad-RP2040
...
Add New Board: EncoderPad RP2040
2021-08-28 10:44:10 -04:00
leoli51
68a4b6448e
ready for pull request
2021-08-28 16:34:38 +02:00
microDev
b90a16b67c
Merge pull request #5255 from tannewt/fix_rp_countio
...
Fix RP2 countio reset
2021-08-28 08:45:00 +05:30
Scott Shawcroft
6e7e703f89
Fix RP2 countio reset
...
Fixes #5251
2021-08-27 17:39:19 -07:00
Scott Shawcroft
a8dd881ee5
Fix GPIOTE crashes by checking everything is ok
...
Fixes #5240 and fixes #5211
2021-08-27 16:07:29 -07:00
Scott Shawcroft
ca989c4357
Update the idf to a newer 4.3 commit
...
Also, make all port-level CIRCUITPY_ settings overridable.
2021-08-27 10:49:57 -07:00
Scott Shawcroft
3e9daeca8f
Merge pull request #5244 from dhalbert/stop-pio-on-deinit
...
Stop StateMachine explicitly on deinit
2021-08-27 08:59:04 -07:00
Scott Shawcroft
8edf0c5d3c
Merge pull request #5243 from dhalbert/user-interruptible-pio
...
Allow PIO to be user-interruptible
2021-08-27 08:57:08 -07:00
Pierre Constantineau
ada178893d
updated PID as per OpenMoko PR
2021-08-27 09:02:49 -06:00
Dan Halbert
09897dbc82
Merge pull request #5238 from tannewt/fix_rp2_usb
...
Fix usb irq race
2021-08-27 10:40:06 -04:00
Dan Halbert
0261cacb06
Stop StateMachine explicitly on deinit
2021-08-27 10:07:14 -04:00
Dan Halbert
f1d25af7ba
Allow PIO to be user-interruptible
2021-08-27 08:38:51 -04:00
Jeff Epler
c174b7c7e7
Merge pull request #5229 from warmbit/warmbit_bluepixel
...
add warmbit_bluepixel
2021-08-27 06:48:34 -05:00
Pierre Constantineau
e07bce2bf1
fixing trailing space
2021-08-27 00:25:22 -06:00
Pierre Constantineau
873729149d
adding EncodderPad RP2040
2021-08-26 23:08:10 -06:00
Neradoc
1302ef62f7
rebase, add adafruit_led_glasses_nrf52840
2021-08-26 23:18:44 +02:00
Jeff Epler
318ea7c8cb
Add Espressif's HMI DevKit
...
this is only tested to come up to the REPL & mount CIRCUITPY. Pin
assignments should be right but were not double-checked. The screen
is unsupported so far.
This board depends on the I/O pull ups for the I2C bus (verified by
schematic) so this adds a compile time option that enables pull ups
for ANY i2c bus on a board.
2021-08-26 16:14:19 -05:00
Neradoc
4d05bb26bf
change board.ID to board.board_id
2021-08-26 23:11:55 +02:00
Neradoc
fed6e8ea99
Spresense: add CIRCUITPY_BOARD_ID because it doesn't use BASE_CFLAGS
2021-08-26 23:11:55 +02:00
Neradoc
b14b294516
add board.ID
2021-08-26 23:11:55 +02:00
Durapensa
05874f3fab
pre-commit fixes
2021-08-26 14:29:04 -04:00
Durapensa
b0d0880f80
Add some more pin definitions, for NEOPIXEL_POWER, I2C, SPI
2021-08-26 13:53:04 -04:00
Scott Shawcroft
9663a227a3
Fix usb irq race
...
Run the USB background once after we hook our IRQ up in case we
missed one.
Related to #5212
2021-08-26 10:20:26 -07:00
Durapensa
b9c7badb56
fix for default names for BUTTON, NEOPIXEL, SDA/SCL, LED, SPI MOSI/MISO/SCK
2021-08-26 10:31:35 -04:00
Durapensa
ffaad96310
fix for GPIO0 / CIRCUITPY_BOOT_BUTTON
2021-08-26 10:15:15 -04:00
Durapensa
da1e29d9e4
fix in pins.c for build
2021-08-26 08:59:02 -04:00
Durapensa
5211a492cc
Merge branch 'main' of github.com:adafruit/circuitpython into s2mini
2021-08-26 08:28:05 -04:00
Durapensa
c6ab3b3a97
nitial try at Lolin S2 Mini board definition
2021-08-25 21:16:22 -04:00
Durapensa
52001f1678
Initial try at Lolin S2 Mini board definition
2021-08-25 21:08:42 -04:00
Scott Shawcroft
13cba8a17f
Merge pull request #5224 from dhalbert/adafruit_led_glasses_nrf52840
...
Add adafruit_led_glasses_nrf52840
2021-08-25 15:50:56 -07:00
WarmBit
da644bebb3
add warmbit_bluepixel
2021-08-25 15:16:59 -06:00
Jeff Epler
7098d4ccd7
8Kib may align better with flash blocks than 9KiB
2021-08-25 13:39:56 -05:00
Jeff Epler
4621cd54fb
esp32s2: update how nvm is mapped onto nvs
...
The old way mapped each byte of nvm onto a distinct nvs key, but this
allowed storage of only a very small number of bytes out of the
theoretical capacity.
Reworked like this, about half of the nvs capacity can be used for
nvm, so you're guaranteed the ability to store 9kB this way.
2021-08-25 11:39:45 -05:00
Jeff Epler
870aa2d79d
espidf: Add function to erase nvs
...
This may be necessary for some cases of migrating from 6.3.0 to 7.0.0.
2021-08-25 11:37:58 -05:00
Dan Halbert
c0c9892887
Add adafruit_led_glasses_nrf52840
2021-08-25 11:29:31 -04:00
microDev
df13bef3a1
Merge pull request #5220 from tannewt/fix_esp_i2c_display
...
Allocate I2C mutex with IDF
2021-08-25 08:42:11 +05:30
microDev
5484a2de25
Merge pull request #5219 from tannewt/multiple_status_dotstars
...
Support multiple status dotstars
2021-08-25 08:38:09 +05:30
Scott Shawcroft
0552ce2d3b
Allocate I2C mutex with IDF
...
This keeps the mutex info in the same spot in memory. "Statically
allocating it" with CircuitPython meant that the buffer moved when
the I2C object is moved to keep it alive for a display.
Fixes #4962
2021-08-24 16:06:14 -07:00
Scott Shawcroft
f9f3894888
Support multiple status dotstars
...
Only supporting one left a white dotstar stranded.
Fixes #5170
2021-08-24 14:35:11 -07:00
Jeff Epler
bef07961ab
raspberrypi: audiopwmout: subtle for #5092
...
I noticed that the loop over 65535 possible denominators took a long time,
causing up to 100ms wait for a sound sample to start playing!
This algorithm, adapted from an algorithm shown in Python's fractions.py,
is guaranteed to find the best denominator in a small number of steps
(I think log2-many steps but I'm not sure). In practice, it means the time
between samples playing is just 10ms, and some of that is recreating the
sine wave sample in Python each time.
It often finds the same solution as the old code, but sometimes it finds
one a bit better since it compares the ratios using float point instead
of integer arithmetic.
2021-08-24 16:33:20 -05:00
Jeff Epler
77b0c76a37
raspberrypi: audiopwmout: simple fix for #5092
2021-08-24 15:54:06 -05:00
Jim Mussared
996f703166
esp32,esp8266: Remove dead code for end_ticks in machine_bitstream.
...
The compiler was optimising this out already so it's a no-op change.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-24 23:55:08 +10:00
microDev
2e41550770
Merge pull request #5210 from DavePutz/issue_5091
...
Change optimizer option so RP2040 DEBUG builds work
2021-08-24 12:24:01 +05:30
root
0e3aa27794
Change optimizer option so RP2040 DEBUG builds work
2021-08-23 21:37:34 -05:00
Dan Halbert
ce5e267143
shrink thunderpack_v11; fix PulseOut doc
2021-08-23 21:57:29 -04:00
Dan Halbert
7587a521cb
Merge pull request #5145 from FoamyGuy/bitmaptools_paint_fill
...
Bitmaptools boundary_fill
2021-08-23 16:20:38 -04:00
Dan Halbert
fa9a98d96c
Merge pull request #5206 from microDev1/patch
...
Turn off `synthio` on `pca10100`
2021-08-23 16:20:10 -04:00
Scott Shawcroft
6d49a9f0c5
Merge pull request #5205 from jepler/deprecate-vertical-scroll
...
Deprecate Display's constructor arg set_vertical_scroll
2021-08-23 12:52:12 -07:00
microDev
533eab5b7f
turn off synthio
on pca10100
2021-08-23 23:33:55 +05:30
Scott Shawcroft
935888927e
Merge pull request #5196 from dhalbert/samd-audio-fixes
...
improve SAMD audio DMA
2021-08-23 10:27:59 -07:00
Scott Shawcroft
6f9078c546
Merge pull request #5202 from dhalbert/nrf-background-callback-critical-section
...
nrf: remove critical section around sd_app_evt_wait()
2021-08-23 09:46:12 -07:00
microDev
57b4d0176f
Merge pull request #5077 from microDev1/atexit
...
Add atexit module
2021-08-23 19:49:46 +05:30
Jeff Epler
379461df7d
Deprecate Display's constructor arg set_vertical_scroll
2021-08-23 09:17:59 -05:00
Dan Halbert
c72c679b1a
nrf: remove critical section around sd_app_evt_wait()
2021-08-22 19:44:03 -04:00
foamyguy
4c95150dab
eol file
2021-08-22 08:53:10 -05:00
foamyguy
707f2e25af
disable bitmaptools on devices without enough room
2021-08-22 08:52:12 -05:00
Dan Halbert
57841dc92b
Merge pull request #5171 from tannewt/unicode_filenames
...
Turn on unicode for FATFS
2021-08-21 16:31:54 -04:00
Dan Halbert
046372d840
put back some dynossat_edu_obc pins
2021-08-21 16:14:09 -04:00
Dan Halbert
b8b23c97d9
improve SAMD audio DMA
2021-08-21 14:34:37 -04:00
microDev
208ec71372
Merge pull request #5190 from jepler/issue4883
...
samd: diagnose out of range I2C frequency
2021-08-21 08:00:50 +05:30
microDev
f6d1caabc9
Merge pull request #5182 from tannewt/fix_imx
...
Check background pending before sleep
2021-08-21 08:00:10 +05:30
Jeff Epler
26d33658ea
samd: diagnose out of range I2C frequency
...
The frequency divisor is limited to 255, which gives 48MHz/2/255 ~= 94.1kHz as
the lowest speed.
Without this change, values below this cut-off gave higher frequencies instead,
which didn't appear to have any relation to the frequency value requested.
Closes : #4883
2021-08-20 15:22:35 -05:00
Scott Shawcroft
490096a480
Turn on advanced MP api for unix build
2021-08-20 12:53:07 -07:00
Scott Shawcroft
9f051ec7bf
Fix usb calibrated SAMD21 builds
2021-08-20 12:45:59 -07:00
Jim Mussared
b51e7e9d01
stm32: Disable computed goto on constrained boards.
...
Saves ~1kiB. Add comment to this effect to mpconfig.h.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-20 20:18:52 +10:00
Damien George
61d5a8b9ce
stm32/stm32_it: Support TIM17 IRQs on WB MCUs.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-08-20 17:04:39 +10:00
microDev
25437dcb33
Merge branch 'main' into atexit
2021-08-20 09:45:54 +05:30
microDev
60c0271e72
Merge pull request #5173 from jepler/issue3447
...
Update all implementations of spi read to honor write_value
2021-08-20 09:31:20 +05:30
microDev
7a0f8ae87f
Merge pull request #5175 from jepler/canio-timeout
...
canio: Run background tasks while waiting for message reception
2021-08-20 09:25:46 +05:30
Mark
f9f106b58d
Merge pull request #5123 from gamblor21/keypad_dup_pin_check
...
Check for duplicate pins in rows and columns
2021-08-19 22:20:04 -05:00
Scott Shawcroft
5c6e80a2bb
Shrink builds by defining advanced micropython API
...
Also, ignore more pins on SAMD boards and disable EXFAT on others.
2021-08-19 16:49:33 -07:00
Dan Halbert
419d374d3c
Merge pull request #5181 from kattni/macropad-speaker-enable
...
Add SPEAKER_ENABLE to MacroPad
2021-08-19 19:32:28 -04:00
Kattni Rembor
1185228b90
Remove SPEAKER_SHUTDOWN pin.
2021-08-19 15:18:19 -04:00
Scott Shawcroft
d2860b58b0
Check background pending before sleep
...
There is a race between when we run background tasks and when we
sleep. If an interrupt happens between the two, then we may delay
executing the background task. On some ports we checked this for
TinyUSB already. On iMX RT, we didn't which caused USB issues.
This PR makes it more generic for all background tasks including
USB.
Fixes #5086 and maybe others.
2021-08-19 12:18:13 -07:00
Jeff Epler
6abcac4ed6
not needed on rp2040
2021-08-19 13:56:31 -05:00
Jeff Epler
371f166de1
canio: Run background tasks while waiting for message reception
...
Closes : #5004
2021-08-19 13:55:30 -05:00
Jeff Epler
6ea136987e
run codeformat
2021-08-19 13:54:13 -05:00
Tobias Thyrrestrup
0886bf46ca
stm32/Makefile: Allow GIT_SUBMODULES and LIBS to be extended.
...
Signed-off-by: Tobias Thyrrestrup <tt@LEGO.com>
2021-08-19 22:56:39 +10:00
Jim Mussared
b352db7a63
rp2/Makefile: Add "submodules" target, to match other ports.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-19 22:54:57 +10:00
Jim Mussared
62fd450e62
drivers/neopixel: Add common machine.bitstream-based neopixel module.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-19 22:50:32 +10:00
Jim Mussared
39e9c0788f
esp8266: Replace esp.neopixel with machine.bitstream.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-19 22:50:32 +10:00
Jim Mussared
71f4faac27
esp32: Replace esp.neopixel with machine.bitstream.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-19 22:50:32 +10:00
Jim Mussared
e64cda5295
stm32: Add implementation of machine.bitstream.
...
Hand-written version for M0, and cycle-counter version for everything else.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-19 22:50:32 +10:00
Kattni Rembor
ae923db06d
Add SPEAKER_ENABLE pin to MacroPad.
2021-08-18 17:30:42 -04:00
Jeff Epler
cabe96e188
canio: Run background tasks while waiting for message reception
...
Closes : #5004
2021-08-18 11:39:40 -05:00
Scott Shawcroft
0390f812be
Fix RP2040 I2C instance check
2021-08-18 08:55:52 -07:00
Scott Shawcroft
e0ce5ff045
Fix some builds by disabling exfat
2021-08-18 08:22:29 -07:00
Jeff Epler
2b64318a57
Update all implementations of common_hal_busio_spi_read to honor write_value
...
(nrf, rp2040, and cxd56)
.. as well as a misleading comment that said that read always output
zeros.
Closes : #3447
2021-08-18 10:20:40 -05:00
gamblor21
d02a4b9f71
Removed ulab to make space in blackpill with flash board
2021-08-18 10:16:44 -05:00
Dan Halbert
5b0009cbc4
Merge pull request #5151 from dhalbert/usb_hid-changes
...
Support multiple reports per device in usb_hid
2021-08-17 17:14:28 -04:00
Scott Shawcroft
2d8346d23b
Merge pull request #5163 from dhalbert/fix-MICROPY_HW-definitions
...
correct some status LED pin defns per #5161
2021-08-17 12:41:00 -07:00
Scott Shawcroft
a5143d284b
Merge pull request #5161 from ZodiusInfuser/patch_micropy
...
Removed unnecessary defines from Pimoroni board files
2021-08-17 12:40:12 -07:00
Dan Halbert
a0c340f727
Update ports/esp32s2/boards/microdev_micro_s2/mpconfigboard.h
...
Co-authored-by: microDev <70126934+microDev1@users.noreply.github.com>
2021-08-17 11:26:43 -04:00
Dan Halbert
064e086570
correct some status LED pin defns per #5161
2021-08-17 09:33:34 -04:00
microDev
6c763762d4
restore sys.atexit() to prevent merge conflict
2021-08-17 10:13:01 +05:30
Jim Mussared
0c2cadf1c8
unix/Makefile: Disable error compression on arm-linux-gnueabi-gcc.
...
This compiler is unable to optimise out the giant strcmp match generated
by MP_MATCH_COMPRESSED.
See github.com/micropython/micropython/pull/7659#issuecomment-899479793
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-17 11:20:58 +10:00
Ryan A. Pavlik
a77e269121
cp_sapling_m0_revb: board.UART not board.uart
...
This is the only board that didn't match the all-uppercase convention for these UART (and more generally, these bus) entries.
2021-08-16 17:07:17 -05:00
Scott Shawcroft
abe8638f41
Merge pull request #5160 from ZodiusInfuser/patch_tiny2040
...
Removed default UART, SPI and I2C from Tiny2040 config
2021-08-16 14:54:52 -07:00
microDev
1c4a6c3667
atexit module refinements
...
- add test for atexit module
- add callback to gc collection
- fix callback memory allocation
- execute callback on both code and repl exit
2021-08-16 21:37:32 +05:30
ZodiusInfuser
2255ab1486
Removed unnecessary Micropy and Ignore defines
2021-08-16 16:40:12 +01:00
ZodiusInfuser
5fb507c3ff
Removed default UART SPI and I2C from Tiny2040 config
2021-08-16 16:31:31 +01:00
Damien George
e25c5cb8d2
esp32/machine_pin: Make check for non-output pins respect chip variant.
...
Fixes issue #7631 .
Signed-off-by: Damien George <damien@micropython.org>
2021-08-16 15:24:05 +10:00
Jonathan Hogg
5b655665ab
esp32/machine_hw_spi: Release GIL during transfers.
...
Release the GIL while waiting for SPI transfers to complete to allow other
threads to make progress.
Fixes #7662 .
2021-08-16 15:21:10 +10:00
Philipp Ebensberger
a1dc7277d9
mimxrt/machine_pin: Implement ioctl for Pin.
...
To make machine.Signal work correctly (among other things). The solution
is taken over from the rp2 port.
Signed-off-by: Philipp Ebensberger
2021-08-16 15:03:50 +10:00
Seth Kerr
201883dcc1
removed bread 2040 from commit
2021-08-15 14:02:43 -06:00
Seth Kerr
3b491ac0f3
ran pre-commit locally
2021-08-15 14:02:43 -06:00
Seth Kerr
2ebeeb5daf
add ODT PixelWing ESP32S2
2021-08-15 14:02:43 -06:00
codetyphon
fd8fe6f013
Update ports/esp32s2/boards/ai_thinker_esp_12k_nodemcu/mpconfigboard.h
...
Co-authored-by: Dan Halbert <halbert@halwitz.org>
2021-08-15 20:39:53 +08:00
codetyphon
7a48fc05b4
fix ai-tinker-esp-12k path
2021-08-15 13:29:42 +08:00
codetyphon
e29346b79a
ai_thinker_esp_12k_nodemcu
2021-08-15 10:18:40 +08:00
Dan Halbert
f37e1d7bf5
squeeze a couple of boards
2021-08-14 17:36:05 -04:00
codetyphon
8945d17aa2
Update mpconfigboard.mk
2021-08-14 23:32:40 +08:00
codetyphon
c577d3b6a4
add ai_thinker_esp_12k
2021-08-14 20:29:33 +08:00
codetyphon
221d66c603
Create board.c
2021-08-14 20:27:51 +08:00
Jim Mussared
1d9e489af3
extmod/modbluetooth: Add send_update arg to gatts_write.
...
This allows the write to trigger a notification or indication, but only to
subscribed clients. This is different to gatts_notify/gatts_indicate,
which will unconditionally notify/indicate.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-14 22:21:55 +10:00
Jim Mussared
5733c49174
stm32,esp32,rp2: Enable MICROPY_PY_FSTRINGS by default.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-14 16:58:40 +10:00
Jim Mussared
692d36d779
py: Implement partial PEP-498 (f-string) support.
...
This implements (most of) the PEP-498 spec for f-strings and is based on
https://github.com/micropython/micropython/pull/4998 by @klardotsh.
It is implemented in the lexer as a syntax translation to `str.format`:
f"{a}" --> "{}".format(a)
It also supports:
f"{a=}" --> "a={}".format(a)
This is done by extracting the arguments into a temporary vstr buffer,
then after the string has been tokenized, the lexer input queue is saved
and the contents of the temporary vstr buffer are injected into the lexer
instead.
There are four main limitations:
- raw f-strings (`fr` or `rf` prefixes) are not supported and will raise
`SyntaxError: raw f-strings are not supported`.
- literal concatenation of f-strings with adjacent strings will fail
"{}" f"{a}" --> "{}{}".format(a) (str.format will incorrectly use
the braces from the non-f-string)
f"{a}" f"{a}" --> "{}".format(a) "{}".format(a) (cannot concatenate)
- PEP-498 requires the full parser to understand the interpolated
argument, however because this entirely runs in the lexer it cannot
resolve nested braces in expressions like
f"{'}'}"
- The !r, !s, and !a conversions are not supported.
Includes tests and cpydiffs.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-14 16:58:40 +10:00
Scott Shawcroft
3ffab36cdc
Merge remote-tracking branch 'adafruit/main' into fix_samd_timer_leak
2021-08-13 15:20:25 -07:00
Dan Halbert
ffb9ecfeca
Merge pull request #5139 from tannewt/onewireio
...
Move OneWire to `onewireio`
2021-08-13 18:10:04 -04:00
Scott Shawcroft
d528386d4e
Merge pull request #5143 from tylercrumpton/add-crumps2
...
Add CrumpS2 ESP32-S2 board
2021-08-13 12:03:42 -07:00
Daniel Mizyrycki
8f45f5ee4f
nrf: Set .mpy features consistent with documentation and other ports.
...
This allows nrf devices to load .mpy files. And nrf52840 and nrf9160 based
boards also support compiling and loading native code.
2021-08-13 23:22:54 +10:00
Scott Shawcroft
de796e2304
Move OneWire to onewireio
from busio
...
This will allow finer grained inclusion in 8.0.0
Fixes #5135
2021-08-12 10:47:14 -07:00
Scott Shawcroft
d294692c4e
Merge pull request #5100 from tannewt/fix_cp_irremote
...
Switch SAMD21 ticks to PER event
2021-08-12 09:52:29 -07:00
Dan Halbert
6c1dbea8b0
Merge pull request #5129 from skieast/add-morphesp240
...
Add morphesp240
2021-08-12 12:27:51 -04:00
Scott Shawcroft
9c77d2653f
Merge pull request #5099 from ZodiusInfuser/main
...
Added definitions for some upcoming Pimoroni LED driver boards
2021-08-12 09:27:21 -07:00
ZodiusInfuser
47c8ff0570
Removed unnecessary defines
2021-08-11 23:34:20 +01:00
Scott Shawcroft
fb6b438580
Make getpass
and traceback
full build only
...
This leaves much more space on SAMD21 builds that aren't "full builds".
These are new APIs that we don't need to add to old boards.
Also, tweak two Arduino boards to save space on them.
2021-08-11 14:47:35 -07:00
Scott Shawcroft
0c1d6cef75
Merge remote-tracking branch 'adafruit/main' into fix_cp_irremote
2021-08-11 13:43:59 -07:00
Bruce Segal
f35afa8239
Formatting and build.yml
2021-08-11 13:43:08 -07:00
Bruce Segal
4be64cd8a9
Initial MorphESP-240 support
2021-08-11 13:11:17 -07:00
Scott Shawcroft
0632a1e681
Merge pull request #5060 from cdwilson/cdwilson/circuitpython/sparkfun-stm32f405-micromod
...
stm/boards: Add support for SparkFun STM32 MicroMod Processor board.
2021-08-11 12:19:16 -07:00
Scott Shawcroft
7f016ae11e
Fix build with filter to do OR
2021-08-11 12:10:51 -07:00
Scott Shawcroft
083960ce90
Fix SAMD51 builds and Prox Trinkey
...
Adds CIRCUITPY_BUSIO_UART to disable UART by raising ValueError
that no pins work.
2021-08-11 11:53:26 -07:00
Scott Shawcroft
ebf0901558
Merge pull request #5079 from dhalbert/debug-audio
...
Fix various RP2040 and SAMD audio issues
2021-08-11 11:19:53 -07:00
Scott Shawcroft
b56455ffbb
Allow sleep while paused
2021-08-11 10:48:39 -07:00
Scott Shawcroft
67c6932ca2
Reset timers separate from pwmio
...
This prevents timer leakage on builds without pwmio.
Fixes #5057
2021-08-11 09:58:31 -07:00
Dan Halbert
4608877c12
address review comments
2021-08-11 12:10:49 -04:00
Dan Halbert
35aac3d26b
display SPI now 10MHz; set PWM duty cycle to zero at stop to quiet output
2021-08-11 10:48:53 -04:00
Dan Halbert
24e61a7da8
Track more carefully which audio buffers to fill, based on interrupt channels
2021-08-10 22:00:09 -04:00
Jeff Epler
1e53cf40ad
Merge pull request #5114 from jpconstantineau/board-bluemicro840
...
Add Board bluemicro840
2021-08-10 19:17:05 -05:00
Scott Shawcroft
f0859ac954
Switch SAMD21 ticks to PER event
...
The EVSYS is used to generate an interrupt from the event. This
simplifies timing used in pulseio that conflicted with the
auto-reload countdown.
Fixes #3890
2021-08-10 15:23:45 -07:00
Ned Konz
42d1a1635c
stm32/mbedtls: Fix compile warning about uninitialized val.
2021-08-10 23:43:25 +10:00
Ned Konz
a0cd18c1a5
stm32/boards/NUCLEO_H743ZI2: Add modified version of NUCLEO_H743ZI.
...
This commit creates a new stm32 board for the NUCLEO_H743ZI2, which is the
current version of this from ST. This is a modified copy of the
NUCLEO_H743ZI board, and the ZI2 board differs in a few minor ways:
- LED2 has moved from PB7 to PE1 and is now yellow rather than blue
- the USB power enable has moved from PG6 to PG10
- the USER button is now pulled down
2021-08-10 23:38:05 +10:00
ZodiusInfuser
e587bd7dc0
Added final USB PIDs
2021-08-10 11:17:06 +01:00
Chris Wilson
c0902dade6
stm/boards: Add support for SparkFun STM32 MicroMod Processor board.
2021-08-09 23:11:13 -07:00
Chris Wilson
e741330ca8
Consistent pin naming for SparkFun MicroMod processor boards.
2021-08-09 23:10:52 -07:00
iabdalkader
23531bca74
rp2/CMakeLists.txt: Allow a board's cmake to set the manifest path.
...
This allows boards to add frozen modules, or bypass the port manifest
entirely.
2021-08-10 11:05:33 +10:00
Pierre Constantineau
aec965e6d9
changed PID as suggested by Scott
2021-08-09 15:25:06 -06:00
microDev
93c9d59960
Merge branch 'main' into getpass
2021-08-10 01:00:10 +05:30
microDev
052c53efc3
Merge pull request #5116 from eddieespinal/atmegazero_esp32s2
...
Fixes the MOSI and MISO pins mapping
2021-08-09 22:45:41 +05:30
Eddie Espinal
6764af182a
Fixes the MOSI and MISO pins. By mistake I added them backward in this mapping
2021-08-09 11:31:20 -04:00
Damien George
3835f5f597
esp32/makeimg.py: Get bootloader and partition offset from sdkconfig.
...
So that it works on ESP32C3, which has the bootloader at 0x0.
Fixes issue #7565 .
Signed-off-by: Damien George <damien@micropython.org>
2021-08-10 00:19:49 +10:00
Dan Halbert
2451c788f4
valid channels in audio_dma_stop; cleaner supervisor_ticks mgmt in keypad
2021-08-09 09:47:13 -04:00
Dan Halbert
59b89fdc5c
Fix various audio DMA issues:
...
RP2040 and SAMD51:
- Detect when DMA has finished, and stop DMA audio explicitly.
- Do not accidentally reuse `first_buffer` supplied by WaveFile or RawSample. Always realloc `first_buffer` and `second_buffer`
RP2040:
- When audio playing is stopped, write a final zero to the output register. This prevents residual PWM tones.
- Handle buffer size for 8-bit samples properly for 16-bit output.
- Fail on some edge cases (which may not be possible at the moment).
2021-08-09 09:47:13 -04:00
Dan Halbert
2cd80d1074
wip, with debugging printf's
2021-08-09 09:47:13 -04:00
Dan Halbert
fd71d924d2
partial buffer mgmt fix
2021-08-09 09:47:13 -04:00
microDev
51f8603783
add getpass module
2021-08-09 17:50:28 +05:30
Daniel Mizyrycki
8645b7c23b
nrf: Enable source line on tracebacks.
2021-08-09 15:09:33 +10:00
Glenn Ruben Bakke
77b4cfcbc9
nrf/modules/nrf: Add function to enable/disable DCDC.
...
This function can be used to enable and disable the DC/DC converter with or
without the Bluetooth stack enabled. It can also be used to query the
current state of the DC/DC.
This commit also adds a definition of ARRAY_SIZE needed by nrfx HAL-layer.
2021-08-09 14:55:59 +10:00
Pierre
7d02fd42f8
removed trailing spaces at end of pins.c
2021-08-08 21:56:24 -06:00
Pierre
1a7cad6562
removed trailing spaces in pins.c
2021-08-08 21:43:03 -06:00
Pierre
b1d5b50551
fromatting updates to pins.c
2021-08-08 21:38:23 -06:00
Nathan Young
579194a543
Colocated board.LED and D13 together (GCM4)
2021-08-09 05:35:38 +02:00
Pierre
9de8045dca
foromatting updates to pins.c
2021-08-08 21:31:07 -06:00
Pierre
45d4058981
adding initial files for BlueMicro840 Board
2021-08-08 21:25:54 -06:00
Nathan Young
a15ac65fa0
Add board.LED for Grand Central M4 Express
...
Fixes #5111
2021-08-08 21:43:12 +02:00
Damien George
e5e0553224
nrf/modules/uos: Add ilistdir to uos module.
...
This was missed in the initial implementation of the uos module.
Signed-off-by: Damien George <damien@micropython.org>
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
55d4321c3e
nrf/boards: Enable MICROPY_VFS_LFS2 for all target boards.
...
Enable LittleFS v2 for all targets, except nrf51 targets when SoftDevice is
present.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
23e8729d3e
nrf/mphalport: Add dummy function for mp_hal_time_ns().
...
extmod/vfs_lfs.c needs to resolve `mp_hal_time_ns()` in order to calculate
a timestamp from 1970 epoch. A wall clock is not available in the nrf
port, hence the function is implemented to resolve compilation linkage
error. The function always return 0.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
aa857eb65e
nrf/Makefile: Set default manifest file for all targets.
...
Set the default manifest to "modules/manifest.py". This includes files
from the folder "modules/scripts". The manifest default value is overriden
by all nrf51 boards that have SoftDevice present (SD=s110) to save flash.
Also add "modules/manifest.py" which is set to freeze
"modules/scripts/_mkfs.py".
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
7b6ad0ce2e
nrf/modules/scripts: Add file system formatting script.
...
Add a helper script _mkfs.py which automatically formats the file system if
nrf.Flash() is located and a VFS file system has been included in the
compilation.
The precedence is: first LFS1, LFS2 then FAT.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
ffc636de2f
nrf/boards: Set FROZEN_MANIFEST blank when SD present on nrf51 targets.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
990341d18e
nrf: Facilitate use of freeze manifest.
...
Update the Makefile to handle FROZEN_MANIFEST, and the README with some
small samples on how to use freeze manifests. And add BOARD_DIR to the
Makefile which can be referenced in boards/<board>/mpconfigboard.mk to
include a board specific manifest.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
4326e08802
nrf/boards: Enable needed features for FAT/LFS1/LFS2.
...
Enable the following features for all boards except
nrf51 boards with SoftDevice present:
- MICROPY_VFS
- MICROPY_PY_NRF
- MICROPY_HW_ENABLE_INTERNAL_FLASH_STORAGE
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
b0fd4372c4
nrf/main: Add auto mount and auto format hook for internal flash FS.
2021-08-08 23:17:55 +10:00
Glenn Ruben Bakke
6ff3a2afef
nrf/qstrdefsport.h: Add entries for in-built FS mount points.
2021-08-08 23:17:49 +10:00
Glenn Ruben Bakke
f99aa82e85
nrf/mpconfigport.h: Enable MICROPY_PY_IO_FILEIO when an FS is enabled.
...
Enable MICROPY_PY_IO_FILEIO if MICROPY_VFS_FAT, MICROPY_VFS_LFS1
or MICROPY_VFS2 has been enabled.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
7a833edf37
nrf/modules/uos: Allow a board to configure MICROPY_VFS_FAT/LFS1/LFS2.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
0bde907a8b
nrf/Makefile: Add _fs_size linker script override from make.
...
Add posibility to override linker script "_fs_size" from make by adding the
FS_SIZE parameter. The syntax of value is linker script syntax. For
example, the value of 131072 bytes can be written as 128K like this:
FS_SIZE=128K.
If not set, default value for "_fs_size" from linker script will be used.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
c9b72ba694
nrf/mpconfigport.h: Tune FAT FS configuration.
...
Disable MICROPY_FATFS_MULTI_PARTITION configuration because there is no
partition table in the flash for FATFS to read.
Also, set MICROPY_FATFS_MAX_SS to the size of a flash page. For nrf51 the
value 1024 is set. For nrf52/nrf91 the value 4096 is set.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
b40dfa961d
nrf/README: Update README.md to reflect internal file systems.
...
This documents parameters that can be passed to make to enable a specific
file system to included in the build. Also, document the Makefile override
parameter "FS_SIZE" that can be used to tune the size of the flash region
to use as internal flash file system.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
85cad50266
nrf/mpconfigport.h: Expose nrf module when MICROPY_PY_NRF is set.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
5a873e27eb
nrf/drivers: Add support for using flash block device with SoftDevice.
...
Update flash.c to also be compiled in when
MICROPY_HW_ENABLE_INTERNAL_FLASH_STORAGE is enabled and SoftDevice is
present.
Update bluetooth/ble_drv.c to forward flash events to flash.c when
MICROPY_HW_ENABLE_INTERNAL_FLASH_STORAGE is enabled.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
127cec8cae
nrf/modules/nrf: Add new nrf module with flash block device.
...
This commit adds the "nrf" module for port specific modules and objects.
Included in it is the "Flash" object which exposes a block device
implementation to access internal SoC flash.
Thanks to @aykevl aka Ayke van Laethem for the initial implementation.
2021-08-08 23:09:26 +10:00
Glenn Ruben Bakke
3b594f7b27
nrf/boards/common.ld: Calculate unused flash region.
...
Calculate the unused flash area on the target device. The values will be
exposed by _unused_flash_start and _unused_flash_length. The start address
and the length are not aligned to either word or pages.
2021-08-08 23:09:26 +10:00
Damien George
f834fef6bb
stm32/powerctrl: Support changing frequency on WB MCUs.
...
This allows changing the frequency to: 100kHz, 200kHz, 400kHz, 800kHz,
1MHz, 2MHz, 4MHz, 8MHz, 16MHz, 32MHz, 64MHz. For frequencies 2MHz and
below, low power run (LPR) mode is enabled automatically.
Signed-off-by: Damien George <damien@micropython.org>
2021-08-07 23:41:20 +10:00
Damien George
3b32b3d1b3
stm32/usbd_cdc_interface: Rename USBD_CDC_xx opts to MICROPY_HW_USB_xx.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-08-07 23:13:58 +10:00
Damien George
f28e8b9073
stm32/usbd_desc: Rename USBD_xxx descriptor opts to MICROPY_HW_USB_xxx.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-08-07 23:13:58 +10:00
Damien George
96c6b8cae3
ports: Rename USBD_VID/PID config macros to MICROPY_HW_USB_VID/PID.
...
For consistency with other board-level config macros that begin with
MICROPY_HW_USB.
Also allow boards in the mimxrt, nrf and samd ports to configure these
values.
Signed-off-by: Damien George <damien@micropython.org>
2021-08-07 23:13:55 +10:00
microDev
063e3946d6
Merge pull request #5094 from jepler/quirc
...
Add qrio: Decode QR codes with quirc lib
2021-08-07 09:30:20 +05:30
Damien George
8616129f2e
esp8266,esp32: Include hidden networks in WLAN.scan results.
...
Addresses issues #2697 and #5329 .
Signed-off-by: Damien George <damien@micropython.org>
2021-08-07 13:28:34 +10:00
Jim Mussared
bfc8e88ce1
esp32/mpconfigport.h: Enable reverse and inplace special methods.
...
Reverse operations are supported on stm32 and rp2, and esp32 has enough
space to also enable inplace operations, to make it complete.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-08-07 13:27:09 +10:00
Patrick Van Oosterwijck
028fc815cd
esp32/boards: Add Silicognition wESP32 board configuration.
...
For rev 7+ boards with 16MB of flash. Partition table allocates 2.4 MiB
for MicroPython, 11 MiB for the filesystem.
2021-08-07 12:50:13 +10:00
Scott Shawcroft
be2342f32f
Merge pull request #5072 from microDev1/traceback
...
Add traceback module
2021-08-06 12:10:17 -07:00
Scott Shawcroft
93aa4e9e47
Merge pull request #5102 from evildave666/blackpill-add-mfg-name
...
Add WeAct manufacturer for STM32F411 blackpill boards
2021-08-06 11:59:24 -07:00
evildave666
4d14bcf2a2
Add WeAct manufacturer for black pill boards
2021-08-06 16:06:16 +09:00
Scott Shawcroft
00b617c9c4
Merge pull request #5097 from anecdata/cucumber
...
Add Gravitech Cucumber M, MS, R, and RS boards
2021-08-05 11:49:51 -07:00
Jeff Epler
f0e489f51f
Merge pull request #5098 from bd34n/bdmicro_vina_d51_flash_chip
...
board bdmicro_vina_d51: Add support for MX25L12833F flash chip.
2021-08-05 13:48:29 -05:00
Scott Shawcroft
e3fa6e2c35
Merge pull request #5089 from tannewt/disable_ble_workflow
...
Add ability to disable BLE workflow
2021-08-05 11:21:17 -07:00
Jeff Epler
2e8eb43dcc
Use new quirc define for small stacks
...
.. and revert stack enlargement of esp32-s2
2021-08-05 12:52:43 -05:00
Jeff Epler
f9393c9e51
enable qrio in unix coverage build, and add a test
2021-08-05 12:24:07 -05:00
ZodiusInfuser
f707fa107a
Tweaks to Interstate75 pinout
2021-08-05 15:00:47 +01:00
Brian Dean
821f3d5532
board bdmicro_vina_d51: Add support for MX25L12833F flash chip. Add QSPI activity indicator LED. Add D15-D19 as aliases for the I2S peripheral pins.
2021-08-05 09:14:51 -04:00