A tiny high-level language (HLL) runtime for embedded computing with the power of C and the extensibility of Forth or LISP.


Pleased to announce the successful completion of a tiny high-level computing language for high-speed, low-power, embedded computing on bare silicon (no BIOS, no OS). In terms of size, cost, and carbon footprint, the kernel clocks in at 730 bytes which includes a fully extensible runtime kernel providing DSL (domain specific language) capability for application specific computing.

What has been achieved:

  1. 372 byte machine coded kernel (yes, this is bytes, not KB, MB or GB). This is small enough to fit into the smallest ROMs, while still leaving plenty of space for application RAM.1
  2. A further 358 bytes comprise bootstrapped runtime instructions written in the language itself, and data organized in jump-tables for efficient threaded execution.
  3. 40 kernel level instructions provide the full expressibility of C for application code.
  4. Compressed application code runs through a threaded design providing high speed code execution (as fast or faster than C) using native code.
  5. The core kernel provides a codestream reader that provides Domain specific language (DSL) capability to allow first class language expansion with the full capability of a Forth or a Lisp. This means expanded instructions have the same first-class attributes as the core kernel instructions.
  6. Language is based on a simple stack-based virtual machine universal architecture onto which any chip can be mapped. Proof of concept designs with Arduino (Atmel 328), ATTiny85, and x86 chips.
  7. Portability between chips is achieved through a light-weight mapping layer to the 40 kernel instructions without requiring any other layer. A single afternoon mapping the 40 kernel instructions between chips and adapting the kernel code is all that is required to port to a new chip.
  8. Lightweight development stack (open source) with compiler/assembler/debugger for cross-compilation.
  9. User/Programmer interface is via live serial link, via keyboard/screen, or via binary ROM/RAM load.

More details to follow.

  1. To put the small size into context, a block of code used to be 4096 bytes (4K), or about 6 pages of binary when viewed on an 80×40 screen in standard 16 bytes per row format. This about 20% of the size of a block, and is viewable in binary in just over 1 page (45 lines).

TinyPhoto: Embedded Graphics and Low-Fat Computing

TinyPhoto is a small rotating photobook embedded graphics project that uses the low-power ATtiny85 microcontroller (3mA) and a 128×64 pixel OLED display (c.5-10mA typical, 15mA max). This combination can deliver at least 20 hrs of continuous play on a 3V coin cell battery (225mAh capacity). TinyPhoto can be readily built from a handful of through-hole electronic components (12 parts, £5) organized to fit onto a 3cm x 7cm single-sided prototype PCB. The embedded software is c.150 lines of C code and uses less than 1,300 bytes of on-chip memory. TinyPhoto rotates through five user-selectable images using a total of 4,900 bytes (yes, bytes!) stored in the on-chip flash RAM. The setup produces crisp photos on the OLED display with a real-time display rate that is instantaneous to the human eye with the Tiny85 boosted to run at 8MHz. A custom device driver (200 bytes) sets up the OLED screen and enables pixel-by-pixel display. Custom Forth code converts a 0-1 color depth image into a byte-stream that can be written to the onboard flash for rapid display. It is a reminder of what can be accomplished with low-fat computing

The magic, of course, is in the software. This article describes how this was done, and the software that enables it. Checkout the TinyPhoto review on Hackaday!

Tiny Photo – 3cm x 7cm photo viewer powered by ATTiny85 8-bit microcontroller sending pixel level image data to OLED display (128×64 pixels), powered by 3V coin cell battery. Cycles through 5 images stored in 5kB of on-chip Flash RAM. (Note, this is 1 million times less memory than on a Windows PC with 8GB RAM). The magic is in the software.

Continue reading this article…

Voice-controlled Hardware: Making Sensors Talk for Under £5

Voice controlled hardware requires four capabilities: (1) vocal response to trigger events (sensors/calculations-to-brain), (2) speech generation (brain-to-mouth), (3) speech recognition (ear-to-brain), and (4) speech understanding (brain-to-database, aka learning). These capabilities can increasingly be implemented using off-the-shelf modules, due to progress in advanced low-cost silicon capable of digital signal processing (DSP) and statistical learning/machine learning/AI.

