Add new API for specifying the idle level and TX carrier output level, and
new write_pulses modes of operation. Also fix wait_done documentation
which was inverted and wrong about timing.
This change allows specification of the idle level and TX carrier output
level (through changed initialisation API), and more flexible specification
of pulses for write_pulses.
This is a breaking change for the esp32.RMT constructor API. Previous code
of this form:
esp32.RMT(..., carrier_duty_percent=D, carrier_freq=F)
will now raise an exception and should be changed to:
esp32.RMT(..., tx_carrier=(F, D, 1))
The firmware for Teensy 4.0, Teensy 4.1 and MIMXRT1020_EVK are created.
Users of other MIMXRT10xx_EVK boards should be able to build the firmware
themselves, they might need specific DEBUG settings.
The Makefile had to be changed in order to build the .bin file as well.
This adds a call to mp_deinit() in the main function of the STM32 port.
This enables the use of MICROPY_PORT_DEINIT_FUNC on that port, as well as
cleaning up the GIL if threading is enabled.
Previous behaviour was: if boot.py had an exception then main.py would
still run, which is arguably unexpected behaviour.
This commit changes the behaviour so main.py is not run if boot.py has an
error.
Signed-off-by: Damien George <damien@micropython.org>
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.
I noticed the build printed things like
```
Font missing 3 characters
```
.. this is why.
We can't make it an error, because Japanese has hundreds of characters
not in the font.
INCOMPATIBLE CHANGE: struct_time(1,2,3,4,5,6,7,8,9) is now _rejected_
just as on standad Python.
This incorrect constructor was added by me in #2327; I assumed
without even checking that the `struct_time` constructor was also
compatible with the `namedtuple` constructor, but it is not and has
always been rejected by standard Python (checked 2.7 and 3.9)
This commit restores the specific error message that we used for this
purpose, which was removed in the previous commit either out of laziness
or out of trying to reduce unneeded error strings. In this case, the
alternate string is too misleading (it refers to arguments, not to
sequence elements) so let's put the better message back.
As discussed in #3410, this is a micropython-compatible (though
differently named) function that allows creation of useful time
and deadline functions in pure python.