MY-IMX6-EK200 Linux-4.1.15 Test Manual

来自明远智睿的wiki
跳转至: 导航搜索


Test Environment

  • Development board model:MYIMX6EK200-6Q-2G-16G
  • Kernel version:Linux-4.1.15
  • File system:L4115-fsl-image-qt5-myimx6a9.tar.bz2

Preparation before test

1)Please connect following the path of 《Linux fast boot manual》->“Linux fast boot” -> “device connection”.

2)Please boot following the path of 《Linux fast boot manual》->“Linux fast boot” -> “device booting”.

Test item

Network inferface test

MY-IMX6-EK200 support two 100 Mbps ethernet interfaces.

Interface property

Eth0 Interface position:P4 Eth1 Interface position:P3

Test method

1)Configure computer IP
Set wired network card IP of computer as 192.168.137.99

2)Eth0 connect test
Connect lan line: connect “eth0”on evaluation board with corresponding wired network card interface on computer with lan line.
Note: check jumper cap to ensure it is attached.

  • Set evaluation board IP:
# ifconfig eth0 192.168.137.81
  • Execute test command:
# ifconfig eth1 down 
# ping 192.168.137.99 -c 2 -w 4 
  • Observe test result:system will output message like following:
  
PING 192.168.137.99 (192.168.137.99) 56(84) bytes of data.
64 bytes from 192.168.137.99: icmp_seq=1 ttl=128 time=0.811 ms
64 bytes from 192.168.137.99: icmp_seq=2 ttl=128 time=0.324 ms

--- 192.168.137.99 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 999ms
rtt min/avg/max/mdev = 0.324/0.567/0.811/0.244 ms
  • Test result:“0% packet loss”represent test passing.

3)Eth1 connect test
Connect lan line: connect “eth1”on evaluation board with corresponding wired network card interface on computer with lan line.
Note: check jumper cap to ensure it is attached.

  • Set the second network port IP:
# ifconfig eth1 192.168.137.82 
  • After setting, the system will output the working status information of the second network port:
fec 20b4000.ethernet eth1: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=20b4000.ethernet:01, irq=-1)
IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
fec 20b4000.ethernet eth1: Link is Up - 100Mbps/Full - flow control rx/tx
IPv6: ADDRCONF(NETDEV_CHANGE): eth1: link becomes ready 
  • Execute test command:
# ifconfig eth0 down
# ping 192.168.137.99 -c 2 -w 4 
  • Observe test result:system will output message like following:
  
PING 192.168.137.99 (192.168.137.99) 56(84) bytes of data.
64 bytes from 192.168.137.99: icmp_seq=1 ttl=128 time=1.54 ms
64 bytes from 192.168.137.99: icmp_seq=2 ttl=128 time=4.03 ms

--- 192.168.137.99 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 1.546/2.792/4.039/1.247 ms
  • Test result:“0% packet loss”represent test passing.

USB Test

Interface property

Interface position:J13 Insert USB device into USB port on base board,system will output message like following:

usb 1-1.2: new high-speed USB device number 5 using ci_hdrc
usb-storage 1-1.2:1.0: USB Mass Storage device detected
scsi host1: usb-storage 1-1.2:1.0
scsi 1:0:0:0: Direct-Access     TOSHIBA  TransMemory      1.00 PQ: 0 ANSI: 4
sd 1:0:0:0: [sda] 15148608 512-byte logical blocks: (7.75 GB/7.22 GiB)
sd 1:0:0:0: [sda] Write Protect is off
sd 1:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
 sda: sda4
sd 1:0:0:0: [sda] Attached SCSI removable disk

2)Test over Take out USB device from base board,system will output message like following:

usb 1-1.2: USB disconnect, device number 5

SD card test

Interface property

Interface position:J25 1)Start test
Insert the equipment into the card slot, and insert the card into the card interface on the card board.
Enter the following command:

