Skip to main content

← Back to AOM-2521

AOM-2521 Yocto 5.2 User Guide

目錄 (Contents)​

    1. 產品官網連結 (Product Official Website Link)
    1. 快速入門 (Quick Start)
    • 2.1 系統下載 (OS Download)
    • 2.2 Switch 設定 (Switch Setting)
    • 2.3 Linux 燒錄方法 (Linux Flash eMMC Method)
    • 2.4 SD Card 開機方法 (SD Card Boot Method)
    1. Linux 系統的基本使用 (Linux System Basic Operating Method)
    • 3.1 顯示設定 (Display Setting)
    • 3.2 乙太網路使用方法 (Ethernet Testing Method)
    • 3.3 WiFi 使用方法 (WiFi Testing Method)
    • 3.4 4G 使用方法 (4G Testing Method)
    • 3.5 COM 埠複合使用方法 (COM Complex Port Operating Method)
    • 3.6 CANBus / CAN-FD
    • 3.7 藍牙使用方法 (Bluetooth Operating Method)
    • 3.8 音訊使用方法 (Audio Operating Method)
    • 3.9 I2C 測試 (I2C Test Method)
    • 3.10 攝像頭測試 (Camera Test Method)
    • 3.11 遠端存取及檔案傳輸 (Remote Access and File Transmission)
    • 3.12 SPI Bus 測試 (SPI Bus Test Method)
    • 3.13 儲存裝置測試 (Storage Test Method)
    • 3.14 USB 測試 (USB Test Method)
    1. 通用方法 (General Method)
    • 4.1 查看 CPU 溫度 (Check CPU Temperature)
    • 4.2 查看 CPU 頻率 (Check CPU Frequency)
    • 4.3 查看記憶體容量 (Check Memory Size)
    • 4.4 查看儲存容量 (Check Storage Size)
    • 4.5 網路 Ping 測試 (Network Ping Test)
    • 4.6 設置固定 IP 與 DNS (Set Static IP and DNS)
    • 4.7 設置 RTC (Set RTC)
    • 4.8 查看系統版本資訊 (Check System Version Information)

AOM-2521

2. 快速入門 (Quick Start)​

2.1 系統下載 (OS Download)​

請由以下連結下載作業系統映像檔。

Download the OS image from the link below.

2.2 Switch 設定 (Switch Setting)​

AOM-DB2300 載板上的 SW8(單段指撥開關)與 SW1(兩段指撥開關)共同決定開機來源與燒錄模式。

On the AOM-DB2300 carrier board, SW8 (a single-position DIP switch) and SW1 (a two-position DIP switch) together determine the boot source and the flashing mode.

> 注意:操作前請務必先斷電,撥動完成後再重新上電。

> Caution: always power off the board before changing the switches, then power on again after the setting is complete.

三種使用情境設定表 (Switch Settings by Use Case)​

撥動位置文字圖示 (Text Diagram of Lever Positions)​

情境一:UUU 燒錄模式 / Case 1: UUU flashing mode (Download Mode)

        SW8                    SW1
+-----------+ +------+------+ <- ON
| | | | # |
+-----------+ +------+------+
| # | | # | |
+-----------+ +------+------+
ON 1 2

SW8 = ON SW1-1 = OFF SW1-2 = ON

情境二:eMMC 開機 / Case 2: Boot from eMMC

        SW8                    SW1
+-----------+ +------+------+ <- ON
| | | # | |
+-----------+ +------+------+
| # | | | # |
+-----------+ +------+------+
ON 1 2

SW8 = ON SW1-1 = ON SW1-2 = OFF

情境三:SD Card 開機 / Case 3: Boot from SD card

        SW8                    SW1
+-----------+ +------+------+ <- ON
| # | | | |
+-----------+ +------+------+
| | | # | # |
+-----------+ +------+------+
ON 1 2

SW8 = OFF SW1-1 = OFF SW1-2 = OFF

> 注意:SW8 的 ON / OFF 方向請以載板實際絲印標示為準。

>

> Note: For SW8, always follow the ON / OFF marking silkscreened on the carrier board.

