AgonLight2 update: embedded Hello world in BBC basic

AgonLight2 is Z80 based retro computer running BBC Basic.

The first thing you do with embedded computer is to run the Hello World equivalent i.e. to blink LED.

AgonLight2 has 34 pin GPIO connector:

In this GPIO-1 connector we can see many different signals are coming both from Z80 and ESP32-D4 . In this demo we decide to connect LED to pin 17 which is GPIO_PC0 signal of ez80F92 processor.

I use Breadboard and some Jumper wires Female-Male to connect the LED anode (+) to GPIO-1.pin17 the LED cathode (-) is connected to 4.7 k OHM which then is connected to GPIO-1.pin3 GND.

With the above setup if PC0 is set high the LED with light ON. When the PC0 is set LOW the LED will go OFF.

So how do we access PC0 in BBC BASIC?

I admit I come from AppleSoft Basic so Z80 BBC Baisc is new for me.

Fortunately Quark Firmware is on GitHub so I can check the sources.

In BBCBasic.txt I nottice commands to access directly Z80 memory, these are GET and PUT commands.

In ez80F92 datasheet I read that GPIO ports are accessed through 4 registers:

PC_DR – data register at address 09E hex /158 dec an 8 bit register where every bit corresponds to port bit i.e. if I want to write in PC0 I have to modify bit0

PC_DDR – data direction register at address 09F hex / 159 dec and 8 bit register where every bit corresponds to port bit direction 1 means Input, 0 means output

I quickly check:

PRINT GET(159)

returns 255 i.e. all ports C are inputs by default

I change PC to output with the PUT command

PUT 159,254

then make PC0 HIGH with the command:

PUT 158,1

LED lights ON:

Yay!

PUT 158,0

command switch LED off:

Now we only have to put some delay between the ON OFF commands.

I search for delay in Quark sources without success when I nottice that INKEY command scans for keystroke pressed for some time and returns -1 if not suceed.

Let’s check if INKEY can be used as delay 🙂

PRINT INKEY 1000

prints -1 after about 1 second, great then our fill code becomes like this:

the code runs and the LED slowly blinks as on the video clip above!

AgonLight Open Source Hardware Retro Computer Running BBC Basic was captured in KiCad and updated by Olimex

AgonLight is a well-documented small computer based on the Z80 family and running BBC BASIC.

With a VGA output and a PS2 Keyboard this is a stand alone retro style computer.

The project is open source hardware and software.

AgonLight may be also seen as an embedded BASIC computer as it has plenty of GPIOs available to interact with other components and modules.

The AgonLight was designed by Bernardo Kastrup and the Quark firmware is developed by Dean Belfield.

The project has an active Facebook group https://www.facebook.com/groups/agoncomputer/

We got a few inquiries from customers asking if Olimex is interested in making this project and we hesitated at first due to having the bad experience in the past with Maximite pseudo open source project.

After exchanging a few words with Bernardo via Twitter, we became confident that this is a true open source hardware project.

