At some point someone has to talk about software…
Our testing of EDDIE wouldn’t go ahead without a bit of backbone from some software.
As part of the products that Bored Owl is developing, we have an operating system core that uses our custom stack based (ie Forth like) language. This language is tuned to use 32 bit integers as its main data type and is suited to small ARM Cortex-M0 cores as well as the M4+ core in EDDIE. Originally the language was developed on a desktop computer and then ported to ESP32 systems. These ESP32 systems are on our “BOB-C” board which is used in our Kairos clock kits.
K4 Features
Stack based interpreter
32 bit integers are native for numbers and memory references
Functionality is provided by built-in and user defined “words”
Support for strings. Strings can be manipulated, edited and printed.
Similar set of built-in words as Forth-79 (https://en.wikipedia.org/wiki/Forth_(programming_language).
The dictionary can be loaded and saved from/to non-volatile storage (CPU Flash, QSPI Flash or SD Card)
A set of built-in system words complements the standard built in words. These words facilitate access to I/O drivers for the hardware resources available in the system.
Our K4 system will ultimately support interrupts, multi-tasking and multi-processing in the EDDIE hardware. For now it is a simple single task console interpreter. Since the EDDIE system has a UART (Serial channel on the backplane, a simple logic-level to RS232 converter provides us with a serial interface to our development computer. The K4 shell has a serial console that we use to start running tests and building useful system interface words:
EDDIE System: A rough serial interface.
Certainly, this serial interface will be integrated onto a proper EDDIE card in the near future.
The screenshot shows K4 in action, testing I/O on the CPU51 card.
Screenshot of K4-51 in action
You can see words for interfacing to the I2C peripherals and SPI channels being invoked in this session. The concept of “words” in K4 is fundamental. Except for the built-in binary words that are compile with the system, all words are made from other words in the system’s vocabulary. This is an inherently modular architecture. It also tends to a very “bottom-up” implementation - where the essential components are built and tested first, and larger and more complex pieces are created from them.
Since K4 is actually a piece of software that runs on a number of our product platforms, including ultimately various different EDDIE cards, it has to be ported to each architecture. When K4 starts, it loads its “standard” vocabulary (sometimes called its dictionary). This vocabulary is built in C++ with the core system. However the core and this dictionary cannot communicate with I/O in any way - since there is no fixed platform that it is designed to run. on.
Every K4 system includes. a “System Interface”. This interface provides lowest level and most vital I/O functions - particularly console I/O and in some cases network access. The extent of that interface is intentionally kept small. It is complimented by the “System Words”. During start-up, once the standard vocabulary is loaded, the system interface is called to contribute the system words - that are unique to each K4 port.
A typical interpreter on the ARM M4+ CPU card uses about 5% of the available flash and 10% of the available RAM. (This includes 16K of dictionary space which is fully available on startup). While this is something we consider quite acceptable, it is a subject of on-going design, research and testing to improve memory usage as K4 is developed.
The details of K4 are not unique to the EDDIE project and are gradually being posted on our blog pages (https://www.boredowl.com.au/k4-blog)
The Next Steps
The past month has given us a great deal of encouragement towards our goal of building a powerful, useful embedded computer system - and most certainly we have a great deal still to do.
The first CPU card is as we have mentioned undergoing a hardware revision while software is being developed particularly for SD card file I/O. This is important as we build dictionaries of words in K4 that do more elaborate things and eventually build complete applications.
In the coming months, the CPU card will at least be complemented by a card which provides various types of serial communication (RS-232, RS-485 ports and additional USB connectivity). That card will have prototyping support that we can use to test hardware for upcoming designs.
A final note about our Blogs
Now the foundations for a series of blogs about our products and experiences. have been layed down. For your convenience, these are the most important links, but there are some other blogs in our collection you might find interesting:
https://www.boredowl.com.au/eddie-blog
https://www.boredowl.com.au/k4-blog
And our main blog index can be reached at:
https://www.boredowl.com.au/our-blogs
Our blogs are constantly being updated so be sure to bookmark and come-back regularly for the next steps in our story.
Features and functions described in our blog posts are not final specifications. Products when made for sale will be published with official documentation and specifiactions that may differ from our aspirations during this development process.