2.3 Linux 燒錄方法 (Linux Flash eMMC Method)​

透過 USB OTG 使用 NXP uuu 工具將映像檔燒錄至板載 eMMC。

Use the NXP uuu utility over USB OTG to flash the image to the onboard eMMC.

Step 1. 依上表將 SW8 切至 ON、SW1 設為 1-OFF / 2-OFF(UUU 燒錄模式)。

Set SW8 to ON and SW1 to 1-OFF / 2-OFF as listed above (UUU flashing mode).

Step 2. 以 USB Type-C 線連接載板 OTG 埠至 Host PC,接上電源。

Connect the carrier board OTG port to the host PC with a USB Type-C cable, then apply power.

Step 3. 於 Host PC 執行以下指令。

Run the following command on the host PC.

uuu -b emmc_all bootloader rootfs.sdcard

Step 4. 燒錄完成後斷電,將 SW1-1 切至 ON(eMMC 開機模式),重新上電即可由 eMMC 開機。

After flashing completes, power off, set SW1-1 to ON (eMMC boot mode), and power on again to boot from eMMC.

2.4 SD Card 開機方法 (SD Card Boot Method)​

Step 1. 於 Host PC 將映像檔寫入 SD Card。

Write the image to the SD card on the host PC.

sudo dd if=rootfs.sdcard of=/dev/sdX bs=1M conv=fsync status=progress
sync

Step 2. 斷電,將 SW8 切至 OFF、SW1 設為 1-OFF / 2-OFF。

Power off, set SW8 to OFF and SW1 to 1-OFF / 2-OFF.

Step 3. 插入 SD Card 後上電開機。

Insert the SD card and power on.

3. Linux 系統的基本使用 (Linux System Basic Operating Method)​

3.1 顯示設定 (Display Setting)​

AOM-2521 支援 HDMI、MIPI DSI、LVDS 三種顯示輸出,透過 U-Boot 切換 device tree 選擇顯示介面。

AOM-2521 supports three display outputs — HDMI, MIPI DSI and LVDS. Select the interface by switching the device tree in U-Boot.

U-Boot 指令 (U-Boot Command)​

setenv fdtfile <dtb_filename>
saveenv
reset

1. HDMI​

預設 dtb 即支援 HDMI 輸出,無須額外設定。驗證顯示器:VIEWSONIC VS15052。

HDMI output works with the default dtb; no extra configuration is needed. Verified monitor: VIEWSONIC VS15052.

2. MIPI DSI Panel​

使用 DSI1 接頭,需搭配 DSI 版本載板。Panel 型號:AUO G101UAN02。

Uses the DSI1 connector and requires the DSI version of the carrier board. Panel model: AUO G101UAN02.

setenv fdtfile imx95-aom2521-b0-auog101uan02.dtb
boot

2. LVDS Panel​

輸出至第一組 LVDS 螢幕。

Outputs to the first LVDS screen.

setenv fdtfile imx95-aom2521-b0-lvds0-auo.dtb
boot

3.2 乙太網路使用方法 (Ethernet Testing Method)​

AOM-DB2300 提供兩組 1G LAN(GBE0 / GBE1)。測試前請將 SW1 兩段全部切至 ON。

AOM-DB2300 provides two 1G LAN ports (GBE0 / GBE1). Set both SW1 positions to ON before testing.

基本連線測試 (Basic Connectivity Test)​

ifconfig eth0
ping google.com
ifconfig eth1
ping google.com

介面名稱以 enP1p5s0f0 為例,實際請以 ip link 查詢結果為準。

enP1p5s0f0 is used here as an example; check the actual interface name with ip link.

# 查詢目前連線速率 / Check the current link speed
ethtool enP1p5s0f0

# 切換至 1000M / 100M / 10M / Switch to 1000M, 100M or 10M
ethtool -s enP1p5s0f0 speed 1000 duplex full
ethtool -s enP1p5s0f0 speed 100 duplex full
ethtool -s enP1p5s0f0 speed 10 duplex full

