Close

SIMPL - Implemented on a high performance Teensy 4.0

A project log for SIMPL

Serial Interpreted Minimal Programming Language for exploring microcontrollers & new cpu architectures

monsonitemonsonite 03/28/2021 at 23:160 Comments

SIMPL implemented on the Teensy 4.0

The Teensy 4.0 is a small and very fast ARM Cortex M7 based microcontroller development board in a compact breadboard friendly package of 24 pins on an 0.6" pitch.

Like any other Arduino IDE compatible microcontroller it can be programmed with SIMPL using just the Arduino IDE.

Compared to the ATmega328, which was used on the Duemillenove and the UNO, Teensy 4.0 is about 300 times faster.

It can do 32-bit math, it has a dual execution unit which almost doubles the rate of executing instructions and it has a large RAM.

All of these things make it and ideal and simple to use development board for "Breadboarding in Code"

SIMPL is written in about 300 lines of standard Arduino C++.

It implements a number of useful commands and it can be extended using the : and ; colon definition.

The 600MHz clock used on the Teensy 4 allows very rapid code execution.

An empty loop can execute in 18.334nS.  This means that if you have time to kill, you can do 54.5 million empty loops per second. The loop is performed in 11 cycles of the 600MHz oscillator.

Even though SIMPL is written in C++, the high speed of the Teensy 4 means that a lot of processing can be done - very quickly.

If you want to toggle a port pin using h and l - the Teensy 4 will allow a 7.5MHz toggle frequency. With direct writing to the I/O registers, instead of using the Arduino digitalWrite function, this frequency could be increased many times over.

Discussions