# mmcblk2: mmc2:1234 SA02G 1.83 GiB 
# mmcblk2:
  • Pop-up SD card The system will output the following information:
mmc2: card 1234 removed

Standard GPIO testing

Interface property

Interface position : EIM_A25__GPIO5_IO02 J7:4
EIM_D23__GPIO3_IO23 J1:12
EIM_D28__GPIO3_IO28 J1:8
EIM_D29__GPIO3_IO29 J1:10
EIM_D30__GPIO3_IO30 J21:12
SD1_CLK__GPIO1_IO20 J4:8
SD1_DAT0__GPIO1_IO16 J14:18
SD2_CMD__GPIO1_IO11 J4:13
SD2_CLK__GPIO1_IO10 J4:7
SD2_DAT0__GPIO1_IO15 J4:3
SD2_DAT1__GPIO1_IO14 J4:5
SD2_DAT2__GPIO1_IO13 J4:9
SD2_DAT3__GPIO1_IO12 J4:11
SD3_DAT5__GPIO7_IO00 J21:11
GPIO_19__GPIO4_IO05 J7:3

Enter the following command:

# OUT_IO_NUMBER=85
# echo ${OUT_IO_NUMBER} > /sys/class/gpio/export
# echo out > /sys/class/gpio/gpio${OUT_IO_NUMBER}/direction
# echo 0 > /sys/class/gpio/gpio${OUT_IO_NUMBER}/value
# echo 1 > /sys/class/gpio/gpio${OUT_IO_NUMBER}/value

GPIO-LED test

led-heartbeat

Note: led-heartbeat is connected to D8, and you can see D8 flickering regularly after the system is started.

led-timer

Note: led-timer connected to D9, the system can be started after the D9 in a regular flashing.

  • Change the time that led-timer (D9) goes out
# echo 1000 > /sys/class/leds/led-timer/delay_off  
  • Change the led-timer (D9) lighting time
# echo 2000 > /sys/class/leds/led-timer/delay_on  
led-default
  • The led - the default (D7)
echo 0 > /sys/class/leds/default/brightness  
  • Keep led-default (D7) on
echo 1 > /sys/class/leds/default/brightness  
led-gpio
  • The led - gpio (D10)
echo 0 > /sys/class/leds/gpio/brightness  
  • Keep led-gpio (D10) on
echo 1 > /sys/class/leds/gpio/brightness  

GPIO-KEY test

  • Run evtest to prepare the test
# evtest 

No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0:  WM8962 Beep Generator
/dev/input/event1:  gpio-keys
Select the device event number [0-1]:
  • Select the serial number corresponding to gpio-keys
Select the device event number [0-1]: 1

Input driver version is 1.0.1
Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100
Input device name: "gpio-keys"
Supported events:
  Event type 0 (EV_SYN)
  Event type 1 (EV_KEY)
    Event code 114 (KEY_VOLUMEDOWN)
    Event code 115 (KEY_VOLUMEUP)
    Event code 116 (KEY_POWER)
Properties:
Testing ... (interrupt to exit)
  • Push the buttons on the development board,The system is shown below:
Event: time 1537921332.815219, type 1 (EV_KEY), code 114 (KEY_VOLUMEDOWN), value 1
Event: time 1537921332.815219, -------------- SYN_REPORT ------------
Event: time 1537921332.985211, type 1 (EV_KEY), code 114 (KEY_VOLUMEDOWN), value 0
Event: time 1537921332.985211, -------------- SYN_REPORT ------------
Event: time 1537921335.355204, type 1 (EV_KEY), code 115 (KEY_VOLUMEUP), value 1
Event: time 1537921335.355204, -------------- SYN_REPORT ------------
Event: time 1537921335.535203, type 1 (EV_KEY), code 115 (KEY_VOLUMEUP), value 0
Event: time 1537921335.535203, -------------- SYN_REPORT ------------
Event: time 1537921337.375207, type 1 (EV_KEY), code 116 (KEY_POWER), value 1
Event: time 1537921337.375207, -------------- SYN_REPORT ------------
Event: time 1537921337.535204, type 1 (EV_KEY), code 116 (KEY_POWER), value 0
Event: time 1537921337.535204, -------------- SYN_REPORT ------------

