Skip to main content

14. armsom-overlay Configuration

1. Introduction​

Device-tree overlays apply incremental changes to the base device tree at boot, configuring pin multiplexing, peripherals, cameras and displays. On ArmSoM OS (Debian 12), you can use the armsom-overlay terminal menu or edit the boot configuration directly. Both methods require a reboot to apply changes.

2. Supported Images​

ImageConfiguration method
ArmSoM OS (custom Debian 12)Use the menu in Section 3 or edit /boot/uEnv/uEnv.txt manually.
Ubuntu 22.04 built with the ArmSoM SDKEdit the board's uEnv file.
Ubuntu with /boot/firmware/ubuntuEnv.txtEdit ubuntuEnv.txt.
ArmbianEdit /boot/armbianEnv.txt.

3. Configure with the armsom-overlay Menu​

The menu is available only on ArmSoM OS (custom Debian 12). The screenshots below show a CM5. On ArmSoM SDK Ubuntu 22.04, use manual uEnv configuration.

3.1 Open the Menu​

Run this command in a desktop terminal, SSH session or serial terminal on the board:

sudo armsom-overlay

When logged in as root, run armsom-overlay directly. A graphical desktop is not required. The tool reads the current board configuration referenced by /boot/uEnv/uEnv.txt and lists its available overlays. The actual configuration filename appears at the top; available options depend on the board's configuration.

armsom-overlay configuration menu showing CM5 peripheral and camera options
armsom-overlay configuration menu, using CM5 as an example
Command not found

If the command is missing on an older ArmSoM OS image, use manual uEnv configuration or install a newer ArmSoM OS image for your board. The menu is part of the root filesystem.

3.2 Select Peripherals​

[ ] means unselected and [*] means selected. Check the peripheral model, connector and pin assignment in your product documentation before changing options.

KeyAction
Up / DownMove through the peripheral list
SpaceSelect or deselect the current overlay
TabSwitch between the list and the button bar
Left / RightMove between buttons
EnterActivate the selected button; in the list, move focus to Save without writing the configuration yet
EscOpen the exit review dialog
F1 / Ctrl+LShow help / resize and redraw the interface

The buttons provide these actions: Select returns to the list, Save writes changes and stays in the menu, Help displays help, and Exit opens the review dialog.

For example, on CM5 select raspberrypi-camera-v2 (imx219-cs0) for an IMX219 connected to J25, or armsom-camera-m1 (ov13850-cs1) for an OV13850 connected to J12. Power off before connecting or changing camera ribbon cables. On other boards, select options matching their connectors.

Option meanings and pin sharing

Selecting hdmi-disabled or dp-disabled disables that display output. Deselecting an overlay removes its overrides and restores the base device-tree settings; it does not always disable a device. Do not enable options that conflict over pins or controllers. The tool checks only conflicts declared in metadata, so also consult your board's pin assignments.

3.3 Confirm, Save and Reboot​

  1. After selecting your options, press Esc, or select Exit and press Enter, to open Review.
  2. Check the changes: Enable adds an overlay and Remove removes one.
  3. Use Left/Right or Tab to select OK, then press Enter to save pending changes and exit. Select Back to continue editing. Review initially selects Back.
Review dialog showing the OV13850 camera being enabled; OK saves and exits
Review the changes, then select OK to save and exit

After exiting, run:

sudo reboot
Saving does not apply changes immediately

The tool saves selections by commenting or uncommenting dtoverlay= lines in the current board's configuration. They take effect after a reboot. Back does not undo a save: changes already written with Save remain. To restore earlier selections, change them back in the menu and save again.

3.4 Check the Configuration and Hardware​

After rebooting, these read-only commands list the saved selections and validate the configuration and corresponding DTBO files:

sudo armsom-overlay --list
sudo armsom-overlay --check

A successful configuration check does not verify hardware operation. Use ArmSoM Camera Applications to check camera preview, and follow the product and interface guides for UART or other peripherals. If the menu does not fit, enlarge the terminal to at least 80 columns × 20 rows and press Ctrl+L to redraw it.

