Before you begin, ensure you have:
Hardware: One of the supported RobustOS Pro devices (EG5100, LG5100, R1520LG, EV8100, EG5101, EG5200, EG5120, or EG3110)
Network Access: SSH access to your device
User Account: A sudo user account on the device (create one via Web GUI if needed)
Basic Knowledge: Familiarity with Linux command line and C programming
| Device | CPU | Architecture | RAM Available |
|---|---|---|---|
| EG5100/LG5100/R1520LG/EV8100/EG5101 | i.MX 6ULL | armv7 (armhf) | 256MB |
| EG5200 | i.MX 8M Plus | armv8 (arm64) | 2.5GB |
| EG5120 | i.MX 8M Plus | armv8 (arm64) | 1.5GB |
| EG3110 | RK3562 | armv8 (arm64) | 256MB-7.5GB |
# Replace <device-ip> with your device's IP address
ssh username@<device-ip>
Example:
ssh sudouser@192.168.0.1
# Update package list
sudo apt update
# Install required packages
sudo apt install -y librosp-dev build-essential devscripts
# Optional: Install additional dependencies
sudo apt install -y libevent-dev libpam0g-dev libcurl4-openssl-dev libssl-dev libxml2-dev
Expected Output:
Reading package lists... Done
Building dependency tree... Done
librosp-dev is already the newest version
build-essential is already the newest version
...
# Check compiler
gcc --version
# Check if librouter is available
dpkg -l | grep librosp
If the SDK is not already present, transfer it to your device:
# Option A: Using SCP from your computer
scp RobustOS_Pro_SDK-2.4.0.tgz username@<device-ip>:~
# Option B: Using USB
# Insert USB drive and mount, then copy the file
# Extract to home directory
cd ~
tar -xzf RobustOS_Pro_SDK-2.4.0.tgz
# Navigate to SDK directory
cd RobustOS_Pro_SDK-2.4.0
# List SDK contents
ls -la
# You should see:
# create_app.sh - Application scaffolding tool
# Makefile - Build system
# docs/ - Documentation
# sample-* - Example applications
# readme.md - README file
The SDK provides a powerful tool to generate complete application templates. Let’s create a simple “Hello World” application:
# Create a simple application
./create_app.sh helloworld --type=simple --web-ui1
💡 Application Naming Tips:
Application names can only contain lowercase letters, numbers, and hyphens (-)
If you use hyphens (e.g., my-app), they will be automatically converted to underscores (my_app) for:
For this tutorial, we use helloworld (no separators) to keep things simple
What happens:
Generates complete source code with logging and signal handling
Creates Debian packaging files
Sets up Web UI configuration files (UCI/USI)
Includes service management script
Generates README documentation
Output:
RobustOS Pro SDK Application Scaffolding Tool
===============================================
[INFO] Creating application: helloworld
[INFO] Application type: simple
[INFO] Web integration: Enabled
[INFO] Version: 1.0.0
[INFO] Author: Developer <developer@example.com>
[SUCCESS] Application project created successfully!
# View the generated structure
cd helloworld
tree
# or
find . -type f
# Key files:
# src/main.c - Main application code
# files/sdk.sh - Service management script
# files/uci.xml - Web configuration interface
# files/usi.xml - Web status interface
# Makefile - Build configuration
# debian/ - Debian packaging files
# README.md - Generated documentation
# View the main application code
cat src/main.c | head -50
Key components you’ll see:
Signal handling (SIGTERM, SIGINT)
Logging integration
UCI configuration reading
USI status updates
Main loop with proper cleanup
Edit src/main.c to add your custom logic:
# Use your preferred editor
vi src/main.c
# or
nano src/main.c
Example customization - Modify the process_main_loop() function:
void process_main_loop(void) {
static int counter = 0;
counter++;
if (counter % 600 == 0) { // Log once per minute
log_info("Hello from RobustOS Pro! Counter: %d", counter);
// Update Web UI status
usi_printf("helloworld.counter", "%d", counter);
usi_update("helloworld.last_update", get_current_time());
// Your custom code here
// Example: Read sensor, process data, send to cloud, etc.
}
}
# Go back to SDK root directory
cd ~/RobustOS_Pro_SDK-2.4.0
The SDK uses automatic application discovery - no Makefile editing needed!
# List all available applications (including your new one)
make list-apps
Output:
Available applications:
- helloworld
- sample-can
- sample-cpp
- sample-crypto
- sample-dido
- sample-event
- sample-gps
- sample-network
- sample-serial
- sample-shell
- sample-uci
- sample-upload
# Build your application
make helloworld
What happens:
Compiles source code
Links against librouter and system libraries
Creates Debian package with all dependencies
Includes UCI/USI configuration files
Expected output:
make -C helloworld clean
...
Compiling src/main.c
Linking helloworld
Creating Debian package...
dpkg-deb: building package 'helloworld' in '../helloworld_1.0.0_armhf.deb'.
# Collect all generated packages
make deb-install
Result:
# Check the generated package
ls -lh install_dir/
# You should see:
# helloworld_1.0.0_armhf.deb (or arm64, depending on your platform)
ls -lh install_dir/
dpkg-deb -I install_dir/helloworld_1.0.0_arm64.deb
# Install the Debian package
sudo dpkg -i install_dir/helloworld_1.0.0_armhf.deb
# Verify installation
dpkg -l | grep helloworld
Expected output:
ii helloworld 1.0.0 armhf Simple RobustOS Pro application
This registers your application with the Web Manager:
sudo systemctl restart router
Note: This may take 10-30 seconds. Your SSH session will remain active.
# Start the application
sudo /etc/sdk/helloworld start
# Check if it's running
sudo /etc/sdk/helloworld status
Expected output:
helloworld[status] is running
# View real-time logs
sudo journalctl -f -t helloworld
Expected output:
Sep 30 10:30:15 router helloworld[12345]: helloworld v1.0.0 starting...
Sep 30 10:30:15 router helloworld[12345]: helloworld started successfully
Sep 30 10:31:15 router helloworld[12345]: Hello from RobustOS Pro! Counter: 600
Press Ctrl+C to exit log view
If you enabled --web-ui :
Open your device's Web Management Interface in a browser (e.g., http://192.168.0.1 )
Login with your credentials
Navigate to Services → helloworld
You’ll see:
Basic Settings Tab: Options to enable/disable, set log level, update interval, and debug mode
Status Tab: Real-time application status, uptime, last update time, running counter, and error count
For detailed Web UI usage, see Step 6.6.
# Check process is running
ps aux | grep helloworld
# Check PID file
cat /var/run/helloworld.pid
# View last 20 log lines
sudo journalctl -t helloworld -n 20
Instead of installing via SSH command line (Step 5.1), you can install the deb package through the device's Web Management Interface.
Open your web browser
Navigate to your device's IP address:
http://<device-ip>
Example: http://192.168.0.1
Enter your credentials:
Username: admin or your sudo user account
Password: admin or your sudo user password
Click LOGIN
Click on the System menu in the left sidebar
Select App Center from the submenu
A file upload field
A Choose File button
An Install button
install_dir/helloworld_1.0.0_arm64.deb
(or helloworld_1.0.0_armhf.deb depending on your device architecture)
Click Install
Wait for the upload to complete (you'll see a progress bar showing 100%)
A dialog will appear: "Operation successfully completed. Do you want to restart immediately?"
Click OK to restart the router service immediately (recommended)
Or click Cancel to restart manually later
After successful installation with --web-ui option, your application will have its own management page in the Web interface.
Important: You must click OK to restart the router service (or manually restart) for the application's Web UI to become available in the Services menu.
Navigate to Services → helloworld in the left sidebar
You'll see two tabs:
Configure your application settings:
Enable helloworld: ON/OFF toggle to enable or disable the application
Log Level: Select logging verbosity (Debug, Info, Warning, Error)
Update Interval (seconds): Configure how often the application updates (default: 60 seconds)
Debug Mode: Enable or disable debug mode
Click Submit to save changes, or Cancel to discard.
View real-time application status information:
Application Status:
Application Status: Current running state
Uptime (minutes): How long the application has been running
Last Update Time: Timestamp of the last status update
Application Statistics:
Running Counter: Number of successful execution cycles
Error Count: Number of errors encountered
The status page updates automatically based on the USI (User Status Interface) updates in your application code.
From the App Center (System → App Center), you can:
View application status: Check if it's running or stopped
Uninstall: Click the delete icon to remove the application
Monitor: View the application in the installed apps list
Note: For detailed application logs and advanced management, you can still use SSH commands as described in Step 5.