APIC – Getting start

Core Engine – Getting Started Guide

The Core Engine package

Welcome to the Core Engine, a high-performance real-time simulation framework designed for deterministic execution, predictable timing, and accurate model behavior. This guide walks you through the basic concepts, setup steps, and core workflow needed to start building simulations.

Looking for the full system-engineering workflow instead? See How to Build an APIC System for Software Engineers.

What Is the Core Engine?

The Core Engine is a modular real-time execution system that runs simulations in fixed-rate frames, allowing you to:

System Requirements

Core Concepts

The Core Engine is built around a deterministic real-time loop that executes simulation logic in fixed, predictable intervals. To understand how to write stable, high-performance simulation modules, it’s essential to know the core components and how they interact. This chapter explains the most important systems within the Core Engine.

Frame Loop (Real-Time Engine)

At the heart of the Core Engine is the Frame Loop, a high-precision, fixed-period execution cycle. Every frame represents one “tick” of simulation time, and all simulation logic runs inside these ticks.

How the frame loop behaves

This produces a stable “heartbeat” for your simulation.

Why this matters

This is the central part of the engine where your logic runs. The Work Section is executed once every frame and should contain all time-critical operations:

Work Section (User Simulation Code)

Rules for Work Section code

ou can think of the Work Section as a “real-time ISR”—fast, predictable, and isolated.

Scheduler

The Scheduler is responsible for managing and executing tasks during each simulation frame.

What the Scheduler does

Types of tasks

The Scheduler typically contains:

Engine States

The Core Engine has a simple but effective state machine:

State Meaning
Run Continuous real-time execution
Step Execute exactly one frame and then pause
Stop Terminate simulation immediately
Init Send Init signal to all the Drivers and the Models
Reset Reset All IO drivers and send Reset signal to all Models

Multi-Threading Model

Although the Frame Loop is single-threaded for determinism, the engine internally may use additional threads:

Main threads

This ensures high-frequency simulation execution is not blocked by slower tasks like disk I/O.

Example of Core Engine App design

The following is an example of an AH-60 device development setup.