A p p l i c a t i o n D e v e l o p m e n t

Application Development

C H A P T E R

5

Writing applications

The user applications are stored in subdirectory apps/ of the project folder.

The template project includes several demo applications for use as templates to begin developing your own programs. They will automatically build and copy to the folder “/usr/bin/” of the target when building the system.

Adding your own applications

To add a new application, run the script bin/add_app with the name of the new application as first parameter.

Example:

~/LxNETES-3.2/build_custom$ bin/add_app customapp

This command creates a sample application named ‘customapp’ in the folder apps/ customapp in the source directory. Edit the file apps/customapp/customapp.c to insert your application code.

To use more than one source file, just create the source files and modify Makefile.in to include the files in the build process.

On the next call to make install, the application is added to your root file system.

3 1

Page 31
Image 31
Digi 9P 9360/9750 manual Application Development, Writing applications, Adding your own applications