Serial port test

Test instruction: adopt the test of serial port.

UART2

Interface property

  • Interface position J1:7,9
  • Device:/dev/ttymxc1
    1)Test preparation Send and receive pin of short serial port 2 (pin no. 7 and no. 9 of J1). 2)Test conducted
    Enter the following command:
# /my-demo/linux-4.1.15/MY_SERIAL_TEST_L4115_MYIMX6A9.out /dev/ttymxc1 "www.myzr.com.cn"  

The system will output similar information:

Welcome to TTYtest  
  
Send test data------www.myzr.com.cn  
read char is w   
read char is w   
read char is w   
read char is .   
read char is m   
read char is y   
read char is z   
read char is r   
read char is .   
read char is c   
read char is o   
read char is m   
read char is .   
read char is c   
read char is n   
Read Test Data finished,Read Test Data is-------www.myzr.com.cn  
UART3

Interface property

  • Interface position J1:11,13
  • Device: /dev/ttymxc2
  • Test conducted
    Enter the following command:
# /my-demo/linux-4.1.15/MY_SERIAL_TEST_L4115_MYIMX6A9.out /dev/ttymxc2"www.myzr.com.cn"

The system will output similar information:

  
Welcome to TTYtest  
  
Send test data------www.myzr.com.cn  
read char is w   
read char is w   
read char is w   
read char is .   
read char is m   
read char is y   
read char is z   
read char is r   
read char is .   
read char is c   
read char is o   
read char is m   
read char is .   
read char is c   
read char is n   
Read Test Data finished,Read Test Data is-------www.myzr.com.cn  
UART4
  • Interface position J1:15,17
  • Device: /dev/ttymxc3
  • Test conducted
    Enter the following command:
# /my-demo/linux-4.1.15/MY_SERIAL_TEST_L4115_MYIMX6A9.out /dev/ttymxc3 "www.myzr.com.cn"  

The system will output similar information:

  
Welcome to TTYtest  
  
Send test data------www.myzr.com.cn  
read char is w   
read char is w   
read char is w   
read char is .   
read char is m   
read char is y   
read char is z   
read char is r   
read char is .   
read char is c   
read char is o   
read char is m   
read char is .   
read char is c   
read char is n   
Read Test Data finished,Read Test Data is-------www.myzr.com.cn  
UART5
  • Interface position J1:16,18
  • Device: /dev/ttymxc4
  • Test conducted
# /my-demo/linux-4.1.15/MY_SERIAL_TEST_L4115_MYIMX6A9.out /dev/ttymxc4 "www.myzr.com.cn"  
  
Welcome to TTYtest  
  
Send test data------www.myzr.com.cn  
read char is w   
read char is w   
read char is w   
read char is .   
read char is m   
read char is y   
read char is z   
read char is r   
read char is .   
read char is c   
read char is o   
read char is m   
read char is .   
read char is c   
read char is n   
Read Test Data finished,Read Test Data is-------www.myzr.com.cn  

CAN Test

  • Test preparation Connect CAN_L of CAN1 to CAN_L of CAN2;Connect CAN_H of CAN1 to CAN_H of CAN2.
  • Configure CAN1 (can0)
# ip link set can0 up type can bitrate 125000
  • Configure CAN2 (can1)
# ip link set can1 up type can bitrate 125000
  • CAN1 (can0) background reception
# candump can0 &
  • CAN2 (can1) sending data
# cansend can1 1F334455#1122334455667788

SPI Test

ECSPI1 Test
  • Interface position :J7:7,9
  • Test Device:/dev/spidev0.1
  • Enter the following command :