In this article we look at the value chain involved in building voice control into hardware. We cover highlights in the history of artificial speech. And we show how to convert an ordinary sensor into a talking sensor for less than £5. We demonstrate this by building a Talking Passive Infra-Red (PIR) motion sensor deployed as part of an April Fool’s Day prank (jump to the design video and demonstration video).

The same design pattern can be used to create any talking sensor, with applications abounding around home, school, work, shop, factory, industrial site, mass-transit, public space, or interactive art/engineering/museum display.

Bringing Junk Model Robots to life with Talking Motion Sensors (April Fools Prank, 2021)

Continue reading this article…

Emerging Technology

The Emerging Technology page has moved here

Curated Shorts

Stats: 1,066,417 article views since 2010 (March update)

Dear Readers:

Welcome to the conversation!  We publish long-form pieces as well as a curated collection of spotlighted articles covering a broader range of topics.   Notifications for new long-form articles are through the feeds (you can join below).  We love hearing from you.  Feel free to leave your thoughts in comments, or use the contact information to reach us!

Reading List…

Looking for the best long-form articles on this site? Below is a curated list by the main topics covered.

Mathematics-History & Philosophy

  1. What is Mathematics?
  2. Prehistoric Origins of Mathematics
  3. The Mathematics of Uruk & Susa (3500-3000 BCE)
  4. How Algebra Became Abstract: George Peacock & the Birth of Modern Algebra (England, 1830)
  5. The Rise of Mathematical Logic: from Laws of Thoughts to Foundations for Mathematics
  6. Mathematical Finance and The Rise of the Modern Financial Marketplace
  7. A Course in the Philosophy and Foundations of Mathematics
  8. The Development of Mathematics
  9. Catalysts in the Development of Mathematics
  10. Characteristics of Modern Mathematics

Electronic & Software Engineering

  1. Electronics in the Junior School - Gateway to Technology
  2. Coding for Pre-Schoolers - A Turtle Logo in Forth
  3. Experimenting with Microcontrollers - an Arduino development kit for under £12
  4. Making Sensors Talk for under £5, and Voice Controlled Hardware
  5. Computer Programming: A brief survey from the 1940s to the present
  6. Forth, Lisp, & Ruby: languages that make it easy to write your own domain specific language (DSL)
  7. Programming Microcontrollers: Low Power, Small Footprints & Fast Prototypes
  8. Building a 13-key pure analog electronic piano.
  9. TinyPhoto: Embedded Graphics and Low-Fat Computing
  10. Computing / Software Toolkits
  11. Assembly Language programming (Part 1 | Part 2 | Part 3)
  12. Bare Bones Programming: The C Language

Pure & Applied Mathematics

  1. Fuzzy Classifiers & Quantile Statistics Techniques in Continuous Data Monitoring
  2. LOGIC in a Nutshell: Theory & Applications (including a FORTH simulator and digital circuit design)
  3. Finite Summation of Integer Powers: (Part 1 | Part 2 | Part 3)
  4. The Mathematics of Duelling
  5. A Radar Tracking Approach to Data Mining
  6. Analysis of Visitor Statistics: Data Mining in-the-Small
  7. Why Zero Raised to the Zero Power IS One

Technology: Sensors & Intelligent Systems

  1. Knowledge Engineering & the Emerging Technologies of the Next Decade
  2. Sensors and Systems
  3. Unmanned Autonomous Systems & Networks of Sensors
  4. The Advance of Marine Micro-ROVs

Math Education

  1. Teaching Enriched Mathematics, Part 1
  2. Teaching Enriched Mathematics, Part 2: Levelling Student Success Factors
  3. A Course in the Philosophy and Foundations of Mathematics
  4. Logic, Proof, and Professional Communication: five reflections
  5. Good mathematical technique and the case for mathematical insight

Explore…

Timeline