Skip to main content

System Configuration

1. Language Settings

  1. Use Vim to edit the /etc/locale.gen file, comment out unnecessary locales, and enable the required ones.

    vim /etc/locale.gen
  2. To switch from Chinese to English, perform the following actions in the file.

    Comment out the line: zh_CN.UTF-8 UTF-8.
    Uncomment the line: en_US.UTF-8 UTF-8.
  1. Use the dpkg-reconfigure command to regenerate the locale files non-interactively:

    dpkg-reconfigure -f noninteractive locales

2. Auto-Start Configuration

This section takes the GPIO program as an example for auto-start. The absolute path of the program is /home/luckfox/gpio.py. Please adjust the file paths according to your actual setup.

2.1 Desktop Auto-Start

  1. First, create a startup.sh script using the following command (Omni3566 by default is located in /home/luckfox):

    sudo touch startup.sh
  2. Open the startup.sh script and add the following content:

    #!/bin/sh
    sudo python3 gpio.py
  3. Grant execute permissions to the startup.sh script:

    sudo chmod 777 startup.sh
  4. Create the autostart directory and file:

    cd .config && mkdir autostart
    cd autostart && sudo nano start.desktop
  5. Add the following content to the start.desktop file:

    [Desktop Entry]
    Type=Application
    Exec=/home/luckfox/startup.sh
  6. Reboot the system:

    sudo reboot

2.2 Add Auto-Start in rc.local Script

  1. Open the /etc/rc.local script and add the following line before exit 0:

    sudo python3 /home/luckfox/gpio.py &
  2. Reboot the Core3576:

    sudo reboot

2.3 Set Auto-Start via System Manager

  1. Create an auto-start service configuration file in /etc/systemd/system/gpio.service and add the following content:

    [Unit]
    Description=start oled

    [Service]
    Type=simple
    Restart=always
    RestartSec=5
    ExecStart=/home/luckfox/gpio.py

    [Install]
    WantedBy=multi-user.target
  2. Enable a service so that it starts automatically at system boot:

    sudo systemctl enable gpio.service
  3. Reboot:

    sudo systemctl restart gpio.service
  4. Reboot Omni3576:

    sudo reboot
  5. If you want to disable a service so that it does not start automatically at system boot:

    sudo systemctl disable gpio.service

3. Installing Input Method

  1. Install the desktop terminal application.

    sudo apt update
    sudo apt install xfce4-terminal
  2. Install the IBUS input method framework and related components.

    sudo apt update
    sudo apt install ibus-gtk ibus-gtk3 ibus ibus-libpinyin ibus-wayland at-spi2-core
  3. Start the IBUS background service.

    ibus-daemon -drx
  4. Configure the Chinese input method.

    ibus-setup
    • In the setup window:
      • Navigate to Input Method -> Add
      • Select Chinese -> Intelligent Pinyin

      • Click Close to exit
  5. Reboot the development board.

    reboot
    • After rebooting, left-click the keyboard icon in the upper-right corner and select Chinese.
  6. Install the im-config configuration tool and set IBUS as the default input method framework.

    sudo apt install im-config
    im-config -n ibus