Wykres commitów

6 Commity (7408ca1d7857df5ea348da35c9ee12f70a024478)

Autor SHA1 Wiadomość Data
Damien George 7408ca1d78 mimxrt: Improve ticks and sleep functions using GPT.
SysTick cannot wake the CPU from WFI/WFE so a hardware timer is needed to
keep track of ticks/delay (similar to the nrf port).

Fixes issue #7234.

Signed-off-by: Damien George <damien@micropython.org>
2021-05-18 22:36:32 +10:00
Damien George f31c6b4840 mimxrt: Fix USB CDC handling so it works reliably.
On i.MX the SysTick IRQ cannot wake the CPU from a WFI so the CPU was
blocked on WFI waiting for USB data in mp_hal_stdin_rx_chr() even though it
had already arrived (because it may arrive just after calling the check
tud_cdc_available()).  This commit fixes this problem by using SEV/WFE to
indicate that there has been a USB event.

The mp_hal_stdout_tx_strn() function is also fixed so that it doesn't
overflow the USB buffers.

Signed-off-by: Damien George <damien@micropython.org>
2021-02-12 13:48:51 +11:00
Damien George 035d16126a ports: Update to build with new tinyusb.
Signed-off-by: Damien George <damien@micropython.org>
2021-02-12 12:50:36 +11:00
Philipp Ebensberger 02cc4462b7 mimxrt: Add initial impl of machine.LED class, and basic pin support.
This commit implements an LED class with rudimentary parts of a pin C API
to support it.  The LED class does not yet support setting an intensity.

This LED class is put in the machine module for the time being, until a
better place is found.

One LED is supported on TEENSY40 and MIMXRT1010_EVK boards.
2020-06-05 11:47:48 +10:00
stijn 84fa3312cf all: Format code to add space after C++-style comment start.
Note: the uncrustify configuration is explicitly set to 'add' instead of
'force' in order not to alter the comments which use extra spaces after //
as a means of indenting text for clarity.
2020-04-23 11:24:25 +10:00
Jim Mussared f46782dde9 mimxrt: Add new, minimal port to NXP i.MX RT series CPUs.
This is an extremely minimal port to the NXP i.MX RT, in the style of the
SAMD port  It's largely based on the TinyUSB mimxrt implementation, using
the NXP SDK.  It currently supports the Teensy 4.0 board with a REPL over
the USB-VCP interface.

This commit also adds the NXP SDK submodule (also from TinyUSB) to
lib/nxp_driver.

Note: if you already have the tinyusb submodule initialized recursively you
will need to run the following as the tinyusb sub-submodules have been
rearranged (upstream):

    git submodule deinit lib/tinyusb
    rm -rf .git/modules/lib/tinyusb
    git submodule update --init lib/tinyusb
2020-03-11 15:34:13 +11:00