3.3 WiFi 使用方法 (WiFi Testing Method)​

驗證模組:AIW-167(M.2 Key E 插槽)。

Verified module: AIW-167 (M.2 Key E slot).

Step 1. 於 U-Boot 切換至 SDIO device tree。

Switch to the SDIO device tree in U-Boot.

setenv fdtfile imx95-aom2521-b0-m2-sdio.dtb
boot

Step 2. 載入驅動。

Load the drivers.

modprobe moal mod_para=nxp/wifi_mod_para.conf
modprobe btnxpuart

Step 3. 連線至 AP。

Connect to an access point.

ifconfig mlan0 up
wpa_passphrase <SSID> <PASSWORD> > /tmp/wpa.conf && \
wpa_supplicant -d -B -i mlan0 -c /tmp/wpa.conf
udhcpc -b -i mlan0

3.4 4G 使用方法 (4G Testing Method)​

驗證模組:EWM-C401(M.2 Key B 插槽)。

Verified module: EWM-C401 (M.2 Key B slot).

# 註冊 USB serial 裝置 / Register the USB serial device
echo 2cb7 0110 > /sys/bus/usb-serial/drivers/option1/new_id
ls /dev/ttyUSB*

# 建立 PPP 撥號連線 / Establish the PPP dial-up connection
pppd /dev/ttyUSB2 115200 \
connect 'chat -v -s -t 30 \
"" "AT" \
"OK" "ATE0" \
"OK" "AT+CFUN=1" \
"OK" "AT+CGDCONT=1,\"IP\",\"internet\"" \
"OK" "ATD*99#" "CONNECT"' \
noauth defaultroute usepeerdns crtscts debug nodetach \
noccp novj novjccomp noipv6 ipcp-accept-local ipcp-accept-remote &

# 驗證連線 / Verify connectivity
ping 8.8.8.8

3.5 COM 埠複合使用方法 (COM Complex Port Operating Method)​

COM 埠對應關係如下。

The COM port mapping is as follows.

COM 埠 (COM Port)UART裝置節點 (Device Node)
COM A1UART1/dev/ttyLP4
COM B1UART3/dev/ttyLP5

RS-232​

stty -F /dev/ttyLP4 -echo -onlcr 115200
cat /dev/ttyLP4 &
echo "Serial Port Test" > /dev/ttyLP4

UART1 (COMA1): ttyLP4:  

UART3(COMB1)ttyLP5:

RS-485​

模式切換由 GPIO 控制(gpiochip5)。

The mode is selected through GPIO (gpiochip5).

ttyLP4 (COM A)

gpioset -c gpiochip5 4=1
gpioset -c gpiochip5 5=0

stty -F /dev/ttyLP4 speed 115200 ignbrk -brkint -icrnl -imaxbel \
-opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke
cat /dev/ttyLP4 &
echo "Serial Test" > /dev/ttyLP4

ttyLP5 (COM B)

gpioset -c gpiochip5 8=1
gpioset -c gpiochip5 9=0

stty -F /dev/ttyLP5 speed 115200 ignbrk -brkint -icrnl -imaxbel \
-opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke
cat /dev/ttyLP5 &
echo "Serial Test" > /dev/ttyLP5

RS-422​

ttyLP4 (COM A)

gpioset -c gpiochip5 4=1
gpioset -c gpiochip5 5=1

stty -F /dev/ttyLP4 speed 115200 ignbrk -brkint -icrnl -imaxbel \
-opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke
cat /dev/ttyLP4 &
echo "Serial Test" > /dev/ttyLP4

ttyLP5 (COM B)

gpioset -c gpiochip5 8=1
gpioset -c gpiochip5 9=1

stty -F /dev/ttyLP5 speed 115200 ignbrk -brkint -icrnl -imaxbel \
-opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke
cat /dev/ttyLP5 &
echo "Serial Test" > /dev/ttyLP5

RS-485 / RS-422 模式對照表 (Mode Reference Table)

