Machines › Computers › PJRC › Teensy 4.0
Teensy 4.0
2019
PJRC's 2019 microcontroller board, built around the NXP i.MX RT1062: a 600MHz ARM Cortex-M7 with a single-precision FPU, tightly-coupled instruction and data memories, and code running from external FlexSPI flash. On board are a single user LED on pin 13 and a USB and UART serial console. There is no display or on-board audio on the bare board.
Teensy 4.0 Online Emulator
Play Teensy 4.0 using JavaScript directly in your browser.
Controls
Runs real compiled PJRC Teensy 4.0 firmware on an in-browser NXP i.MX RT1062 (ARM Cortex-M7, 600 MHz, FPv5-SP FPU). The default is "Blink pin 13": a bare-metal C program that gates the GPIO clock in CCM, routes the pin-13 pad to the fast GPIO7 port, configures it as an output and blinks the on-board LED (pin 13 = GPIO7 bit 3, active-high). "Timer Blink (GPT1)" blinks the same LED but times it with the GPT1 general-purpose timer instead of a busy loop — it starts GPT1 and polls the output-compare flag (SR.OF1). "Serial Hello" brings up LPUART6 (Teensy Serial1, TX on pin 1) and prints a greeting to the serial console while blinking the LED each line; "Serial Counter" prints an incrementing counter over LPUART6. All four are original CC0 programs compiled with clang for thumbv7em (Cortex-M7). Open the debugger, or add ?debug, to single-STEP real Thumb-2 instructions from FlexSPI flash at 0x60000000, set PC breakpoints and write watchpoints, and read the ARM registers (r0-r15, xPSR, N/Z/C/V and the FPv5 file s0-s31) and the real i.MX RT1062 memory map live (ITCM 0x00000000, DTCM 0x20000000, OCRAM 0x20200000, FLASH 0x60000000, peripherals). The bare Teensy 4.0 has no user input wired to the firmware and no on-board speaker, so it is honestly silent with no input pad.
Runs real compiled PJRC Teensy 4.0 firmware on an in-browser NXP i.MX RT1062 (ARM Cortex-M7, 600 MHz, FPv5-SP FPU). The default is "Blink pin 13": a bare-metal C program that gates the GPIO clock in CCM, routes the pin-13 pad to the fast GPIO7 port, configures it as an output and blinks the on-board LED (pin 13 = GPIO7 bit 3, active-high). "Timer Blink (GPT1)" blinks the same LED but times it with the GPT1 general-purpose timer instead of a busy loop — it starts GPT1 and polls the output-compare flag (SR.OF1). "Serial Hello" brings up LPUART6 (Teensy Serial1, TX on pin 1) and prints a greeting to the serial console while blinking the LED each line; "Serial Counter" prints an incrementing counter over LPUART6. All four are original CC0 programs compiled with clang for thumbv7em (Cortex-M7). Open the debugger, or add ?debug, to single-STEP real Thumb-2 instructions from FlexSPI flash at 0x60000000, set PC breakpoints and write watchpoints, and read the ARM registers (r0-r15, xPSR, N/Z/C/V and the FPv5 file s0-s31) and the real i.MX RT1062 memory map live (ITCM 0x00000000, DTCM 0x20000000, OCRAM 0x20200000, FLASH 0x60000000, peripherals). The bare Teensy 4.0 has no user input wired to the firmware and no on-board speaker, so it is honestly silent with no input pad.
Runs real compiled PJRC Teensy 4.0 firmware on an in-browser NXP i.MX RT1062 (ARM Cortex-M7, 600 MHz, FPv5-SP FPU). The default is "Blink pin 13": a bare-metal C program that gates the GPIO clock in CCM, routes the pin-13 pad to the fast GPIO7 port, configures it as an output and blinks the on-board LED (pin 13 = GPIO7 bit 3, active-high). "Timer Blink (GPT1)" blinks the same LED but times it with the GPT1 general-purpose timer instead of a busy loop — it starts GPT1 and polls the output-compare flag (SR.OF1). "Serial Hello" brings up LPUART6 (Teensy Serial1, TX on pin 1) and prints a greeting to the serial console while blinking the LED each line; "Serial Counter" prints an incrementing counter over LPUART6. All four are original CC0 programs compiled with clang for thumbv7em (Cortex-M7). Open the debugger, or add ?debug, to single-STEP real Thumb-2 instructions from FlexSPI flash at 0x60000000, set PC breakpoints and write watchpoints, and read the ARM registers (r0-r15, xPSR, N/Z/C/V and the FPv5 file s0-s31) and the real i.MX RT1062 memory map live (ITCM 0x00000000, DTCM 0x20000000, OCRAM 0x20200000, FLASH 0x60000000, peripherals). The bare Teensy 4.0 has no user input wired to the firmware and no on-board speaker, so it is honestly silent with no input pad.
Runs real compiled PJRC Teensy 4.0 firmware on an in-browser NXP i.MX RT1062 (ARM Cortex-M7, 600 MHz, FPv5-SP FPU). The default is "Blink pin 13": a bare-metal C program that gates the GPIO clock in CCM, routes the pin-13 pad to the fast GPIO7 port, configures it as an output and blinks the on-board LED (pin 13 = GPIO7 bit 3, active-high). "Timer Blink (GPT1)" blinks the same LED but times it with the GPT1 general-purpose timer instead of a busy loop — it starts GPT1 and polls the output-compare flag (SR.OF1). "Serial Hello" brings up LPUART6 (Teensy Serial1, TX on pin 1) and prints a greeting to the serial console while blinking the LED each line; "Serial Counter" prints an incrementing counter over LPUART6. All four are original CC0 programs compiled with clang for thumbv7em (Cortex-M7). Open the debugger, or add ?debug, to single-STEP real Thumb-2 instructions from FlexSPI flash at 0x60000000, set PC breakpoints and write watchpoints, and read the ARM registers (r0-r15, xPSR, N/Z/C/V and the FPv5 file s0-s31) and the real i.MX RT1062 memory map live (ITCM 0x00000000, DTCM 0x20000000, OCRAM 0x20200000, FLASH 0x60000000, peripherals). The bare Teensy 4.0 has no user input wired to the firmware and no on-board speaker, so it is honestly silent with no input pad.
Configurations
| Configuration | Emulator | Machine | OS | Legal | |
|---|---|---|---|---|---|
| Blink pin 13 (on-board LED) | Teensy 4.0 | Teensy 4.0 | open | Open ⛶ | |
| Timer Blink (GPT1) | Teensy 4.0 | Teensy 4.0 | open | Open ⛶ | |
| Serial Hello | Teensy 4.0 | Teensy 4.0 | open | Open ⛶ | |
| Serial Counter | Teensy 4.0 | Teensy 4.0 | open | Open ⛶ |
Downloads — ROMs & software
| Title | Type | Size (bytes) | Legal | |
|---|---|---|---|---|
| Blink pin 13 (on-board LED) | demo | 0 | open | Download ↓ |
| Serial Counter | demo | 0 | open | Download ↓ |
| Timer Blink (GPT1) | demo | 0 | open | Download ↓ |
| Serial Hello | demo | 0 | open | Download ↓ |
Downloads — ROMs & software
| Title | Type | Size (bytes) | Legal | |
|---|---|---|---|---|
| Blink pin 13 (on-board LED) | demo | 0 | open | Download ↓ |
| Serial Counter | demo | 0 | open | Download ↓ |
| Timer Blink (GPT1) | demo | 0 | open | Download ↓ |
| Serial Hello | demo | 0 | open | Download ↓ |
Chips
Emulators
| Emulator | Type | License | Site |
|---|---|---|---|
| Teensy 4.0 | online | CC0 firmware · MIT core | Website ↗ |