Using Free-RTOS in AGX ORIN

Hello everyone,
Lately I had been working on Nvidia Jetson AGX ORIN and came across a forum stating that FreeRTOS and SPE are present as inbuilt inside the L4T Package(my machine version is 35.1). Then I started researching about how to run FreeRTOS alongside the Linux by assigning a carmel core. Still couldn’t find a correct resource for the procedure. Also came across the FreeRTOS events folder inside the rootfs.

If anyone does have an idea on using FreeRTOS, could you please provide the resource / steps to proceed further ?

Thanks in advance,
Regards
Siva

Hello,
I’m a little confused by your statement as

how to run FreeRTOS alongside the Linux by assigning a carmel core

Current L4T package, FreeRTOS can only run in SPE R5 core.

br
ChenJian

1 Like

Thanks for the immediate reply Chen Jian and sorry for the confusion. I would like to know whether is it possible to run FreeRTOS on AGX ORIN/ XAVIER or not .

Regards,
Siva

FreeRTOS is useful on a Cortex-R series of CPU core. The CPU cores you would normally hear about on a Jetson are the Cortex-A series. The sensor processing engine (and audio processing engine) has its own CPU core which is a Cortex-R5. Those separate cores can run FreeRTOS. The main Jetson cores cannot run FreeRTOS (or at least it would not be useful, they are the wrong architecture).

1 Like

Thanks for the reply @linuxdev . As you have mentioned that we could run FreeRTOS on Cortex-R series. So how do i utilize the Cortex-R5 sub-system in AGX ORIN for running RTOS?
If you do have any resources related to it, please share them.

Regards,
Siva

I have not actually done that. However, there are two Cortex-R5s in the system: The APE (Audio Processing Engine) and the SPE (Sensor Processing Engine, e.g., camera source input). If you use one of those, then it means losing the original function. I don’t know if both can be used for custom purposes or not. I’m pretty sure the SPE can be used if you’re not using it for cameras, and maybe the APE can be used (someone from NVIDIA would have to comment). Those processors tend to be used “behind the scenes” and don’t really get mentioned much so far as end user access goes, so I have no reference.

Someone from NVIDIA might be able to reply with some document to get started with, or a thread in the forum, whereby the SPE or APE have FreeRTOS added. I’d kind of like to see such a document myself, I’m fond of hard realtime, which is something sadly missing in the typical embedded controller space. One can use a Cortex-M CPU for this, but they are much more limited, e.g., scheduling in hard realtime quickly becomes a problem load after only a very small number of processes start running, and the Cortex-R has some hardware support for this which is why they are so useful (versus Cortex-M) in hard realtime (it isn’t just functional safety with shadow cores which Cortex-R excels at).

1 Like

Hello, billakurthi.sivasai
You can take a look at https://developer.nvidia.com/downloads/embedded/l4t/r35_release_v4.1/sources/spe-freertos-bsp.tbz2/

That package contains full source code and docs, which can run FreeRTOS in SPE R5 core.

br
ChenJian

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.