Threadx c++

123 146 Reputation points
2020-12-10T04:09:24.61+00:00

Hi, all
Dose Threadx smp support C++??
thanks

Azure RTOS
Azure RTOS
An Azure embedded development suite including a small but powerful operating system for resource-constrained devices.
330 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,636 questions
0 comments No comments
{count} votes

Accepted answer
  1. 123 146 Reputation points
    2020-12-11T03:12:17.287+00:00

    Hi @António Sérgio Azevedo @Ryan
    I want use C++ to write application, so I need to know whether the Azure RTOS(Threadx ) support C++. and I found QuantumLeaps qpcpp have a c++ port,(https://github.com/QuantumLeaps/qpcpp/tree/master/ports/threadx), Dose the Threadx SMP support C++??


2 additional answers

Sort by: Most helpful
  1. Ryan 276 Reputation points Microsoft Employee
    2020-12-10T18:14:42.387+00:00

    Hi @123 ,

    1. Azure RTOS includes the correct extern "C" wrappers in the interface header files, so supports calling directly from a c++ class.
    2. There is no supported c++ class interfaces for Azure RTOS. You would have to write and support these yourself.

    Thanks

    1 person found this answer helpful.
    0 comments No comments

  2. António Sérgio Azevedo 7,666 Reputation points Microsoft Employee
    2020-12-10T17:25:06.573+00:00

    Hi @123 ,
    Azure RTOS ThreadX source code is here: https://github.com/azure-rtos/threadx and is written in ANSI C and Assembly mostly.

    47061-image.png

    See also here in the official documentation: https://learn.microsoft.com/en-us/azure/rtos/threadx/threadx-smp/chapter1#ansi-c-source-code

    "ThreadX SMP is written primarily in ANSI C. A small amount of assembly language is needed to tailor the kernel to the underlying target processor. This design makes it possible to port ThreadX SMP to a new processor family in a very short time—usually within weeks!"

    Please add your feedback below, suggesting the business reason to have ThreadX SMP supporting C++.

    Thank you!

    Remember:

    • Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.
    • Want a reminder to come back and check responses? Here is how to subscribe to a notification.
    0 comments No comments