3. Debian Application

Account: linaro; Password: linaro

3.1 Serial Terminal

_images/debug.webp

Connect the board and PC with USB Serial cable, then power on, the terminal will output boot information. The default baudrate is 1500000.

Terminal_UI

3.2 Display

MIPI_DSI

Connect the board and MIPI LCD (default 800×1280 @60Hz), then start up.

_images/MIPI_display_Debian.webp

3.3 USB

_images/USB.webp

3.3.1 USB3.0 DRD

The SBC1126B USB3.0 supports both Host and Device roles, with Device as the default configuration.

Switch USB3.0 DRD back to USB Host mode.

1echo host > /sys/kernel/debug/usb/21500000.usb/mode

Switch USB3.0 DRD to USB device mode.

1echo device > /sys/kernel/debug/usb/21500000.usb/mode

3.3.2 USB Host

The USB2.0 Host can connect peripherals such as mouse, keyboards, and flash drives.

After a USB flash drive is inserted and recognized successfully, a removable media dialog box will pop up automatically.

Debian_Test_USB

Keep Open in File Manager selected and click OK. The system will then open the USB flash drive directory, and users can access the files on the USB flash drive.

Debian_Test_USB

The current USB connection speed can be checked from the kernel log. When the device operates in USB2.0 mode, the log usually shows high-speed. When the device operates in USB3.0 mode, the log usually shows SuperSpeed.

3.4 Audio

Audio

3.4.1 Audio Output

❶ Connect the Speaker to the connector (2-pin/2.0mm pitch)

❷ Set the DAC digital volume.

1amixer -c 0 cset name='DAC Digital Volume' 250,250

❸ Play the audio file.

Execute command according to the actual audio file path, eg. /media/linaro/F3AB-0FF3/video/music/2.wav

1aplay -D hw:0,0 /media/linaro/F3AB-0FF3/video/music/2.wav

3.4.2 Audio Input

SBC1126B supports MIC recording and Loopback.
  • MIC recording captures outside sounds (e.g., voice) for storage, transmission, or voice commands.

  • Loopback captures the device’s own playback as a reference signal. It is primarily used for Acoustic Echo Cancellation (AEC) and audio monitoring. It is a tool for signal processing, not an audio recording of the environment.

❶ Connect the MIC to the connector (2-pin/2.0mm pitch).

❷ Execute the commands.

1amixer -c 0 cset name='SAI2 Receive PATH0 Source Select' 'From SDI0'   //Select MIC0 as the recording input source
2amixer -c 0 cset name='ACodec Digital Gain Volume' 100   //Set the audio codec digital gain
3arecord -D hw:0,0 -f cd -t wav test.wav   //Record audio from MIC0
4aplay -D hw:0,0 test.wav   //Play the recorded audio through the speaker
Serial terminal output
root@linaro-alip:/#amixer -c 0 cset name='SAI2 Receive PATH0 Source Select' 'From SDI0'
numid=29,iface=MIXER,name='SAI2 Receive PATH0 Source Select'
 ; type=ENUMERATED,access=rw------,values=1,items=4
 ; Item #0 'From SDI0'
 ; Item #1 'From SDI1'
 ; Item #2 'From SDI2'
 ; Item #3 'From SDI3'
 : values=0
root@linaro-alip:/# amixer -c 0 cset name='ACodec Digital Gain Volume' 100
numid=44,iface=MIXER,name='ACodec Digital Gain Volume'
 ; type=INTEGER,access=rw---R--,values=1,min=0,max=127,step=0
 : values=100
 | dBscale-min=-95.00dB,step=0.75dB,mute=0
root@linaro-alip:/#
root@linaro-alip:/# arecord -D hw:0,0 -f cd -t wav test.wav
Recording WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
^CAborted by signal Interrupt...
root@linaro-alip:/#
root@linaro-alip:/# aplay -D hw:0,0 test.wav
Playing WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo

3.5 Ethernet

_images/Ethernet.webp

The 100M Ethernet and 1000M Ethernet interfaces on the SBC1126B are multiplexed and cannot be used at the same time. When switching between them, the corresponding firmware image must be updated in software, and the hardware selection must also be changed using the DIP switch on the development board.

