FAQ of iMX6 Series Development Board

This article is based on Forlinx dev board: SBC OKMX6Q/OKMX6DL-C. This series uses i.MX6Q/DL processors. The system for demonstrating is linux3.0.35. For dev boards of other brands, please refer to use.

This article introduces the solutions to three problems of iMX6 platform: users' automatic login, self-starting after booting, and loading QT program into the main interface.


Question 1: How to achieve automatic login of iMX6Q dev board

The file system provided in User Profile requires user to log in to operate after iMX6Q dev board is started. Some users want to achieve automatic user login according to their own practices, without manual input. To help our users, Forlinx has tested the following methods to achieve it.

Modify as follows:

There is a soft link login for automatic login in the bin directory of file system, while Login authentication is implemented by etc/rc.d/rc_mxc.S. To achieve automatic login, user can pass parameters to the link to directly log in to root account.


Modify rc_mxc.S as below:

#!/bin/bash
#
/bin/login -f root          //Directly pass the parameters of root login
/*
if grep -sq ttymxc0 /proc/cmdline; then
/sbin/getty -L ttymxc0 115200 vt100
elif grep -sq ttymxc1 /proc/cmdline; then
/sbin/getty -L ttymxc1 115200 vt100
elif grep -sq ttymxc2 /proc/cmdline; then
/sbin/getty -L ttymxc2 115200 vt100
elif grep -sq ttymxc3 /proc/cmdline; then
/sbin/getty -L ttymxc3 115200 vt100
else
sleep 100000
*/
fi

If operate on iMX6 dev board, execute sync after the file modified and saved, and then restart i.MX6 dev board.

User can also modify it in file system of iMX6 User Profile, repackaged into a flashable format after modification, and then flash it.


Question 2: How to achieve self-starting of user’s QT application after booting

The following is how to set the application made by user to run directly on iMX6Q dev board after booting. Here Forlinx takes Music as an example, assuming the file is placed in path /opt/qt4.8.5/apps. Please follow the actual file name and path for user own practices.

Modify startup script

After OKMX6 series platform is powered on, desktop program fluidlauncher of QT system is launched by default. To change to start other QT applications by default, modify /etc/rc.d/apps.sh of file system. If operates on iMX6Q dev board, execute the following commands in HyperTerminal:

root@freescale /$ vi /etc/rc.d/apps.sh

Modify apps.sh to the following via command: vi

#!/bin/sh
#app
#cd /opt/qt4.8.5/demos/embedded/fluidlauncher
#./fluidlauncher -qws &
cd /opt/qt4.8.5/apps
./music -qws &
#apps

After the file saved, execute sync, and restart. User will see the application just set is started by default.

User can also modify etc/rc.d/apps.sh in file system. The modification method is same as the above, and then re-create file system image and flash it to platform.


Question 3: How to load User’s QT program into main interface

The following method is how to load user own QT program to main interface of desktop.

Here takes Music as an example:

1. Modify in file system

Modify opt/qt4.8.5/demos/embedded/fluidlauncher/config.xml:

Open it and at the next line ofAdd

Remember to save after added.

2. Add APP's desktop icon

Add image music.png in opt/qt4.8.5/demos/embedded/fluidlauncher/screenshots/apps, which is used as main interface to identify Music.

3. Add executable program

Add the executable file Music compiled by user self in opt/qt4.8.5/apps, and authorize executable permission to the executable file via command: chmod.

4. Save and apply

If the above are performed on dev board, after operations completed, user need to execute sync to save, then restart dev board. User will see Music in main interface.

User can also modify in file system of User Profile. After the modification is completed, repackage it and flash to iMX6Q dev board.