# /my-demo/linux-4.1.15/MY_SPIDEV_TEST_L4115_MYIMX6A9.out -D /dev/spidev0.0   
  
spi mode: 0  
bits per word: 8  
max speed: 500000 Hz (500 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   
ECSPI2 Test
  • Interface position : J7: 8,10
  • Device:/dev/spidev1.0
  • Test instruction
# /my-demo/linux-4.1.15/MY_SPIDEV_TEST_L4115_MYIMX6A9.out -D /dev/spidev1.0   
  
spi mode: 0  
bits per word: 8  
max speed: 500000 Hz (500 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  

Watchdog Test

Timeout reset test
# /unit_tests/wdt_driver_test.out 10 15 1  
  
Starting wdt_driver (timeout: 10, sleep: 15, test: write)
Trying to set timeout value=10 seconds
The actual timeout was set to 10 seconds
Now reading back -- The timeout is 10 seconds


U-Boot 2016.03-svn270 (Oct 09 2018 - 14:44:15 +0800)

CPU:   Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz)
CPU:   Extended Commercial temperature grade (-20C to 105C) at 45C
Reset cause: WDOG
Board: MYZR i.MX6 Evaluation Kit
Feed the dog test
# /unit_tests/wdt_driver_test.out 4 2 1 &  
  
[1] 748
Starting wdt_driver (timeout: 4, sleep: 2, test: write)
Trying to set timeout value=4 seconds
The actual timeout was set to 4 seconds
Now reading back -- The timeout is 4 seconds

RTC test

  • View the current system clock
# date  
  
Wed Sep 26 00:27:45 UTC 2018
  • View the current RTC chip clock
# hwclock   
  
Wed Sep 26 00:28:01 2018  0.000000 seconds 
  • Set the system clock and synchronize to the RTC chip
# date -s "2018-09-21 12:34:56"  
  
Fri Sep 21 12:34:56 UTC 2018  
  • Writes the system clock to the hardware clock
# hwclock -w  
  • Power outage restart panel
  • View the current system clock
# date  
  
Fri Sep 21 12:36:11 UTC 2018  
  • View the current RTC chip clock
# hwclock  
  
Fri Sep 21 12:36:16 2018  0.000000 seconds  

Timed wake-up test

  • Set to wake up event 10 seconds later
# echo +10 > /sys/class/rtc/rtc1/wakealarm 
  • Gear in
# echo mem > /sys/power/state
  • Sleep information
PM: Syncing filesystems ... done.
Freezing user space processes ... (elapsed 0.001 seconds) done.
Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
Suspending console(s) (use no_console_suspend to debug)
PM: suspend of devices complete after 59.213 msecs
PM: suspend devices took 0.060 seconds
PM: late suspend of devices complete after 1.004 msecs
PM: noirq suspend of devices complete after 1.031 msecs
Disabling non-boot CPUs ...
CPU1: shutdown
CPU2: shutdown
CPU3: shutdown
Enabling non-boot CPUs ...
CPU1 is up
CPU2 is up
CPU3 is up
PM: noirq resume of devices complete after 1.138 msecs
PM: early resume of devices complete after 1.136 msecs
PM: resume of devices complete after 116.878 msecs
PM: resume devices took 0.120 seconds
Restarting tasks ... done.
  • Wake up the information
(elapsed 0.012 seconds) done.
PM: suspend of devices complete after 693.963 msecs
PM: suspend devices took 0.700 seconds
PM: late suspend of devices complete after 2.419 msecs
PM: noirq suspend of devices complete after 2.303 msecs
Disabling non-boot CPUs ...
PM: noirq resume of devices complete after 1.402 msecs
PM: early resume of devices complete after 1.476 msecs
PM: resume of devices complete after 121.763 msecs
PM: resume devices took 0.130 seconds
Restarting tasks ... done.

Audio test

Play Audio
# aplay /unit_tests/audio8k16S.wav   
  
Playing WAVE '/unit_tests/audio8k16S.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Stereo
Audio Recorder
  • record
# arecord -d 5 -f S16_LE -t wav foobar.wav  
  • Play recording
# aplay foobar.wav  

Display (optional) test

  • Special notes:
When  u-boot  version u-boot-2016.03 svn315 and above
      Kernel  version Linux -3.0.35 svn31 and above
                      Linux -3.14.52 svn369 and above
                      Linux -3.14.52 svn368 and above
      Burning tool MfgTool-MYIMX6A9-L* svn181 and above 

Please refer to 《[MY-IMX6-A9 series: display functional tests》my-imx6-a9 series: display function test for testing

  • In general, it is tested as follows:

During the system startup, you can see the Linux penguin and OpenEmbedded startup scene.

Display configuration test

Instructions: for each display function test, reboot the system to enter the u-boot command line, enter the command and press the confirmation key.

U-Boot 2016.03-svn270 (Oct 09 2018 - 14:44:15 +0800)

CPU:   Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz)
CPU:   Extended Commercial temperature grade (-20C to 105C) at 43C
Reset cause: POR
Board: MYZR i.MX6 Evaluation Kit
Model: MY-IMX6-EK200-6Q-2G
I2C:   ready
DRAM:  2 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
SF: Detected SST25VF016B with page size 256 Bytes, erase size 64 KiB, total 2 MiB
*** Warning - bad CRC, using default environment

No panel detected: default to MY-LVDS-WSVGA
Display: MY-LVDS-WSVGA (1024x600)
In:    serial
Out:   serial
Err:   serial
Net:   FEC [PRIME]
Normal Boot
Hit any key to stop autoboot:  0 
=> 
LVDS1 single screen
=> setenv display ${disp_fb0_lvds1}
=> saveenv; boot
LVDS0 single screen
=> setenv display ${disp_fb0_lvds0}
=> saveenv; boot
HDMI single screen
=> setenv display ${disp_fb0_hdmi}
=> saveenv; boot
RGB(LCD) single screen
=> setenv display ${disp_fb0_lcd}
=> saveenv; boot
LVDS1 + LVDS0 dual screen asynchronous display
=> setenv display ${disp_lvds_sync}
=> saveenv; boot
LVDS1 + LVDS0 dual screen asynchronous display
=> setenv display ${disp_lvds_sync}
=> saveenv; boot
LVDS1(main) + HDMI dual screen asynchronous display
=> setenv display ${disp_fb0_lvds1} ${disp_fb1_hdmi}
=> saveenv; boot
LVDS1(main) + RGB dual screen asynchronous display
=> setenv display ${disp_fb0_lvds1} ${disp_fb1_lcd}
=> saveenv; boot
LVDS0(main) + HDMI dual screen asynchronous display
=> setenv display ${disp_fb0_lvds0} ${disp_fb1_hdmi}
=> saveenv; boot
LVDS0(main) + RGB dual screen asynchronous display
=> setenv display ${disp_fb0_lvds0} ${disp_fb1_lcd}
=> saveenv; boot
HDMI(main) + LVDS1 dual screen asynchronous display
=> setenv display ${disp_fb0_hdmi} ${disp_fb0_lvds1}
=> saveenv; boot
HDMI(main) + LVDS0 dual screen asynchronous display
=> setenv display ${disp_fb0_hdmi} ${disp_fb0_lvds0}
=> saveenv; boot
Video plays the test
  • Set Linux environment variables
# export GSTL=gst-launch-1.0
# export PLAYBIN=playbin
# export GPLAY=gplay-1.0
# export GSTINSPECT=gst-inspect-1.0
# export MP4_FILE="/unit_tests/akiyo.mp4"
  • Play video to main display
# $GSTL $PLAYBIN uri=file://$MP4_FILE video-sink="imxv4l2sink device=/dev/video17"
  • Play the video to the second screen
# $GSTL $PLAYBIN uri=file://$MP4_FILE video-sink="imxv4l2sink device=/dev/video18"

4G Module EC20 (Optional) test

# /my-demo/linux-4.1.15/MY_EC20_QuectelCM_L4115_MYIMX6A9.out &

[1] 636
[10-01_14:02:10:616] WCDMA&LTE_QConnectManager_Linux&Android_V1.1.34
[10-01_14:02:10:617] /my-demo/linux-4.1.15/MY_EC20_QuectelCM_L4115_MYIMX6A7.out profile[1] = (null)/(null)/(null)/0, pincode = (null)
[10-01_14:02:10:619] Find /sys/bus/usb/devices/1-1.2 idVendor=2c7c idProduct=0125
[10-01_14:02:10:620] Find /sys/bus/usb/devices/1-1.2:1.4/net/eth2
[10-01_14:02:10:620] Find usbnet_adapter = eth2
[10-01_14:02:10:620] Find /sys/bus/usb/devices/1-1.2:1.4/GobiQMI/qcqmi2
[10-01_14:02:10:620] Find qmichannel = /dev/qcqmi2
[10-01_14:02:10:665] Get clientWDS = 7
[10-01_14:02:10:697] Get clientDMS = 8
[10-01_14:02:10:729] Get clientNAS = 9
[10-01_14:02:10:760] Get clientUIM = 10
[10-01_14:02:10:792] Get clientWDA = 11
[10-01_14:02:10:825] requestBaseBandVersion EC20CEFAR02A10M4G
[10-01_14:02:10:920] requestGetSIMStatus SIMStatus: SIM_READY
[10-01_14:02:10:953] requestGetProfile[1] cmnet///0
[10-01_14:02:10:985] requestRegistrationState2 MCC: 460, MNC: 0, PS: Attached, DataCap: LTE
[10-01_14:02:11:017] requestQueryDataCall IPv4ConnectionStatus: DISCONNECTED
[10-01_14:02:11:081] requestRegistrationState2 MCC: 460, MNC: 0, PS: Attached, DataCap: LTE
[10-01_14:02:11:144] requestSetupDataCall WdsConnectionIPv4Handle: 0x87779840
[10-01_14:02:11:241] requestQueryDataCall IPv4ConnectionStatus: CONNECTED
[10-01_14:02:11:274] ifconfig eth2 up
[10-01_14:02:11:305] busybox udhcpc -f -n -q -t 5 -i eth2
[10-01_14:02:11:321] udhcpc (v1.24.1) started
[10-01_14:02:11:433] Sending discover...
[10-01_14:02:11:493] Sending select for 10.127.206.63...
[10-01_14:02:11:552] Lease of 10.127.206.63 obtained, lease time 7200
[10-01_14:02:11:637] /etc/udhcpc.d/50default: Adding DNS 211.136.17.107
[10-01_14:02:11:638] /etc/udhcpc.d/50default: Adding DNS 211.136.20.203

4 - channel video acquisition module (optional) test

# EXEC_FILE=/my-demo/linux-4.1.15/MY_TW6865_DEMO_L4115_MYIMX6A9.out
# ${EXEC_FILE} -x 2 -ot 0 -ol 0 -ow 512 -oh 300 -m 2 &
# ${EXEC_FILE} -x 3 -ot 0 -ol 512 -ow 512 -oh 300 -m 2 &
# ${EXEC_FILE} -x 4 -ot 300 -ol 0 -ow 512 -oh 300 -m 2 &
# ${EXEC_FILE} -x 5 -ot 300 -ol 512 -ow 512 -oh 300 -m 2 &

--------------------------------------------------------------------------------  
* Looking forward to communicating with you for more functions and field applications.     
* ZhuHai MYZR Technology CO.,LTD.  
* Latest Update: 2018/10/08    
--------------------------------------------------------------------------------