Thursday, February 6, 2020

RTEMS.

The Real-Time Executive for Multiprocessor Systems or RTEMS is an open source Real Time Operating System (RTOS) that supports open standard application programming interfaces (API) such as POSIX. It is used in space flight, medical, networking and many more embedded devices using processor architectures including ARM, PowerPC, Intel, Blackfin, MIPS, Microblaze and more.

RTEMS is a super interesting project and naturally, I wanted to tinker around with it to learn more.

BUT, building RTEMS can be a pain, especially if you are new to open source and you are building from source for the first time. For this project, I have been using a virtualbox instance running Ubuntu (well it is actually elementaryOs, but I uninstalled pantheon and installed LXDE on it for memory consumption reasons.)

Anyways, getting back to the main topic, building and installing RTEMS. What you *want* to do, is follow the documentation guide step by step. Unfortunately and even rightly so, the developers of the project cannot predict and provide instructions for all operating systems and their many distributions (looking at you GNU+Linux :O). The problems I faced were all Ubuntu related, so if your distribution is different, I may not be of much help.

But if you are on Ubuntu, this is the right place for you. Lets get started, shall we? It is very important that you keep this url open when you are building RTEMS: 

https://docs.rtems.org/branches/master/user/index.html

Go through the "Introduction" and when you're done, go through the first two steps of the "Quick Start" pages. Just go through the "Prefix" part but you don't have to do anything on your machine... just read it for your understanding. Once you are done with that, clone the RTEMS git repo to your machine (personally, I recommend using git even though they have an option of using curl to get the source. Git will get you the latest source code automatically, curl will not unless you specifically set it to download the latest version.)

Before you start copy-pasting the commands from the next section, "Installing the Tool Suit", make sure to do the following:

1. check if texinfo and python2.7-dev is installed. If not, install it.
    sudo apt install texinfo python2.7-dev

2. check if sed, grep, chown, chgrp and bzip2 are present in your /usr/bin folder.

If they are not in /usr/bin but rather in /bin/ , and I don't really know if this is safe or not, just make a copy of the aforementioned files to the /usr/bin folder

You'll need superuser privilages for this:


cd /bin/
sudo cp chown chgrp grep bzip2 sed ../usr/bin/ 
sudo cp chown ../usr/sbin/
And hopefully, this will do the trick. Try to build RTEMS now. 

I will be updating this post if I find any more problems. Stay tuned y'all !



No comments:

Post a Comment

RTEMS.

The Real-Time Executive for Multiprocessor Systems or RTEMS is an open source Real Time Operating System (RTOS) that supports open standar...