4. Configure Overlays Manually​

4.1 Ubuntu images using ubuntuEnv.txt​

If your image uses /boot/firmware/ubuntuEnv.txt, edit its overlays= line. The available overlays are in /boot/firmware/dtbs/rockchip/overlay/. This Sige7 example enables two overlays:

overlays=armsom-sige7-camera-imx415-4k armsom-sige7-display-10hd

Save the file and reboot for the changes to take effect.

4.2 Enable overlay for Armbian images​

  • The overlay file of the Armbian image is stored in the path on the board:/boot/dtb/rockchip/overlay/*.dtbo
  • Find or add the keyword 'overlays=' in the /boot/armbianEnv.txt file. The following is an example of using two overlay layers for ArmSoM Sige7.
overlays=armsom-sige7-camera-imx415-4k armsom-sige7-display-10hd

After editing, restart the device to change the overlay settings.

  • Armbian images can have overlay files added to them: Taking the addition of Sige5 UART10 functionality as an example:
linux-rockchip/arch/arm64/boot/dts/rockchip/overlay$ git remote -v
origin git@github.com:xxx/linux-rockchip.git (fetch)
origin git@github.com:xxx/linux-rockchip.git (push)
upstream git@github.com:armbian/linux-rockchip.git (fetch)
upstream git@github.com:armbian/linux-rockchip.git (push)

Download the linux-rockchip to your local system, refer to other dts files related to serial ports in the arch/arm64/boot/dts/rockchip/overlay directory, and modify the KERNELSOURCE in config/sources/families/rk35xx.conf to point to the local code

4.3 ArmSoM SDK images using uEnv.txt​

On ArmSoM SDK Ubuntu 22.04 and ArmSoM OS (Debian 12), /boot/uEnv/uEnv.txt points to the current board's configuration. Open its target file:

sudo vi "$(readlink -e /boot/uEnv/uEnv.txt)"

Find the existing dtoverlay= line for your peripheral. Remove the leading # to enable it, or add # to stop loading it. For example, this line enables I²C0 M1 on Sige7:

dtoverlay=/dtb/overlay/rk3588-armsom-i2c0-m1.dtbo

Choose an entry listed for your board. The matching DTBO files are in /boot/dtb/overlay/. Save the file and run sudo reboot.

5. 40-PIN functional test​

Some of the pins on the 40PIN can be reused for multiple functions, which can be configured as needed. For specific pin functions, please refer to the 40 pin header on the board.

Taking the 11 and 15 pins in the 40PIN on Sige7 to open the serial port function as an example:

  • View the serial ports opened by the system
root@armsom-sige7 :/boot# ls /dev/ttyS*
/dev/ttyS6
  • Open overlay

The serial ports corresponding to pins 11 and 15 on the 40PIN are UART 7_m1, and the corresponding overlay file is/boot/dtb/rockchip/overlay/rk3588-uart7-m1.dtbo.

Edit/boot/armbianEnv. txt file:

root@armsom-sige7 :/boot# cat armbianEnv.txt
verbosity=1
bootlogo=false
console=both
overlay_prefix=rockchip-rk3588
overlays=rk3588-uart7-m1
fdtfile=rockchip/rk3588-bananapi-m7.dtb
rootdev=UUID=a61c17cd-2e49-4302-879c-6cb86ebf07d1
rootfstype=ext4
usbstoragequirks=0x2537:0x1066:u,0x2537:0x1068:u

Only the line overlays= has been added here.

Configuration takes effect after restart:

root@armsom-sige7 :/boot# ls /dev/ttyS*
/dev/ttyS6 /dev/ttyS7
tip

The functions in the 40PIN are turned off by default and need to be manually turned on to use

Add configuration in/boot/armbianEnv. txt and restart the Linux system to take effect

If only one function needs to be opened, just fill in one. If there are multiple functions, separate them with spaces after overlays= overlays=uart2-m0 uart3-m1 uart4-m2 uart7-m1

Similar to UART 7-m1 and UART 7-m2, they cannot be used simultaneously

Contact us