Since the new keypad module is taking over gamepad functionality,
I'm switching to it. If this works well, I will make the change
for the remaining boards.
nRF CircuitPython boards will now provide the file transfer
service defined here: https://github.com/adafruit/Adafruit_CircuitPython_BLE_File_Transfer
USB capable boards will only advertise if previously bonded to a
device or if the reset button is pressed during the fast blue
flashes on start up. When pressed, the board will restart again but
the blue period will not flash.
Boards without USB will always advertise.
When previously bonded, the advertisement is private so that no
other peers can connect. If advertising publicly, the tx power is
lowered to reduce the likelihood of bonding from a distance.
This PR also fixes issues with loading identities of bonded peers
so that our address can now be resolved and we can resolve others'
addresses when scanning.
Commit 0abf6f830c removed _boot.py from the
manifest for the GENERIC_512K board because the build does not include a
filesystem. But the main code expects _boot.py to be there and prints an
error if it's not. So add a custom _boot.py, which just sets the
gc.threshold().
Signed-off-by: Damien George <damien@micropython.org>
This adds a wlan.config(reconnects=N) option to set the number of reconnect
attempts that will be made if the WLAN connection goes down. The default
is N=-1 (infinite retries, current behavior). Setting
wlan.config(reconnects=0) will disable the reconnect attempts.
A nice side effect of reconnects=0 is that wlan.status() will report the
disconnect reason now. See related issue #5326.
Ethernet-PHYs from ESP-IDF (LAN8720, IP101, RTL8201, DP83848) are now
supported in IDF v4.1 and above. PHY_KSZ8041 is only for ESP-IDF 4.3 and
above. ESP32S2 is not supported.
Signed-off-by: Tobias Eydam <eydam-prototyping@outlook.com>
The implementation uses the LPUARTx devices. Up to 8 UARTs can be used,
given that the pins are accessible. E.g. 8 on Teensy 4.1, 5 on
MIMXRT1020_EVK.
For Tennsy 4.0 and 4.1 the UART numbers are as printed on the pinout 1..N.
The MIMXRT10xx-EVK boards have only one UART named, which gets the number
1. All other UART are assigned to different Pins:
MIMXRT1010-EVK:
D0/D1 UART 1
D6/D7 UART 2
A0/D4 UART 3
MIMXRT1020-EVK:
D0/D1 UART 1
D6/D9 UART 2
D10/D12 UART 3
D14/D15 UART 4
A0/A1 UART 5
MIMXRT1050-EVK, MIMXRT1060-EVK, MIMXRT1064-EVK:
D0/D1 UART 1
D7/D6 UART 2
D8/D9 UART 3
A1/A0 UART 4
This fixes error: cast to smaller integer type 'int' from 'pthread_t'.
pthread_t is defined as long, not as int.
Signed-off-by: Pavol Rusnak <pavol@rusnak.io>
The rtc_set_datetime() from pico-sdk will validate the values in the
datetime_t structure and refuse to set the time if they aren't valid. It
makes sense to raise an exception if this happens instead of failing
silently which might be confusing (as an example, see:
https://github.com/micropython/micropython/pull/6928#issuecomment-860166044
).
The supplied value for microseconds in datetime() will be treated as a
starting value for the reported microseconds. Due to internal processing
in setting the time, there is an offset about 1 ms.
This change moves the datetime tuple format back to the one used by all the
other ports:
(year, month, day, weekday, hour, minute, second, microsecond)
Weekday is a number between 0 and 6, with 0 assigned to Monday. It has to
be provided when setting the RTC with datetime(), but will be ignored on
entry and calculated when needed.
The weekday() method was removed, since that is now again a part of the
datetime tuple.
The now() method was updated so it continues to return a tuple that matches
CPython's datetime module.
Initial support for machine.RTC on rp2 port. It only supports datetime()
method and nothing else. The method gets/returns a tuple of 8 items, just
like esp32 port, for example, but the usec parameter is ignored as the RP2
RTC only works up to seconds precision.
The Pico RTC isn't very useful as the time is lost during reset and there
seems to be no way to easily power up just the RTC clock with a low current
voltage, but still there seems to be use-cases for that, see issues #6831,
and a Thonny issue #1592. It was also requested for inclusion on v1.15
roadmap on #6832.
Signed-off-by: Krzysztof Adamski <k@japko.eu>
Changes introduced are:
- the application offset is now loaded from the partition table instead of
being hard-coded to 0x10000
- maximum size of all sections is computed using the partition table
- an error is generated if any section overflows its allocated space
- remaining bytes are printed for each section
Signed-off-by: Damien George <damien@micropython.org>
`idf.py monitor` connects to the debug UART and shows the messages. In
contrast to a traditional terminal program, it also has the limited
ability to transform hex addresses into file & line number information,
especially for debug builds.
This requires the elf file be copied to a specific place.