埠 (Port)模式 (Mode)GPIO 設定 (GPIO Setting)
ttyLP4RS-485gpiochip5 4=1, 5=0
ttyLP4RS-422gpiochip5 4=1, 5=1
ttyLP5RS-485gpiochip5 8=1, 9=0
ttyLP5RS-422gpiochip5 8=1, 9=1

3.6 CANBus / CAN-FD​

標準 CAN (Standard CAN, 125 kbps)​

ip link set can0 up type can bitrate 125000
ifconfig can0 up
ip link set can1 up type can bitrate 125000
ifconfig can1 up

candump can0 &
cansend can1 1F334455#1122334455667788

CAN-FD (1 Mbps / 8 Mbps)​

ip link set can0 up type can bitrate 1000000 dbitrate 8000000 fd on
ip link set can1 up type can bitrate 1000000 dbitrate 8000000 fd on

candump can0 &
cansend can1 123##300112233445566778899aabbccddeeff

3.7 藍牙使用方法 (Bluetooth Operating Method)​

需先完成 3.3 節的 WiFi/BT 驅動載入(modprobe btnxpuart)。

The WiFi/BT drivers from section 3.3 must be loaded first (modprobe btnxpuart).

hciconfig hci0 up
bluetoothctl

進入 bluetoothctl 後執行以下指令。

Then run the following inside bluetoothctl.

discoverable on
pairable on
scan on
# 找到目標裝置後 / after the target device appears
scan off
pair <BD_ADDR>
connect <BD_ADDR>

3.8 音訊使用方法 (Audio Operating Method)​

音訊編解碼器 (Audio Codec):SGTL5000

確認音效卡 (Check the Sound Card)​

cat /proc/asound/cards

預期輸出 (Expected output):

 0 [sgtl5000      ]: fsl-asoc-card - sgtl5000
sgtl5000

HDMI Audio​

aplay -D plughw:0,0 LRMonoPhase4.wav

Line-Out / Speaker​

amixer -c 1 set Headphone 100%
amixer -c 1 set Lineout unmute
amixer -c 1 set Lineout 100%
aplay -D plughw:0,0 LRMonoPhase4.wav

Mic-In​

amixer -c 1 set Mic 100%
arecord -D plughw:0,0 -r 16000 -f S16_LE ./f-16000.wav
aplay -D plughw:0,0 f-16000.wav

3.9 I2C 測試 (I2C Test Method)​

列出可用的 I2C 介面。

List the available I2C buses.

i2cdetect -l

預期輸出 (Expected output):

匯流排 (Bus)位址 (Address)
i2c-144350000.i2c
i2c-242530000.i2c
i2c-342540000.i2c
i2c-6426d0000.i2c
i2c-7426e0000.i2c

EEPROM 讀寫驗證 (EEPROM Read/Write Verification)​

modprobe at24
echo "ADVANTECH" > test
dd if=test of=/sys/bus/i2c/devices/3-0050/eeprom
hexdump -C /sys/bus/i2c/devices/3-0050/eeprom -n 64

3.10 攝像頭測試 (Camera Test Method)​

驗證組合:AOM-DB2300 CSI → ROM-EG55 → OV5640 Camera(2 lane)

Verified chain: AOM-DB2300 CSI → ROM-EG55 → OV5640 camera (2 lane).

Media Pipeline 設定 (Media Pipeline Configuration)​

media-ctl -l "'ov5640 2-003c':0 ->'csidev-4ad30000.csi':0 [1]"
media-ctl -V "'ov5640 2-003c':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'csidev-4ad30000.csi':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'crossbar':2 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.0':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.2':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.3':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.4':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.5':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.6':0 [fmt: UYVY8_1X16/1920x1080 field:none]"
media-ctl -V "'mxc_isi.7':0 [fmt: UYVY8_1X16/1920x1080 field:none]"

即時預覽 (Live Preview)​

gst-launch-1.0 -v v4l2src device=/dev/video0 io-mode=mmap \
! "video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1" \
! imxvideoconvert_g2d ! queue ! waylandsink sync=false

3.11 遠端存取及檔案傳輸 (Remote Access and File Transmission)​

