System Configuration
1. Language Settings
-
Use Vim to edit the
/etc/locale.gen
file, comment out unwanted language environments and enable required language environments. -
To switch from Chinese to English, perform the following operations in the file:
# Comment out the zh_CN.UTF-8 UTF-8 line
# Uncomment the en_US.UTF-8 UTF-8 line
- Use the
dpkg-reconfigure
command to regenerate locale files non-interactively:
dpkg-reconfigure -f noninteractive locales
2. Auto-start Configuration
This section uses a GPIO program as an example for auto-start, with the absolute path being /home/linaro/gpio.py
. Please modify corresponding locations according to your actual files and paths.
2.1 Desktop Auto-start
- First, create a new
startup.sh
using the following command: (K1 Pro default in/home/linaro
)
touch startup.sh
- Open the
startup.sh
script file and enter the following content:
#!/bin/sh
sudo python3 gpio.py
- Grant permissions to the
startup.sh
script file:
sudo chmod 777 startup.sh
- Create auto-start file:
cd .config && mkdir autostart
cd autostart && sudo nano start.desktop
- Enter the following content:
[Desktop Entry]
Type=Application
Exec=/home/linaro/startup.sh
- Restart:
sudo reboot
2.2 Adding Auto-start in rc.local Script
- Open
/etc/rc.local
script and add a line beforeexit 0
:
sudo python3 /home/linaro/gpio.py &
- Restart:
sudo reboot
2.3 System Manager Auto-start Settings
- Create a new configuration file for the auto-start service at
/etc/systemd/system/gpio.service
, enter the following content:
[Unit]
Description=start oled
[Service]
Type=simple
Restart=always
RestartSec=5
ExecStart=/home/linaro/gpio.py
[Install]
WantedBy=multi-user.target
- Enable a service to auto-start at system boot:
sudo systemctl enable gpio.service
- Restart:
sudo systemctl restart gpio.service
- Restart Omni3576:
sudo reboot
- If you want to disable a service from auto-starting at system boot:
sudo systemctl disable gpio.service
3. Chinese Input Method Installation
- Install desktop terminal software.
sudo apt update
sudo apt install xfce4-terminal
- Install IBUS input method and related components.
sudo apt update
sudo apt install ibus-gtk ibus-gtk3 ibus ibus-libpinyin ibus-wayland at-spi2-core
- Start IBUS input method background service.
ibus-daemon
-
Configure Chinese input method.
- In the pop-up settings window:
- Select Chinese -> Intelligent Pinyin
-
Restart the development board
sudo reboot
- Then left-click the keyboard icon in the top right corner, select Chinese.
-
Install
im-config
configuration tool and set IBUS as the default input method framework
sudo apt install im-config
im-config -n ibus