DTS Configuration Switching Instructions File path kernel-6.1\arch\arm64\boot\dts\rockchip\boardcon-sbc1126b.dts

//#include "boardcon-sbc1126b-gephy.dtsi" //1000M
#include "boardcon-sbc1126b-fephy.dtsi"   //100M

3.5.1 100M Ethernet

❶ Connect the network cable to the 100M Ethernet port, and set the DIP switch to the 100M position.

Serial terminal output
root@linaro-alip:/# [  447.452298] rk_gmac-dwmac 21c70000.ethernet end0: Link is Up - 100Mbps/Full - flow control rx/tx
[  447.452318] IPv6: ADDRCONF(NETDEV_CHANGE): end0: link becomes ready

❷ View the status of the network interface.

1ifconfig end0
Serial terminal output
root@linaro-alip:/# ifconfig end0
end0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.0.175  netmask 255.255.255.0  broadcast 192.168.0.255
        inet6 fe80::f0f0:b7ba:cb75:eaa  prefixlen 64  scopeid 0x20<link>
        ether 2e:cd:2f:8a:a1:64  txqueuelen 1000  (Ethernet)
        RX packets 40745  bytes 29660674 (28.2 MiB)
        RX errors 0  dropped 2195  overruns 0  frame 0
        TX packets 6682  bytes 428612 (418.5 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device interrupt 79

❸ Ping URL to test Network.

1ping -I end0 www.armdesigner.com
Serial terminal output
root@linaro-alip:/# ping -I end0 www.armdesigner.com
PING d3dsoj86mhwkk6.cloudfront.net (18.64.122.52) from 192.168.0.175 end0: 56(84) bytes of data.
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=1 ttl=242 time=163 ms
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=2 ttl=242 time=163 ms
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=3 ttl=242 time=163 ms
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=4 ttl=242 time=163 ms
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=5 ttl=242 time=162 ms
64 bytes from server-18-64-122-52.nrt12.r.cloudfront.net (18.64.122.52): icmp_seq=6 ttl=242 time=163 ms
^C
--- d3dsoj86mhwkk6.cloudfront.net ping statistics ---
7 packets transmitted, 6 received, 14.2857% packet loss, time 14406ms
rtt min/avg/max/mdev = 162.277/162.577/162.765/0.157 ms

3.5.2 1000M Ethernet

❶ Connect the network cable to the 1000M Ethernet port, and set the DIP switch to the 1000M position.

Serial terminal output
root@linaro-alip:/# [   58.028698] rk_gmac-dwmac 21c70000.ethernet end0: Link is Up - 1Gbps/Full - flow control rx/tx
[   58.028767] IPv6: ADDRCONF(NETDEV_CHANGE): end0: link becomes ready

❷ View the status of the network interface.

1ifconfig end0

❸ Ping URL to test Network.

1ping -I end0 www.armdesigner.com

3.6 SD Card

SD

After the micro SD card is inserted and recognized successfully, a removable media dialog box will pop up automatically.

Debian_test_SD

Keep Open in File Manager selected and click OK. The system will then open the micro SD card directory, and users can access the files on the micro SD card.

Debian_test_SD

3.7 WiFi & Bluetooth

WiFi&BT

3.7.1 WiFi

❶ Connect the WiFi antenna.

❷ Click the network icon in the bottom-right corner of the UI interface.

❸ Select the SSID from the list of available networks and enter the password.

_images/Debian_Test_WIFI.webp

❹ After connected, user can open Browser or ping URL/IP at terminal to test network.

_images/Debian_WIFI_connect.webp
1ifconfig
2ping -I wlan0 www.armdesigner.com

3.7.2 Bluetooth

❶ Click the Bluetooth icon in the bottom right corner of the UI interface.

Debian_Test_BT_1

❷ The Bluetooth device name is hidden by default. Set the Bluetooth device name to be visible. Click Adapter -> Preferences -> Always visible

_images/Debian_Test_BT_2.webp
_images/Debian_Test_BT_2-2.webp

❸ Click Search to start searching and select the available device in the list to pair.

_images/Debian_Test_BT_3.webp

After pairing, devices can connect with each other automatically.

3.8 IR

IR

❶ Connect the IR receiver.

❷ Open IR debugging print.

1echo 1 > /sys/module/rockchip_pwm_remotectl/parameters/code_print

❸ Press remote button, key value printed to log.

Serial terminal output
root@linaro-alip:/# echo 1 > /sys/module/rockchip_pwm_remotectl/parameters/code_print
root@linaro-alip:/#
[ 1274.657882] USERCODE=0xc00
[ 1274.683832] RMC_GETDATA=33
[ 1276.005540] USERCODE=0x1818
[ 1276.032607] RMC_GETDATA=99
[ 1276.492593] USERCODE=0xc00
[ 1276.517441] RMC_GETDATA=32
[ 1276.983249] USERCODE=0x300
[ 1278.009855] USERCODE=0xc001
[ 1278.238809] USERCODE=0x1
[ 1278.392047] USERCODE=0x1818

3.9 RS485

RS485

❶ Connect PC and board with USB-to-RS485 adapter.

RS485 connection

RS485 connection

❷ Open the Serial Terminal and set baud rate for the board and RS485 adapter respectively.

Baud rate: board - 1500000; RS485 adapter - 115200

_images/Debian_RS485_baudrate.png

❸ Execute command on the terminal serial port of board.

1com /dev/ttyS5 115200 8 0 1       //RS485_0

❹ Input character to test RS485 communication.

_images/Debian_RS485_0_Test.png

❺ Press Ctrl+C to exit RS485_0 testing.

❻ Test RS485_1.

1com /dev/ttyS6 115200 8 0 1
_images/Debian_RS485_1_Test.png

3.10 UART

UART connect

❶ Connect RX and TX of UART.

❷ Execute command and input character to test.

1com /dev/ttyS4 115200 8 0 1
Serial terminal output
root@linaro-alip:/# com /dev/ttyS4 115200 8 0 1
port = /dev/ttyS4
baudrate = 115200
cs = 8
parity = 0
stopb = 1
12345678
RECV: 12345678
abcdefg
RECV: abcdefg

3.11 CAN

CAN

❶ Connect PC and board with USB-to-CAN adapter.

CAN connection

CAN connection

❷ Open the CAN application and set the baudrate to 500000 on PC.

_images/Debian_CAN_baudrate.png

❸ Configure and enable the CAN0 on the board with a bitrate of 500000.

1ip link set can0 down
2ip link set can0 type can bitrate 500000
3ip link set can0 up

❹ Configure CAN0 as receiver.

1candump can0
_images/Debian_CAN_receiver.png

❺ Set CAN0 as Transmitter.

1cansend can0 123#DEADBEEFDEADBEEF
_images/Debian_CAN_Transmitter.png

The tests for CAN1 are similar to those for CAN0. Simply replace can0 with can1.

3.12 SPI

SPI

❶ Connect MOSI and MISO of SPI.

❷ SPI loopback test.

1test_spi 1 0
Serial terminal output
root@linaro-alip:/# test_spi 1 0
device= /dev/spidev1.0
spi mode: 0
bits per word: 8
max speed: 5000000 Hz (5000 KHz)

FF FF FF FF FF FF
40 00 00 00 00 95
FF FF FF FF FF FF
FF FF FF FF FF FF
FF FF FF FF FF FF
DE AD BE EF BA AD
F0 0D

3.13 ADC

ADC

Connect the ADC pin to two different voltage levels within 0~1.8V respectively. For each level, after setting the pin to that level, execute the test command.

1cat /sys/bus/iio/devices/iio:\device0/in_voltage1_raw   //test ADC1
Serial terminal output
root@linaro-alip:/# cat /sys/bus/iio/devices/iio:\device0/in_voltage1_raw
8191
root@linaro-alip:/# cat /sys/bus/iio/devices/iio:\device0/in_voltage1_raw
7

For other ADC read commands, refer to the ADC read command description below.

Single-channel read commands
1cat /sys/bus/iio/devices/iio:\device0/in_voltage1_raw   //ADC1
2cat /sys/bus/iio/devices/iio:\device0/in_voltage2_raw   //ADC2
3cat /sys/bus/iio/devices/iio:\device0/in_voltage3_raw   //ADC3
4cat /sys/bus/iio/devices/iio:\device0/in_voltage4_raw   //ADC4
5cat /sys/bus/iio/devices/iio:\device0/in_voltage5_raw   //ADC5
6cat /sys/bus/iio/devices/iio:\device0/in_voltage6_raw   //ADC6
Read all ADC1–ADC6 raw values
1for i in 1 2 3 4 5 6; do
2    echo -n "ADC$i: "
3    cat /sys/bus/iio/devices/iio:\device0/in_voltage${i}_raw
4done

3.14 RTC

RTC

The RTC on the SBC1126B is powered by a supercapacitor.

❶ Set the system time manually.

1date -s "2026-06-17 17:56:00"

If the network is connected, the system time may be synchronized automatically to the current UTC time.

❷ set the hardware clock to current system time.

1hwclock -w

❸ Display date and time.

1hwclock

❹ Power off the board and disconnect the main power supply. Wait for a period of time, then power on the board again.

❺ Read the hardware clock time again.

1hwclock

If the RTC is working properly, the hardware clock time should be retained and continue running after power-off.

3.15 Battery Supply

BAT

❶ Connect the Li-ion battery(7.4V) to the BAT connector.

❷ Read the current battery capacity percentage.

1cat /sys/class/power_supply/cw221X-bat/capacity

❸ Read the current battery voltage.

1cat /sys/class/power_supply/cw221X-bat/voltage_now

Attention

Currently, only basic battery status reading is supported. Since the battery capacity curve has not been calibrated, the capacity percentage is for reference only.

3.16 Camera

Camera

❶ Connect the camera to the board and power on.

❷ Check the camera preview device nodes.

1grep "" /sys/class/video4linux/v*/name | grep mainpath
Serial terminal output
root@linaro-alip:/# grep "" /sys/class/video4linux/v*/name | grep mainpath
/sys/class/video4linux/video44/name:rkisp_mainpath
/sys/class/video4linux/video52/name:rkisp_mainpath
/sys/class/video4linux/video60/name:rkisp_mainpath
/sys/class/video4linux/video68/name:rkisp_mainpath

❸ Preview camera.

1gst-launch-1.0 v4l2src device=/dev/video44 ! video/x-raw,format=NV16,width=1920,height=1080, framerate=25/1 ! kmssink
Serial terminal output
root@linaro-alip:/# gst-launch-1.0 v4l2src device=/dev/video44 ! video/x-raw,format=NV16,width=1920,height=1080, framerate=25/1 ! kmssink
mpp[3153]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crashamerate=25/1 ! kmssink
mpp[3153]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[3153]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[3153]: mpp: unable to create enc vp8 for soc rv1126b unsupported
mpp[3153]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
[  163.521393] rkvpss-offline: CLK_CORE_VPSS set to 396000000 Hz (requested 400000000 Hz)
[  164.273559] rkvpss-offline: CLK_CORE_VPSS set to 396000000 Hz (requested 400000000 Hz)
Setting pipeline to PAUSED ...
Using mplane plugin for capture
Pipeline is live and does not need PREROLL ...
        Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
[  164.353646] rkisp_hw 21d00000.isp: set isp clk = 297000000Hz
[  164.355762] rkcif-mipi-lvds: stream[0] start streaming
[  164.356019] rockchip-mipi-csi2 mipi0-csi2: stream on, src_sd: 00000000860eb766, sd_name:rockchip-csi2-dphy1
[  164.356040] rockchip-mipi-csi2 mipi0-csi2: stream ON
[  164.356088] rockchip-csi2-dphy1: dphy1, data_rate_mbps 742
[  164.356117] rockchip-csi2-dphy csi2-dphy1: csi2_dphy_s_stream stream on:1, dphy1, ret 0
[  164.356130] sc200ai 5-0030: 1920x1080@10, mode 0, vts 0x1a5e
Redistribute latency...
0:00:27.0 / 99:99:99

3.17 Video Playback

3.17.1 Built-in playback

The script instruction directory is in /rockchip-test/video/, just run it.

root@linaro-alip:/# /rockchip-test/video/test_gst_video.sh
[  130.441969] dw9714 3-000c: cmd 0x80685600 not supported
[  130.442393] dw9714 4-000c: dw9714_set_power(1046) on(1)
[  130.479174] dw9714 4-000c: cmd 0x80685600 not supported
[  130.502451] dw9714 4-000c: dw9714_set_power(1046) on(0)
[  130.504096] rkvpss-offline: CLK_CORE_VPSS set to 396000000 Hz (requested 400000000 Hz)
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Redistribute latency...
mpp[2161]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2161]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2161]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2161]: mpp: unable to create enc vp8 for soc rv1126b unsupported
mpp[2161]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2161]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
Redistribute latency...
mpp[2161]: h264d_api: is_avcC=1
mpp[2161]: mpp_buf_slot: mismatch h_stride_by_pixel 1472 - 1280
mpp[2161]: mpp_buf_slot: mismatch h_stride_by_byte 1472 - 1280
mpp[2161]: mpp_buf_slot: mismatch size_total 1589760 - 1843200
mpp[2161]: mpp_buf_slot: mismatch h_stride_by_pixel 1472 - 1280
mpp[2161]: mpp_buf_slot: mismatch h_stride_by_byte 1472 - 1280
mpp[2161]: mpp_buf_slot: mismatch size_total 1589760 - 1843200
Pipeline is PREROLLED ...
Prerolled, waiting for async message to finish...
Setting pipeline to PLAYING ...
Redistribute latency...
New clock: GstSystemClock
0:00:02.9 / 0:00:29.5 (10.0 %

3.17.2 Command line

1export GST_MPP_VIDEODEC_DEFAULT_ARM_AFBC=1
2gst-play-1.0 --flags=3 --videosink="kmssink plane-id=74" /media/linaro/F3AB-0FF3/video/4KP30/4K30P-BLACKPINK-DDU-DU_DDU-DU.mp4 --audiosink="alsasink device=hw:0,0"

Command explanation:

  • export GST_MPP_VIDEODEC_DEFAULT_ARM_AFBC=1: Open AFBC.

  • --videosink="kmssink plane-id=74": Specifies the plane. Which can be viewed using the command cat /sys/kernel/debug/dri/0/state | grep “plane[”

  • /media/linaro/F3AB-0FF3/video/4KP30/4K30P-BLACKPINK-DDU-DU_DDU-DU.mp4: The media file path to be played.

  • --audiosink="alsasink device=hw:0,0": Specifies the audio output device as hw:0,0.

Serial terminal output
root@linaro-alip:/# export GST_MPP_VIDEODEC_DEFAULT_ARM_AFBC=1         gst-play-1.0 --flags=3 --videosink="kmssink plane-id=74" /media/linaro/F3AB-0FF3/video/4KP30/4K30P-BLACKPINK-DDU-DU_DDU-DU.mp4 --audiosink="alsasink device=hw:0,0"INK-DDU-DU_DDU-DU.mp4 --audiosink="alsasink device=hw:0,0"
Press 'k' to see a list of keyboard shortcuts.
Now playing /media/linaro/F3AB-0FF3/video/4KP30/4K30P-BLACKPINK-DDU-DU_DDU-DU.mp4
Redistribute latency...
mpp[2887]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2887]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2887]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2887]: mpp: unable to create enc vp8 for soc rv1126b unsupported
mpp[2887]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
mpp[2887]: mpp_info: mpp version: 520ab553 author: Herman Chen   2025-12-16 fix[sys_cfg]: Fix decoder sys_cfg crash
Redistribute latency...
mpp[2887]: h264d_api: is_avcC=1
mpp[2887]: mpp_buf_slot: mismatch h_stride_by_pixel 4032 - 3840
mpp[2887]: mpp_buf_slot: mismatch h_stride_by_byte 4032 - 3840
mpp[2887]: mpp_buf_slot: mismatch size_total 13063680 - 16588800
mpp[2887]: mpp_buf_slot: mismatch h_stride_by_pixel 4032 - 3840
mpp[2887]: mpp_buf_slot: mismatch h_stride_by_byte 4032 - 3840
mpp[2887]: mpp_buf_slot: mismatch size_total 13063680 - 16588800
WARNING No volume control found
WARNING debug information: ../gst/playback/gstplaysink.c(2908): gen_audio_chain (): /GstPlayBin:playbin/GstPlaySink:playsink:
Volume/mute is not available
Redistribute latency...
Redistribute latency...
[  931.560710] [drm:vop_plane_atomic_check] *ERROR* Invalid source: 3840x2160. max input: 1920x1920
Redistribute latency...
0:00:07.3 / 0:03:28.8