# SSH 遠端登入 / SSH remote login
ssh root@<device_ip>

# 檔案傳輸 / File transfer
scp <local_file> root@<device_ip>:/home/root/
scp root@<device_ip>:/home/root/<remote_file> ./

3.12 SPI Bus 測試 (SPI Bus Test Method)​

於 SPI NOR Flash 起始位址寫入並驗證資料。

Write data to the start address of the SPI NOR flash and verify it.

> 注意:執行前請確認 SPI NOR Flash 內容已清除。

> Note: make sure the SPI NOR flash has been erased before running this test.

echo -n $'\x06\x05\x04\x03\x02\x01' > test
dd if=test of=/dev/mtdblock0
hexdump -C /dev/mtdblock0 -n 64

3.13 儲存裝置測試 (Storage Test Method)​

SD Card​

fdisk -l

eMMC​

板載 eMMC 容量 16 GB,裝置節點為 mmcblk0。

The onboard eMMC is 16 GB and appears as mmcblk0.

lsblk -d -o NAME,SIZE,TYPE,MODEL

3.14 USB 測試 (USB Test Method)​

AOM-DB2300 提供 USB 2.0 Type-A x2(上/下層)及 USB OTG x1。

AOM-DB2300 provides two USB 2.0 Type-A ports (upper / lower) and one USB OTG port.

裝置偵測 (Device Detection)​

lsusb
dmesg | tail

讀寫驗證 (Read/Write Verification)​

以 /dev/sda1(上層)或 /dev/sdb1(下層)為例。

Using /dev/sda1 (upper) or /dev/sdb1 (lower) as an example.

mount /dev/sda1 /mnt
md5sum NXPAI123.mp4
cp NXPAI123.mp4 /mnt/
sync
md5sum /mnt/NXPAI123.mp4

比對兩次 md5sum 結果應完全一致。

The two md5sum values must match exactly.

USB OTG​

USB OTG 埠用於 uuu 燒錄,詳見 2.3 節。

The USB OTG port is used for uuu flashing; see section 2.3.

4. 通用方法 (General Method)​

4.1 查看 CPU 溫度 (Check CPU Temperature)​

cat /sys/class/thermal/thermal_zone0/temp

4.2 查看 CPU 頻率 (Check CPU Frequency)​

lscpu
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq

4.3 查看記憶體容量 (Check Memory Size)​

free -h

4.4 查看儲存容量 (Check Storage Size)​

lsblk -d -o NAME,SIZE,TYPE,MODEL
df -h

4.5 網路 Ping 測試 (Network Ping Test)​

ping 8.8.8.8
ping google.com

4.6 設置固定 IP 與 DNS (Set Static IP and DNS)​

ifconfig eth0 192.168.1.100 netmask 255.255.255.0 up
route add default gw 192.168.1.1
echo "nameserver 8.8.8.8" > /etc/resolv.conf

4.7 設置 RTC (Set RTC)​

AOM-2521 的外部 RTC 節點為 /dev/rtc1。

The external RTC of AOM-2521 is exposed as /dev/rtc1.

# 先停用網路校時,避免覆寫 / Disable network time sync first to avoid being overwritten
systemctl stop systemd-timesyncd
systemctl disable systemd-timesyncd

# 設定系統時間並寫入 RTC / Set the system time and write it to the RTC
date -s "2026-02-25 11:30:00"
hwclock -w -f /dev/rtc1

# 故意改錯系統時間後,讀回 RTC 驗證 / Deliberately set a wrong time, then read the RTC back
date -s "2000-01-01 00:00:00"
hwclock -r -f /dev/rtc1

# 由 RTC 還原系統時間 / Restore the system time from the RTC
hwclock -s -f /dev/rtc1
date

4.8 查看系統版本資訊 (Check System Version Information)​

cat /etc/os-release
uname -a
cat /etc/OEMInfo.ini

Linux BSP編譯方法(Linux BSP Compile Method)​

tip

完整的 BSP 編譯步驟請參考對應 OS 版本的 README:NXP Yocto 5.2 BSP