We checked the schematic and decided to do some small changes.

  • We decided to re-capture the design in KiCad instead of EasyEDA
  • The power of the original AgonLight is delivered by a USB-A connector which is quite odd and USB-A to USB-A cables are less popular. We decided to replace it with USB-C connector which is used in all new phones, tablets and devices due to the new EU directive. Usually everyone has such a cable at home to charge and transfer files to their cell phone.
  • We replaced the Linear voltage regulator with DCDC which delivers up to 2A current.
  • We added a battery LiPo charger and step-up converter which allows operations even if external power supply is interrupted.
  • The original design had a PS2 connector for a keyboard and required a USB to PS2 adapter to operate with the more available USB keyboards. We replaced the PS2 connector with a USB-A connector so a normal USB keyboard (which supports PS2) can be directly plugged-in to AgonLight
  • We routed the AS7C34096A-10TCTR SRAM with 40 ohm impedance lines as per the datasheet
  • Fixed a wrong signal naming in the ESP32-PICO-D4, which now is updated in the original AgonLight documentation.
  • Replaced the bare header 32-pin connector with a plastic boxed 34-pin connector following the same layout and adding two additional signals Vbat and Vin which allow AgonLight to be powered by this connector too.
  • Added a UEXT connector (https://www.olimex.com/Products/Modules/) which allows AgonLight to be connected to: temperature sensors, environmental air quality sensors, pressure, humidity, gyroscope, light, RS485, LCDs, LED matrix, relays, Bluettooth, Zigbee, Lora, GSM, RFID reader, GPS, Pulse, EKG, RTC etc.

We changed most of the components to our component base, which we source and stock in large quantities and allow us to bring the cost down.

The design was completed 1 week ago:

Today the first blank PCBs arrived:

Next week we will assemble 5 pcs to test by ourselves and then send to the original AgonLight developers.


AgonLight will be put on our web and available for pre-order next week with a special Christmas price of EUR 50 for a completely assembled, programmed and tested computer.


If the prottotypes are good mass production will follow and all pre-orders taken to 23.12.2022 will be shipped by the end of January.

We plan to make metal case and other accessories in the near future.

New shield for STMP157-OLinuXino Industrial grade Open Source Hardware Linux computer

The open source hardware STMP157-OLinuXino industrial grade Linux computer got new shield which adds two UEXT connectors, second micro SD card and 40 pin GPIO connector in breadboard friendly 0.1″ (2.54 mm) step format.

STMP15X-SHIELD plugs on top of OLinuXino, the overlays are already included in OLIMAGE Linux images and no need for additional setup.

ESP32-C3-DevKit-Lipo RISC-V development board with build in USB JTAG, WiFi, Bluetooth5, Lipo charger and 15 GPIOs

ESP32-C3-DevKit-Lipo is EUR 6.00 Open Source Hardware compact development board with:

  • RISC-V running on 160Mhz
  • 400KB RAM, 8K data RAM
  • 4MB Flash
  • Two headers (soldered) with power supply and GPIO signals
  • ESP-PROG-C compatible rescue connector (if you mess with bootloader)
  • USB-C for programming and JTAG debugging
  • LiPo battery charger allowing handheld applications with single LiPo battery
  • 4 mount holes

This is all you need to get started with RISC-V programming in C and Assembly.

Shteryana Shopova recently did RISC-V workshop with this board and explained how to setup your tools for programming and debugging. Here you can find her work.

GigaDevices GD32 boards replacements for the popular STM32 are now in stock

STM32 are one of the most popular Cortex ARM devices on the market as they are with aggresive pricing and nice features. The semiconductor crisis hit ST as all other semiconductor vendors and STM32 disappeared from the market. Many customers have been left for more than year without MCus.

GigaDevices is well known Flash memory manufacturer, they have range of ARM Cortex M3, M4 devices which are pin to pin compatible with STM32 MCUs.

We check GD32 assembled on our STM32 boards and they work equal the only difference we notice is that GD32 lack two wires JTAG SWD interface and only support the full JTAG, which is not big issue.

All code we test run equal on both STM32 and GD32.

Here are links for the GigaDevices based boards:

GD32-H103 header board equal to STM32-H103

GD32-P103 prototype board equal to STM32-P103

OLIMEXINO-GD32 Arduino like board equal to OLIMEXINO-STM32

OLIMEXINO-GD32F3 Arduino like board equal to OLIMEXINO-STM32F3

GD32-H405 header board equal to STM32-H405

GD32-P405 prototype board equal to STM32-P405

GD32-H407 development board equal to STM32-H407

GD32-E407 development board equal to STM32-E407

GD32-P407 development board equal to STM32-P407

iMX8MPlus-SOM is alive and boots!

This board development started in April 2021 and finished August 2021 but the semiconductor shortages didn’t allow us to test the prototypes until recently. We assembled 4 boards and all theyare alive and boot.

The features are:

  • MIMX8ML8DVNLZAB – Quad Core Arm Cortex-A53 running at 1.8Ghz with Arm Cortex-M7 co-processor running at 800Mhz and 2.3 TOPS Neural Processing Unit.
  • 6GB LPDDR4 RAM
  • Power management
  • configuration EEPROM
  • status LED
  • LCD LVDS connector compatible with LCD-OLinuXino displays
  • MIPI DSI connector
  • 2x MIPI CSI comera connectors with Raspberry Pi compatible pinout
  • 220 signals on 6 0.05″ step connectors with essential peripherials like:
    • PCIe-3.0
    • 2x CAN FD
    • HDMI 2.0a
    • SPDIF
    • SAI
    • 2x USB 3.0
    • 2x Gigabit Ethernet one of them with TSN
    • eMMC 5.1
    • SDIO 3.0 200Mhz
    • 4 UART
    • 6 I2C
    • 3 SPI
    • JTAG

Unfortunately we only managed to find 24Gb LPDDR4 for the prototypes so instead of 6GB they are with only 3GB of RAM.

Now is time to prepare Linux and Android images! NXP provide iMX8MPlus with Linux Kernel 5.10 and Android 11.

MIMX8ML8DVNLZAB is industrial grade -40+105C

Quad Core 64bit Open Source Hardware Linux computer A64-OLinuXino now have version with external antenna

A64-OLinuXino is Open Source Hardware Quad core 64 bit Linux Computer.

We also offer nice metal box for it named BOX-A64-BLACK:

The only problem was that A64-OLinuXino have option for on board WiFi-BT but it uses PCB antenna and when put in box the communication range was decreasing signiificantly.

New revision of A64-OLinuXino board now supports both internal PCB antenna and U.FL externally attached 2.4Ghz antenna.

So A64-OLinuXino can be put inside the metal box and have the antenna outside:

Open Source Hardware S3-OLinuXino update – The new board targeting industrial vision applications is now with mainline Linux support

S3-OLinuXino is board we create to may add vision to the PTH components Soldering Robot we are working on for some time.

Revision.B now is a bit different than the first prototype we made. It has these features:

  • S3 SOC Cortex-A7 running at 1.2Ghz
  • 1Gb DDR3 RAM inside S3 SOC up to 1333Mhz
  • MIPI Raspberry Pi camera interface up to 8Mpix camera support
  • Parallel CSI camera interface up to 8 Mpix
  • Power Management Unit with LiPo battery charger and step-up to allow stand alone battery operation
  • 100Mb Ethernet interface with POE support (external optional module)
  • SPI, NAND, eMMC external optional module
  • LCD connector to connect to LCD-OLinuXino displays with different sizes and resolutions
  • LiPo battery connector
  • USB-OTG interface
  • UEXT connector with SPI, I2C, Serial and power supply
  • EXT1 connector for LED PWM lighting
  • audio input with microphone
  • audio output
  • WiFi and BT module with external antenna
  • micro SD card connector

We are working to offer Mainline Linux with this board.
Bootlin got sample board and have working MIPI driver.

S3-OLinuXino can take power from USB, LiPo battery or PoE (with optional PoE module).

Different NAND Flash, SPI Flash, eMMC flash options are possible with addon module

The only thing we still didn’t complete is USB-OTG functionality.

Mass production is planned for March 2021.

The popular Olimex ARM OpenOCD JTAG programmer debugger ARM-USB-OCD-H gets better, now has a modification which works with targets from 0.65 up to 5.5V

ARM-USB-OCD-H is a low-cost ARM OpenOCD debugger. It supports targets from 1.65V up to 5.0V. Many SOC manufacturers like Intel, Intel/Movidius, nVidia and others use it in their development work. Intel quotes ARM-USB-OCD-H and ARM-JTAG-20-10 in their appnote “Source Level Debug using OpenOCD/GDB/Eclipse on Intel® Quark™ SoC X1000”.

A few month ago we got an interesting question. A new SOC manufacturer was trying to debug their SOC with ARM-USB-OCD-H, but the problem was that their target was working on 1.2V. They asked us if we could modify our JTAG to be able to work at lower than 1.65V targets.

Our engineers identified a couple of components which we could upgrade to support lower voltages. The final result was that the ARM-USB-OCD-HL new modification of the JTAG can now work with targets from 0.65V up to 5.5V.

This pretty much covers all existing SOCs on the market.

The work on our most complex Open Source Hardware Linux board started – meet the Tukhla iMX8QuadMax SOC based board to be designed with KiCAD

We started working on our most complex OSHW board with KiCAD.

iMX8 is broad range of very different ARM architectures under same name which some people may find quite confusing.
Here is the table chart:

You can see by yourself:

  • iMX8X is quite humble with up to x4 Cortex-A35+Cortex-M4F cores, something less capable than Allwinner A13 or STM32MP1XX
  • iMX8M, Nano/Mini/Plus is x4 Cortex-A53 + Cortex-A7/M4F something in the range of power of Allwinner A64
  • finally iMX8QuadMax comes with different configurations, but the high end is Octa-core with x2 Cortex-A72 + x4 Cortex-A53 + x2 Cortex-M4F and is more powerful than the popular Rockchip RK3399

Why we did started working on such monster?

Company from EU which values the OSHW recognized the absence of high end open source Linux board and asked us to design one. They offered to cover all associated design costs. They specially requested this to be not yet another RK3399 board, but based on SOC with proper documentation and software support. NXP’s high end iMX8QuadMax matched their requirements perfectly.

Currently all powerful Cortex-A72 comes from Chinese or Korean origin and are always closed projects, the only published info in best case is PDF schematic which can’t be verified i.e. the final product may or may not match what they publish. The popular Raspberry Pi go even further and their “schemaitcs” are just connector diagrams.

This is how the Tukhla project was born, it will have:

  • MIMX8QM5AVUFFAB Octa-core SOC with: ( x2 Cortex-A72, x4 Cortex-A53, x2 Cortex-M4F, x4 GPUs with 16 Vec4-Shader GPU, 32 compute units OpenGL® ES 3.2 and Vulkan® support Tessellation and Geometry Shading, Split-GPU architecture enables 2x 8 Shader Cores, 4k h.265 Decode, 1080p h.264 encode)
  • x2 LPDDR4 x32 databus RAM memory with up to 16GB of RAM configuration
  • PMU taking all power lines from single 12V/4A source
  • micro SD card
  • eMMC Flash with differnt sizes
  • QSPI Flash
  • x1 SATA for external HDD/SSD drives
  • x2 single lane PCIe with M2 connectors for NVMe
  • HDMI input 1.4 RX with HDCP 2.2
  • HDMI output 2.0 TX with HDCP 2.2 4K
  • USB 2.0 OTG
  • USB 3.0 HOST
  • x2 Gigabit Ethernet
  • x2 MIPI CSI camera connectors

The price of MIMX8QM5AVUFFAB alone is around EUR 100 in small quantities and currently LPDDR4 4GB cost EUR 35, LPDDR4 8GB cost EUR 50, LPDDR4 16GB cost EUR 180.

So with BOM over EUR 200 this board will not be affordable for the most of Raspberry Pi $35 price range users.

This board targets professionals, who need high performance board and being not dependent by Chinese SOC vendors. With all hardware open, which gives them security for their business as the design is public.

iMX8QuadMax SOC is available in automotive AEC-Q100 Grade 3 (-40° to 125° C Tj), Industrial (-40° to 105° C Tj), Consumer (-20° to 105° C Tj)

Some of the features like HDMI input are not present in the Chinese SOCs at all.

iMX8QuadMax may have DSP and incorporate Vision and Speech Recognition interactivity via a powerful vision pipeline and audio processing subsystem.

The Software support include: Android™, Linux®, FreeRTOS, QNX™, Green Hills®, Dornerworks XEN™.

iMX8QuadMax is fully supported on NXP’s 10 and 15-year Longevity Program

Tukhla means Brick in Bulgarian (and other Slavish languages) and it will be the OSHW building block for whole range of different solutions.

How long it will take to finish this design?

We honestly don’t know. It took more than month just to capture the schematic in the state it is now:

There is long path now to create and verify all component packages (just the SOC is in 1313 BGA ball package), verify the schematic signals, place the components on the PCB, route high speed signals manually.

It may be 6 months or more. We got unofficial info that NXP engineers spent more than year to make the NXP iMX8QMax demo board.

Previous Older Entries