Examples

Examples

Complete projects that ship with the editor. Open one, look at how it is built, change something, download it — usually faster than starting from an empty file, because the scaffolding you would have built anyway is already there and already consistent.

They are not toys cut down for a manual. They are real projects that get extended as features arrive, which is also why they are worth re-opening after an update.


The projects

Project Board What it is
Thermostat Olimex ESP32-EVB, 240×320 a wall thermostat: hysteresis, two relays, manual mode, trend, alarms and a phone page
Showcase STM32F746 Discovery, 480×272 the same runtime on other silicon: status word lamps, bit access, ethernet, online

More will be added here. Each gets its own page, with what it shows, what is worth copying from it, and something to try changing.


Where they live

Find them in ProgramData\ctrl32, or open them from the editor's welcome screen. The projects are sorted into three folders:

Folder Holds
examples\ the board projects and feature demos — this page
tutorials\ small, single-idea projects, one lesson each
examples\tests\ regression fixtures. Real projects, but written to exercise the compiler rather than to be read

The editor, working

The same tool in the views you will spend your time in. These come from the projects above.

Ladder

The ladder editor: five rungs of the thermostat, blocks in the rungs, the Toolbox on the right

Blocks sit in the rungs with EN/ENO — BLINK, SEL, RAMP, PT1, HYST — so the whole control chain is one picture rather than a diagram somewhere else. Comments run above each rung.

Ladder, online

The same rungs with live values from a running board: green power flow, 233 cycles counted, values on every pin

The same program, connected to a running board. Green is current flowing, and every pin carries its live value.

This is the view worth knowing about before you need it: when something behaves differently than you expected, you watch the rung rather than guess.

Function block diagram

The FBD editor: SCALE, HYST, NOT, LT and TON wired through named variables

A tank controller as a diagram — from tutorials. Blocks run top to bottom and pass values through variables, which is why the order on screen is the data flow.

Structured Text

The ST editor with syntax highlighting and "compiles clean" in the status bar

For anything a diagram makes clumsy: loops, step sequences, a long calculation. It compiles as you type, and the same block library is callable from it.

CANopen

The board page with the CANopen master, its nodes and their objects

Nodes on the bus, their objects, and the variables generated from them. An EDS file from the manufacturer becomes correctly typed, correctly addressed variables — see CANopen.

A different board

The same editor with a stepHMI32.4 project open

Same editor, same languages, same widgets. The board is a choice in the project, not a different tool.


Using one as a starting point

  1. Open it and Save As under your own name. (Saving needs a licence — in the demo you can open, change and simulate an example, you just cannot write it back out. See Licensing.)
  2. Change the target board in the project settings to yours.
  3. Delete the screens you do not want. Nothing else breaks — a screen is only referenced by the nav buttons pointing at it.
  4. Keep the variables you need, rename the rest.

The examples are regression tests too

They are compiled and rendered on every build, which is why they stay current. If an example does something the documentation does not describe, the example is the one telling the truth.


Your first project build one from an empty file
Tutorial projects eleven small ones, a single idea each
Supported hardware what the runtime runs on
Tags