The most common issues on Embedded Linux are similar to issues in a standard Linux distribution. These range from administration/management issues (which packages to install, setting the right build options, etc.) to run-time issues (limited disk/swap space due to improper allocation; not enough memory – still very much an issue for an Embedded Linux system). The key to avoiding these issues is proper planning: knowing what you expect your Linux system to do and then building a system accordingly (maintaining the system is simply an extension of this planning stage – changing the system as your needs evolve). In an Embedded Linux system with fewer resources and more rigid constraints this process becomes even more critical. Therefore, the migration stage when you are making the switch to Embedded Linux is the time when you have to make the right choices.
You could be migrating to Embedded Linux for various reasons: you were already using some other RTOS and realize that Embedded Linux has better support for your platform (example: ARM has excellent Embedded Linux support); you may be a traditional Linux user who is preparing to move into the Embedded domain for the first time (due to business reasons or otherwise - perhaps you are hacking your Linksys wireless router); etc.
The planning stage can be simplified by answering the following questions:
1.What hardware are you using? Does it have Linux support – are device drivers, libraries available? The hardware you purchase may already have a pre-installed Embedded Linux distribution (that will usually prove to be a pretty good choice), or you may get resold devices on which people have installed Embedded Linux (especially common for those wireless routers). In either case, there will be a lot of information available online (support docs, How-Tos, issues that people have faced before). Are development boards available? What kind of expansion capabilities are there?
- a.Whether or not to use a commercial Linux distribution (because these have support and training possibilities)? If not using a commercial Linux distribution then how to get support and training? Is a lot of information available online? Is the online user community active?
- b.What software tools/packages are available for a selected version of Linux? How often are updates, new packages available for the selected distribution?
2.Which kernel / distribution to use? You need to consider several things in addition to the kind of hardware you have and your target application:
3.What compilers and debuggers to use? This is the process of deciding which development environment to use. How will your software development process change because of the switch to Embedded Linux?
4.It is critical to understand certain implications of using GPL: Using GPL may require you to release proprietary code to the general public.
5.Finally, you need to understand some aspects of the system itself: what are its real-time constraints? What kind of networking capabilities does it have (wireless, Ethernet, etc.)? What kind of communication ports does it have? Is expansion possible?
6.What packages/tools do you need to install? These depend on your application, the hardware (1), the development environment (3), and the constraints (5), among other things.
Obviously, there are several inter-relationships above, so the ordering is simply a guideline and your actual planning stage will be some combination of the above steps (and not necessarily of all these steps), with a certain amount of back-and-forth. There will, of course, be economic constraints guiding the entire process. In fact, economic constraints may be one of the reasons why you are making the switch to Linux in the first place.
A sound planning stage ensures that a number of future problems will be avoided.