Formation Real Time Programming with RT-Thread | Ac6 Training

ac6-training, un département d'Ac6 SAS
FR
FrançaisEnglish
 
go-up

ac6 ac6-training Programmation Temps réel Real Time Programming with RT-Thread
RT7Real Time Programming with RT-Thread
From Theory to Practice

Objectives

  • Understand the RT-Thread architecture and execution model
  • Migrate from bare-metal designs to a thread-based RTOS architecture
  • Get an overview on Cortex-M architecture used by RT-Thread
  • Understand the concepts of real time multithreading
  • Learn how to configure, build, develop and debug RT-Thread applications
  • Use Env, menuconfig and SCons in a BSP-based workflow
  • Understand RT-Thread thread management, synchronization and communication services
  • Understand RT-Thread memory management mechanisms
  • Understand the RT-Thread device framework and device model
  • Learn how to access devices through RT-Thread APIs
  • Get a concise overview of the RT-Thread ecosystem
  • Theoretical course
    • PDF course material (in English)
    • The trainer to answer trainees’ questions during the training and provide technical and pedagogical assistance
  • Practical activities
    • Practical activities represent from 40% to 50% of course duration
    • Example code, labs and solutions
    • Physical Board (NXP FRDM or STM32) or simulated board (STM32 or NXP) using Zazu Simulator
  • Strong embedded C programming skills
  • Basic knowledge of embedded processors
  • 3 days
  • Cours théorique
    • Support imprimé et PDF (en anglais).
    • Assistance du formateur tout au long de la formation.
  • Activités pratiques (40-50% de la durée)
    • Exemples de code, exercices et solutions.
    • Un PC (un par binôme au-delà de 6 stagiaires) avec carte cible si nécessaire.
  • Machine virtuelle préconfigurée téléchargeable pour refaire les TP après le cours.
  • Chaque session débute par un point avec les stagiaires.
  • Tout ingénieur ou technicien en systèmes embarqués possédant les prérequis ci-dessus.
  • Les prérequis sont évalués avant la formation.
  • Les progrès sont évalués par le formateur via les exercices pratiques, et par des quizz pour les sections sans exercices.
  • Chaque stagiaire reçoit une attestation de réussite.
  • En cas de prérequis manquant, une formation différente ou complémentaire est proposée.

Plan du cours

  • Cortex-M architecture overview
  • Registers and execution states
  • Privilege levels and execution modes
    • Thread mode and Handler mode
    • MSP and PSP
  • Exception and interrupt mechanism overview
  • NVIC and SysTick
  • PendSV role in context switching
Exercise :  Exercise: Interrupt management and Cortex-M execution model
  • RT-Thread standard architecture
  • RT-Thread kernel architecture overview
  • Kernel object model
  • Standard BSP / project tree
  • Where application code is added in an RT-Thread project
  • Main thread, idle thread and timer-related system services
  • Differences between a bare-metal superloop design and an RT-Thread application structure
Exercise :  Explore the structure of a Hello World RT-Thread project
  • System startup sequence
    • Board initialization
    • Scheduler initialization
    • Main thread, timer thread and idle thread
  • Automatic initialization mechanism
  • Kernel service overview
  • Clock and timer management
Exercise :  Follow the boot sequence from reset to main()
  • RT-Thread Env workflow
  • Opening Env from the BSP environment
  • menuconfig usage
  • Configuration principles in RT-Thread
  • Generation and role of .config and rtconfig.h
  • Enabling and disabling kernel features and components
  • Managing BSP-specific configuration
  • Practical differences between source-level customization and package selection
Exercise :  Enable selected RT-Thread features with menuconfig, rebuild and validate the generated configuration
  • Base real time concepts
  • Tasks and task descriptors
  • Context switch
  • Task scheduling and preemption
  • Tick-based scheduling
  • Deterministic preemptive scheduling
  • Priority-based scheduling in RT-Thread
  • Time-slice rotation for same-priority threads
Exercise :  Analyse scheduling and context switch behavior
  • Thread control block
  • Thread stack layout
  • Thread states and life-cycle
  • Thread creation
  • Thread startup
  • Thread delay, yield and suspend / resume
  • Main thread and idle thread roles
Exercise :  Create and manage RT-Thread threads
  • Critical sections
  • Interrupt lock and scheduler lock
  • Semaphores
  • Mutexes
    • Recursive locking
    • Priority inversion
    • Priority inheritance
  • Events
    • OR trigger
    • AND trigger
  • Choosing the right synchronization primitive
Exercise :  Synchronize threads with events
  • Mailbox
  • Message queue
  • Signals overview
  • Thread-to-thread communication patterns
  • ISR-to-thread communication patterns
  • Data passing versus synchronization
Exercise :  Implement producer-consumer and command / message exchange patterns
  • Memory model in embedded real-time systems
  • Static objects versus dynamic objects
  • Dynamic memory heap
  • Small memory management algorithm
  • Slab allocator overview
  • Memheap for multiple non-contiguous heaps
  • Memory pools
  • Determinism and fragmentation considerations
  • Memory allocation constraints in ISR context
Exercise :  Compare heap and memory pool usage in RT-Thread
  • Clock tick and system heartbeat
  • Software timers
    • One-shot timers
    • Periodic timers
  • HARD_TIMER versus SOFT_TIMER
  • Timer thread role
Exercise :  Use RT-Thread timers for periodic processing
  • I/O device framework
    • I/O device management layer
    • Device driver framework layer
    • Device driver layer
  • RT-Thread device object model
  • Device registration and lookup
  • Standard device operations
    • init()
    • open()
    • close()
    • read()
    • write()
    • control()
  • Character devices versus block devices
  • Application to driver interaction flow
  • Overview of common device classes
  • Typical threaded device access patterns
Exercise :  Access and use a device through the RT-Thread device framework
  • Components and packages overview
    • FinSH / MSH
    • Virtual File System
    • Network-related components
    • Utility components
  • When to use components and when to keep a minimal RTOS design
  • Kernel porting principles
  • BSP porting overview
  • Additional device classes available in RT-Thread
  • Debug and tracing directions
Plus d'information

Pour vous enregistrer ou pour toute information supplémentaire, contactez nous par email à l'adresse info@ac6-formation.com.

Les inscriptions aux sessions de formation sont acceptées jusqu'à une semaine avant le début de la formation. Pour une inscription plus tardive nous consulter

Vous pouvez aussi remplir et nous envoyer le bulletin d'inscription

Ce cours peut être dispensé dans notre centre de formation près de Paris ou dans vos locaux, en France ou dans le monde entier.

Les sessions inter-entreprises programmées sont ouvertes dès deux inscrits. Sous condition d'un dossier complet, les inscriptions sont acceptées jusqu'à une semaine avant le début de la formation.

Dernière mise à jour du plan de cours : 20 mai 2026

L'inscription à nos formations est soumise à nos Conditions Générales de Vente